panda3D运行出错

这几天学习到了panda3D
当我编写并运行了一个panda3D的窗口时终端突然报错:
这是源代码

from direct.showbase.ShowBase import ShowBase


class Game(ShowBase):
    def __init__(self):
        ShowBase.__init__(self)

game = Game()
game.run()

这是报错:

Known pipe types:
  wglGraphicsPipe
(all display modules loaded.)
:display(error): The application requested harware acceleration, but your OpenGL
:display(error): driver, GDI Generic, only supports software rendering.
:display(error): You need to install a hardware-accelerated OpenGL driver, or,
:display(error): if you actually *want* to use a software renderer, then
:display(error): alter the hardware/software configuration in your Config.prc file.
:ShowBase(warning): Unable to open 'onscreen' window.
Traceback (most recent call last):
  File "E:\My_Game\3DGmae\第一个3D游戏.py", line 8, in <module>
    game = Game()
  File "E:\My_Game\3DGmae\第一个3D游戏.py", line 6, in __init__
    ShowBase.__init__(self)
  File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\direct\showbase\ShowBase.py", line 341, in __init__
    self.openDefaultWindow(startDirect = False, props=props)
  File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\direct\showbase\ShowBase.py", line 1026, in openDefaultWindow
    self.openMainWindow(*args, **kw)
  File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\direct\showbase\ShowBase.py", line 1061, in openMainWindow
    self.openWindow(*args, **kw)
  File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\direct\showbase\ShowBase.py", line 806, in openWindow
    raise Exception('Could not open window.')
Exception: Could not open window.

还是那句话,不懂就问。
各位大佬帮我看一下

讨论数量: 1
Squ1rrel

不要养成中文命名文件的习惯

1年前 评论

讨论应以学习和精进为目的。请勿发布不友善或者负能量的内容,与人为善,比聪明更重要!