小编too*_*nky的帖子

带有 glObjectLabel 的 OpenGL 调试扩展

我刚开始在我的项目中使用调试扩展,但是 glObjectLabel 在与 GL_BUFFER 一起使用时会产生错误。

显卡是带有 340.82 驱动程序的 nVidia Quadro 600

这个简单的测试是用 32 位的 MSVC 2010 构建的:

#include <GL/glew.h>
#include <GLFW/glfw3.h>
#include <iostream>

void GLAPIENTRY ogl_cb(GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar* message, const void* userParam)
{
  using namespace std;
  cout << "message: "<< message << endl;
}

int main()
{
  using namespace std;

  if (!glfwInit())
  {
    cerr << "Error initializing GLFW" << endl;
    return 1;
  }

  glfwWindowHint(GLFW_OPENGL_DEBUG_CONTEXT, GL_TRUE);
  GLFWwindow *window = glfwCreateWindow(1, 1, "", …
Run Code Online (Sandbox Code Playgroud)

opengl debugging

0
推荐指数
1
解决办法
1098
查看次数

标签 统计

debugging ×1

opengl ×1