|
![](/i/fill.gif) |
in SuperPatch version of parse.c, in the function
Parse_Mesh(), there is the line
number_of_vertices=0;
then in parsing of 'plain' (non-smooth) triangles,
nothing is done to number_of_vertices.
Looking down at the smooth_triangle mesh code,
number_of_vertices is set for smooth_triangles
by calling
Mesh_Hash_Vertex(&number_of_vertices,
&max_vertices,
&Vertices, P1);
but Mesh_Hash_Vertex(&number_of_vertices,...) is
not called for plain triangles.
But then later there is:
Object->Data->Vertices =
(SNGL_VECT
*)POV_MALLOC(number_of_vertices*sizeof(SNGL_VECT), "triangle mesh
data");
and POV-Ray stops for trying to malloc zero bytes.
Now, what I did, and it is working, is just stick in some
Mesh_Hash_Vertex(&number_of_vertices,
&max_vertices,
&Vertices, P1);
for plain triangles.
Comments / condemnations ??
Post a reply to this message
|
![](/i/fill.gif) |