Can't visualize PolyData with Java

Rene Tschirley pooh at cs.tu-berlin.de
Thu May 25 06:09:11 EDT 2000


Dear all,


I'm close to desperation. :) With my first steps with vtkJava, I thought
it would be easy to read a file with vertices and triangles, create a
vtkpolyData object (calles surface) and feed all the vertex triangle data
to the PolyData and visualize it.

Now, I can read the file correctly and feed the data to the PolyData:

1. I create a vtkPoints object and feed it with InsertNextPoint()
2. I create a vtkCellArray object and feed it with InsertNextCell() and
   InsertCellPoint().
3. I create the vtkPolyData object (surface), set the vertex data with
   SetPoints() to my vtkPoints object and set the triangle data with
   SetPolys().
4. Some debug output indicates the following:
   - GetNumberOfCells() returns apriximately the correct number of
     Vertices.
   - GetMaxCellSize() returns the correct cell size of 3.
   - GetBounds() returns quite exactly the bounds of my object.

All seems perfect. The only trouble is -- I can't see my object. Before
you ask, yes my rendering pipeline is ok. For testing, I added a second
actor showing the result of a vtkOutlineFilter from my surface. I even
added a primitive triangle by hand (using vtkPoints, vtkCellArray and
vtkPolyData). The bounding box and the simple triangle are shown as
expected, but not the surface.

Does anyone have an idea what went wrong?


Bye,
	René

-- 
Dipl.-Inform. René Tschirley,              http://cg.cs.tu-berlin.de/~pooh
TU Berlin, Computer Graphics and Computer Assisted Medicine research group
--------------------------------------------------------------------
This is the private VTK discussion list. Please keep messages on-topic.
Check the FAQ at: <http://public.kitware.com/cgi-bin/vtkfaq>
To UNSUBSCRIBE, send message body containing "unsubscribe vtkusers" to
<majordomo at public.kitware.com>. For help, send message body containing
"info vtkusers" to the same address.
--------------------------------------------------------------------



More information about the vtkusers mailing list