Reputation: 83
Is it possible to get the real world coordinates form the original model in the Forge viewer? It looks like when a model is loaded into the Viewer it is placed with the center of the model in the origin of the Viewer.
Upvotes: 1
Views: 1297
Reputation: 4375
viewer.model.getData().globalOffset
is what you are looking for:
Aligning Coordinate Systems in Autodesk Forge Viewer
Upvotes: 2
Reputation: 8294
Afaik, the Forge viewer centres the model. In other words, the origin of the viewer coordinate system is the centroid of the model. The scale of the model remains unchanged. As a result, you can transform the original model coordinates to Forge viewer and vice versa simply by adding or subtracting the model centroid.
Upvotes: 0