[vtkusers] Problems importing STL and VRML files to VTK

bdemin slavd88 at gmail.com
Wed Dec 5 12:08:12 EST 2018


I'm trying to import a CAD assembly from SolidWorks to VTK using vtkSTLReader
and vtkVRMLImporter in Python. From my understanding, these are the only 3D
formats VTK is able to read from SolidWorks.

Doing that, I encountered 2 issues:
1) When importing an STL part, is it possible to scale its size so that it
will fit my original SolidWorks part? After adding the actor of the STL
part, it seems to give the part an arbitrary origin and scale.

2) How can I import a VRML 3D model and assign an actor to it?
What I fail to understand is why the VRMLImporter is creating the renderer
without any artist involved. With vtkSTLReader or VTKSources (cube, cone,
etc) I assign their mappers to an actor for applying transformations or
other functions on the artists. With VRML there is no artist which
corresponds to the 3D object in all examples I've seen. How can I do that?



--
Sent from: http://vtk.1045678.n5.nabble.com/VTK-Users-f1224199.html


More information about the vtkusers mailing list