Fixed the PremiereContentTransmissionDescriptor in 'libsi'

This commit is contained in:
Klaus Schmidinger 2006-05-28 14:42:21 +02:00
parent e892171736
commit 4355183150
6 changed files with 55 additions and 21 deletions

View File

@ -218,6 +218,7 @@ Stefan Huelswitt <huels@iname.com>
for suggesting that the SVDRP command GRAB should allow file names without extension
again
for reporting a problem with channel up/down switching on single card systems
for fixing the PremiereContentTransmissionDescriptor in 'libsi'
Ulrich Röder <roeder@efr-net.de>
for pointing out that there are channels that have a symbol rate higher than 27500

View File

@ -4745,3 +4745,8 @@ Video Disk Recorder Revision History
(reported by Mirko Dölle).
- Fixed deleting channels in case the current channel's number changes (reported
by Mirko Dölle).
2006-05-28: Version 1.4.0-3
- Fixed the PremiereContentTransmissionDescriptor in 'libsi' (thanks to Stefan
Huelswitt).

View File

@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
* $Id: config.h 1.257 2006/05/19 12:12:39 kls Exp $
* $Id: config.h 1.258 2006/05/28 14:42:21 kls Exp $
*/
#ifndef __CONFIG_H
@ -21,7 +21,7 @@
// VDR's own version number:
#define VDRVERSION "1.4.0-2"
#define VDRVERSION "1.4.0-3"
#define VDRVERSNUM 10400 // Version * 10000 + Major * 100 + Minor
// The plugin API's version number:

View File

@ -6,7 +6,7 @@
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
* *
* $Id: descriptor.c 1.20 2006/04/17 12:19:15 kls Exp $
* $Id: descriptor.c 1.21 2006/05/28 14:25:30 kls Exp $
* *
***************************************************************************/
@ -806,21 +806,34 @@ int PremiereContentTransmissionDescriptor::getServiceId() const {
return HILO(s->service_id);
}
int PremiereContentTransmissionDescriptor::getMJD() const {
void PremiereContentTransmissionDescriptor::Parse() {
s=data.getData<const descr_premiere_content_transmission>();
startDayLoop.setData(data+sizeof(descr_premiere_content_transmission), getLength()-sizeof(descr_premiere_content_transmission));
}
int PremiereContentTransmissionDescriptor::StartDayEntry::getMJD() const {
return HILO(s->mjd);
}
void PremiereContentTransmissionDescriptor::Parse() {
s=data.getData<const descr_premiere_content_transmission>();
startTimeLoop.setData(data+sizeof(descr_premiere_content_transmission), getLength()-sizeof(descr_premiere_content_transmission));
int PremiereContentTransmissionDescriptor::StartDayEntry::getLoopLength() const {
return s->start_time_loop;
}
time_t PremiereContentTransmissionDescriptor::StartTimeEntry::getStartTime(int mjd) const {
int PremiereContentTransmissionDescriptor::StartDayEntry::getLength() {
return sizeof(item_premiere_content_transmission_day)+getLoopLength();
}
void PremiereContentTransmissionDescriptor::StartDayEntry::Parse() {
s=data.getData<const item_premiere_content_transmission_day>();
startTimeLoop.setData(data+sizeof(item_premiere_content_transmission_day), getLoopLength());
}
time_t PremiereContentTransmissionDescriptor::StartDayEntry::StartTimeEntry::getStartTime(int mjd) const {
return DVBTime::getTime(mjd >> 8, mjd & 0xff, s->start_time_h, s->start_time_m, s->start_time_s);
}
void PremiereContentTransmissionDescriptor::StartTimeEntry::Parse() {
s=data.getData<const item_premiere_content_transmission_reference>();
void PremiereContentTransmissionDescriptor::StartDayEntry::StartTimeEntry::Parse() {
s=data.getData<const item_premiere_content_transmission_time>();
}
void ApplicationSignallingDescriptor::Parse() {

View File

@ -6,7 +6,7 @@
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
* *
* $Id: descriptor.h 1.14 2006/04/14 10:53:44 kls Exp $
* $Id: descriptor.h 1.15 2006/05/28 14:25:30 kls Exp $
* *
***************************************************************************/
@ -490,20 +490,30 @@ private:
class PremiereContentTransmissionDescriptor : public Descriptor {
public:
class StartTimeEntry : public LoopElement {
class StartDayEntry : public LoopElement {
public:
virtual int getLength() { return sizeof(item_premiere_content_transmission_reference); }
time_t getStartTime(int mjd) const; //UTC
class StartTimeEntry : public LoopElement {
public:
virtual int getLength() { return sizeof(item_premiere_content_transmission_time); }
time_t getStartTime(int mjd) const; //UTC
protected:
virtual void Parse();
private:
const item_premiere_content_transmission_time *s;
};
StructureLoop<StartTimeEntry> startTimeLoop;
virtual int getLength();
int getMJD() const;
int getLoopLength() const;
protected:
virtual void Parse();
private:
const item_premiere_content_transmission_reference *s;
const item_premiere_content_transmission_day *s;
};
StructureLoop<StartTimeEntry> startTimeLoop;
StructureLoop<StartDayEntry> startDayLoop;
int getOriginalNetworkId() const;
int getTransportStreamId() const;
int getServiceId() const;
int getMJD() const;
protected:
virtual void Parse();
private:

View File

@ -10,7 +10,7 @@
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
* *
* $Id: headers.h 1.6 2006/04/14 10:53:44 kls Exp $
* $Id: headers.h 1.7 2006/05/28 14:25:30 kls Exp $
* *
***************************************************************************/
@ -1790,7 +1790,7 @@ struct descr_application_icons_descriptor_end {
// 0xF2 Content Transmission Descriptor
// http://dvbsnoop.sourceforge.net/examples/example-private-section.html
#define DESCR_PREMIERE_CONTENT_TRANSMISSION_LEN 11
#define DESCR_PREMIERE_CONTENT_TRANSMISSION_LEN 8
struct descr_premiere_content_transmission {
u_char descriptor_tag :8;
@ -1801,14 +1801,19 @@ struct descr_premiere_content_transmission {
u_char original_network_id_lo :8;
u_char service_id_hi :8;
u_char service_id_lo :8;
};
#define ITEM_PREMIERE_CONTENT_TRANSMISSION_DAY_LEN 3
struct item_premiere_content_transmission_day {
u_char mjd_hi :8;
u_char mjd_lo :8;
u_char start_time_loop :8;
};
#define ITEM_PREMIERE_CONTENT_TRANSMISSION_LEN 3
#define ITEM_PREMIERE_CONTENT_TRANSMISSION_TIME_LEN 3
struct item_premiere_content_transmission_reference {
struct item_premiere_content_transmission_time {
u_char start_time_h :8;
u_char start_time_m :8;
u_char start_time_s :8;