Hi Sandra,

starting with revision 27263, MITK has gained much better support for 
visualizing unstructured grids. If you are using the "ExtApp", you might 
want to use the new "org.mitk.gui.qt.ugvisualization" bundle (you have 
to switch it on via CMake).

See bug http://bugs.mitk.org/show_bug.cgi?id=5597 and 
http://bugs.mitk.org/show_bug.cgi?id=5876 for more information.

Your code below looks good and if you don't have special requirements, 
you don't need to look at UnstructuredGridVtkMapper3D and 
VtkPropRenderer. When you call node->SetData(grid) in step 2, the 
UnstructuredGridVtkMapper3D mapper is automatically used as the default 
mapper for your node. The mapper makes use of a couple of properties 
attached to your node which you can modify by code to render the grid in 
special ways. For a supported list of properties, have a look at 
mitk::UnstructuredGridVtkMapper3D::SetDefaultProperties(...).

If something is buggy, please provide feedback in the bugs above.

Best,

Sascha



On 11/01/2010 01:59 PM, Scherer, Sandra wrote:
> Hello all,
>
> is there anybody who has experience with the "UnstructuredGridVtkMapper3D". 
> When should I use it? I want to optimize the visualization pipeline for a 
> vtkUnstructuredGrid and now I´m using the following pipeline:
>
> 1.) Unstructured Grid erzeugen:
>       mitk::UnstructuredGrid::Pointer grid = mitk::UnstructuredGrid::New();
>       grid->SetVtkUnstructuredGrid(result->uGrid);  //grid = vtkMesh
>
> 2.) Data Node erzeugen:
>       mitk::DataNode::Pointer node = mitk::DataNode::New();
>       node->SetData(grid);
>
> 3.) Datastorage ansprechen
>       mitk::DataStorage::Pointer m_DataStorage = this->GetDataStorage();
>
> 4.) Node dem Data Storage hinzufügen:
>       m_DataStorage->Add(node);
>
> 5.) Rendering Manager
>       mitk::RenderingManager::GetInstance()->InitializeViews( 
> m_DataStorage->ComputeBoundingGeometry3D(m_DataStorage->GetAll()));
>
> Das Drahtgitter wird mit den Skalarwerten angezeigt. Bringt mir nun die 
> Verwendung von oben erwähntem Mapper irgenwelche Vorteile? Wann wird 
> VtkPropRenderer verwendet? Muss ich mich diesen Klassen widmen um auch etwas 
> mehr Flexibilität in der Darstellung der vtk-Daten zu haben (wireframe, 
> solid?)... Interaktion mit dem Modell?
>
> Mit bestem Gruß,
> Sandra
>
>
>
> ------------------------------------------------------------------------------
> Nokia and AT&T present the 2010 Calling All Innovators-North America contest
> Create new apps&  games for the Nokia N8 for consumers in  U.S. and Canada
> $10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing
> Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store
> http://p.sf.net/sfu/nokia-dev2dev
> _______________________________________________
> mitk-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/mitk-users
>    


------------------------------------------------------------------------------
The Next 800 Companies to Lead America's Growth: New Video Whitepaper

_______________________________________________
mitk-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mitk-users

Reply via email to