Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PVR Add-on API v9.2.0 #273

Merged
merged 1 commit into from
Oct 24, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pvr.nextpvr/addon.xml.in
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<addon
id="pvr.nextpvr"
version="22.2.0"
version="22.3.0"
name="NextPVR PVR Client"
provider-name="Graeme Blackley">
<requires>@ADDON_DEPENDS@
Expand Down
2 changes: 2 additions & 0 deletions pvr.nextpvr/changelog.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
v22.3.0
- PVR Add-on API v9.2.0

v22.2.0
- Start timeshift in realtime for radio playback
Expand Down
12 changes: 6 additions & 6 deletions src/pvrclient-nextpvr.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ cPVRClientNextPVR::~cPVRClientNextPVR()
{
// this is likley only needed for transcoding but include all cases
if (m_nowPlaying == Recording)
CloseRecordedStream();
CloseRecordedStream(-1);
else
CloseLiveStream();
}
Expand Down Expand Up @@ -740,7 +740,7 @@ bool cPVRClientNextPVR::CanSeekStream(void)
/** Record stream handling */


bool cPVRClientNextPVR::OpenRecordedStream(const kodi::addon::PVRRecording& recording)
bool cPVRClientNextPVR::OpenRecordedStream(const kodi::addon::PVRRecording& recording, int64_t& streamId)
{
kodi::addon::PVRRecording copyRecording = recording;
m_nowPlaying = Recording;
Expand All @@ -749,7 +749,7 @@ bool cPVRClientNextPVR::OpenRecordedStream(const kodi::addon::PVRRecording& reco
return m_recordingBuffer->Open(line, copyRecording);
}

void cPVRClientNextPVR::CloseRecordedStream(void)
void cPVRClientNextPVR::CloseRecordedStream(int64_t streamId)
{
if (IsServerStreamingRecording())
{
Expand All @@ -759,7 +759,7 @@ void cPVRClientNextPVR::CloseRecordedStream(void)
m_nowPlaying = NotPlaying;
}

int cPVRClientNextPVR::ReadRecordedStream(unsigned char* pBuffer, unsigned int iBufferSize)
int cPVRClientNextPVR::ReadRecordedStream(int64_t streamId, unsigned char* pBuffer, unsigned int iBufferSize)
{
if (IsServerStreamingRecording())
{
Expand All @@ -768,7 +768,7 @@ int cPVRClientNextPVR::ReadRecordedStream(unsigned char* pBuffer, unsigned int i
return -1;
}

int64_t cPVRClientNextPVR::SeekRecordedStream(int64_t iPosition, int iWhence)
int64_t cPVRClientNextPVR::SeekRecordedStream(int64_t streamId, int64_t iPosition, int iWhence)
{
if (IsServerStreamingRecording())
{
Expand All @@ -777,7 +777,7 @@ int64_t cPVRClientNextPVR::SeekRecordedStream(int64_t iPosition, int iWhence)
return -1;
}

int64_t cPVRClientNextPVR::LengthRecordedStream(void)
int64_t cPVRClientNextPVR::LengthRecordedStream(int64_t streamId)
{
if (IsServerStreamingRecording())
{
Expand Down
10 changes: 5 additions & 5 deletions src/pvrclient-nextpvr.h
Original file line number Diff line number Diff line change
Expand Up @@ -87,11 +87,11 @@ class ATTR_DLL_LOCAL cPVRClientNextPVR : public kodi::addon::CInstancePVRClient
bool IsServerStreamingRecording(bool log = true);

/* Record stream handling */
bool OpenRecordedStream(const kodi::addon::PVRRecording& recinfo) override;
void CloseRecordedStream() override;
int ReadRecordedStream(unsigned char* buffer, unsigned int size) override;
int64_t SeekRecordedStream(int64_t position, int whence) override;
int64_t LengthRecordedStream() override;
bool OpenRecordedStream(const kodi::addon::PVRRecording& recinfo, int64_t& streamId) override;
void CloseRecordedStream(int64_t streamId) override;
int ReadRecordedStream(int64_t streamId, unsigned char* buffer, unsigned int size) override;
int64_t SeekRecordedStream(int64_t streamId, int64_t position, int whence) override;
int64_t LengthRecordedStream(int64_t streamId) override;

void ForceRecordingUpdate() { m_lastRecordingUpdateTime = 0; }

Expand Down