Guiliani  Version 2.6 revision 7293 (documentation build 12)
CGfxEnv Class Reference

#include <GfxEnv.h>

Inheritance diagram for CGfxEnv:

Public Types

enum  SurfaceMode_t { SM_OPENGL , SM_FRAMEBUFFER , SM_VULKAN }
 

Public Member Functions

eC_Bool AddLayer (const LayerConfiguration_t &kLayerConfig)
 
void AddMainLayer (const eC_UInt &uiLayerID=0, const eC_Bool &bCached=false)
 
eC_UByte ApplyGlobalAlpha (const eC_UByte &ubAlpha) const
 
virtual void DeInitDisplay ()
 
virtual void EndOfRefresh ()
 
eC_UInt GetActiveLayerID () const
 
virtual eC_UByte GetBPP () const
 
virtual eC_UInt GetBufferCount () const
 
eC_UByte GetBytesPerPixel (const CGUICommonEnums::ImageType_t &ePixFormat) const
 
virtual CGUICommonEnums::ImageType_t GetColorFormat () const
 
void * GetDisplayBuffer (const eC_UInt &uiLayerID) const
 
virtual void * GetDisplayHandle () const
 
virtual void ** GetFrameBuffers () const
 
eC_UByte GetGlobalAlpha () const
 
virtual eC_UInt GetHeight () const
 
eC_UByte GetLayerAlpha (const eC_UInt &uiLayerID) const
 
eC_Bool GetLayerBufferSize (const eC_UInt &uiLayerID, eC_UInt &uiWidth, eC_UInt &uiHeight, eC_UByte &ubBPP)
 
eC_Bool GetLayerChromaKey (const eC_UInt &uiLayerID, eC_Bool &bChromaKeyActive, eC_UInt &uiChromaKey, eC_UByte &ubAlpha) const
 
eC_Bool GetLayerConfig (const eC_UInt &uiLayerIndex, LayerConfiguration_t &rkLayerConfig) const
 
eC_Bool GetLayerConfigForID (const eC_UInt &uiLayerID, LayerConfiguration_t &rkLayerConfig) const
 
eC_Bool GetLayerConfigForMainLayer (LayerConfiguration_t &rkLayerConfig) const
 
eC_Bool GetLayerIndexForID (const eC_UInt &uiLayerID, eC_UInt &ruiLayerIndex) const
 
eC_Bool GetLayerPosition (const eC_UInt &uiLayerID, eC_Int &iXPos, eC_Int &iYPos)
 
eC_Bool GetLayerVisibleSize (const eC_UInt &uiLayerID, eC_UInt &uiWidth, eC_UInt &uiHeight)
 
eC_UInt GetMainLayerID () const
 
virtual void * GetMergeBuffer () const
 
virtual eC_String GetName () const
 
eC_UInt GetNumberOfLayers () const
 
void * GetRenderBuffer (const eC_UInt &uiLayerID) const
 
virtual SurfaceMode_t GetSurfaceMode () const
 
virtual eC_UInt GetWidth () const
 
virtual void * GetWindowHandle () const
 
virtual eC_UInt GetXPos () const
 
virtual eC_UInt GetYPos () const
 
virtual eC_UInt InitDisplay ()
 
void InitLayers ()
 
void InvalidateLayer (const eC_UInt &uiLayerID)
 
virtual eC_Bool IsCreated () const
 
eC_Bool IsLayerModified (const eC_UInt &uiLayerID) const
 
eC_Bool IsLayerVisible (const eC_UInt &uiLayerID) const
 
eC_Bool IsMainLayer (const eC_UInt &uiLayerID) const
 
virtual eC_Bool IsNull ()
 
virtual eC_Bool IsResizable () const
 
virtual eC_Bool IsVSyncEnabled () const
 
virtual eC_Bool NeedsManualMerge () const
 
virtual eC_Bool RefreshScreen (const CGUIRect &rkInvalidatedArea)
 
virtual eC_Bool RefreshScreen (const eC_TListDoubleLinked< CGUIRect > &kInvalidatedRectList)
 
eC_Bool SetActiveLayerID (const eC_UInt &uiLayerID, const eC_Bool &bMarkAsModified=false)
 
virtual void SetCliprect (const CGUIRect &rkNewClipRect)
 
virtual void SetDevice (void *pkDevice)
 
void SetGfxWrap (CGfxWrap *pkGfxWrap)
 
void SetGlobalAlpha (const eC_UByte &ubGlobalAlpha)
 
eC_Bool SetLayerAlpha (const eC_UInt &uiLayerID, const eC_UByte &ubAlpha)
 
eC_Bool SetLayerChromaKey (const eC_UInt &uiLayerID, const eC_Bool &bChromaKeyActive, const eC_UInt &uiChromaKey, const eC_UByte &ubAlpha)
 
eC_Bool SetLayerPosition (const eC_UInt &uiLayerID, const eC_Int &iXPos, const eC_Int &iYPos)
 
eC_Bool SetLayerVisible (const eC_UInt &uiLayerID, const eC_Bool &bVisible)
 
eC_Bool SetLayerVisiblePos (const eC_UInt &uiLayerID, const eC_Int &iXPos, const eC_Int &iYPos)
 
eC_Bool SetLayerVisibleSize (const eC_UInt &uiLayerID, const eC_UInt &uiWidth, const eC_UInt &uiHeight)
 
void SetMainLayerID (const eC_UInt &uiLayerID)
 
void SetMainLayerProperties (const eC_UInt &uiLayerID, const eC_Bool &bCached)
 
void SetObjectForLayerID (const eC_UInt &uiLayerID, CGUIObject *pkObject)
 
virtual void SetScreenPosition (const eC_UInt &uiX, const eC_UInt &uiY)
 
virtual void SetScreenSize (const eC_UInt &uiWidth, const eC_UInt &uiHeight)
 
virtual void SetVSyncEnabled (const eC_Bool &bVSyncEnabled)
 
virtual void SetWindowCaption (const eC_String &kCaption)
 
virtual void StartOfRefresh ()
 
virtual eC_Bool SupportsCopy () const
 
virtual eC_Bool SwapBuffers ()
 
virtual void UpdateLayer (const LayerConfiguration_t &kLayerConfig, const LayerUpdate_t &eUpdateReason)
 
virtual eC_Bool UpdateLayerBuffers (const eC_UInt &uiLayerID, void *pkRenderBuffer, void *pkDisplayBuffer, const eC_UInt &uiWidth, const eC_UInt &uiHeight)
 
void UpdateLayerPositions ()
 

Static Public Member Functions

static eC_Bool CreateInstance (const SurfaceMode_t &eSurfaceMode, const CGUICommonEnums::ImageType_t &eScreenFormat, const eC_UInt &uiWidth, const eC_UInt &uiHeight, const eC_UInt &uiBufferCount=1, void **ppkBuffers=NULL, const eC_Bool &bResizable=false)
 
static void DeleteInstance ()
 called to destroy and detach GfxEnv
 

Protected Member Functions

 CGfxEnv (const SurfaceMode_t &eSurfaceMode, const CGUICommonEnums::ImageType_t &eScreenFormat, const eC_UInt &uiWidth, const eC_UInt &uiHeight, const eC_UInt &uiBufferCount=1, void **ppkBuffers=NULL, const eC_Bool &bResizable=false)
 
virtual ~CGfxEnv ()
 
eC_UByte GetBPPFromScreenFormat () const
 
virtual void InitLayer (const LayerConfiguration_t &kLayerConfig)
 
void UpdateMainLayer (const CGUICommonEnums::ImageType_t &eColorFormat, const eC_UInt &uiWidth, const eC_UInt &uiHeight, const eC_UInt &uiBufferCount, void **ppkBuffers)
 

Protected Attributes

eC_TArray< LayerConfiguration_tm_akLayers
 : *DCLayer_t, one DCLayer_t struct per layer storing general settings
 
eC_Bool m_bNeedsManualMerge
 if supports merge
 
eC_Bool m_bResizable
 resizable
 
eC_Bool m_bSupportsCopy
 if supports copy
 
eC_Bool m_bVSyncEnabled
 if vsync is enabled
 
CGUICommonEnums::ImageType_t m_eColorFormat
 color-format
 
SurfaceMode_t m_eSurfaceMode
 surface mode
 
eC_Int m_iMainLayerID
 id of main-layer
 
eC_String m_kName
 name
 
CGfxWrapm_pkGfxWrap
 pointer to GfxWrapper
 
void ** m_ppkBuffers
 buffers for the main-screen
 
eC_UByte m_ubBPP
 BPP of the surface.
 
eC_UByte m_ubGlobalAlpha
 global alpha for blending
 
eC_UInt m_uiActiveLayerID
 : unsigned int = Active Layer
 
eC_UInt m_uiActiveLayerIndex
 index of currentl< active layer
 
eC_UInt m_uiBufferCount
 number of buffers used
 
eC_UInt m_uiHeight
 height of the surface
 
eC_UInt m_uiWidth
 width of the surface
 

Friends

class CGUIComponentManager
 

Detailed Description

This is the base-class for all GfxEnvXXX-classes dealing with environment used by the GfxWrap

This class is used to set up the environment for the actual GfxWrap with a generic interface. It will provide the size, buffers and all necessary data. Additionally it will hold all hardware layers.

Typical order of events:

After the frame has been drawn by the GfxWrap into the currently active render-buffer the refresh is done Inside the refresh the following things are done for each layer

  • UpdateLayerBuffers to switch to the next buffer

After that EndOfRefresh and RefreshScreen with each invalidated region is called

Depending on the actual underlying API UpdateLayerBuffers can be used to execute cache-invalidation on the buffers currently used for drawing. Additionally the switch of buffers for the display-hardware can be done.

In EndOfRefresh the switch of all used buffers should already be done, thus it can be used to wait for a vertical sync-signal.

RefreshScreen can be used to copy the regions that have been redrawn in the last frame over to the new drawing-buffer to start the next frame.

Member Enumeration Documentation

◆ SurfaceMode_t

Surface-mode

Enumerator
SM_OPENGL 

use OpenGL for surface

SM_FRAMEBUFFER 

use framebuffer for surface

Constructor & Destructor Documentation

◆ CGfxEnv()

CGfxEnv::CGfxEnv ( const SurfaceMode_t eSurfaceMode,
const CGUICommonEnums::ImageType_t eScreenFormat,
const eC_UInt &  uiWidth,
const eC_UInt &  uiHeight,
const eC_UInt &  uiBufferCount = 1,
void **  ppkBuffers = NULL,
const eC_Bool &  bResizable = false 
)
protected

Constructor

Parameters
eSurfaceModeOpenGL or Framebuffer
eScreenFormatscreen-format
uiWidthwidth
uiHeightheight
uiBufferCountnumber of buffers to use
ppkBuffersbuffers to use
bResizabletrue if resizable

◆ ~CGfxEnv()

virtual CGfxEnv::~CGfxEnv ( )
protectedvirtual

Destructor

Member Function Documentation

◆ AddLayer()

eC_Bool CGfxEnv::AddLayer ( const LayerConfiguration_t kLayerConfig)

Add layer to internal configuration. should only be called during startup of application

Parameters
kLayerConfiglayer-configuration
Returns
true if successful

◆ AddMainLayer()

void CGfxEnv::AddMainLayer ( const eC_UInt &  uiLayerID = 0,
const eC_Bool &  bCached = false 
)

Set information for the main-layer

Parameters
uiLayerIDthe id for the layer (default: 0)
bCachedtrue if the layer-memory is cached (default: false)

◆ ApplyGlobalAlpha()

eC_UByte CGfxEnv::ApplyGlobalAlpha ( const eC_UByte &  ubAlpha) const

Calculate the alpha-value according to the global alpha

Parameters
ubAlphainput alpha-value
Returns
applied alpha

◆ CreateInstance()

static eC_Bool CGfxEnv::CreateInstance ( const SurfaceMode_t eSurfaceMode,
const CGUICommonEnums::ImageType_t eScreenFormat,
const eC_UInt &  uiWidth,
const eC_UInt &  uiHeight,
const eC_UInt &  uiBufferCount = 1,
void **  ppkBuffers = NULL,
const eC_Bool &  bResizable = false 
)
static

Create Instance

Parameters
eSurfaceModesurface-mode
eScreenFormatscreen-format
uiWidthwidth
uiHeightheight
uiBufferCountnumber of buffers to use
ppkBufferspointers to buffers
bResizabletrue if resizable
Returns
true if successful

◆ DeInitDisplay()

virtual void CGfxEnv::DeInitDisplay ( )
inlinevirtual

De-Initialize display

Reimplemented in CGfxEnvDAVE.

◆ EndOfRefresh()

virtual void CGfxEnv::EndOfRefresh ( )
inlinevirtual

This will be called when all layers have been refreshed. To wait for V-sync this would be the right place.

Reimplemented in CGfxEnvCDC, CGfxEnvCDCDI, CGfxEnvDAVE, CGfxEnvDRM, CGfxEnvFBDevice, CGfxEnvFBDeviceRZA2M, CGfxEnvSDL2, and CGfxEnvWin.

◆ GetActiveLayerID()

eC_UInt CGfxEnv::GetActiveLayerID ( ) const

Return the id of the currently active layer

Returns
id of active layer

◆ GetBPP()

virtual eC_UByte CGfxEnv::GetBPP ( ) const
virtual

Get the BPP of the surface

Returns
BPP

◆ GetBPPFromScreenFormat()

eC_UByte CGfxEnv::GetBPPFromScreenFormat ( ) const
protected

Get the number of bits per pixel from the screen-format

Returns
number of bits

◆ GetBufferCount()

virtual eC_UInt CGfxEnv::GetBufferCount ( ) const
virtual

Get number of used buffers

Returns
buffer-count

◆ GetBytesPerPixel()

eC_UByte CGfxEnv::GetBytesPerPixel ( const CGUICommonEnums::ImageType_t ePixFormat) const

Return the number of bytes per pixel for pixel-format

Parameters
ePixFormat
Returns
bpp

◆ GetColorFormat()

virtual CGUICommonEnums::ImageType_t CGfxEnv::GetColorFormat ( ) const
virtual

Retrieve the Screen-Format (e.g. RGB565)

Returns
screen-format

◆ GetDisplayBuffer()

void * CGfxEnv::GetDisplayBuffer ( const eC_UInt &  uiLayerID) const

Get the currently active buffer which is used for display

Parameters
uiLayerIDid of layer
Returns
address of buffer or NULL if layer was not found

◆ GetDisplayHandle()

virtual void * CGfxEnv::GetDisplayHandle ( ) const
inlinevirtual

return display-handle if any

Returns
NULL by default

Reimplemented in CGfxEnvDRM, and CGfxEnvWayland.

◆ GetFrameBuffers()

virtual void ** CGfxEnv::GetFrameBuffers ( ) const
inlinevirtual

return the used framebuffer if any

Returns
framebuffer or NULL

Reimplemented in CGfxEnvDRM, CGfxEnvFBDevice, CGfxEnvWayland, CGfxEnvFBDeviceRZA2M, CGfxEnvSDL, CGfxEnvSDL2, and CGfxEnvWin.

◆ GetGlobalAlpha()

eC_UByte CGfxEnv::GetGlobalAlpha ( ) const

Return the currently set global alpha-value

Returns
global alpha

◆ GetHeight()

virtual eC_UInt CGfxEnv::GetHeight ( ) const
virtual

Get the height of the surface

Returns
height

Reimplemented in CGfxEnvSDL, CGfxEnvSDL2, and CGfxEnvWin.

◆ GetLayerAlpha()

eC_UByte CGfxEnv::GetLayerAlpha ( const eC_UInt &  uiLayerID) const

Get the current alpha-value for the given layer.

Parameters
uiLayerIDid of layer
Returns
alpha-value

◆ GetLayerBufferSize()

eC_Bool CGfxEnv::GetLayerBufferSize ( const eC_UInt &  uiLayerID,
eC_UInt &  uiWidth,
eC_UInt &  uiHeight,
eC_UByte &  ubBPP 
)

Get the size of the buffer attached to the given layer.

Parameters
uiLayerIDid of layer
uiWidthwidth of layer
uiHeightheight of layer
ubBPPbytes per pixel
Returns
true if layer was found

◆ GetLayerChromaKey()

eC_Bool CGfxEnv::GetLayerChromaKey ( const eC_UInt &  uiLayerID,
eC_Bool &  bChromaKeyActive,
eC_UInt &  uiChromaKey,
eC_UByte &  ubAlpha 
) const

Get the current chroma-key settings for the given layer.

Parameters
uiLayerIDid of layer
bChromaKeyActivetrue if chroma-keying is active
uiChromaKeythe color for chroma-keying
ubAlphaalpha-value for replacement
Returns
true if layer was found

◆ GetLayerConfig()

eC_Bool CGfxEnv::GetLayerConfig ( const eC_UInt &  uiLayerIndex,
LayerConfiguration_t rkLayerConfig 
) const

Get configuration for given layer. Note: this will need an index instead of id

Parameters
uiLayerIndexindex of layer in internal data
rkLayerConfigconfiguation of layer
Returns
true if config was found

◆ GetLayerConfigForID()

eC_Bool CGfxEnv::GetLayerConfigForID ( const eC_UInt &  uiLayerID,
LayerConfiguration_t rkLayerConfig 
) const

Get configuration for layer with given ID

Parameters
uiLayerIDid of layer
rkLayerConfigconfiguation of layer
Returns
true if config was found

◆ GetLayerConfigForMainLayer()

eC_Bool CGfxEnv::GetLayerConfigForMainLayer ( LayerConfiguration_t rkLayerConfig) const

Get configuration for main-layer

Parameters
rkLayerConfigconfiguation of layer
Returns
true if config was found

◆ GetLayerIndexForID()

eC_Bool CGfxEnv::GetLayerIndexForID ( const eC_UInt &  uiLayerID,
eC_UInt &  ruiLayerIndex 
) const

—— layer functionality ——

Get the internal index for given layer-id

Parameters
uiLayerIDid of requested layer
ruiLayerIndexinternal index
Returns
true if layer exists, otherwise false

◆ GetLayerPosition()

eC_Bool CGfxEnv::GetLayerPosition ( const eC_UInt &  uiLayerID,
eC_Int &  iXPos,
eC_Int &  iYPos 
)

Get the current position for the given layer

Parameters
uiLayerIDid of layer
iXPosx-position
iYPosy-position
Returns
true if layer was found

◆ GetLayerVisibleSize()

eC_Bool CGfxEnv::GetLayerVisibleSize ( const eC_UInt &  uiLayerID,
eC_UInt &  uiWidth,
eC_UInt &  uiHeight 
)

Get the visible size for the given layer

Parameters
uiLayerIDid of layer
uiWidthvisible width
uiHeightvisible height
Returns
true if layer was found

◆ GetMainLayerID()

eC_UInt CGfxEnv::GetMainLayerID ( ) const

Return the ID of the main-layer

Returns
main-layer ID

◆ GetMergeBuffer()

virtual void * CGfxEnv::GetMergeBuffer ( ) const
inlinevirtual

Return merge-buffer

Returns
NULL by default

Reimplemented in CGfxEnvDAVE.

◆ GetName()

virtual eC_String CGfxEnv::GetName ( ) const
virtual

Return the name of the environment

Returns
name of environment

◆ GetNumberOfLayers()

eC_UInt CGfxEnv::GetNumberOfLayers ( ) const

Return number of configured layers

Returns
number of layers

◆ GetRenderBuffer()

void * CGfxEnv::GetRenderBuffer ( const eC_UInt &  uiLayerID) const

Get the currently active buffer which is used for rendering

Parameters
uiLayerIDid of layer
Returns
address of buffer or NULL if layer was not found

◆ GetSurfaceMode()

virtual SurfaceMode_t CGfxEnv::GetSurfaceMode ( ) const
virtual

Retrieve the Surface-Mode

Returns
surface-mode

◆ GetWidth()

virtual eC_UInt CGfxEnv::GetWidth ( ) const
virtual

Get the width of the surface

Returns
width

Reimplemented in CGfxEnvSDL, CGfxEnvSDL2, and CGfxEnvWin.

◆ GetWindowHandle()

virtual void * CGfxEnv::GetWindowHandle ( ) const
inlinevirtual

return window-handle if any

Returns
NULL by default

Reimplemented in CGfxEnvDRM, CGfxEnvWayland, CGfxEnvSDL2, and CGfxEnvWin.

◆ GetXPos()

virtual eC_UInt CGfxEnv::GetXPos ( ) const
virtual

Get the x-position of the surface

Returns
x-position

Reimplemented in CGfxEnvSDL, CGfxEnvSDL2, and CGfxEnvWin.

◆ GetYPos()

virtual eC_UInt CGfxEnv::GetYPos ( ) const
virtual

Get the y-position of the surface

Returns
y-position

Reimplemented in CGfxEnvSDL, CGfxEnvSDL2, and CGfxEnvWin.

◆ InitDisplay()

virtual eC_UInt CGfxEnv::InitDisplay ( )
inlinevirtual

Initialize display

Returns
1 on success, else 0

Reimplemented in CGfxEnvDAVE.

◆ InitLayer()

virtual void CGfxEnv::InitLayer ( const LayerConfiguration_t kLayerConfig)
inlineprotectedvirtual

Initialize layer this can be used to execute platform-specific code is called when layer gets added to DCWrap

Parameters
kLayerConfiglayer-configuration

Reimplemented in CGfxEnvDAVE, CGfxEnvDRM, and CGfxEnvWin.

◆ InitLayers()

void CGfxEnv::InitLayers ( )

Initialize layers after all layers have been added

◆ InvalidateLayer()

void CGfxEnv::InvalidateLayer ( const eC_UInt &  uiLayerID)

Refresh layer after content has been changed. This applies merely to layers containing user-defined content

Parameters
uiLayerIDid of layer to refresh

◆ IsCreated()

virtual eC_Bool CGfxEnv::IsCreated ( ) const
virtual

Is surface created

Returns
true if created

Reimplemented in CGfxEnvFBDevice, CGfxEnvWayland, CGfxEnvFBDeviceRZA2M, CGfxEnvSDL, and CGfxEnvSDL2.

◆ IsLayerModified()

eC_Bool CGfxEnv::IsLayerModified ( const eC_UInt &  uiLayerID) const

Return if layer was recently modified

Parameters
uiLayerIDid of layer
Returns
True if modified

◆ IsLayerVisible()

eC_Bool CGfxEnv::IsLayerVisible ( const eC_UInt &  uiLayerID) const

Get current visibility of layer

Parameters
uiLayerIDid of layer
Returns
true if visible, else false

◆ IsMainLayer()

eC_Bool CGfxEnv::IsMainLayer ( const eC_UInt &  uiLayerID) const

Return if layer is set to be used as main-layer

Parameters
uiLayerIDid of layer
Returns
True if main-layer

◆ IsNull()

virtual eC_Bool CGfxEnv::IsNull ( )
inlinevirtual

Check if Wrapper is NULL-implementation

Returns
true if NULL

Reimplemented in CGfxEnvNull.

◆ IsResizable()

virtual eC_Bool CGfxEnv::IsResizable ( ) const
virtual

Get Resizable

Returns
resizable

◆ IsVSyncEnabled()

virtual eC_Bool CGfxEnv::IsVSyncEnabled ( ) const
inlinevirtual

Return if VSync is enabled

Returns
true if VSync is enabled

◆ NeedsManualMerge()

virtual eC_Bool CGfxEnv::NeedsManualMerge ( ) const
virtual

Get if merge is needed

Returns
merge needed

◆ RefreshScreen() [1/2]

virtual eC_Bool CGfxEnv::RefreshScreen ( const CGUIRect rkInvalidatedArea)
inlinevirtual

Refresh the screen within the given invalidate area. This can be used to copy regions of the display-buffer to the drawing-buffer

Parameters
rkInvalidatedAreaThis area will be refreshed.
Returns
True if OK

Reimplemented in CGfxEnvFBDevice, CGfxEnvWayland, CGfxEnvFBDeviceRZA2M, CGfxEnvSDL, CGfxEnvDRM, and CGfxEnvWin.

◆ RefreshScreen() [2/2]

virtual eC_Bool CGfxEnv::RefreshScreen ( const eC_TListDoubleLinked< CGUIRect > &  kInvalidatedRectList)
virtual

Refresh multiple parts of the screen

Parameters
kInvalidatedRectListinvalidated areas
Returns
True if OK

◆ SetActiveLayerID()

eC_Bool CGfxEnv::SetActiveLayerID ( const eC_UInt &  uiLayerID,
const eC_Bool &  bMarkAsModified = false 
)

Set the given layer-id as the active all following access for rendering will be sent to the layer

Parameters
uiLayerIDid of layer
bMarkAsModifiedlayer will be marked as modified upon switch (default: false)
Returns
true if layer exists, otherwise false

◆ SetCliprect()

virtual void CGfxEnv::SetCliprect ( const CGUIRect rkNewClipRect)
inlinevirtual

Set the clip rectangle.

Parameters
rkNewClipRectThe new clipping rectangle.

Reimplemented in CGfxEnvFBDevice, CGfxEnvFBDeviceRZA2M, and CGfxEnvSDL.

◆ SetDevice()

virtual void CGfxEnv::SetDevice ( void *  pkDevice)
inlinevirtual

Set a device

Parameters
pkDevice

Reimplemented in CGfxEnvDAVE.

◆ SetGfxWrap()

void CGfxEnv::SetGfxWrap ( CGfxWrap pkGfxWrap)
inline

Set the GfxWrapper

Parameters
pkGfxWrap

◆ SetGlobalAlpha()

void CGfxEnv::SetGlobalAlpha ( const eC_UByte &  ubGlobalAlpha)

Set the global alpha-value, which is used to correctly blend the layers during a transition

Parameters
ubGlobalAlpha

◆ SetLayerAlpha()

eC_Bool CGfxEnv::SetLayerAlpha ( const eC_UInt &  uiLayerID,
const eC_UByte &  ubAlpha 
)

Set the alpha-value for blending between layer for the given layer.

Parameters
uiLayerIDid of layer
ubAlphaalpha-value
Returns
true if layer was found

◆ SetLayerChromaKey()

eC_Bool CGfxEnv::SetLayerChromaKey ( const eC_UInt &  uiLayerID,
const eC_Bool &  bChromaKeyActive,
const eC_UInt &  uiChromaKey,
const eC_UByte &  ubAlpha 
)

Set the chroma-key for blending between layer for the given layer.

Parameters
uiLayerIDid of layer
bChromaKeyActivetrue if chroma-keying is active
uiChromaKeythe color for chroma-keying
ubAlphaalpha-value for replacement
Returns
true if layer was found

◆ SetLayerPosition()

eC_Bool CGfxEnv::SetLayerPosition ( const eC_UInt &  uiLayerID,
const eC_Int &  iXPos,
const eC_Int &  iYPos 
)

Set the position for the given layer

Parameters
uiLayerIDid of layer
iXPosx-position
iYPosy-position
Returns
true if layer was found

◆ SetLayerVisible()

eC_Bool CGfxEnv::SetLayerVisible ( const eC_UInt &  uiLayerID,
const eC_Bool &  bVisible 
)

Set the layer to visible

Parameters
uiLayerIDid of layer
bVisiblevisibility of layer
Returns
true if layer was found

◆ SetLayerVisiblePos()

eC_Bool CGfxEnv::SetLayerVisiblePos ( const eC_UInt &  uiLayerID,
const eC_Int &  iXPos,
const eC_Int &  iYPos 
)

Set the visible position for the given layer

Parameters
uiLayerIDid of layer
iXPosx-position
iYPosy-position
Returns
true if layer was found

◆ SetLayerVisibleSize()

eC_Bool CGfxEnv::SetLayerVisibleSize ( const eC_UInt &  uiLayerID,
const eC_UInt &  uiWidth,
const eC_UInt &  uiHeight 
)

Set the visible size for the given layer

Parameters
uiLayerIDid of layer
uiWidthvisible width
uiHeightvisible height
Returns
true if layer was found

◆ SetMainLayerID()

void CGfxEnv::SetMainLayerID ( const eC_UInt &  uiLayerID)

This will set the id of the main-layer

Parameters
uiLayerIDid of layer

◆ SetMainLayerProperties()

void CGfxEnv::SetMainLayerProperties ( const eC_UInt &  uiLayerID,
const eC_Bool &  bCached 
)

Set the configuration of the main-layer

Parameters
uiLayerIDset layer-id (default: 0)
bCachedset to true if layer-memory is cached (default: false)

◆ SetObjectForLayerID()

void CGfxEnv::SetObjectForLayerID ( const eC_UInt &  uiLayerID,
CGUIObject pkObject 
)

This will link an object to a specific layer. this info is used in UpdateLayerPositions

Parameters
uiLayerIDid of layer
pkObjectpointer to object

◆ SetScreenPosition()

virtual void CGfxEnv::SetScreenPosition ( const eC_UInt &  uiX,
const eC_UInt &  uiY 
)
virtual

Set the screen position if available

Parameters
uiX
uiY

Reimplemented in CGfxEnvSDL, CGfxEnvSDL2, and CGfxEnvWin.

◆ SetScreenSize()

virtual void CGfxEnv::SetScreenSize ( const eC_UInt &  uiWidth,
const eC_UInt &  uiHeight 
)
virtual

Set the screen-size this will normally result in recreating the surfaces

Parameters
uiWidth
uiHeight

Reimplemented in CGfxEnvWayland, CGfxEnvSDL, CGfxEnvSDL2, and CGfxEnvWin.

◆ SetVSyncEnabled()

virtual void CGfxEnv::SetVSyncEnabled ( const eC_Bool &  bVSyncEnabled)
virtual

Set if VSync is enabled

Parameters
bVSyncEnabledset to true if VSync is enabled

◆ SetWindowCaption()

virtual void CGfxEnv::SetWindowCaption ( const eC_String &  kCaption)
inlinevirtual

Set the window caption

Parameters
kCaption

Reimplemented in CGfxEnvFBDevice, CGfxEnvWayland, CGfxEnvFBDeviceRZA2M, CGfxEnvSDL, CGfxEnvSDL2, and CGfxEnvWin.

◆ StartOfRefresh()

virtual void CGfxEnv::StartOfRefresh ( )
inlinevirtual

This will be called at the start of refresh

Reimplemented in CGfxEnvDAVE.

◆ SupportsCopy()

virtual eC_Bool CGfxEnv::SupportsCopy ( ) const
virtual

Get if copy is supported

Returns
copy supported

◆ SwapBuffers()

virtual eC_Bool CGfxEnv::SwapBuffers ( )
inlinevirtual

Swap buffers

Returns
true if successful

Reimplemented in CGfxEnvDRM, CGfxEnvFBDevice, CGfxEnvWayland, CGfxEnvFBDeviceRZA2M, CGfxEnvSDL, CGfxEnvSDL2, and CGfxEnvWin.

◆ UpdateLayer()

virtual void CGfxEnv::UpdateLayer ( const LayerConfiguration_t kLayerConfig,
const LayerUpdate_t &  eUpdateReason 
)
inlinevirtual

Update layer according to reason. This will be called when attributes of the layer (position, size, etc) have changed

Parameters
kLayerConfigconfiguration of updated layer
eUpdateReasonreason of update

Reimplemented in CGfxEnvDAVE, CGfxEnvDRM, and CGfxEnvWin.

◆ UpdateLayerBuffers()

virtual eC_Bool CGfxEnv::UpdateLayerBuffers ( const eC_UInt &  uiLayerID,
void *  pkRenderBuffer,
void *  pkDisplayBuffer,
const eC_UInt &  uiWidth,
const eC_UInt &  uiHeight 
)
virtual

Update buffers for layer

Parameters
uiLayerIDid of layer
pkRenderBuffercurrently used buffer for rendering
pkDisplayBuffercurrently used buffer for display
uiWidthwidth of layer
uiHeightheight of layer
Returns
true if successful

Reimplemented in CGfxEnvCDC, CGfxEnvCDCDI, CGfxEnvDAVE, CGfxEnvDRM, and CGfxEnvWin.

◆ UpdateLayerPositions()

void CGfxEnv::UpdateLayerPositions ( )

This will update the positions for all layers, BEFORE the redraw is done.

◆ UpdateMainLayer()

void CGfxEnv::UpdateMainLayer ( const CGUICommonEnums::ImageType_t eColorFormat,
const eC_UInt &  uiWidth,
const eC_UInt &  uiHeight,
const eC_UInt &  uiBufferCount,
void **  ppkBuffers 
)
protected

Update settings of main-layer

Parameters
eColorFormatcolor-format
uiWidthwidth
uiHeightheight
uiBufferCountnumber of buffers
ppkBufferspointer to buffers

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