+// -------------------------------------------------------------------------
+void cpExtensions::Visualization::ImageBlender::
+ThreadedRequestData(
+ vtkInformation* request,
+ vtkInformationVector** inputVector,
+ vtkInformationVector* outputVector,
+ vtkImageData*** inData, vtkImageData** outData,
+ int outExt[ 6 ], int id
+ )
+{
+ if( inData[ 0 ][ 0 ] == NULL )
+ {
+ vtkErrorMacro( << "Input " << 0 << " must be specified." );
+ return;
+
+ } // fi
+
+ int numInputs = this->GetNumberOfInputConnections( 0 );
+ int scalarType = inData[ 0 ][ 0 ]->GetScalarType( );
+ int numComp = inData[ 0 ][ 0 ]->GetNumberOfScalarComponents( );
+ for( int i = 1; i < numInputs; ++i )
+ {
+ int otherType = inData[ 0 ][ i ]->GetScalarType( );
+ int otherComp = inData[ 0 ][ i ]->GetNumberOfScalarComponents( );
+ if( otherType != scalarType || otherComp != numComp )
+ {
+ if( id == 0 )
+ vtkErrorMacro(
+ "ThreadedRequestData: Input " << i
+ << " has " << otherComp << " components of type "
+ << otherType << ", but input 0 has " << numComp
+ << " components of type " << scalarType
+ );
+ return;
+
+ } // fi
+
+ } // rof
+
+ switch( scalarType )
+ {
+ vtkTemplateMacro(
+ cpExtensions_Visualization_ImageBlender_Execute(
+ this, inData[ 0 ], numInputs, this->m_Ranges,
+ outData[ 0 ], outExt, id, static_cast< VTK_TT* >( 0 )
+ )
+ );
+ default:
+ if( id == 0 )
+ vtkErrorMacro( << "Execute: Unknown ScalarType" );
+ return;
+ } // hctiws
+}
+
+// -------------------------------------------------------------------------
+int cpExtensions::Visualization::ImageBlender::
+FillInputPortInformation( int i, vtkInformation* info )
+{
+ info->Set( vtkAlgorithm::INPUT_IS_REPEATABLE( ), 1 );
+ return( this->Superclass::FillInputPortInformation( i,info ) );
+}
+