[Paraview] casting vtkPointData* to double*
Natalie Happenhofer
nataliehapp at hotmail.com
Thu Sep 4 03:23:36 EDT 2008
Hi!
I´m writing a filter and I want to perform arithmetic operations, i.e. "+=" with the scalar data associated to each point of my grid. So I get the Point Data from the input file:
void vtkHorizontalAverage::Execute()
{vtkStructuredGrid *input = this->GetInput();
vtkStructuredGrid *output = this->GetOutput();
vtkPointData *inPtr = input->GetPointData();
vtkPointData *outPtr = output->GetPointData();
...
here and now I want to apply the += operator, but I have no idea how to cast my vtkPointData - object, since I do not really know where to fit the cast operator in, to the vtkPointData class or to the vtkDataArray..
I could also use a reinterpretcast, but I´m not sure if the format of the data in vtkPointData is double or float..
So, any help would be apreciated!
thx,
NH
_________________________________________________________________
Express yourself instantly with MSN Messenger! Download today it's FREE!
http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.paraview.org/pipermail/paraview/attachments/20080904/8d6c9a5b/attachment.htm>
More information about the ParaView
mailing list