Skip to content

Commit

Permalink
Merge pull request #240 from ksooo/addon-api-9-2-0
Browse files Browse the repository at this point in the history
PVR Add-on API v9.2.0
  • Loading branch information
ksooo authored Oct 24, 2024
2 parents b8152a9 + c5e6123 commit 724f744
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 12 deletions.
2 changes: 1 addition & 1 deletion pvr.vdr.vnsi/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.vdr.vnsi"
version="22.1.0"
version="22.2.0"
name="VDR VNSI Client"
provider-name="Team Kodi, FernetMenta">
<requires>@ADDON_DEPENDS@</requires>
Expand Down
3 changes: 3 additions & 0 deletions pvr.vdr.vnsi/changelog.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
v22.2.0
- PVR Add-on API v9.2.0

v22.1.0
- PVR Add-on API v9.0.0

Expand Down
12 changes: 6 additions & 6 deletions src/ClientInstance.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1655,9 +1655,9 @@ PVR_ERROR CVNSIClientInstance::GetStreamTimes(kodi::addon::PVRStreamTimes& times
/*******************************************/
/** PVR Recording Stream Functions **/

bool CVNSIClientInstance::OpenRecordedStream(const kodi::addon::PVRRecording& recording)
bool CVNSIClientInstance::OpenRecordedStream(const kodi::addon::PVRRecording& recording, int64_t& streamId)
{
CloseRecordedStream();
CloseRecordedStream(streamId);

m_recording = new cVNSIRecording(*this);
try
Expand All @@ -1680,13 +1680,13 @@ bool CVNSIClientInstance::OpenRecordedStream(const kodi::addon::PVRRecording& re
}
}

void CVNSIClientInstance::CloseRecordedStream()
void CVNSIClientInstance::CloseRecordedStream(int64_t streamId)
{
delete m_recording;
m_recording = nullptr;
}

int CVNSIClientInstance::ReadRecordedStream(unsigned char* buffer, unsigned int size)
int CVNSIClientInstance::ReadRecordedStream(int64_t streamId, unsigned char* buffer, unsigned int size)
{
if (!m_recording)
return -1;
Expand All @@ -1702,7 +1702,7 @@ int CVNSIClientInstance::ReadRecordedStream(unsigned char* buffer, unsigned int
}
}

int64_t CVNSIClientInstance::SeekRecordedStream(int64_t position, int whence)
int64_t CVNSIClientInstance::SeekRecordedStream(int64_t streamId, int64_t position, int whence)
{
try
{
Expand All @@ -1717,7 +1717,7 @@ int64_t CVNSIClientInstance::SeekRecordedStream(int64_t position, int whence)
return -1;
}

int64_t CVNSIClientInstance::LengthRecordedStream()
int64_t CVNSIClientInstance::LengthRecordedStream(int64_t streamId)
{
if (m_recording)
return m_recording->Length();
Expand Down
10 changes: 5 additions & 5 deletions src/ClientInstance.h
Original file line number Diff line number Diff line change
Expand Up @@ -108,11 +108,11 @@ class ATTR_DLL_LOCAL CVNSIClientInstance : public kodi::addon::CInstancePVRClien

//--==----==----==----==----==----==----==----==----==----==----==----==----==

bool OpenRecordedStream(const kodi::addon::PVRRecording& recording) 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& recording, 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;
PVR_ERROR GetStreamReadChunkSize(int& chunksize) override;

//--==----==----==----==----==----==----==----==----==----==----==----==----==
Expand Down

0 comments on commit 724f744

Please sign in to comment.