I'm trying to do my uni project and I'm using pyglet for the task . This is part of the code that makes me a problem.
from pyglet.gl import *
from pyglet.window import key
from pyglet.window import mouse
window=pyglet.window.Window(resizable=True)
@window.event
def on_draw():
glutInitDisplayMode (GLUT_RGB | GLUT_DOUBLE)
glutInitWindowSize (width, height)
glutInitWindowPosition (100, 100)
glClearColor( 1.0, 1.0, 1.0, 1.0)
glClear (GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT)
myObject ()
glutSwapBuffers()
When i searched for functions glutInitDisplayMode
, glutInitWindowSize
and glutInitWindowPosition
it only shows pyOpenGL threads, so do they exist for pyglet or im just defining them wrong?
Terminal Output:
glutInitDisplayMode (GLUT_RGB | GLUT_DOUBLE)
NameError: global name 'glutInitDisplayMode' is not defined
and same is for other two