def renderScene(programObj, width, height):
 gl.glMatrixMode(gl.GL_PROJECTION)
 gl.glLoadIdentity()
 glu.gluOrtho2D(0, width, 0, height)
 gl.glViewport(0, 0, width, height)
 gl.glMatrixMode(gl.GL_MODELVIEW)
 gl.glLoadIdentity()
 gl.glUseProgram(programObj)
 gl.glBegin(gl.GL_QUADS)
 gl.glTexCoord2f(0.0, 0.0)
 gl.glVertex2f(0.0, 0.0)
 gl.glTexCoord2f(1.0, 0.0)
 gl.glVertex2f(float(width), 0.0)
 gl.glTexCoord2f(1.0, 1.0)
 gl.glVertex2f(float(width), float(height))
 gl.glTexCoord2f(0.0, 1.0)
 gl.glVertex2f(0.0, float(height))
 gl.glEnd()
 gl.glUseProgram(0)
 checkGLError()

def renderScene ( programObj , width , height ) : gl . glMatrixMode ( gl . GL_PROJECTION ) gl . glLoadIdentity ( ) glu . gluOrtho2D ( 0 , width , 0 , height ) gl . glViewport ( 0 , 0 , width , height ) gl . glMatrixMode ( gl . GL_MODELVIEW ) gl . glLoadIdentity ( ) gl . glUseProgram ( programObj ) gl . glBegin ( gl . GL_QUADS ) gl . glTexCoord2f ( 0.0 , 0.0 ) gl . glVertex2f ( 0.0 , 0.0 ) gl . glTexCoord2f ( 1.0 , 0.0 ) gl . glVertex2f ( float ( width ) , 0.0 ) gl . glTexCoord2f ( 1.0 , 1.0 ) gl . glVertex2f ( float ( width ) , float ( height ) ) gl . glTexCoord2f ( 0.0 , 1.0 ) gl . glVertex2f ( 0.0 , float ( height ) ) gl . glEnd ( ) gl . glUseProgram ( 0 ) checkGLError ( )
renderscene - the opengl commands to render our scene .