PyOpenGL TypeError in glutCreate

2016-07-21  本文已影响0人  DKChain

在使用PyOpenGL的时候,出现以下错误

Traceback (most recent call last):
  File "viewer.py", line 80, in <module>
    viewer = Viewer()
  File "viewer.py", line 19, in __init__
    self.init_interface()
  File "viewer.py", line 31, in init_interface
    glutCreateWindow('3D Modeller')
  File "D:\python\lib\site-packages\OpenGL\GLUT\special.py", line 73, in glutCreateWindow
    return __glutCreateWindowWithExit(title, _exitfunc)
ctypes.ArgumentError: argument 1: <class 'TypeError'>: wrong type

之后在StackOverflow上找到解决办法
原因是Python3默认给出的是Unicode

上一篇下一篇

猜你喜欢

热点阅读