How can vtkCompositePolyDataMapper achive the effect of all data blocks facing the camera?

Hi VTK users,

I am trying to use vtkMultiBlockDataSet + vtkCompositePolyDataMapper to handle lots of dimension/tolerance labels (which has numbers, symbols and frames), but found that vtkFollower did not work correctly – it looks like that the follower treats all the data blocks as one, thus the labels do not move correctly when rotating the scene with mouse. Could anyone please help share some experience or hints on handling this issue? Should I customize a follower or a composite mapper? Or should I update the raw data based on the posture of the camera? How to do that? Please kindly teach me the guidlines. Thanks a lot!

About labeling the geometry parts’ dimension and tolerance, is there any suggestion? Thanks!

By the way, choosing vtkMultiBlockDataSet is aimed to handle thousands of labels with good interaction experience. Have tried using vtkVectorText + vtkPolyData + vtkFollower for each label.

Best regards,
Yongjin

Using the learnings from vtkFollower, I realized this follower effect through a callback function for the active camera’s Modified event – each block’s data is updated. By this way, 1000 labels like simple triangle (for testing) has a good frame rate. When the number of labels comes to 5000, the frame rate drops down to 17 fps – a little lag could be felt. With a SMP parallel handling in the callback, the fps can be somehow improved.

1 Like