From bd61fee1e9328aec470c319494cccb90e53302c2 Mon Sep 17 00:00:00 2001 From: Klaus Schmidinger Date: Sun, 19 Jun 2011 12:41:00 +0200 Subject: Version 1.7.19 Original announce message: VDR developer version 1.7.19 is now available at MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ftp://ftp.tvdr.de/vdr/Developer/vdr-1.7.19.tar.bz2 A 'diff' against the previous version is available at ftp://ftp.tvdr.de/vdr/Developer/vdr-1.7.18-1.7.19.diff MD5 checksums: 1eb04ecdc2b11ab8641ebfaa2cb93f42 vdr-1.7.19.tar.bz2 db16ce7bb51e0db837ed56ef4744a67e vdr-1.7.18-1.7.19.diff WARNING: ======== This is a developer version. Even though I use it in my productive environment. I strongly recommend that you only use it under controlled conditions and for testing and debugging. This version introduces functions to determine the "signal strength" and "signal quality" through cDevice. If you are using a DVB card that contains an stb0899 frontend chip (like the TT-budget S2-3200) you may want to apply the patches from ftp://ftp.tvdr.de/vdr/Developer/Driver-Patches to the LinuxDVB driver source in order to receive useful results from that frontend. Since apparently the various frontend drivers return different maximum values in their FE_READ_SIGNAL_STRENGTH and FE_READ_SNR functions (some deliver a value in the range 0x0000...0xFFFF, while others return values as "dB/10" or "dBm/10" (the latter with an offset to make the value positive, since the parameter is unsigned), the functions cDvbTuner::GetSignalStrength() and cDvbTuner::GetSignalQuality() use the device's "subsystem ID" to map these values into the range 0...100, which is the normalized return value of these functions. Take a look at these two functions and maybe remove the comment characters from the lines //#define DEBUG_SIGNALSTRENGTH //#define DEBUG_SIGNALQUALITY in dvbdevice.c to get some debug output if your device doesn't return any directly useful values and may have to be added appropriately to the 'switch (subsystemId)' statement. The channel display of the 'sttng' skin uses these values to implement a signal strength/quality display. From the HISTORY file: - Fixed cString's operator=(const char *String) in case the given string is the same as the existing one (thanks to Dirk Leber). - Avoiding a gcc 4.6 compiler error in the skincurses plugin (thanks to Tobias Grimm). - TsGetPayload() now checks if there actually is a payload in the given TS packet (reported by Dirk Leber). - Now sorting the source file names in the call to xgettext, to make sure the results are not dependent on the sequence of the files. Plugin authors may want to change the line containing the xgettext call in their Makefile accordingly by changing "$^" to "`ls $^`". - The primary device is now only avoided for recording if it is an old SD full featured card. This is done through the new function cDevice::AvoidRecording(). - Subtitle PIDs are now also decrypted (thanks to Reinhard Nissl). - Fixed a possible race condition in cDiseqc::Execute() (reported by Marco Göbenich). The return value of cDiseqcs::Get() is now const, so plugin authors may need to adjust their code if they use this function. - The new functions cDevice::SignalStrength() and cDevice::SignalQuality() can be used to determine the signal strength and quality of a given device (thanks to Rolf Ahrenberg for some input on how to use BER and UNC values to generate a "quality" value). - The 'sttng' skin now displays two colored bars at the bottom of the channel display, indicating the strength (upper bar) and quality (lower bar) of the received signal. The number to the left of these bars indicates the actual device the current channel is being received with. - Fixed detecting frames in case the Picture Start Code or Access Unit Delimiter extends over TS packet boundaries (reported by Johan Andersson). In order to fix this, the semantics of cFrameDetector had to be changed a little. See cRecorder::Action() and cIndexFileGenerator::Action() on how to use the new cFrameDetector::NewPayload() function. - The frame detector now only starts collecting PTS values after it has seen the first I-frame, otherwise it might get MaxPtsValues values and stop analyzing even though the incoming data is still garbage (reported by Derek Kelly). - The info file of a recording is now only overwritten with a new fps value if that new value is not the default value (thanks to Derek Kelly for reporting a problem with the fps value being overwritten in case a recording was interrupted and resumed, and the fps value could not be determined after resuming recording). - The initial channel is now stored by the channel ID in the setup.conf file, in order to avoid problems in case channels are reordered or deleted (reported by Lars Bläser). - Added support for "content identifier descriptor" and "default authority descriptor" to 'libsi' (thanks to Dave Pickles). --- libsi/descriptor.c | 29 ++++++++++++++++++++++++++++- libsi/descriptor.h | 27 ++++++++++++++++++++++++++- libsi/headers.h | 20 +++++++++++++++++++- libsi/si.c | 10 +++++++--- 4 files changed, 80 insertions(+), 6 deletions(-) (limited to 'libsi') diff --git a/libsi/descriptor.c b/libsi/descriptor.c index 59f636a..06a58c0 100644 --- a/libsi/descriptor.c +++ b/libsi/descriptor.c @@ -6,7 +6,7 @@ * the Free Software Foundation; either version 2 of the License, or * * (at your option) any later version. * * * - * $Id: descriptor.c 2.1 2010/11/01 15:24:31 kls Exp $ + * $Id: descriptor.c 2.2 2011/06/15 21:26:00 kls Exp $ * * ***************************************************************************/ @@ -643,6 +643,33 @@ void ServiceIdentifierDescriptor::Parse() { textualServiceIdentifier.setData(data+sizeof(descr_service_identifier), getLength()-sizeof(descr_service_identifier)); } +void ContentIdentifierDescriptor::Parse() { + identifierLoop.setData(data+sizeof(descr_content_identifier), getLength()-sizeof(descr_content_identifier)); +} + +void ContentIdentifierDescriptor::Identifier::Parse() { + int offset=0; + data.setPointerAndOffset(s, offset); + if (s->crid_location == 0) { + identifier.setData(data+(offset-1), s->crid_length); + } + else { + identifier.setData(data+(offset-1), 2); + } +} + +int ContentIdentifierDescriptor::Identifier::getCridType() const { + return s->crid_type; +} + +int ContentIdentifierDescriptor::Identifier::getCridLocation() const { + return s->crid_location; +} + +void DefaultAuthorityDescriptor::Parse() { + DefaultAuthority.setData(data+sizeof(descr_default_authority), getLength()-sizeof(descr_default_authority)); +} + void MultilingualNameDescriptor::Parse() { nameLoop.setData(data+sizeof(descr_multilingual_network_name), getLength()-sizeof(descr_multilingual_network_name)); } diff --git a/libsi/descriptor.h b/libsi/descriptor.h index 4f2e41b..f105f7a 100644 --- a/libsi/descriptor.h +++ b/libsi/descriptor.h @@ -6,7 +6,7 @@ * the Free Software Foundation; either version 2 of the License, or * * (at your option) any later version. * * * - * $Id: descriptor.h 2.1 2010/11/01 15:24:32 kls Exp $ + * $Id: descriptor.h 2.2 2011/06/15 21:26:00 kls Exp $ * * ***************************************************************************/ @@ -361,6 +361,31 @@ protected: virtual void Parse(); }; +class ContentIdentifierDescriptor : public Descriptor { +public: + class Identifier : public LoopElement { + public: + String identifier; + int getCridType() const; + int getCridLocation() const; + virtual int getLength() { return sizeof(content_identifier_entry)+identifier.getLength(); } + protected: + virtual void Parse(); + private: + const content_identifier_entry *s; + }; + StructureLoop identifierLoop; +protected: + virtual void Parse(); +}; + +class DefaultAuthorityDescriptor : public Descriptor { +public: + String DefaultAuthority; //ID +protected: + virtual void Parse(); +}; + //abstract base class class MultilingualNameDescriptor : public Descriptor { public: diff --git a/libsi/headers.h b/libsi/headers.h index 3ec35de..6867d2c 100644 --- a/libsi/headers.h +++ b/libsi/headers.h @@ -10,7 +10,7 @@ * the Free Software Foundation; either version 2 of the License, or * * (at your option) any later version. * * * - * $Id: headers.h 2.1 2010/11/01 15:24:32 kls Exp $ + * $Id: headers.h 2.2 2011/06/15 21:26:00 kls Exp $ * * ***************************************************************************/ @@ -1680,6 +1680,24 @@ struct descr_content_identifier { u_char descriptor_length :8; }; +struct content_identifier_entry { +#if BYTE_ORDER == BIG_ENDIAN + u_char crid_type :6; + u_char crid_location :2; +#else + u_char crid_location :2; + u_char crid_type :6; +#endif + union { + u_char crid_length :8; + u_char crid_ref_hi :8; + }; + union { + u_char crid_byte :8; + u_char crid_ref_lo :8; + }; +}; + /* 0x77 time_slice_fec_identifier_descriptor (ETSI EN 301 192) */ struct descr_time_slice_fec_identifier { diff --git a/libsi/si.c b/libsi/si.c index 3991178..840b3a1 100644 --- a/libsi/si.c +++ b/libsi/si.c @@ -6,7 +6,7 @@ * the Free Software Foundation; either version 2 of the License, or * * (at your option) any later version. * * * - * $Id: si.c 2.3 2010/11/01 15:24:32 kls Exp $ + * $Id: si.c 2.4 2011/06/15 21:26:00 kls Exp $ * * ***************************************************************************/ @@ -609,6 +609,12 @@ Descriptor *Descriptor::getDescriptor(CharArray da, DescriptorTagDomain domain, case RegistrationDescriptorTag: d=new RegistrationDescriptor(); break; + case ContentIdentifierDescriptorTag: + d=new ContentIdentifierDescriptor(); + break; + case DefaultAuthorityDescriptorTag: + d=new DefaultAuthorityDescriptor(); + break; //note that it is no problem to implement one //of the unimplemented descriptors. @@ -650,10 +656,8 @@ Descriptor *Descriptor::getDescriptor(CharArray da, DescriptorTagDomain domain, case TransportStreamDescriptorTag: //defined in ETSI EN 300 468 v 1.7.1 - case DefaultAuthorityDescriptorTag: case RelatedContentDescriptorTag: case TVAIdDescriptorTag: - case ContentIdentifierDescriptorTag: case TimeSliceFecIdentifierDescriptorTag: case ECMRepetitionRateDescriptorTag: case EnhancedAC3DescriptorTag: -- cgit v1.2.3