cocos2dx Configuration类

前端之家收集整理的这篇文章主要介绍了cocos2dx Configuration类前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。

官方给的类说明是 Configuration contains some openGL variables。意思是Configuration包含了一些openGL易变的东西。

查看类内容之后发现,Configuration正如它的名字一样,提供的是一些配置信息。具体如下。

/** OpenGL Max texture size. */

int getMaxTextureSize() const;


/** OpenGL Max Modelview Stack Depth. */

int getMaxModelviewStackDepth() const;


/** returns the maximum texture units

@since v2.0.0

*/

int getMaxTextureUnits() const;


/** Whether or not the GPU supports NPOT (Non Power Of Two) textures.

OpenGL ES 2.0 already supports NPOT (iOS).

@since v0.99.2

*/

bool supportsNPOT() const;


/** Whether or not PVR Texture Compressed is supported */

bool supportsPVRTC() const;

/** Whether or not ETC Texture Compressed is supported */

bool supportsETC() const;

/** Whether or not S3TC Texture Compressed is supported */

bool supportsS3TC() const;

/** Whether or not ATITC Texture Compressed is supported */

bool supportsATITC() const;

/** Whether or not BGRA8888 textures are supported.

@since v0.99.2

*/

bool supportsBGRA8888() const;


/** Whether or not glDiscardFramebufferEXT is supported

@since v0.99.2

*/

bool supportsDiscardFramebuffer() const;


/** Whether or not shareable VAOs are supported.

@since v2.0.0

*/

bool supportsShareableVAO() const;

/** Max support directional light in shader,for Sprite3D

@since v3.3

*/

int getMaxSupportDirLightInShader() const;

/** Max support point light in shader,for Sprite3D

*since v3.3

*/

int getMaxSupportPointLightInShader() const;

/** Max support spot light in shader,for Sprite3D

*since v3.3

*/

int getMaxSupportSpotLightInShader() const;


/** returns whether or not an OpenGL is supported */

bool checkForGLExtension(const std::string &searchName) const;


提供了一些openGL属性获取方法

原文链接:https://www.f2er.com/cocos2dx/344561.html

猜你在找的Cocos2d-x相关文章