Once the input 3D file has been prepared in the form of CDXWEB files, their contents can be loaded into the application as follows:
where:
theModelPath
is a url to the top CDXWEB directory (e.g. output/conrod.cdxweb
),theObjId
is a file in the CDXWEB directory (e.g. scenegraph.cdxweb
)cadex.ModelData_Model
is essentially an object which encapsulates 3D model in memory. This class corresponds to a C++ counterpart cadex::ModelData_Model class described in details in the CAD Exchanger SDK User’s Guide. So you might want to read that guide if you have not done so yet.
Refer to Model explorer example for a self-contained demonstration of the model loading and exploring with the help of Web Toolkit.