[Paraview-developers] How to add multiple inputs to a plugin (writer)

houssen houssen at ipgp.fr
Fri Jul 10 10:55:02 EDT 2015


I have a plugin (writer which inherit from vtkWriter) with :
- SetNumberOfInputPorts(1) in the constructor
- vtkDataObject* data=GetInput() to get data to save (when I am called 
back on the save button click)
This works OK.

How to save "all what is in the pipeline browser" ? Say I opened 2 
files : I have 2 sets of data to save in the pipeline browser. How to 
save the 2 data set ?
I tried :
- SetNumberOfInputPorts(GetNumberOfInputPorts()) in the constructor
- for (int p = 0; p < GetNumberOfInputPorts() ...) vtkDataObject* 
data=GetInput(p) to get data to save
But this doesn't work : seems I always get one data to save (whatever 
what is hidden/shown or highlighted in the pipeline browser when I click 
on the save button)

FH


More information about the Paraview-developers mailing list