[vtkusers] Overriding RequestData() (Ellipsoid source)
David Doria
daviddoria+vtk at gmail.com
Mon Oct 12 11:39:37 EDT 2009
On Mon, Oct 12, 2009 at 7:43 AM, Jérôme <jerome.velut at gmail.com> wrote:
> Hi,
> I quickly gave a watch. Since your class derives from vtkSphereSource, your
> vtkTypeRevisionMacro should do the same:
> vtkTypeRevisionMacro( vtkEllipsoidSource, vtkSphereSource );
>
> If it does'nt, your filter 'tells' that it is -in the oo sense- a
> vtkPolyDataAlgorithm, but not a vtkSphereSource. So you have conflict
> between pure C++ and VTK object approach.
> - C++ : vtkEllipsoidSource derives from vtkSphereSource, the compiler stays
> quiet.
> - VTK : vtkEllipsoidSource "IsA" vtkPolyDataAlgorithm. The error seems to
> deal with the differences between vtkSphereSource and vtkPolyDataAlgorithm.
> Especially, Execute is an old method that certainly exists in
> vtkSphereSource -old old source-, but *maybe* not, or in
> vtkPolyDataAlgorithm that comes from vtk-5.x design.
>
> For the RequestInformation redefinition in your class, I really don't know.
> I effectively implement it when I need to pre-define some parameters. In
> your case, It could be the EllipsoidTransform member's parameters set...
>
> HTH,
> Jerome
>
Thanks a lot Jerome - that was exactly the problem.
Thanks,
David
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20091012/459c9588/attachment.htm>
More information about the vtkusers
mailing list