zots
Re-member
i'm beginning to read the opengl superbible. the first project just creates a window and renders it blue. on build i get a warning implicit declaration NSApplicationMain. on run i get a bunch of lines that say object released with no pool - just leaking. can anyone tell me what is wrong? here is the code:
#include <GLUT/glut.h>
void display(void)
{
glClear(GL_COLOR_BUFFER_BIT|GL_DEPTH_BUFFER_BIT);
glFlush();
}
void setup(void)
{
glClearColor(0.0f, 0.0f, 1.0f, 1.0f);
}
int main(int argc, char** argv)
{
glutInitDisplayMode(GLUT_SINGLE | GLUT_RGB);
glutCreateWindow("test");
glutDisplayFunc(display);
setup();
glutMainLoop();
return NSApplicationMain(argc, argv);
}
#include <GLUT/glut.h>
void display(void)
{
glClear(GL_COLOR_BUFFER_BIT|GL_DEPTH_BUFFER_BIT);
glFlush();
}
void setup(void)
{
glClearColor(0.0f, 0.0f, 1.0f, 1.0f);
}
int main(int argc, char** argv)
{
glutInitDisplayMode(GLUT_SINGLE | GLUT_RGB);
glutCreateWindow("test");
glutDisplayFunc(display);
setup();
glutMainLoop();
return NSApplicationMain(argc, argv);
}