ScummVM API documentation
OpenGL::Context Class Reference

#include <context.h>

Inheritance diagram for OpenGL::Context:
Common::Singleton< Context > Common::NonCopyable

Public Member Functions

void initialize (ContextType contextType)
 
void reset ()
 
bool isGLVersionOrHigher (int major, int minor) const
 

Public Attributes

ContextType type
 
int majorVersion
 
int minorVersion
 
int glslVersion
 
int maxTextureSize
 
bool NPOTSupported
 
bool shadersSupported
 
bool enginesShadersSupported
 
bool multitextureSupported
 
bool framebufferObjectSupported
 
bool framebufferObjectMultisampleSupported
 
int multisampleMaxSamples
 
bool packedPixelsSupported
 
bool packedDepthStencilSupported
 
bool unpackSubImageSupported
 
bool OESDepth24
 
bool textureEdgeClampSupported
 
bool textureBorderClampSupported
 
bool textureMirrorRepeatSupported
 
bool textureMaxLevelSupported
 

Additional Inherited Members

- Static Public Member Functions inherited from Common::Singleton< Context >
static bool hasInstance ()
 
static Context & instance ()
 
static void destroy ()
 
- Protected Types inherited from Common::Singleton< Context >
typedef Context SingletonBaseType
 
- Static Protected Attributes inherited from Common::Singleton< Context >
static Context * _singleton
 

Detailed Description

Description structure of the OpenGL (ES) context.

Member Function Documentation

◆ initialize()

void OpenGL::Context::initialize ( ContextType  contextType)

Initialize the context description from currently active context.

The extensions and features are marked as available according to the current context capabilities.

◆ reset()

void OpenGL::Context::reset ( )

Reset context.

This marks all extensions as unavailable.

◆ isGLVersionOrHigher()

bool OpenGL::Context::isGLVersionOrHigher ( int  major,
int  minor 
) const
inline

Helper function for checking the GL version supported by the context.

Member Data Documentation

◆ type

ContextType OpenGL::Context::type

The type of the active context.

◆ majorVersion

int OpenGL::Context::majorVersion

The GL version supported by the context.

◆ glslVersion

int OpenGL::Context::glslVersion

The GLSL version supported by the context

◆ maxTextureSize

int OpenGL::Context::maxTextureSize

The maximum texture size supported by the context.

◆ NPOTSupported

bool OpenGL::Context::NPOTSupported

Whether GL_ARB_texture_non_power_of_two is available or not.

◆ shadersSupported

bool OpenGL::Context::shadersSupported

Whether shader support is available or not.

◆ enginesShadersSupported

bool OpenGL::Context::enginesShadersSupported

Whether shader support is good enough for engines or not.

◆ multitextureSupported

bool OpenGL::Context::multitextureSupported

Whether multi texture support is available or not.

◆ framebufferObjectSupported

bool OpenGL::Context::framebufferObjectSupported

Whether FBO support is available or not.

◆ framebufferObjectMultisampleSupported

bool OpenGL::Context::framebufferObjectMultisampleSupported

Whether multisample FBO support is available or not

◆ multisampleMaxSamples

int OpenGL::Context::multisampleMaxSamples

Contains the maximum number of supported multisample samples if multisample FBOs are supported. Contains -1 otherwise.

◆ packedPixelsSupported

bool OpenGL::Context::packedPixelsSupported

Whether packed pixels support is available or not.

◆ packedDepthStencilSupported

bool OpenGL::Context::packedDepthStencilSupported

Whether packing the depth and stencil buffers is possible or not.

◆ unpackSubImageSupported

bool OpenGL::Context::unpackSubImageSupported

Whether specifying a pitch when uploading to textures is available or not

◆ OESDepth24

bool OpenGL::Context::OESDepth24

Whether depth component 24 is supported or not

◆ textureEdgeClampSupported

bool OpenGL::Context::textureEdgeClampSupported

Whether texture coordinate edge clamping is available or not.

◆ textureBorderClampSupported

bool OpenGL::Context::textureBorderClampSupported

Whether texture coordinate border clamping is available or not.

◆ textureMirrorRepeatSupported

bool OpenGL::Context::textureMirrorRepeatSupported

Whether texture coordinate mirrored repeat is available or not.

◆ textureMaxLevelSupported

bool OpenGL::Context::textureMaxLevelSupported

Whether texture max level is available or not.


The documentation for this class was generated from the following file: