Re: [PyOpenGL-Users] Depth buffer attachment problem
Brought to you by:
mcfletch
From: Nicolas R. <Nic...@in...> - 2014-02-25 11:20:02
|
I investigated furthermore and my problem may come from my misunderstanding on vertex/index buffers. I attach an simple example where 2 programs are built (cube and quad): - cube is a rotating cube using vcube and icube (vertex and index buffer) and TRIANGLES. - quad is a simple quad using vquad (vertex buffer) and TRIANGLE_STRIP. In the "display" method, one can choose to display the rotating cube (if 1) or the quad (if 0). The rotating cube runs fine on my machine but the quad display does not. It is like the quad is using the cube vertex buffer and the display appears broken (cube vertices have been divided by 2 and it impacts the quad). It's very similar to the bug I first reported here and this makes me think there's no connection with the framebuffer. Also, the quad seems to be able to use the cube texture information while I did not set the "u_texture" information in that program. Obviously I'm doing something wrong but I can't see it. Finally, binding the texture (see line #DEBUG) blacks out the texture. A lot of weird things are happening indeed. Any help appreciated. Nicolas |