Some time ago I reported problems with using CVA and flat triangles.
Now I have a problem which might be related, at least this happens when
I (again) used flat shaded triangles (by accident (again)).
This time I think I have been able to locate the problem pretty well...
Here is the "stack dump", sorry for the wrapping lines:
gl_clip_interp_color_tex(vertex_buffer * 0x0a94c9b8, unsigned int 3000,
float 0.515227, unsigned int 184, unsigned int 186) line 132
viewclip_polygon_4(vertex_buffer * 0x0a94c9b8, unsigned int 3, unsigned
int * 0x01623718, unsigned char 31) line 129 + 761 bytes
gl_render_clipped_triangle(gl_context * 0x06200070, unsigned int 3,
unsigned int * 0x01623718, unsigned int 186) line 233 + 37 bytes
cva_render_tris_indirect(vertex_buffer * 0x0a94c9b8, vertex_buffer *
0x0a94c9b8, const gl_prim_state * 0x1013c598, unsigned int 0, unsigned
int 618) line 157 + 140 bytes
fxDDRenderCVAElements(vertex_buffer * 0x0a94c9b8, int 4, unsigned int *
0x0a8f7ea0, unsigned int 618) line 454 + 21 bytes
gl_DrawElements(gl_context * 0x06200070, int 4, int 618, int 5125, void
* 0x0a8f7ea0) line 1007 + 31 bytes
glDrawElements(int 4, int 618, int 5125, void * 0x0a8f7ea0) line 797 +
28 bytes
This is my reasoning what happens:
When the clip routine at the top is called the dst parameter is set to
3000,
because the VB->FirstFree was 3000. But the vertex buffer which is in
use is
actually a CVA buffer which only has space for 3000 elements in it.
As the clipping creates new vertices this causes it to write over the
end of
a malloced area. Thus thrashing the malloc heap.
I commented on the subject that this bug is nasty, this is because when
the program
fails like this on a Win95 machine the VC debugger doesn't attach into
it post mortem.
Also if I run into the problem with the debugger it freezes and also
seems to freeze
the b****y Win95 environment, this leads to excessive rebooting..
I have really missed Unix+Purify when looking at this!
Keith can you track the problem based on this information? If not I can
try to dig
out something more. I still don't have a small/neat test case for this.
Eero
_______________________________________________
Mesa-dev maillist - [EMAIL PROTECTED]
http://lists.mesa3d.org/mailman/listinfo/mesa-dev