[vtkusers] How to convert (cast) "vtkExtractRectilinearGrid" data type to "vtkRectilinearGrid" type.

Cory Quammen cory.quammen at kitware.com
Fri Jul 17 06:45:51 EDT 2015


Manjunath,

vtkExtractRectilinearGrid is a vtkAlgorithm subclass - it read's data and
produces data - while vtkRectilinearGrid is a subclass of vtkDataObject -
it stores data. No conversion between the two is possible.

What you need to do is call vtkExtractRectilinearGrid::GetOutput() to get
the vtkRectilinearGrid. Make sure to call vtkExtractRectilinearGrid::Update()
before you call GetOutput() so that the output data is up-to-date.

Best regards,
Cory

On Fri, Jul 17, 2015 at 1:36 AM, Manjunath K E <ke.manjunath at gmail.com>
wrote:

> Hi,
>
> I am Manjunath, working on ocean visualization.
> I have generated certain volume of interest (VOI) using
> vtkExtractRectilinearGrid type. Now I would like to render
> vtkExtractRectilinearGrid as "vtkRectilinearGrid" type.
>
> I would like to know how to convert "vtkExtractRectilinearGrid" data type
> to "vtkRectilinearGrid" type.
>
>  Thanks and Regards,
>
>  Manjunath K E
>  Help Ever Hurt Never
>
>
> _______________________________________________
> 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 VTK FAQ at:
> http://www.vtk.org/Wiki/VTK_FAQ
>
> Search the list archives at: http://markmail.org/search/?q=vtkusers
>
> Follow this link to subscribe/unsubscribe:
> http://public.kitware.com/mailman/listinfo/vtkusers
>
>


-- 
Cory Quammen
R&D Engineer
Kitware, Inc.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/vtkusers/attachments/20150717/e5c02230/attachment.html>


More information about the vtkusers mailing list