[vtkusers] Integrating VTK into a scene-graph based renderer?

Peter Ellsiepen peter.ellsiepen at gmx.de
Thu Sep 13 06:15:37 EDT 2001


Hello VTK-Users,

currently, I'm thinking of an efficient way to integrate the VTK 
visualization pipeline into a scene-graph based renderer. I found 
vtkActorToPF which pretty much does the job in case of IRIS Performer. 
However, each change in the visualization leads to a complete remove/add of 
the geometry object in the scene-graph (here: the geode node). This can be 
very time-consuming, especially when large datasets are handled leading to 
large geometric objects as output of the visualization pipeline (for example 
cutplanes, isosurfaces, meshes from finite element analyses).

As an example, you can think of a cutplane through a structured 
dataset where only the position is changed by interaction. In the case of 
vtkActorToPF, the complete geometry would be re-created for each new cutplane 
even though only a change of the vertex colors and vertex transformation is 
necessary, i.e. the topology stays constant. In most scene-graph based 
rendering APIs the "expensive" operations are topology changes while color 
and transformation changes are "cheap".

By reading the VTK Book and the VTK User's Guide I thought of the following 
alternative: Instead of creating the geometry inside VTK and then copying it 
to the scene-graph geometry node, it would be better to directly create and 
update the geometry inside the scene-graph. Then, on update, I could try to 
find out which aspects of the geometry really changed and thus update only 
the relevant parts. This leads to the following questions:

1.) Which is the right entry point in the VTK class hierarchy, i.e. which 
class would I extend by a derived class to connect to my scene-graph renderer?
More special: I need to know which object actually creates the geometric 
primitives such that I can directly create the primitives inside the geometry 
node of the scene-graph.

2.) How can I find out, which changes to the visualization object have 
occured due to the last update? (In the above example the task would be to 
find out if the topology is unchanged.)

3.) How does this extension fit into the VTK concept of the visualization 
pipeline, i.e. how and when do I "fire" the pipeline? (The obvious time would 
be just before the draw method of the renderer is called.)

Thanks in advance for any help on this topic,
Peter



More information about the vtkusers mailing list