السلام علكيم
لدي كود يرسم مستطيل لكن عند تنفيذه لا يظهر اي شي , لماذا ؟؟
#include <windows.h>
#include <gl/gl.h>
#include <gl/glu.h>
#include <gl/glaux.h>
void display(void)
{
//Clear all pixels
glClear(GL_COLOR_BUFFER_BIT);
//draw white polygon (rectangle) with corners at
// (0.25, 0.25, 0.0) and (0.75, 0.75, 0.0)
glColor3f(1.0,1.0,1.0);
glBegin(GL_POLYGON);
glVertex3f(0.25, 0.25, 0.0);
glVertex3f(0.75, 0.25, 0.0);
glVertex3f(0.75, 0.75, 0.0);
glVertex3f(0.25, 0.75, 0.0);
glEnd();
// Don't wait start processing buffered OpenGL routines
glFlush();
}
main()
{
display();
}