try this:
#include "vtkStructuredGrid.h"
#include "vtkRectilinearGrid.h"
vtkDataSet* ds = ...
vtkStructuredGrid* sg = vtkStructuredGrid::SafeDownCast(ds);
if (sg)
{
...
}
vtkRectilinearGrid* rg = vtkRectilinearGrid::SafeDownCast(ds);
if (rg)
{
...
}
etc.
Utkarsh
Natalie Happenhofer wrote:
Hi!
Is there any possibility to cast from vtkDataSet to vtkRectilinearGrid
or vtkStructuredGrid,....?
I´m writing a filter which should input vtkDataSet, it´s to say I have
RectilinearGrid, StructuredGrid and StructuredPoint files with which the
filter should work.
I need to extract the dimensions from these DataSets, i.e use
"GetDimensions(dims)" to implement my algorithm, so that´s why I´d need
the downcast..
or is there any other possibility to get the dimensions of the input
Dataset?
thx,
NH
------------------------------------------------------------------------
Express yourself instantly with MSN Messenger! MSN Messenger
<http://clk.atdmt.com/AVE/go/onm00200471ave/direct/01/>
------------------------------------------------------------------------
_______________________________________________
ParaView mailing list
[email protected]
http://www.paraview.org/mailman/listinfo/paraview
_______________________________________________
ParaView mailing list
[email protected]
http://www.paraview.org/mailman/listinfo/paraview