Ok, I am now trying to make the glut teapot appear, as before, under CEGUI in a test program, on a different platform (Win32, mingw, opengl). I've gotten everything to compile, and now my CEGUI layout appears, but when it does, my glut teapot then disappears! (The teapot does appear for a split second, but gets immediately erased.) The CEGUI seems to work fine, gui window is movable etc - but it seems to clobber the opengl glut teapot beneath it. If I just remove the guiSystem.renderGUI(); call then the glut teapot remains. Also, and this mght be an important clue: if I resize my window, I then see the glut teapot (behind the cegui) but it then also immediately disappears. My cegui shineth forth brilliantly though.
Code: Select all
09/03/2011 22:35:20 (Std) ********************************************************************************
09/03/2011 22:35:20 (Std) * -------- START OF ESSENTIAL SECTION TO BE POSTED ON THE FORUM -------- *
09/03/2011 22:35:20 (Std) ********************************************************************************
09/03/2011 22:35:20 (Std) ---- Version 0.7.5 (Build: Nov 19 2010 Microsoft Windows g++ 4.4.0 32 bit) ----
09/03/2011 22:35:20 (Std) ---- Renderer module is: CEGUI::OpenGLRenderer - Official OpenGL based 2nd generation
renderer module. TextureTarget support is not available :( No glBlendFuncSeparate(EXT) support. ----
09/03/2011 22:35:20 (Std) ---- XML Parser module is: CEGUI::ExpatParser - Official expat based parser module fo
r CEGUI ----
09/03/2011 22:35:20 (Std) ---- Image Codec module is: SILLYImageCodec - Official SILLY based image codec ----
09/03/2011 22:35:20 (Std) ---- Scripting module is: None ----
09/03/2011 22:35:20 (Std) ********************************************************************************
09/03/2011 22:35:20 (Std) * -------- END OF ESSENTIAL SECTION TO BE POSTED ON THE FORUM -------- *
09/03/2011 22:35:20 (Std) ********************************************************************************
Here's how opengl+cegui renders (same as with linux):
Code: Select all
// prepare to render, typical OpenGL things
glMatrixMode(GL_MODELVIEW);
glLoadIdentity();
glClearColor(0.0f, 0.0f, 0.0f, 1.0f);
glClear( GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT );
//
// (draw your application OpenGL here, as usual)
//
glPushMatrix();
glTranslatef( 0,0,-5 );
glColor4f(1.0f,1.0f,0.0f,1.0f);
glutSolidSphere( 1, 30,30);
glColor4f(1.0f,0.0f,0.0f,1.0f);
glutWireTeapot( 2.0 );
glPopMatrix();
//
// Now, CEGUI draws on top of that...
//
guiSystem.renderGUI();
// (typical OpenGL double-buffering display sequence)
glutPostRedisplay();
glutSwapBuffers();
I might be able to use gdb to tell me more ... But so close! Has anyone seen something like that before, I wonder?