GLUT

My window quickly disapers after being displayed.

#include <stdlib.h>
#ifdef __APPLE__
# include <GLUT/glut.h>
#else
# include <GL/glut.h>
#endif
#include <iostream>

using namespace std;

int main(int argc, char **argv ){

glutInit(&argc,argv);

glutInitWindowPosition(0,0);

glutInitWindowSize(1000,100);

glutInitDisplayMode(GLUT_RGBA | GLUT_DEPTH | GLUT_DOUBLE);

glutCreateWindow("Test.cpp");

glutMainLoop();

return 0;



}
BAWMP
Try adding some functions: http://www.opengl.org/resources/libraries/glut/spec3/node45.html (little old since it's glut and not freeglut but could be a little helpful).

Maybe just a simple display function that doesn't actually do anything.
Topic archived. No new replies allowed.