Skip to content
This repository has been archived by the owner on Apr 15, 2023. It is now read-only.

Commit

Permalink
Update PVR API to v1.5.0 (pause/seek support for LiveTV streams)
Browse files Browse the repository at this point in the history
  • Loading branch information
margro committed Oct 9, 2012
1 parent 9e7a5ba commit a13c545
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 2 deletions.
22 changes: 22 additions & 0 deletions xbmc/xbmc_pvr_dll.h
Original file line number Diff line number Diff line change
Expand Up @@ -512,6 +512,25 @@ extern "C"
*/
unsigned int GetChannelSwitchDelay(void);

/*!
* Check if the backend support pausing the currently playing stream
* This will enable/disable the pause button in XBMC based on the return value
* @return false if the PVR addon/backend does not support pausing, true if possible
*/
bool CanPauseStream();

/*!
* Check if the backend supports seeking for the currently playing stream
* This will enable/disable the rewind/forward buttons in XBMC based on the return value
* @return false if the PVR addon/backend does not support seeking, true if possible
*/
bool CanSeekStream();

/*!
* @brief Notify the pvr addon that XBMC (un)paused the currently playing stream
*/
void PauseStream(bool bPaused);

/*!
* Called by XBMC to assign the function pointers of this add-on to pClient.
* @param pClient The struct to assign the function pointers to.
Expand Down Expand Up @@ -568,6 +587,9 @@ extern "C"
pClient->SignalStatus = SignalStatus;
pClient->GetLiveStreamURL = GetLiveStreamURL;
pClient->GetChannelSwitchDelay = GetChannelSwitchDelay;
pClient->CanPauseStream = CanPauseStream;
pClient->PauseStream = PauseStream;
pClient->CanSeekStream = CanSeekStream;

pClient->OpenRecordedStream = OpenRecordedStream;
pClient->CloseRecordedStream = CloseRecordedStream;
Expand Down
7 changes: 5 additions & 2 deletions xbmc/xbmc_pvr_types.h
Original file line number Diff line number Diff line change
Expand Up @@ -72,10 +72,10 @@ struct DemuxPacket;
#define PVR_STREAM_MAX_STREAMS 20

/* current PVR API version */
#define XBMC_PVR_API_VERSION "1.4.0"
#define XBMC_PVR_API_VERSION "1.5.0"

/* min. PVR API version */
#define XBMC_PVR_MIN_API_VERSION "1.4.0"
#define XBMC_PVR_MIN_API_VERSION "1.5.0"

#ifdef __cplusplus
extern "C" {
Expand Down Expand Up @@ -329,6 +329,9 @@ extern "C" {
void (__cdecl* DemuxFlush)(void);
DemuxPacket* (__cdecl* DemuxRead)(void);
unsigned int (__cdecl* GetChannelSwitchDelay)(void);
bool (__cdecl* CanPauseStream)(void);
void (__cdecl* PauseStream)(bool);
bool (__cdecl* CanSeekStream)(void);
} PVRClient;

#ifdef __cplusplus
Expand Down

0 comments on commit a13c545

Please sign in to comment.