Messed up mesh connectivity

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Messed up mesh connectivity

Budo Zindovic
Hello,

I'm trying to visualize triangular mesh (by using unstructured data) from a VTK file I've created. Contents of this file are as follows:

# vtk DataFile Version 3.0
Test data
ASCII

DATASET UNSTRUCTURED_GRID
POINTS 7 float
-174.0 -305.0 0.0
4538.0 135.0 0.0
43860.0 35730.0 0.0
18980.0 35780.0 0.0
298770.0 -109640.0 0.0
265940.0 141140.0 0.0
2342000.0 3887000.0 0.0

CELLS 8 24
3 7 4 6
3 7 6 5
3 6 4 3
3 6 3 5
3 5 2 1
3 5 3 2
3 4 2 3
3 4 1 2

CELL_TYPES 8
5
5
5
5
5
5
5
5

POINT_DATA 7
SCALARSĀ  float
LOOKUP_TABLE default
0.0
0.0
0.0
0.0
0.0
0.500000
0.0

The problem is that VTK displays mesh with triangles messed up. I've attached two images, one with correct and the other with messed up triangles (from VTK visualization engine).

Did anyone encounter this? If you have, how did you overcome this issue?

Budo Zindovic

_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the VTK FAQ at: http://www.vtk.org/Wiki/VTK_FAQ

Search the list archives at: http://markmail.org/search/?q=vtkusers

Follow this link to subscribe/unsubscribe:
https://public.kitware.com/mailman/listinfo/vtkusers

Mesh_Correct.jpg (78K) Download Attachment
Mesh_VTK.jpg (48K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Messed up mesh connectivity

Budo Zindovic
What a novice mistake. VTK indices start with 0 and not 1 as I thought.



--
Sent from: http://vtk.1045678.n5.nabble.com/VTK-Users-f1224199.html
_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the VTK FAQ at: http://www.vtk.org/Wiki/VTK_FAQ

Search the list archives at: http://markmail.org/search/?q=vtkusers

Follow this link to subscribe/unsubscribe:
https://public.kitware.com/mailman/listinfo/vtkusers