mirror of
https://github.com/rofafor/vdr-plugin-iptv.git
synced 2023-10-10 13:37:03 +02:00
Updated for vdr-1.7.15.
This commit is contained in:
parent
6eb259e8fb
commit
899db53845
4
HISTORY
4
HISTORY
@ -138,6 +138,6 @@ VDR Plugin 'iptv' Revision History
|
|||||||
- Fixed channel parameter corruption.
|
- Fixed channel parameter corruption.
|
||||||
- Added Dutch translation (Thanks to Carel).
|
- Added Dutch translation (Thanks to Carel).
|
||||||
|
|
||||||
2010-xx-xx: Version 0.4.2
|
2010-06-06: Version 0.4.2
|
||||||
|
|
||||||
- Updated for vdr-1.7.14.
|
- Updated for vdr-1.7.15.
|
||||||
|
4
iptv.c
4
iptv.c
@ -12,8 +12,8 @@
|
|||||||
#include "setup.h"
|
#include "setup.h"
|
||||||
#include "device.h"
|
#include "device.h"
|
||||||
|
|
||||||
#if defined(APIVERSNUM) && APIVERSNUM < 10714
|
#if defined(APIVERSNUM) && APIVERSNUM < 10715
|
||||||
#error "VDR-1.7.14 API version or greater is required!"
|
#error "VDR-1.7.15 API version or greater is required!"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
static const char VERSION[] = "0.4.2";
|
static const char VERSION[] = "0.4.2";
|
||||||
|
13
pidscanner.c
13
pidscanner.c
@ -122,7 +122,9 @@ void cPidScanner::Process(const uint8_t* buf)
|
|||||||
cChannel *IptvChannel = Channels.GetByChannelID(channel.GetChannelID());
|
cChannel *IptvChannel = Channels.GetByChannelID(channel.GetChannelID());
|
||||||
if (IptvChannel) {
|
if (IptvChannel) {
|
||||||
int Apids[MAXAPIDS + 1] = { 0 }; // these lists are zero-terminated
|
int Apids[MAXAPIDS + 1] = { 0 }; // these lists are zero-terminated
|
||||||
|
int Atypes[MAXAPIDS + 1] = { 0 };
|
||||||
int Dpids[MAXDPIDS + 1] = { 0 };
|
int Dpids[MAXDPIDS + 1] = { 0 };
|
||||||
|
int Dtypes[MAXDPIDS + 1] = { 0 };
|
||||||
int Spids[MAXSPIDS + 1] = { 0 };
|
int Spids[MAXSPIDS + 1] = { 0 };
|
||||||
char ALangs[MAXAPIDS][MAXLANGCODE2] = { "" };
|
char ALangs[MAXAPIDS][MAXLANGCODE2] = { "" };
|
||||||
char DLangs[MAXDPIDS][MAXLANGCODE2] = { "" };
|
char DLangs[MAXDPIDS][MAXLANGCODE2] = { "" };
|
||||||
@ -136,18 +138,23 @@ void cPidScanner::Process(const uint8_t* buf)
|
|||||||
Apid = 0; // No detected audio pid
|
Apid = 0; // No detected audio pid
|
||||||
for (unsigned int i = 1; i < MAXAPIDS; ++i) {
|
for (unsigned int i = 1; i < MAXAPIDS; ++i) {
|
||||||
Apids[i] = IptvChannel->Apid(i);
|
Apids[i] = IptvChannel->Apid(i);
|
||||||
|
Atypes[i] = IptvChannel->Atype(i);
|
||||||
if (Apids[i] && (Apids[i] == Apid))
|
if (Apids[i] && (Apids[i] == Apid))
|
||||||
foundApid = true;
|
foundApid = true;
|
||||||
}
|
}
|
||||||
if (!foundApid)
|
if (!foundApid) {
|
||||||
Apids[0] = Apid;
|
Apids[0] = Apid;
|
||||||
for (unsigned int i = 0; i < MAXDPIDS; ++i)
|
Atypes[0] = 4;
|
||||||
|
}
|
||||||
|
for (unsigned int i = 0; i < MAXDPIDS; ++i) {
|
||||||
Dpids[i] = IptvChannel->Dpid(i);
|
Dpids[i] = IptvChannel->Dpid(i);
|
||||||
|
Dtypes[i] = IptvChannel->Dtype(i);
|
||||||
|
}
|
||||||
for (unsigned int i = 0; i < MAXSPIDS; ++i)
|
for (unsigned int i = 0; i < MAXSPIDS; ++i)
|
||||||
Spids[i] = IptvChannel->Spid(i);
|
Spids[i] = IptvChannel->Spid(i);
|
||||||
debug("cPidScanner::Process(): Vpid=0x%04X, Apid=0x%04X\n", Vpid, Apid);
|
debug("cPidScanner::Process(): Vpid=0x%04X, Apid=0x%04X\n", Vpid, Apid);
|
||||||
int Vtype = IptvChannel->Vtype();
|
int Vtype = IptvChannel->Vtype();
|
||||||
IptvChannel->SetPids(Vpid, Ppid, Vtype, Apids, ALangs, Dpids, DLangs, Spids, SLangs, Tpid);
|
IptvChannel->SetPids(Vpid, Ppid, Vtype, Apids, Atypes, ALangs, Dpids, Dtypes, DLangs, Spids, SLangs, Tpid);
|
||||||
}
|
}
|
||||||
Channels.Unlock();
|
Channels.Unlock();
|
||||||
process = false;
|
process = false;
|
||||||
|
Loading…
Reference in New Issue
Block a user