|
From: Roger H. <rog...@mi...> - 2008-09-16 07:31:31
|
I have had a problem with a corrupt 3DMF file which draws OK and seems fine until I do some complicated manipulations on it where my code gets everything which is not already a TriMesh into a TriMesh (or Triangle) and calls Q3TriMesh_GetData on all the objects. Part of what this gives me is an edge list which contains pairs of triangle indices. The problem came when I got a triangle index of 86 and there were only 11 triangles in the triangle list. This caused my program to crash. I am now filtering the data I get back from Q3TriMesh_GetData and every index which is invalid gets set to 0xFFFFFFFF which means the edge has no triangle on that side. So others don't have to spend two days debugging, would it be worth adding this extra processing to Q3TriMesh_GetData itself, or where we read the trimeshes in from the 3DMF? Roger Holmes. |