GLEW是公正的扩展库还是包含OpenGL ES 2.0实现? [英] GLEW is just and extension library or it contains OpenGL ES 2.0 implementation as well?

查看:185
本文介绍了GLEW是公正的扩展库还是包含OpenGL ES 2.0实现?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

GLEW是公正的扩展库还是包含OpenGL ES 2.0实现?

GLEW is just and extension library or it contains OpenGL ES 2.0 implementation as well?

OpenGL扩展牧马人库(GLEW)是跨平台的 开源C/C ++扩展加载库. GLEW提供高效 确定哪些OpenGL扩展是运行时机制 在目标平台上受支持. OpenGL核心和扩展 功能显示在单个头文件中.

The OpenGL Extension Wrangler Library (GLEW) is a cross-platform open-source C/C++ extension loading library. GLEW provides efficient run-time mechanisms for determining which OpenGL extensions are supported on the target platform. OpenGL core and extension functionality is exposed in a single header file.

我很困惑,因为我在glew.h中找到以下内容:

I am confused as I find the following in glew.h:

#define glLinkProgram GLEW_GET_FUN(__glewLinkProgram)

其中__glewLinkProgram

GLEW_FUN_EXPORT PFNGLLINKPROGRAMPROC __glewLinkProgram;

我猜想

其中PFNGLLINKPROGRAMPROC是从libdll获得的.我在任何地方都找不到.

where PFNGLLINKPROGRAMPROC is obtained from a lib or a dll, I guess. I cannot find it anywhere.

推荐答案

引号的第一行指出GLEW是什么:

The first line of your quote states what GLEW is:

OpenGL扩展牧马人库(GLEW)是一个... 扩展加载库.

它从OpenGL实现中加载OpenGL扩展功能(通常由GPU驱动程序提供).它不会自己实现.

It loads OpenGL extension functions from the OpenGL implementation (typically provided by GPU drivers). It doesn't implement them themselves.

glext.h提供的那些PFN... typedef是函数指针类型. GLEW只是定义了一些变量来保存函数指针,并使用wglGetProcAddressglXGetProcAddress函数加载它们.

Those PFN... typedefs are provided by glext.h and are function pointer types. GLEW simply defines some variables to hold the function pointers, and to load them using using the wglGetProcAddress or glXGetProcAddress functions.

这篇关于GLEW是公正的扩展库还是包含OpenGL ES 2.0实现?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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