xbmc
Public Member Functions | List of all members
KODI::SHADER::CShaderPresetGL Class Reference
Inheritance diagram for KODI::SHADER::CShaderPresetGL:
Inheritance graph
[legend]
Collaboration diagram for KODI::SHADER::CShaderPresetGL:
Collaboration graph
[legend]

Public Member Functions

 CShaderPresetGL (RETRO::CRenderContext &context, unsigned videoWidth=0, unsigned videoHeight=0)
 
bool ReadPresetFile (const std::string &presetPath) override
 Reads/Parses a shader preset file and loads its state to the object. What this state is is implementation specific. More...
 
bool RenderUpdate (const CPoint dest[], IShaderTexture *source, IShaderTexture *target) override
 Updates state if needed and renderes the preset to the target texture. More...
 
void SetSpeed (double speed) override
 Informs about the speed of playback. More...
 
void SetVideoSize (const unsigned videoWidth, const unsigned videoHeight) override
 Size of the input/source frame in pixels. More...
 
bool SetShaderPreset (const std::string &shaderPresetPath) override
 Set the preset to be rendered on the next frame. More...
 
const std::string & GetShaderPreset () const override
 Gets the full path to the shader preset. More...
 
ShaderPassVec & GetPasses () override
 Gets the passes of the loaded preset. More...
 
bool Update ()
 

Member Function Documentation

◆ GetPasses()

ShaderPassVec & CShaderPresetGL::GetPasses ( )
overridevirtual

Gets the passes of the loaded preset.

Returns
All the video shader passes of the currently loaded preset

Implements KODI::SHADER::IShaderPreset.

◆ GetShaderPreset()

const std::string & CShaderPresetGL::GetShaderPreset ( ) const
overridevirtual

Gets the full path to the shader preset.

Returns
The full path to the currently loaded preset file

Implements KODI::SHADER::IShaderPreset.

◆ ReadPresetFile()

bool CShaderPresetGL::ReadPresetFile ( const std::string &  presetPath)
overridevirtual

Reads/Parses a shader preset file and loads its state to the object. What this state is is implementation specific.

Parameters
presetPathFull path of the preset file.
Returns
True on successful parsing, false on failed.

Implements KODI::SHADER::IShaderPreset.

◆ RenderUpdate()

bool CShaderPresetGL::RenderUpdate ( const CPoint  dest[],
IShaderTexture source,
IShaderTexture target 
)
overridevirtual

Updates state if needed and renderes the preset to the target texture.

Parameters
destCoordinates of the 4 corners of the output viewport/window
sourceInput texture. The source of the video frame, in is original resolution (unscaled)
targetThe target texture. The texture that the final result will be rendered in.
Returns
Returns false if updating or rendering failed, true if both succeeded.

Implements KODI::SHADER::IShaderPreset.

◆ SetShaderPreset()

bool CShaderPresetGL::SetShaderPreset ( const std::string &  shaderPresetPath)
overridevirtual

Set the preset to be rendered on the next frame.

Parameters
shaderPresetPathFull path to the preset file to be loaded
Returns
Returns false if loading the preset failed, true otherwise.

Implements KODI::SHADER::IShaderPreset.

◆ SetSpeed()

void CShaderPresetGL::SetSpeed ( double  speed)
overridevirtual

Informs about the speed of playback.

Parameters
speedCommonly 1.0 for normal playback, and 0.0 if paused

Implements KODI::SHADER::IShaderPreset.

◆ SetVideoSize()

void CShaderPresetGL::SetVideoSize ( const unsigned  videoWidth,
const unsigned  videoHeight 
)
overridevirtual

Size of the input/source frame in pixels.

Parameters
videoWidthHeight of the source frame in pixels
videoHeightHeight of the source frame in pixels

Implements KODI::SHADER::IShaderPreset.


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