Rendering with (free)glut Problems

I’m using Freeglut on NetBeans with MinGW which works okay.

But when i am creating a c++ project and try to use freeglut and opengl (with -lopengl32, -lglu32 and -lfreeglut libs) i only will get a white screen… but the demos just work fine (same project, same setup).

my Code:
http://pastebin.com/aX68vRKC

ust get a white window…

the original code is here:
http://pastebin.com/V6pfEQAD

this behaviour confuses me, since some other demos will run properly (with the same Project-Setup within NetBeans).
any ideas?

Since u have attached the display function after creating the first window, the contents will be drawn on the first window.
if u attach the display function after creating the second window, the contents will be displayed on the second window.

hey,

this wasn’t the problem at all, somehow i forgot to add glutSwapBuffers(); at the end of the display func. problem solved :slight_smile: yay \o/