[Paraview] Design of Multiple Input Filter

Burlen Loring burlen.loring at gmail.com
Fri Jan 15 13:25:54 EST 2010


woops my bad! I guess I was thinking of chapter 11 & 13 in the VTK user 
guide...

Michael Jackson wrote:
> great. Thanks. I actually have the ParaView User Guide for ParaView 3, 
> could you point me in the general vicinity in the user guide where 
> this is explained? The index wasn't much help but I am probably not 
> looking up the correct terms.
>
> Thanks
> -- 
> Mike Jackson <www.bluequartz.net>
>
> On Jan 15, 2010, at 1:00 PM, burlen wrote:
>
>> It doesn't have to be be a composite data algorithm or operate on 
>> composite data. There are two options available without delving into 
>> composite data, 1) make multiple inputs, 2)  make a single input 
>> repeatable.
>>
>>
>> in option 1)
>>
>>   class vtkMyFilter : public vtkImageDataAlgorithm
>>   {
>>   ...
>>   };
>>
>>   vtkMyFilter::vtkMyFilter()
>>   {
>>   ...
>>   this->SetNumberOfInputPorts(3);
>>   }
>>
>>
>> or in option 2)
>>
>>   class vtkMyFilter : public vtkImageDataAlgorithm
>>   {
>>   ...
>>   };
>>
>>   vtkMyFilter::vtkMyFilter()
>>   {
>>   ...
>>   this->SetNumberOfInputPorts(1);
>>   }
>>
>>   int vtkMyFilter::FillInputPortInformation(int port, vtkInformation
>>   *info)
>>   {
>>   ...
>>   info->Set(vtkAlgorithm::INPUT_REQUIRED_DATA_TYPE(), "vtkImageData");
>>   info->Set(vtkAlgorithm::INPUT_IS_REPEATABLE(),1);
>>   }
>>
>> during request data in option 1) you get a vector of information 
>> objects each with one dataset, in 2) you get a vector of datasets in 
>> one information object. The UI differs in the way the inputs are 
>> selected, option 1) will be more clear that 3 are required.
>>
>> This is explained (much better) in the user guide along with 
>> composite data algorithm.
>>
>>
>> Michael Jackson wrote:
>>> I have an algorithm that needs to take 3 inputs. All three will be 
>>> vtkImageData objects using Floating point values. I was wondering, 
>>> before I even start anything, does the first data set in the 
>>> pipeline have to be a composite data set so if I apply the filter I 
>>> can assign specific "pieces" of the composite data set as inputs to 
>>> the filter I am designing? What would be an example of a filter that 
>>> takes multiple inputs that I could look at as an example?
>>>
>>> Thanks for any help.
>>> ___________________________________________________________
>>> Mike Jackson                      www.bluequartz.net
>>> Principal Software Engineer       mike.jackson at bluequartz.net
>>> BlueQuartz Software               Dayton, Ohio
>>>
>>>
>>> _______________________________________________
>>> Powered by www.kitware.com
>>>
>>> Visit other Kitware open-source projects at 
>>> http://www.kitware.com/opensource/opensource.html
>>>
>>> Please keep messages on-topic and check the ParaView Wiki at: 
>>> http://paraview.org/Wiki/ParaView
>>>
>>> Follow this link to subscribe/unsubscribe:
>>> http://www.paraview.org/mailman/listinfo/paraview
>>
>



More information about the ParaView mailing list