Forum: Poser - OFFICIAL


Subject: Need some technical advice on verticies, weld, split...

SAMS3D opened this issue on Aug 11, 2003 ยท 14 posts


Mason posted Mon, 11 August 2003 at 11:52 AM

Well imagine a stored cube. That has 6 faces, 12 triangles and 8 vertices. Now to store each edge seperately takes 4 verts to describe each face so that comes out to 24 verts total. But since the 24 verts are the same 8 verts used over and over the verts are shared. Internally the mesh is stored with a vertex table (the 8 vertices) and a triangle table containing indices into the vertex table to describe each triangle. This way only 8 verts are stored but 24 can be referenced since the indices in each triangle can point to the same verts over and over. Vert splitting creates verts by itterating through each triangle and creating a unique vertex and index for each triangle vert. So your box stored as 8 verts and 12 triangles becomes 24 verts and 12 triangles. Now smoothing occurs across triangles that share the same vertices. Its assumed these triangles are connected. A ray called a normal is created for each triangle. A normal is a ray of length 1 that is perpendicular to the surface of the triangle. What smoothing does is create an averaged normal across adjacent traingles and uses that for lighting calculations. Now a system can theoretically find all vertices occupying the same spot and smooth those as well but its usually assumed that any no adjacent vertex is not to be smoothed. This is the difference between a soft and hard edge. A hard edge is one in which the vertices are not shared between triangles. A soft edge is one in which its vertices are shared.