2

I am finding a way to pass my coordinates from 2D to 3D model. I am stuck with an issue where I have Line/Spine which has Start and End Point. I would like to know how can I get the Start and End point of that line which is been show in my model. also is there any way to replace that line with my custom line using geometry (i know how to do this in 3D viewer but not sure about 2d view) I have tried different approaches but seems like nothing is working for me here is the reference which I was trying to follow

Link

and below is the Line/Path, what I am looking for is geometry of this line or the path of this line so that I can extract vector3 point from where the line is traveling

here

Ronak Shetiya
  • 960
  • 6
  • 27

1 Answers1

0

If you are interested in parsing the contents of a 2D model in Forge Viewer, that is also possible, using a helper class called Autodesk.Viewing.Private.VertexBufferReader. It can iterate through all the "primitives" in a 2D drawing (lines, circular arcs, elliptical arcs, etc.) and call your custom code for each one of them. Here's a blog post that explains the usage of this class: https://forge.autodesk.com/blog/working-2d-and-3d-scenes-and-geometry-forge-viewer.

Petr Broz
  • 8,891
  • 2
  • 15
  • 24