opengl错误:未处理的异常在0x0251D09F(ig4dev32.dll)在GLTest.exe:0xC0000005:访问冲突读取位置0x00000000 [英] opengl error: Unhandled exception at 0x0251D09F (ig4dev32.dll) in GLTest.exe: 0xC0000005: Access violation reading location 0x00000000

查看:844
本文介绍了opengl错误:未处理的异常在0x0251D09F(ig4dev32.dll)在GLTest.exe:0xC0000005:访问冲突读取位置0x00000000的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想获得的OpenGL版本,代码为:

i want to get opengl version,the code is:

#include "stdafx.h"
#include <GL/glut.h>

void main(int argc, char** argv)
{
    glutInit(&argc,argv);
    glutInitDisplayMode(GLUT_SINGLE|GLUT_RGB);
    glutInitWindowPosition(100,100);
    glutInitWindowSize(400,300);
    glutCreateWindow("OpenGL Version");
    const char* version = (const char*)glGetString(GL_VERSION);
    printf("OpenGL version:%s\n", version);
    glutMainLoop();
}



但我得到的 glutCreateWindow错误(OpenGL的版本); ,谁可以帮我。

推荐答案

看起来你正在使用的Microsoft提供的默认图形驱动程序。要使用OpenGL,您必须安装由您的显卡制造商提供的驱动程序。

It looks like you're using the default graphics driver provided by Microsoft. To use OpenGL, you have to install drivers provided by your graphics card manufacture.

这篇关于opengl错误:未处理的异常在0x0251D09F(ig4dev32.dll)在GLTest.exe:0xC0000005:访问冲突读取位置0x00000000的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆