Search code examples
autodesk-forgeautodesk-viewer

Forge Viewer applyScaling not working for dwg model


We are trying to view a pair of 3D models in the Forge Viewer. One is an rvm file with a base unit of Meters. The second model is a .DWG file with a base unit of millimeters.

As we load each model we are specifying the following values (as described in this post: Loading models with different units into Forge viewer)

  • model 1 (rvm): applyScaling: 'm'
  • model 2 (dwg): applyScaling: 'mm'

For each model we are passing the desired baseUnit value to applyScaling during loadDocumentNode

However the scaling is not being applied to the second model. Is there something different we need to do to make this work correctly?


Solution

  • The applyScaling property should indicate the target units you want to apply (assuming that the loaded model contains information about the original units), so you'll most likely want to pass the same scaling ('m') to both models.