Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我想知道是否有可能在第二个线程中创建 OpenGL-Display-List。我试过了,但总是遇到同样的错误:“在当前线程中找不到 OpenGL-Context”。
谢谢您的帮助
OpenGL 上下文总是一次绑定到一个线程。在线程之间迁移 OpenGL 上下文是完全可能的,但是这样做会与它所在的线程分离。
但是您可以创建多个 OpenGL 上下文,每个上下文绑定到不同的线程,并且您可以让上下文共享它们的显示列表和纹理(以及其他内容)。
话虽如此,您不应该在新程序中使用显示列表。它们已被弃用,并已从现代版本的 OpenGL 中删除。