Class to do pixel format mapping between GL and OGRE. More...
#include <OgreGLPixelFormat.h>
Static Public Member Functions | |
static GLenum | getClosestGLInternalFormat (PixelFormat mFormat, bool hwGamma=false) |
Takes the OGRE pixel format and returns the type that must be provided to GL as internal format. More... | |
static PixelFormat | getClosestOGREFormat (GLenum fmt) |
Function to get the closest matching OGRE format to an internal GL format. More... | |
static GLenum | getGLInternalFormat (PixelFormat mFormat, bool hwGamma=false) |
Takes the OGRE pixel format and returns the type that must be provided to GL as internal format. More... | |
static GLenum | getGLOriginDataType (PixelFormat mFormat) |
Takes the OGRE pixel format and returns type that must be provided to GL as data type for reading it into the GPU. More... | |
static GLenum | getGLOriginFormat (PixelFormat mFormat) |
Takes the OGRE pixel format and returns the appropriate GL one. More... | |
static size_t | getMaxMipmaps (uint32 width, uint32 height, uint32 depth, PixelFormat format) |
Returns the maximum number of Mipmaps that can be generated until we reach the mininum format possible. More... | |
static uint32 | optionalPO2 (uint32 value) |
Returns next power-of-two size if required by render system, in case RSC_NON_POWER_OF_2_TEXTURES is supported it returns value as-is. More... | |
Class to do pixel format mapping between GL and OGRE.
Definition at line 38 of file OgreGLPixelFormat.h.
|
static |
Takes the OGRE pixel format and returns the type that must be provided to GL as internal format.
If no match exists, returns the closest match.
mFormat | The pixel format |
hwGamma | Whether a hardware gamma-corrected version is requested |
|
static |
Function to get the closest matching OGRE format to an internal GL format.
To be precise, the format will be chosen that is most efficient to transfer to the card without losing precision.
|
static |
Takes the OGRE pixel format and returns the type that must be provided to GL as internal format.
GL_NONE if no match exists.
mFormat | The pixel format |
hwGamma | Whether a hardware gamma-corrected version is requested |
|
static |
Takes the OGRE pixel format and returns type that must be provided to GL as data type for reading it into the GPU.
|
static |
Takes the OGRE pixel format and returns the appropriate GL one.
|
static |
Returns the maximum number of Mipmaps that can be generated until we reach the mininum format possible.
This does not count the base level.
width | The width of the area |
height | The height of the area |
depth | The depth of the area |
format | The format of the area |
Returns next power-of-two size if required by render system, in case RSC_NON_POWER_OF_2_TEXTURES is supported it returns value as-is.
Copyright © 2012 Torus Knot Software Ltd
This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.
Last modified Tue Apr 13 2021 08:53:15