Kodi Documentation 22.0
Kodi is an open source media player and entertainment hub.
Loading...
Searching...
No Matches
CRenderSystemGL Class Referenceabstract

#include <RenderSystemGL.h>

Inheritance diagram for CRenderSystemGL:
CRenderSystemBase CWinSystemOSXGL KODI::WINDOWING::GBM::CWinSystemGbmGLContext KODI::WINDOWING::WAYLAND::CWinSystemWaylandEGLContextGL KODI::WINDOWING::X11::CWinSystemX11GLContext

Public Member Functions

 CRenderSystemGL ()
 
 ~CRenderSystemGL () override
 
bool InitRenderSystem () override
 
bool DestroyRenderSystem () override
 
bool ResetRenderSystem (int width, int height) override
 
bool BeginRender () override
 
bool EndRender () override
 
void PresentRender (bool rendered, bool videoLayer) override
 
void InvalidateColorBuffer () override
 
bool ClearBuffers (KODI::UTILS::COLOR::Color color) override
 
bool IsExtSupported (const char *extension) const override
 
void SetVSync (bool vsync)
 
void ResetVSync ()
 
void SetViewPort (const CRect &viewPort) override
 
void GetViewPort (CRect &viewPort) override
 
bool ScissorsCanEffectClipping () override
 
CRect ClipRectToScissorRect (const CRect &rect) override
 
void SetScissors (const CRect &rect) override
 
void ResetScissors () override
 
void SetDepthCulling (DEPTH_CULLING culling) override
 
void CaptureStateBlock () override
 
void ApplyStateBlock () override
 
void SetCameraPosition (const CPoint &camera, int screenWidth, int screenHeight, float stereoFactor=0.0f) override
 
void SetStereoMode (RENDER_STEREO_MODE mode, RENDER_STEREO_VIEW view) override
 
bool SupportsStereo (RENDER_STEREO_MODE mode) const override
 
bool SupportsNPOT (bool dxt) const override
 
void Project (float &x, float &y, float &z) override
 
std::string GetShaderPath (const std::string &filename) override
 
void GetGLVersion (int &major, int &minor)
 
void GetGLSLVersion (int &major, int &minor)
 
void ResetGLErrors ()
 
void EnableShader (ShaderMethodGL method)
 
void DisableShader ()
 
GLint ShaderGetPos ()
 
GLint ShaderGetCol ()
 
GLint ShaderGetCoord0 ()
 
GLint ShaderGetCoord1 ()
 
GLint ShaderGetDepth ()
 
GLint ShaderGetUniCol ()
 
GLint ShaderGetModel ()
 
GLint ShaderGetMatrix ()
 
GLint ShaderGetClip ()
 
GLint ShaderGetCoordStep ()
 
- Public Member Functions inherited from CRenderSystemBase
 CRenderSystemBase ()
 
virtual ~CRenderSystemBase ()
 
virtual void RestoreViewPort ()
 
void GetRenderVersion (unsigned int &major, unsigned int &minor) const
 
const std::string & GetRenderVendor () const
 
const std::string & GetRenderRenderer () const
 
const std::string & GetRenderVersionString () const
 
unsigned int GetMaxTextureSize () const
 
unsigned int GetMinDXTPitch () const
 
virtual void ShowSplash (const std::string &message)
 

Protected Member Functions

virtual void SetVSyncImpl (bool enable)=0
 
virtual void PresentRenderImpl (bool rendered)=0
 
void CalculateMaxTexturesize ()
 
void InitialiseShaders ()
 
void ReleaseShaders ()
 

Protected Attributes

bool m_bVsyncInit = false
 
int m_width
 
int m_height
 
std::string m_RenderExtensions
 
int m_glslMajor = 0
 
int m_glslMinor = 0
 
GLint m_viewPort [4]
 
std::map< ShaderMethodGL, std::unique_ptr< CGLShader > > m_pShader
 
ShaderMethodGL m_method = ShaderMethodGL::SM_DEFAULT
 
GLuint m_vertexArray = GL_NONE
 
- Protected Attributes inherited from CRenderSystemBase
bool m_bRenderCreated
 
bool m_bVSync
 
unsigned int m_maxTextureSize
 
unsigned int m_minDXTPitch
 
std::string m_RenderRenderer
 
std::string m_RenderVendor
 
std::string m_RenderVersion
 
int m_RenderVersionMinor
 
int m_RenderVersionMajor
 
RENDER_STEREO_VIEW m_stereoView = RENDER_STEREO_VIEW_OFF
 
RENDER_STEREO_MODE m_stereoMode = RENDER_STEREO_MODE_OFF
 
bool m_limitedColorRange = false
 
bool m_transferPQ {false}
 
std::unique_ptr< CGUIImagem_splashImage
 
std::unique_ptr< CGUITextLayoutm_splashMessageLayout
 

Constructor & Destructor Documentation

◆ CRenderSystemGL()

CRenderSystemGL::CRenderSystemGL ( )

◆ ~CRenderSystemGL()

CRenderSystemGL::~CRenderSystemGL ( )
overridedefault

Member Function Documentation

◆ ApplyStateBlock()

void CRenderSystemGL::ApplyStateBlock ( )
overridevirtual

Implements CRenderSystemBase.

◆ BeginRender()

bool CRenderSystemGL::BeginRender ( )
overridevirtual

Implements CRenderSystemBase.

◆ CalculateMaxTexturesize()

void CRenderSystemGL::CalculateMaxTexturesize ( )
protected

◆ CaptureStateBlock()

void CRenderSystemGL::CaptureStateBlock ( )
overridevirtual

Implements CRenderSystemBase.

◆ ClearBuffers()

bool CRenderSystemGL::ClearBuffers ( KODI::UTILS::COLOR::Color color)
overridevirtual

Implements CRenderSystemBase.

◆ ClipRectToScissorRect()

CRect CRenderSystemGL::ClipRectToScissorRect ( const CRect & rect)
overridevirtual

Reimplemented from CRenderSystemBase.

◆ DestroyRenderSystem()

bool CRenderSystemGL::DestroyRenderSystem ( )
overridevirtual

Implements CRenderSystemBase.

◆ DisableShader()

void CRenderSystemGL::DisableShader ( )

◆ EnableShader()

void CRenderSystemGL::EnableShader ( ShaderMethodGL method)

◆ EndRender()

bool CRenderSystemGL::EndRender ( )
overridevirtual

Implements CRenderSystemBase.

◆ GetGLSLVersion()

void CRenderSystemGL::GetGLSLVersion ( int & major,
int & minor )

◆ GetGLVersion()

void CRenderSystemGL::GetGLVersion ( int & major,
int & minor )

◆ GetShaderPath()

std::string CRenderSystemGL::GetShaderPath ( const std::string & filename)
overridevirtual

Reimplemented from CRenderSystemBase.

◆ GetViewPort()

void CRenderSystemGL::GetViewPort ( CRect & viewPort)
overridevirtual

Implements CRenderSystemBase.

◆ InitialiseShaders()

void CRenderSystemGL::InitialiseShaders ( )
protected

◆ InitRenderSystem()

bool CRenderSystemGL::InitRenderSystem ( )
overridevirtual

Implements CRenderSystemBase.

◆ InvalidateColorBuffer()

void CRenderSystemGL::InvalidateColorBuffer ( )
overridevirtual

Reimplemented from CRenderSystemBase.

◆ IsExtSupported()

bool CRenderSystemGL::IsExtSupported ( const char * extension) const
overridevirtual

◆ PresentRender()

void CRenderSystemGL::PresentRender ( bool rendered,
bool videoLayer )
overridevirtual

◆ PresentRenderImpl()

◆ Project()

void CRenderSystemGL::Project ( float & x,
float & y,
float & z )
overridevirtual

Project (x,y,z) 3d scene coordinates to (x,y) 2d screen coordinates

Reimplemented from CRenderSystemBase.

◆ ReleaseShaders()

void CRenderSystemGL::ReleaseShaders ( )
protected

◆ ResetGLErrors()

void CRenderSystemGL::ResetGLErrors ( )

◆ ResetRenderSystem()

bool CRenderSystemGL::ResetRenderSystem ( int width,
int height )
overridevirtual

Implements CRenderSystemBase.

◆ ResetScissors()

void CRenderSystemGL::ResetScissors ( )
overridevirtual

Implements CRenderSystemBase.

◆ ResetVSync()

void CRenderSystemGL::ResetVSync ( )
inline

◆ ScissorsCanEffectClipping()

bool CRenderSystemGL::ScissorsCanEffectClipping ( )
overridevirtual

Reimplemented from CRenderSystemBase.

◆ SetCameraPosition()

void CRenderSystemGL::SetCameraPosition ( const CPoint & camera,
int screenWidth,
int screenHeight,
float stereoFactor = 0.0f )
overridevirtual

Implements CRenderSystemBase.

◆ SetDepthCulling()

void CRenderSystemGL::SetDepthCulling ( DEPTH_CULLING culling)
overridevirtual

Reimplemented from CRenderSystemBase.

◆ SetScissors()

void CRenderSystemGL::SetScissors ( const CRect & rect)
overridevirtual

Implements CRenderSystemBase.

◆ SetStereoMode()

void CRenderSystemGL::SetStereoMode ( RENDER_STEREO_MODE mode,
RENDER_STEREO_VIEW view )
overridevirtual

Reimplemented from CRenderSystemBase.

◆ SetViewPort()

void CRenderSystemGL::SetViewPort ( const CRect & viewPort)
overridevirtual

Implements CRenderSystemBase.

◆ SetVSync()

void CRenderSystemGL::SetVSync ( bool vsync)

◆ SetVSyncImpl()

◆ ShaderGetClip()

GLint CRenderSystemGL::ShaderGetClip ( )

◆ ShaderGetCol()

GLint CRenderSystemGL::ShaderGetCol ( )

◆ ShaderGetCoord0()

GLint CRenderSystemGL::ShaderGetCoord0 ( )

◆ ShaderGetCoord1()

GLint CRenderSystemGL::ShaderGetCoord1 ( )

◆ ShaderGetCoordStep()

GLint CRenderSystemGL::ShaderGetCoordStep ( )

◆ ShaderGetDepth()

GLint CRenderSystemGL::ShaderGetDepth ( )

◆ ShaderGetMatrix()

GLint CRenderSystemGL::ShaderGetMatrix ( )

◆ ShaderGetModel()

GLint CRenderSystemGL::ShaderGetModel ( )

◆ ShaderGetPos()

GLint CRenderSystemGL::ShaderGetPos ( )

◆ ShaderGetUniCol()

GLint CRenderSystemGL::ShaderGetUniCol ( )

◆ SupportsNPOT()

bool CRenderSystemGL::SupportsNPOT ( bool dxt) const
overridevirtual

Reimplemented from CRenderSystemBase.

◆ SupportsStereo()

bool CRenderSystemGL::SupportsStereo ( RENDER_STEREO_MODE mode) const
overridevirtual

Reimplemented from CRenderSystemBase.

Member Data Documentation

◆ m_bVsyncInit

bool CRenderSystemGL::m_bVsyncInit = false
protected

◆ m_glslMajor

int CRenderSystemGL::m_glslMajor = 0
protected

◆ m_glslMinor

int CRenderSystemGL::m_glslMinor = 0
protected

◆ m_height

int CRenderSystemGL::m_height
protected

◆ m_method

ShaderMethodGL CRenderSystemGL::m_method = ShaderMethodGL::SM_DEFAULT
protected

◆ m_pShader

std::map<ShaderMethodGL, std::unique_ptr<CGLShader> > CRenderSystemGL::m_pShader
protected

◆ m_RenderExtensions

std::string CRenderSystemGL::m_RenderExtensions
protected

◆ m_vertexArray

GLuint CRenderSystemGL::m_vertexArray = GL_NONE
protected

◆ m_viewPort

GLint CRenderSystemGL::m_viewPort[4]
protected

◆ m_width

int CRenderSystemGL::m_width
protected

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