yade-users team mailing list archive
-
yade-users team
-
Mailing list archive
-
Message #08719
[Question #240509]: Rendering problem of triangles
New question #240509 on Yade:
https://answers.launchpad.net/yade/+question/240509
Dear Yade-Dev,
I have problems with rendering of faces of my deformable tetrahedron class that I defined within yade. Within deformable tetrahedrons, each vertex is defined in a list and each face of the deformable tetrahedron also defined in another list including it's connected vertex indices. I create tetrahedrons by importing mesh from a gmsh file where its node numbering order is given in gmsh's manual.
When I try to give opengl the normal of each face with the calculating method given here[1] or even calculating it with the node numbering as given in the user manual of gmsh , I see the coloring difference of the tetrahedrons faces. My drawing function of the deformable elements can be found here[2].
So I want to ask; What may cause the difference of the colors of the faces of tetrahedron with the code given at[2]? Do you suggest a better way to draw a tetrahedron?
[1]http://math.stackexchange.com/questions/183030/given-a-tetrahedron-how-to-find-the-outward-surface-normals-for-each-side
[2]https://github.com/burak-er/trunk/blob/master/pkg/dem/deformablecohesive/Gl1_DeformableElement.cpp
--
You received this question notification because you are a member of
yade-users, which is an answer contact for Yade.