hey all,
i'm working thru nehe tutorials and am at basic level and alreay having issues :D
i've written this code:
SetGraphicsDriver GLGraphicsDriver()
GLGraphics 640,480
Repeat
glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT)
glLoadIdentity()
glTranslatef(-1.5,0.0,-6.0);
glBegin(GL_TRIANGLES);
glVertex3f( 0.0, 1.0, 0.0);
glVertex3f(-1.0,-1.0, 0.0);
glVertex3f( 1.0,-1.0, 0.0);
glEnd();
Flip()
Until KeyDown(key_escape)
but as far as i can see is valid, and should draw a white triangle as per the nehe tut. however i get a black scr. if i take out the gltranslatef() it draws a triangle that fills the who;e screen but thats not the desired effect, it should be smaller
any ideas?
i'm working thru nehe tutorials and am at basic level and alreay having issues :D
i've written this code:
SetGraphicsDriver GLGraphicsDriver()
GLGraphics 640,480
Repeat
glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT)
glLoadIdentity()
glTranslatef(-1.5,0.0,-6.0);
glBegin(GL_TRIANGLES);
glVertex3f( 0.0, 1.0, 0.0);
glVertex3f(-1.0,-1.0, 0.0);
glVertex3f( 1.0,-1.0, 0.0);
glEnd();
Flip()
Until KeyDown(key_escape)
but as far as i can see is valid, and should draw a white triangle as per the nehe tut. however i get a black scr. if i take out the gltranslatef() it draws a triangle that fills the who;e screen but thats not the desired effect, it should be smaller
any ideas?