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.
我成功创建了 GL 渲染上下文(我检查了所有 WinApi 函数的返回值)。当我尝试使用以下代码破坏上下文时,它失败了:
bool success = ::wglMakeCurrent ( 0, 0 ); // false success = ::wglDeleteContext ( glRenderingContext_ ); // false
上述所有内容都发生在一个线程中。怎么了?
在进行此调用之前,您是否销毁了保存设备和呈现上下文的窗口?在销毁窗口之前,您应该关闭渲染上下文。