Dear all,

I am developing a plug-in for mitk 0.12.2 (with QT 3) using VTK-5.2.1 
and ITK-3.8.0.
In my program I render rather simple objects (most are spheres and 
cubes) but the number of the objects is quite high (about several 
hundreds).
Now, I encountered serious performance problems during data-loading and 
also during normal program running (as I often create and remove 
dynamically objects to be rendered).

A typical way how I create a object for rendering looks like this:
vtkSphereSource* sphere = vtkSphereSource::New();
CommonFunctionality::AddVtkMeshToDataTree(sphere->GetOutput(),
                                                   
this->GetDataTreeIterator(),
                                                   "node-name");

Running a profiler showed me that 
CommonFunctionality::AddVtkMeshToDataTree() is the bottleneck of my 
program.
I went with the profiler deeper into that function and it seems to me 
that a great chunk of the time is consumed by tree-operations like 
itk::TreeNode<>::ChildPosition() or 
itk::SmartPointer<itk::TreeNode<void<mitk::DataTreeNode> > 
 >::operator==<const void<mitk::DataTreeNode>*>(bool, 
mitk::DataTreeNode) const.

I am not sure whether I interpret this correctly. Is the problem really 
the high number of objects and the from this resulting data-tree 
handling-code?
Is there another (faster) way how I can create high number of objects?
I am not sure what AddVtkMeshToDataTree() exactly does. What are 
important criterias to increase its performance?

Many questions....hope you can help me with them :-)

Milad Sadinam



------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
mitk-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mitk-users

Reply via email to