OpenGL - One of eight simple box drawings disappears ...
"R.Wieser" <[email protected]> Mon, 24 Mar 2025 12:28:19 +0100
| Newsgroups | alt.comp.os.windows-xp,alt.windows7.general,comp.os.ms-windows.programmer.win32 |
|---|---|
| Organization | A noiseless patient Spider |
| Message-ID | <[email protected]> |
Hello all, I'm drawing some stuff using OpenGL32, and have run into something I can't explain. I'm drawing a line and two rectangles with "markers" (a small box) on each corner. For some reason *one* of those markers disappears. The code: - - - - - - - - - - - glPushAttrib GL_CURRENT_BIT or GL_ENABLE_BIT glColor3ubv glBegin,GL_LINES ... glEnd glDisable GL_CULL_FACE DrawMarker DrawMarker DrawMarker DrawMarker glBegin,GL_QUADS ... glEnd DrawMarker <-- this one disappears DrawMarker DrawMarker DrawMarker glBegin,GL_QUADS ... glEnd glPopAttrib - - - - - - - - - - - -- DrawMarker glPushAttrib GL_CURRENT_BIT glColor3ubv glBegin GL_QUADS ... glEnd glPopAttrib - - - - - - - - - - - The interesting thing is that if I either, in the DrawMarker part, not push the attributes or not set the color all markers are visible again. If I make the above change for just the disappearing marker it appears, but than the next marker disappears. In the DrawMarker code I've followed both the glPushAttib and glColor3ubv with glGetError, but those returned Zero for all markers. I have no idea what is happening. Does anyone know ? Regards, Rudy Wieser