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

#include <LinuxRendererGLES.h>

Inheritance diagram for CLinuxRendererGLES:
CBaseRenderer CRendererMediaCodec CRendererVAAPIGLES CRendererVTB

Classes

struct  CPictureBuffer
 
struct  CYuvPlane
 

Public Member Functions

 CLinuxRendererGLES ()
 
 ~CLinuxRendererGLES () override
 
bool Configure (const VideoPicture &picture, float fps, unsigned int orientation) override
 
bool IsConfigured () override
 
void AddVideoPicture (const VideoPicture &picture, int index) override
 
void UnInit () override
 
bool Flush (bool saveBuffers) override
 
void SetBufferSize (int numBuffers) override
 
bool IsGuiLayer () override
 
void ReleaseBuffer (int idx) override
 
void RenderUpdate (int index, int index2, bool clear, unsigned int flags, unsigned int alpha) override
 
void Update () override
 
bool RenderCapture (int index, CRenderCapture *capture) override
 
CRenderInfo GetRenderInfo () override
 
bool ConfigChanged (const VideoPicture &picture) override
 
bool SupportsMultiPassRendering () override
 
bool Supports (ERENDERFEATURE feature) const override
 
bool Supports (ESCALINGMETHOD method) const override
 
CRenderCaptureGetRenderCapture () override
 
- Public Member Functions inherited from CBaseRenderer
 CBaseRenderer ()
 
virtual ~CBaseRenderer ()
 
virtual bool IsPictureHW (const VideoPicture &picture)
 
virtual bool NeedBuffer (int idx)
 
virtual bool WantsDoublePass ()
 
void SetViewMode (int viewMode)
 
void GetVideoRect (CRect &source, CRect &dest, CRect &view) const
 Get video rectangle and view window.
 
float GetAspectRatio () const
 
unsigned int GetOrientation () const
 
void SetVideoSettings (const CVideoSettings &settings)
 
virtual DEBUG_INFO_VIDEO GetDebugInfo (int idx)
 

Static Public Member Functions

static CBaseRendererCreate (CVideoBuffer *buffer)
 
static bool Register ()
 
- Static Public Member Functions inherited from CBaseRenderer
static void SettingOptionsRenderMethodsFiller (const std::shared_ptr< const CSetting > &setting, std::vector< IntegerSettingOption > &list, int &current, void *data)
 

Protected Member Functions

virtual bool Render (unsigned int flags, int index)
 
virtual void RenderUpdateVideo (bool clear, unsigned int flags=0, unsigned int alpha=255)
 
int NextYV12Texture ()
 
virtual bool ValidateRenderTarget ()
 
virtual void LoadShaders (int field=FIELD_FULL)
 
virtual void ReleaseShaders ()
 
void SetTextureFilter (GLenum method)
 
void UpdateVideoFilter ()
 
void CheckVideoParameters (int index)
 
AVColorPrimaries GetSrcPrimaries (AVColorPrimaries srcPrimaries, unsigned int width, unsigned int height)
 
virtual bool UploadTexture (int index)
 
virtual void DeleteTexture (int index)
 
virtual bool CreateTexture (int index)
 
bool UploadYV12Texture (int index)
 
void DeleteYV12Texture (int index)
 
bool CreateYV12Texture (int index)
 
virtual bool SkipUploadYV12 (int index)
 
bool UploadNV12Texture (int index)
 
void DeleteNV12Texture (int index)
 
bool CreateNV12Texture (int index)
 
void CalculateTextureSourceRects (int source, int num_planes)
 
void RenderToFBO (int index, int field)
 
void RenderFromFBO ()
 
void RenderSinglePass (int index, int field)
 
virtual bool LoadShadersHook ()
 
virtual bool RenderHook (int idx)
 
virtual void AfterRenderHook (int idx)
 
void LoadPlane (CYuvPlane &plane, int type, unsigned width, unsigned height, int stride, int bpp, void *data)
 
- Protected Member Functions inherited from CBaseRenderer
void CalcDestRect (float offsetX, float offsetY, float width, float height, float inputFrameRatio, float zoomAmount, float verticalShift, CRect &destRect)
 
void CalcNormalRenderRect (float offsetX, float offsetY, float width, float height, float inputFrameRatio, float zoomAmount, float verticalShift)
 
void CalculateFrameAspectRatio (unsigned int desired_width, unsigned int desired_height)
 
virtual void ManageRenderArea ()
 
virtual void ReorderDrawPoints ()
 
virtual EShaderFormat GetShaderFormat ()
 
void MarkDirty ()
 
void EnableAlwaysClip ()
 
void saveRotatedCoords ()
 
void syncDestRectToRotatedPoints ()
 
void restoreRotatedCoords ()
 

Protected Attributes

struct { 
 
   CFrameBufferObject   fbo 
 
   float   width {0.0} 
 
   float   height {0.0} 
 
m_fbo 
 
int m_iYV12RenderBuffer {0}
 
int m_NumYV12Buffers {0}
 
bool m_bConfigured {false}
 
bool m_bValidated {false}
 
GLenum m_textureTarget = GL_TEXTURE_2D
 
int m_renderMethod {RENDER_GLSL}
 
RenderQuality m_renderQuality {RQ_SINGLEPASS}
 
int m_currentField {FIELD_FULL}
 
int m_reloadShaders {0}
 
CRenderSystemGLESm_renderSystem {nullptr}
 
GLenum m_pixelStoreKey {0}
 
CPictureBuffer m_buffers [NUM_BUFFERS]
 
Shaders::GLES::BaseYUV2RGBGLSLShaderm_pYUVProgShader {nullptr}
 
Shaders::GLES::BaseYUV2RGBGLSLShaderm_pYUVBobShader {nullptr}
 
Shaders::GLES::BaseVideoFilterShaderm_pVideoFilterShader {nullptr}
 
ESCALINGMETHOD m_scalingMethod {VS_SCALINGMETHOD_LINEAR}
 
ESCALINGMETHOD m_scalingMethodGui {VS_SCALINGMETHOD_MAX}
 
bool m_fullRange
 
AVColorPrimaries m_srcPrimaries
 
bool m_toneMap = false
 
ETONEMAPMETHOD m_toneMapMethod = VS_TONEMAPMETHOD_OFF
 
bool m_passthroughHDR = false
 
unsigned char * m_planeBuffer = nullptr
 
size_t m_planeBufferSize = 0
 
float m_clearColour {0.0f}
 
CRect m_viewRect
 
- Protected Attributes inherited from CBaseRenderer
unsigned int m_sourceWidth = 720
 
unsigned int m_sourceHeight = 480
 
float m_sourceFrameRatio = 1.0f
 
float m_fps = 0.0f
 
unsigned int m_renderOrientation = 0
 
CPoint m_rotatedDestCoords [4]
 
CPoint m_savedRotatedDestCoords [4]
 
CRect m_destRect
 
CRect m_sourceRect
 
CRect m_viewRect
 
unsigned m_iFlags = 0
 
AVPixelFormat m_format = AV_PIX_FMT_NONE
 
CVideoSettings m_videoSettings
 

Static Protected Attributes

static const int FIELD_FULL {0}
 
static const int FIELD_TOP {1}
 
static const int FIELD_BOT {2}
 

Constructor & Destructor Documentation

◆ CLinuxRendererGLES()

CLinuxRendererGLES::CLinuxRendererGLES ( )

◆ ~CLinuxRendererGLES()

CLinuxRendererGLES::~CLinuxRendererGLES ( )
override

Member Function Documentation

◆ AddVideoPicture()

void CLinuxRendererGLES::AddVideoPicture ( const VideoPicture & picture,
int index )
overridevirtual

Implements CBaseRenderer.

Reimplemented in CRendererMediaCodec.

◆ AfterRenderHook()

virtual void CLinuxRendererGLES::AfterRenderHook ( int idx)
inlineprotectedvirtual

Reimplemented in CRendererVAAPIGLES, CRendererVTB, and CRendererVTB.

◆ CalculateTextureSourceRects()

void CLinuxRendererGLES::CalculateTextureSourceRects ( int source,
int num_planes )
protected

◆ CheckVideoParameters()

void CLinuxRendererGLES::CheckVideoParameters ( int index)
protected

◆ ConfigChanged()

bool CLinuxRendererGLES::ConfigChanged ( const VideoPicture & picture)
overridevirtual

Implements CBaseRenderer.

Reimplemented in CRendererVAAPIGLES.

◆ Configure()

bool CLinuxRendererGLES::Configure ( const VideoPicture & picture,
float fps,
unsigned int orientation )
overridevirtual

Implements CBaseRenderer.

Reimplemented in CRendererVAAPIGLES.

◆ Create()

CBaseRenderer * CLinuxRendererGLES::Create ( CVideoBuffer * buffer)
static

◆ CreateNV12Texture()

bool CLinuxRendererGLES::CreateNV12Texture ( int index)
protected

◆ CreateTexture()

bool CLinuxRendererGLES::CreateTexture ( int index)
protectedvirtual

◆ CreateYV12Texture()

bool CLinuxRendererGLES::CreateYV12Texture ( int index)
protected

◆ DeleteNV12Texture()

void CLinuxRendererGLES::DeleteNV12Texture ( int index)
protected

◆ DeleteTexture()

void CLinuxRendererGLES::DeleteTexture ( int index)
protectedvirtual

◆ DeleteYV12Texture()

void CLinuxRendererGLES::DeleteYV12Texture ( int index)
protected

◆ Flush()

bool CLinuxRendererGLES::Flush ( bool saveBuffers)
overridevirtual

Reimplemented from CBaseRenderer.

◆ GetRenderCapture()

CRenderCapture * CLinuxRendererGLES::GetRenderCapture ( )
overridevirtual

Reimplemented from CBaseRenderer.

◆ GetRenderInfo()

CRenderInfo CLinuxRendererGLES::GetRenderInfo ( )
overridevirtual

Reimplemented from CBaseRenderer.

Reimplemented in CRendererMediaCodec.

◆ GetSrcPrimaries()

AVColorPrimaries CLinuxRendererGLES::GetSrcPrimaries ( AVColorPrimaries srcPrimaries,
unsigned int width,
unsigned int height )
protected

◆ IsConfigured()

bool CLinuxRendererGLES::IsConfigured ( )
inlineoverridevirtual

Implements CBaseRenderer.

◆ IsGuiLayer()

bool CLinuxRendererGLES::IsGuiLayer ( )
overridevirtual

Reimplemented from CBaseRenderer.

◆ LoadPlane()

void CLinuxRendererGLES::LoadPlane ( CYuvPlane & plane,
int type,
unsigned width,
unsigned height,
int stride,
int bpp,
void * data )
protected

◆ LoadShaders()

void CLinuxRendererGLES::LoadShaders ( int field = FIELD_FULL)
protectedvirtual

◆ LoadShadersHook()

virtual bool CLinuxRendererGLES::LoadShadersHook ( )
inlineprotectedvirtual

◆ NextYV12Texture()

int CLinuxRendererGLES::NextYV12Texture ( )
protected

◆ Register()

bool CLinuxRendererGLES::Register ( )
static

◆ ReleaseBuffer()

void CLinuxRendererGLES::ReleaseBuffer ( int idx)
overridevirtual

Reimplemented from CBaseRenderer.

Reimplemented in CRendererMediaCodec, CRendererVAAPIGLES, CRendererVTB, and CRendererVTB.

◆ ReleaseShaders()

void CLinuxRendererGLES::ReleaseShaders ( )
protectedvirtual

◆ Render()

bool CLinuxRendererGLES::Render ( unsigned int flags,
int index )
protectedvirtual

◆ RenderCapture()

bool CLinuxRendererGLES::RenderCapture ( int index,
CRenderCapture * capture )
overridevirtual

Implements CBaseRenderer.

◆ RenderFromFBO()

void CLinuxRendererGLES::RenderFromFBO ( )
protected

◆ RenderHook()

virtual bool CLinuxRendererGLES::RenderHook ( int idx)
inlineprotectedvirtual

Reimplemented in CRendererMediaCodec, and CRendererVAAPIGLES.

◆ RenderSinglePass()

void CLinuxRendererGLES::RenderSinglePass ( int index,
int field )
protected

◆ RenderToFBO()

void CLinuxRendererGLES::RenderToFBO ( int index,
int field )
protected

◆ RenderUpdate()

void CLinuxRendererGLES::RenderUpdate ( int index,
int index2,
bool clear,
unsigned int flags,
unsigned int alpha )
overridevirtual

Implements CBaseRenderer.

◆ RenderUpdateVideo()

void CLinuxRendererGLES::RenderUpdateVideo ( bool clear,
unsigned int flags = 0,
unsigned int alpha = 255 )
protectedvirtual

◆ SetBufferSize()

void CLinuxRendererGLES::SetBufferSize ( int numBuffers)
inlineoverridevirtual

Reimplemented from CBaseRenderer.

◆ SetTextureFilter()

void CLinuxRendererGLES::SetTextureFilter ( GLenum method)
protected

◆ SkipUploadYV12()

virtual bool CLinuxRendererGLES::SkipUploadYV12 ( int index)
inlineprotectedvirtual

◆ Supports() [1/2]

bool CLinuxRendererGLES::Supports ( ERENDERFEATURE feature) const
overridevirtual

Reimplemented from CBaseRenderer.

◆ Supports() [2/2]

bool CLinuxRendererGLES::Supports ( ESCALINGMETHOD method) const
overridevirtual

Implements CBaseRenderer.

◆ SupportsMultiPassRendering()

bool CLinuxRendererGLES::SupportsMultiPassRendering ( )
overridevirtual

Implements CBaseRenderer.

◆ UnInit()

void CLinuxRendererGLES::UnInit ( )
overridevirtual

Implements CBaseRenderer.

◆ Update()

void CLinuxRendererGLES::Update ( )
overridevirtual

Implements CBaseRenderer.

◆ UpdateVideoFilter()

void CLinuxRendererGLES::UpdateVideoFilter ( )
protected

◆ UploadNV12Texture()

bool CLinuxRendererGLES::UploadNV12Texture ( int index)
protected

◆ UploadTexture()

bool CLinuxRendererGLES::UploadTexture ( int index)
protectedvirtual

◆ UploadYV12Texture()

bool CLinuxRendererGLES::UploadYV12Texture ( int index)
protected

◆ ValidateRenderTarget()

bool CLinuxRendererGLES::ValidateRenderTarget ( )
protectedvirtual

Member Data Documentation

◆ fbo

CFrameBufferObject CLinuxRendererGLES::fbo

◆ FIELD_BOT

const int CLinuxRendererGLES::FIELD_BOT {2}
staticprotected

◆ FIELD_FULL

const int CLinuxRendererGLES::FIELD_FULL {0}
staticprotected

◆ FIELD_TOP

const int CLinuxRendererGLES::FIELD_TOP {1}
staticprotected

◆ height

float CLinuxRendererGLES::height {0.0}

◆ m_bConfigured

bool CLinuxRendererGLES::m_bConfigured {false}
protected

◆ m_buffers

CPictureBuffer CLinuxRendererGLES::m_buffers[NUM_BUFFERS]
protected

◆ m_bValidated

bool CLinuxRendererGLES::m_bValidated {false}
protected

◆ m_clearColour

float CLinuxRendererGLES::m_clearColour {0.0f}
protected

◆ m_currentField

int CLinuxRendererGLES::m_currentField {FIELD_FULL}
protected

◆ [struct]

struct { ... } CLinuxRendererGLES::m_fbo

◆ m_fullRange

bool CLinuxRendererGLES::m_fullRange
protected

◆ m_iYV12RenderBuffer

int CLinuxRendererGLES::m_iYV12RenderBuffer {0}
protected

◆ m_NumYV12Buffers

int CLinuxRendererGLES::m_NumYV12Buffers {0}
protected

◆ m_passthroughHDR

bool CLinuxRendererGLES::m_passthroughHDR = false
protected

◆ m_pixelStoreKey

GLenum CLinuxRendererGLES::m_pixelStoreKey {0}
protected

◆ m_planeBuffer

unsigned char* CLinuxRendererGLES::m_planeBuffer = nullptr
protected

◆ m_planeBufferSize

size_t CLinuxRendererGLES::m_planeBufferSize = 0
protected

◆ m_pVideoFilterShader

Shaders::GLES::BaseVideoFilterShader* CLinuxRendererGLES::m_pVideoFilterShader {nullptr}
protected

◆ m_pYUVBobShader

Shaders::GLES::BaseYUV2RGBGLSLShader* CLinuxRendererGLES::m_pYUVBobShader {nullptr}
protected

◆ m_pYUVProgShader

Shaders::GLES::BaseYUV2RGBGLSLShader* CLinuxRendererGLES::m_pYUVProgShader {nullptr}
protected

◆ m_reloadShaders

int CLinuxRendererGLES::m_reloadShaders {0}
protected

◆ m_renderMethod

int CLinuxRendererGLES::m_renderMethod {RENDER_GLSL}
protected

◆ m_renderQuality

RenderQuality CLinuxRendererGLES::m_renderQuality {RQ_SINGLEPASS}
protected

◆ m_renderSystem

CRenderSystemGLES* CLinuxRendererGLES::m_renderSystem {nullptr}
protected

◆ m_scalingMethod

ESCALINGMETHOD CLinuxRendererGLES::m_scalingMethod {VS_SCALINGMETHOD_LINEAR}
protected

◆ m_scalingMethodGui

ESCALINGMETHOD CLinuxRendererGLES::m_scalingMethodGui {VS_SCALINGMETHOD_MAX}
protected

◆ m_srcPrimaries

AVColorPrimaries CLinuxRendererGLES::m_srcPrimaries
protected

◆ m_textureTarget

GLenum CLinuxRendererGLES::m_textureTarget = GL_TEXTURE_2D
protected

◆ m_toneMap

bool CLinuxRendererGLES::m_toneMap = false
protected

◆ m_toneMapMethod

ETONEMAPMETHOD CLinuxRendererGLES::m_toneMapMethod = VS_TONEMAPMETHOD_OFF
protected

◆ m_viewRect

CRect CLinuxRendererGLES::m_viewRect
protected

◆ width

float CLinuxRendererGLES::width {0.0}

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