OGRE 14.3
Object-Oriented Graphics Rendering Engine
Loading...
Searching...
No Matches
Ogre::GpuConstantDefinition Struct Reference

Information about predefined program constants. More...

#include <OgreGpuProgramParams.h>

Public Member Functions

 GpuConstantDefinition ()
 
bool isBool () const
 
bool isDouble () const
 
bool isFloat () const
 
bool isInt () const
 
bool isSampler () const
 
bool isSpecialization () const
 
bool isUnsignedInt () const
 

Static Public Member Functions

static BaseConstantType getBaseType (GpuConstantType ctype)
 
static uint32 getElementSize (GpuConstantType ctype, bool padToMultiplesOf4)
 Get the number of elements of a given type, including whether to pad the elements into multiples of 4 (e.g.
 
static bool isBool (GpuConstantType c)
 
static bool isDouble (GpuConstantType c)
 
static bool isFloat (GpuConstantType c)
 
static bool isInt (GpuConstantType c)
 
static bool isSampler (GpuConstantType c)
 
static bool isSpecialization (GpuConstantType c)
 
static bool isUnsignedInt (GpuConstantType c)
 

Public Attributes

uint32 arraySize
 Length of array.
 
GpuConstantType constType
 Data type.
 
uint32 elementSize
 Number of typed slots per element (some programs pack each array element to float4, some do not)
 
size_t logicalIndex
 Logical index - used to communicate this constant to the rendersystem.
 
size_t physicalIndex
 Physical byte offset in buffer.
 
uint16 variability
 How this parameter varies (bitwise combination of GpuProgramVariability)
 

Detailed Description

Information about predefined program constants.

Note
Only available for high-level programs but is referenced generically by GpuProgramParameters.

Constructor & Destructor Documentation

◆ GpuConstantDefinition()

Ogre::GpuConstantDefinition::GpuConstantDefinition ( )
inline

Member Function Documentation

◆ isFloat() [1/2]

bool Ogre::GpuConstantDefinition::isFloat ( ) const
inline

◆ isFloat() [2/2]

static bool Ogre::GpuConstantDefinition::isFloat ( GpuConstantType c)
inlinestatic

References Ogre::BCT_FLOAT, and getBaseType().

◆ isDouble() [1/2]

bool Ogre::GpuConstantDefinition::isDouble ( ) const
inline

References constType, and isDouble().

Referenced by isDouble().

◆ isDouble() [2/2]

static bool Ogre::GpuConstantDefinition::isDouble ( GpuConstantType c)
inlinestatic

References Ogre::BCT_DOUBLE, and getBaseType().

◆ isInt() [1/2]

bool Ogre::GpuConstantDefinition::isInt ( ) const
inline

References constType, and isInt().

Referenced by isInt().

◆ isInt() [2/2]

static bool Ogre::GpuConstantDefinition::isInt ( GpuConstantType c)
inlinestatic

References Ogre::BCT_INT, and getBaseType().

◆ isUnsignedInt() [1/2]

bool Ogre::GpuConstantDefinition::isUnsignedInt ( ) const
inline

References constType, and isUnsignedInt().

Referenced by isUnsignedInt().

◆ isUnsignedInt() [2/2]

static bool Ogre::GpuConstantDefinition::isUnsignedInt ( GpuConstantType c)
inlinestatic

References Ogre::BCT_UINT, and getBaseType().

◆ isBool() [1/2]

bool Ogre::GpuConstantDefinition::isBool ( ) const
inline

References constType, and isBool().

Referenced by isBool().

◆ isBool() [2/2]

static bool Ogre::GpuConstantDefinition::isBool ( GpuConstantType c)
inlinestatic

References Ogre::BCT_BOOL, and getBaseType().

◆ isSampler() [1/2]

bool Ogre::GpuConstantDefinition::isSampler ( ) const
inline

◆ isSampler() [2/2]

static bool Ogre::GpuConstantDefinition::isSampler ( GpuConstantType c)
inlinestatic

References Ogre::BCT_SAMPLER, and getBaseType().

◆ isSpecialization() [1/2]

bool Ogre::GpuConstantDefinition::isSpecialization ( ) const
inline

References constType, and isSpecialization().

Referenced by isSpecialization().

◆ isSpecialization() [2/2]

static bool Ogre::GpuConstantDefinition::isSpecialization ( GpuConstantType c)
inlinestatic

◆ getBaseType()

static BaseConstantType Ogre::GpuConstantDefinition::getBaseType ( GpuConstantType ctype)
inlinestatic

◆ getElementSize()

Member Data Documentation

◆ physicalIndex

size_t Ogre::GpuConstantDefinition::physicalIndex

Physical byte offset in buffer.

Referenced by GpuConstantDefinition().

◆ logicalIndex

size_t Ogre::GpuConstantDefinition::logicalIndex

Logical index - used to communicate this constant to the rendersystem.

Referenced by GpuConstantDefinition().

◆ elementSize

uint32 Ogre::GpuConstantDefinition::elementSize

Number of typed slots per element (some programs pack each array element to float4, some do not)

Referenced by GpuConstantDefinition().

◆ arraySize

uint32 Ogre::GpuConstantDefinition::arraySize

Length of array.

Referenced by GpuConstantDefinition().

◆ constType

GpuConstantType Ogre::GpuConstantDefinition::constType

◆ variability

uint16 Ogre::GpuConstantDefinition::variability
mutable

How this parameter varies (bitwise combination of GpuProgramVariability)

Referenced by GpuConstantDefinition().


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