Add vtkVectorText programmatically

Jeff_Zeyl
Thu, 25 Jan 2024 18:29:39 +0000
Development

I would like to engrave many text models onto a skin model, programmatically, based on a set of markup control point coordinates.

My current approach is to generate vtk.vtkVectorText models, set their location, and subtract the text and skin models. I have successfully loaded vtk model, but vtk.vtkVectorText doesn’t have a set center method (like some other vtk model types types) but rather position is set by a vtkActor. If I understand correctly, in Slicer vtkPolyDataActor and vtkPolyDataMapper are tied into Displayable Managers (Documentation/Nightly/Developers/DisplayableManagers - Slicer Wiki) but don’t see relevant methods to set position.

How can i set the position of a model vtkVectorText inside slicer, which would otherwise be controlled by vtkActor outside of the Slicer environment?

5 posts - 2 participants