[Paraview] plugin error: "Input for algorithm vtkPVPostFilter is of type ..., but a vtkPolyData is required"

corinna reuter corinnareuter75 at gmail.com
Mon Jul 4 09:09:07 EDT 2016


To anybody experienced in plugin programming:

I am trying to include items in the paraview tree, which are not derived
from vtkDataSet or vtkDataObject. For example, a mySQL database should be
allowed as a data source, which delivers data in an intermediate format.
Next I'd implement filters which take the intermediate format and produce
vtkDataSets as output.

Is it possible to use such "abstract" (not vtkDataSet) objects in the
paraview tree as a representation of the intermediate format? I have tried
to integrate the example for custom classes from
http://www.vtk.org/Wiki/VTK_Examples_vtkAlgorithm_Source into a paraview
plugin (CMakeLists and servermanager xml below). When the plugin is loaded
and I add a source of the new type AlgorithmSourceExample, this error is
thrown:

ERROR: In
/opt/ParaView-v5.0.1/VTK/Common/ExecutionModel/vtkDemandDrivenPipeline.cxx,
line 810
vtkPVPostFilterExecutive (0x3857810): Input for connection index 0 on input
port index 0 for algorithm vtkPVPostFilter(0x3858910) is of type vtkTest,
but a vtkPolyData is required.

What do I need to change such that the vtkTest objects, produced by
AlgorithmSourceExample, can live in the paraview tree?

Thank you
Corinna

CMakeLists.txt:

FIND_PACKAGE(ParaView REQUIRED)
INCLUDE(${PARAVIEW_USE_FILE})
#changes required in
http://www.vtk.org/Wiki/VTK_Examples_vtkAlgorithm_Source:
# remove vtkCxxRevisionMacro calls
# change vtkTypeRevisionMacro into vtkTypeMacro
# remove call output->SetPipelineInformation( outInfo );
 ADD_PARAVIEW_PLUGIN(
   AlgorithmSourceExample
  "1.0"
   SERVER_MANAGER_XML AlgorithmSourceExample.xml
   SERVER_MANAGER_SOURCES vtkTestSource.cxx vtkTest.cxx
 )

AlgorithmSourceExample.xml:

<ServerManagerConfiguration>
  <ProxyGroup name="sources">
   <SourceProxy name="AlgorithmSourceExample" class="vtkTestSource"
label="AlgorithmSourceExample">
     <Documentation
        long_help="AlgorithmSourceExample"
        short_help="AlgorithmSourceExample">
     </Documentation>
   </SourceProxy>
 </ProxyGroup>
</ServerManagerConfiguration>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/paraview/attachments/20160704/ebae8513/attachment.html>


More information about the ParaView mailing list