You can set the number of inputs to a filter in the constructor. Like this:

this->SetNumberOfInputPorts ( 2 );

Than in the RequestData you will have to do something like this:

vtkInformation *inInfo = inputVector[0]->GetInformationObject ( 0 );
  vtkInformation *sourceInfo = inputVector[1]->GetInformationObject ( 0 );
  vtkInformation *outInfo = outputVector->GetInformationObject ( 0 );

  // get the input and ouptut
  vtkDataSet *input = vtkDataSet::SafeDownCast (
                          inInfo->Get ( vtkDataObject::DATA_OBJECT() ) );
 
  vtkPolyData *source = vtkPolyData::SafeDownCast (
                        sourceInfo->Get ( vtkDataObject::DATA_OBJECT() ) );
 
 
  vtkPolyData *output = vtkPolyData::SafeDownCast (
                         outInfo->Get ( vtkDataObject::DATA_OBJECT() ) );


Gregory D Abram wrote:

Is there a way to drive a filter from two inputs? I'd like to derive a planar equation from one filter and use it to specify a cut plane slicing a the result from a different filter. Any pointers?

Greg


_______________________________________________ ParaView mailing list ParaView@paraview.org http://www.paraview.org/mailman/listinfo/paraview



_______________________________________________
ParaView mailing list
ParaView@paraview.org
http://www.paraview.org/mailman/listinfo/paraview

Reply via email to