Conversion Service Helper
WMD viewer
NodeJS scripts for converting models.
Helper supports:
.zip
archive with assembly and assembly root file name supplied as argument- following CAD formats:
.sldasm, .sldprt, .prt, .prt.1, .prt.2, .ifc, .ipt, .rvt, .stp, .step, .x_t, .catpart
To run helper:
- install NodeJS (version >= 10) and NPM (version >= 6)
- Create
credentials.json
with provided credentials cd helper
npm i
node app.js -i <PATH_TO_YOUR_MODEL_FILE> -r <ASSEMBLY_ROOT_FILE_PATH_IF_NEEDED>
- converted result will be put in
output
folder
$ node app.js -i "samples/Resort Homey059.rvt"
$ node app.js -i samples/chair.zip -r chair/Chair_Assem_Rotate_v1.iam
$ node app.js -i samples/RaspberryPI4.zip -r "assembly/Assembly Raspberry Pi 4 B.SLDASM"
Sandbox viewer to display converted models
To run viewer:
cd viewer
- put folder with converted
wmd
model toviewer/models
npx node-static -a 0.0.0.0
- Go to http://0.0.0.0:8080/?model=name-of-the-model-folder (replace "name-of-the-model-folder" with the name of the converted model folder).
IMPORTANT: All symbols in model name must be URL-encoded
example: http://0.0.0.0:8080/?model=chair