Kodi Documentation 22.0
Kodi is an open source media player and entertainment hub.
Loading...
Searching...
No Matches
KODI::GAME::IGameClientStream Class Referenceabstract

#include <IGameClientStream.h>

Inheritance diagram for KODI::GAME::IGameClientStream:
KODI::GAME::CGameClientStreamAudio KODI::GAME::CGameClientStreamVideo KODI::GAME::CGameClientStreamSwFramebuffer

Public Member Functions

virtual ~IGameClientStream ()=default
 
virtual bool OpenStream (RETRO::IRetroPlayerStream *stream, const game_stream_properties &properties)=0
 Open the stream.
 
virtual void CloseStream ()=0
 Release the RetroPlayer stream resource.
 
virtual bool GetBuffer (unsigned int width, unsigned int height, game_stream_buffer &buffer)
 Get a buffer for zero-copy stream data.
 
virtual void ReleaseBuffer (game_stream_buffer &buffer)
 Free an allocated buffer.
 
virtual void AddData (const game_stream_packet &packet)=0
 Add a data packet to a stream.
 

Constructor & Destructor Documentation

◆ ~IGameClientStream()

virtual KODI::GAME::IGameClientStream::~IGameClientStream ( )
virtualdefault

Member Function Documentation

◆ AddData()

virtual void KODI::GAME::IGameClientStream::AddData ( const game_stream_packet & packet)
pure virtual

Add a data packet to a stream.

Parameters
packetThe data packet

Implemented in KODI::GAME::CGameClientStreamAudio, and KODI::GAME::CGameClientStreamVideo.

◆ CloseStream()

virtual void KODI::GAME::IGameClientStream::CloseStream ( )
pure virtual

Release the RetroPlayer stream resource.

Implemented in KODI::GAME::CGameClientStreamAudio, and KODI::GAME::CGameClientStreamVideo.

◆ GetBuffer()

virtual bool KODI::GAME::IGameClientStream::GetBuffer ( unsigned int width,
unsigned int height,
game_stream_buffer & buffer )
inlinevirtual

Get a buffer for zero-copy stream data.

Parameters
widthThe framebuffer width, or 0 for no width specified
heightThe framebuffer height, or 0 for no height specified
[out]bufferThe buffer, or unmodified if false is returned

If this returns true, buffer must be freed using ReleaseBuffer().

Returns
True if buffer was set, false otherwise

Reimplemented in KODI::GAME::CGameClientStreamSwFramebuffer.

◆ OpenStream()

virtual bool KODI::GAME::IGameClientStream::OpenStream ( RETRO::IRetroPlayerStream * stream,
const game_stream_properties & properties )
pure virtual

Open the stream.

Parameters
streamThe RetroPlayer resource to take ownership of
Returns
True if the stream was opened, false otherwise

Implemented in KODI::GAME::CGameClientStreamAudio, and KODI::GAME::CGameClientStreamVideo.

◆ ReleaseBuffer()

virtual void KODI::GAME::IGameClientStream::ReleaseBuffer ( game_stream_buffer & buffer)
inlinevirtual

Free an allocated buffer.

Parameters
bufferThe buffer returned from GetBuffer()

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