[vtkusers] LOOKUP_TABLE: Please, please, please help! Going Nuts!!!

Malcolm Drummond malcolm at geovision.co.za
Mon Mar 15 14:57:52 EST 2004


# vtk DataFile Version 3.0
test.vtk
Hi Andrew, you were almost there. Main thing was your lookup color - values
must be RGBA not just RGB. Also, I wouldn't include attribute info for
CELL_DATA if there isn't any. Try this ...

ASCII
DATASET POLYDATA
POINTS 8 float
0 0 0
0 0 1
1 0 0
1 0 1
1 1 0
1 1 1
0 1 0
0 1 1
POLYGONS 6 30
4 0 2 4 6
4 1 3 5 7
4 0 2 3 1
4 2 4 5 3
4 4 6 7 5
4 6 0 1 7
POINT_DATA 8
SCALARS scalars int 1
LOOKUP_TABLE colors
0 0 0 0 0 0 0 0
LOOKUP_TABLE colors 1
0 1 0 1

HTH
Malcolm

----- Original Message -----
From: "Andrew Wilford" <andrew at artwork.com>
To: <vtkusers at vtk.org>
Sent: Monday, March 15, 2004 8:49 PM
Subject: [vtkusers] LOOKUP_TABLE: Please, please, please help! Going Nuts!!!


> Hi,
>
> When I view this VTK file, I expect to see a green cube, but I do not!
>
> # vtk DataFile Version 3.0
> test.vtk
> ASCII
> DATASET POLYDATA
> POINTS 8 float
> 0 0 0
> 0 0 1
> 1 0 0
> 1 0 1
> 1 1 0
> 1 1 1
> 0 1 0
> 0 1 1
> POLYGONS 6 30
> 4 0 2 4 6
> 4 1 3 5 7
> 4 0 2 3 1
> 4 2 4 5 3
> 4 4 6 7 5
> 4 6 0 1 7
> CELL_DATA 6
> POINT_DATA 8
> SCALARS scalars int 1
> LOOKUP_TABLE colors
> 0 0 0 0 0 0 0 0
> LOOKUP_TABLE colors 1
> 0 1 0
>
> Do I need some special code other than just reading the file - I thought
> this was automatic!
>
> Regards,
> Andrew Wilford
>
> _______________________________________________
> This is the private VTK discussion list.
> Please keep messages on-topic. Check the FAQ at:
<http://public.kitware.com/cgi-bin/vtkfaq>
> Follow this link to subscribe/unsubscribe:
> http://www.vtk.org/mailman/listinfo/vtkusers
>




More information about the vtkusers mailing list