[vtkusers] Creating Structured Point Set of Cells From 3D Matrix

William Pierce flaming_bee at hotmail.com
Sat Mar 7 07:37:23 EST 2009


I have a 3D matrix filled with double values which I want to put into a structured point set and then contour using a vtkContourFilter. I can't work out how to do this. The problem is, all the examples of isosurface extraction using a contour filter use a vtkReader or vtkVolumeReader to read in the data. I already have the data, in the form of a 3D matrix (indexed by i,j,k). I want to create a vtkStructuredPoints, and fill it with this cell data. The problem is, I can't work out how to fill it.


I want to do something like:


vtkStructuredPoints structuredPoints = new vtkStructuredPoints();

double value = dataMatrix.get(i,j,k);
structuredPoints.addCell(i,j,k, value);

 

Any help would be greatly appreciated,
Thanks,
Will Pierce

_________________________________________________________________
 25GB of FREE Online Storage – Find out more
http://clk.atdmt.com/UKM/go/134665320/direct/01/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20090307/c2ddd8d9/attachment.htm>


More information about the vtkusers mailing list