[Paraview] How to create a c++ plugin using 2 filters (cell data to point data + streamtracer) ?

R M mlokida at yahoo.fr
Thu Dec 9 09:42:31 EST 2010


Hi,

I have some data that have velocities at cells data. I can use the 
CellDataToPointData filter and then apply the streamTracer filter.
But, I would like to have juste one filter doing this operation. From this 
filter, I would like to find in its GUI the same parameters as in StreamTracer 
and also select the vectors I want to display.
With the create custom filter it doesn't work because vectors combo box is 
empty. It is normals because CellDataToPointData has not been executed so 
streamTracer can't know that is has some vectors to add in the combo box.

So I write a C++ plugin that inherits from vtkStreamTracer but it is quite 
complicated. In fact, I have the same problem: the vectors are not displayed in 
the combo box. 


The input vector informations  parameters in RequestData has a 
vtkMultiBlockDataSet that contains geometries and velocities at cells data and 
the source for the streamtracer.
the output contains the vtkPolyData that will be generated by the streamTracer.

So, I have to call RequestData 's CellDataToPointData for each block (for that I 
create a new request, a new input vector and a new output vector). Then I create 
a new multiblockDataSet that contains geometry and velocities at point data.  
Then, I want to call RequestData 's StreamTracer but, it has no selected Vectors 
(velocity) on which doing the operation.

So where should I do the CellDataToPointData operation in my plugin in order to 
be sure that streamTracer can have a exposed vectors in the GUI.

I have tried in RequestDataObject (REQUEST_DATA_OBJECT request) but it doesn't 
work.

Any idea how to implement such a plugin ?

Thank you.



      
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.paraview.org/pipermail/paraview/attachments/20101209/670454d3/attachment-0001.htm>


More information about the ParaView mailing list