[Paraview] Question about building reader plugin

Jacques Papper jacques.papper at gmail.com
Wed Apr 1 02:35:29 EDT 2009


Isn't your problem that you want a vtkImageAlgorithm and not a
vtkIamgeAlgorithm ???
Seems like a typo to me....

2009/4/1 shenyanwen <shenyanwen at gmail.com>

> Hello, everyone!
> I am trying to build my own reader into ParaView as a plugin. But after I
> put my source file and XML files and the CMakeLists file into the specific
> directory and I used CMake to build it. Then I open the sln file it created.
> I just choose ALL_BUILD and I ran to many errors like below:
>
> error C2504: 'vtkIamgeAlgorithm' : base class undefined
>  error C2440: 'static_cast' : cannot convert from 'vtkObjectBase *' to
> 'vtkSgnReader *'
> error C2440: 'return' : cannot convert from 'vtkSgnReader *' to
> 'vtkObjectBase *'
> 'GetDebug' : is not a member of 'vtkSgnReader'
> 'GetClassName' : is not a member of 'vtkSgnReader'
> .....
> .....
> error C2664: 'vtkIamgeAlgorithmCommand' : cannot convert parameter 2 from
> 'vtkSgnReader *' to 'vtkObjectBase *
>
> And here is my header file:
> #ifndef __vtkSgnReader_h_
> #define __vtkSgnReader_h_
>
> #include "vtkImageAlgorithm.h"
> #include "vtkSgn.h"               //Needed for read actual META_DATA
>
> class VTK_EXPORT vtkSgnReader : public vtkIamgeAlgorithm
> {
> public:
>     static vtkSgnReader* New();
>     vtkTypeRevisionMacro(vtkSgnReader, vtkImageAlgorithm);
>     void PrintSelf(ostream& os, vtkIndent indent);
>
>     vtkSetStringMacro( FileName );
>     vtkGetStringMacro( FileName );
>     virtual int ReadMetaData(vtkInformation* *outInfo);
> protected:
>     vtkSgnReader();
>     ~vtkSgnReader();
>
>     virtual int RequestData(vtkInformation *, vtkInformationVector **,
>                             vtkInformationVector *);
>     virtual int RequestInformation(vtkInformation *, vtkInformationVector
> **,
>                                    vtkInformationVector *);
>     virtual int FillOutputPortInformation(int, vtkInformation *);
> public:
>     vtkSgn sgnfile;
>     char *FileName;
>
> private:
>     vtkSgnReader(const vtkSgnReader&);      //Not implemented
>     void operator=(const vtkSgnReader&);   //Not implemented
> };
> #endif
>
> Plase help me . Thanks so much!
>
> --
> shenyanwen at gmail.com
> Mobile Phone:13476177952
> Tel: 027-87558144
>
> _______________________________________________
> 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
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.paraview.org/pipermail/paraview/attachments/20090401/7a042260/attachment.htm>


More information about the ParaView mailing list