summaryrefslogtreecommitdiff
path: root/device.h
diff options
context:
space:
mode:
authorKlaus Schmidinger <kls (at) cadsoft (dot) de>2009-01-06 20:31:53 +0100
committerKlaus Schmidinger <kls (at) cadsoft (dot) de>2009-01-06 20:31:53 +0100
commitc2966475942fcb9d4b8d41dbf026ff57630a1ad6 (patch)
tree1b41925820073ddee361c5acb0fd68fbadcd11a8 /device.h
parent1834751c4510edb66c96d0b741def5922738e74c (diff)
downloadvdr-patch-lnbsharing-c2966475942fcb9d4b8d41dbf026ff57630a1ad6.tar.gz
vdr-patch-lnbsharing-c2966475942fcb9d4b8d41dbf026ff57630a1ad6.tar.bz2
Version 1.7.3vdr-1.7.3
- Updated the Russian OSD texts (thanks to Oleg Roitburd). - Fixed handling the 'pointer field' in generating and parsing PAT/PMT (thanks to Frank Schmirler). - Fixed handling modulation types for DVB-S transponders when processing the NIT. - Changed cDvbDevice::GrabImage() to use V4L2 (thanks to Marco Schlüßler). - Added a poll to cDvbDevice::PlayVideo() and cDvbDevice::PlayAudio() to avoid excessive CPU load (this is just a makeshift solution until the FF DVB cards can play TS directly). - The recording format is now Transport Stream. Existing recordings in PES format can still be replayed and edited, but new recordings are done in TS. All code for recording in PES has been removed. The following changes were made to switch to TS recording format: + The index file format has been changed to support file sizes of up to 1TB (previously 2GB), and up to 65535 separate files per recording (previously 255). + The recording file names are now of the form 00001.ts (previously 001.vdr). + The frame rate is now detected by looking at two subsequent PTS values. The "frame duration" (in multiples of 1/90000) is stored in the info.vdr file using the new tag F (thanks to Artur Skawina for helping to get the IndexToHMSF() calculation right). + Several functions now have an additional parameter FramesPerSecond. + Several functions now have an additional parameter IsPesRecording. + The functionality of cFileWriter was moved into cRecorder, and cRemux is now obsolete. This also avoids one level of data copying while recording. + cRemux, cRingBufferLinearPes, cTS2PES and all c*Repacker classes have been removed. + A PAT/PMT is inserted before every independent frame, so that no extra measures need to be taken when editing a recording. + The directory name for a recording has been changed from YYYY-MM-DD-hh[.:]mm.pr.lt.rec (pr=priority, lt=lifetime) to YYYY-MM-DD-hh.mm.ch-ri.rec (ch=channel, ri=resumeId). Priority and Lifetime are now stored in the info.vdr file with the new tags P and L (if no such file exists, the maximum values are assumed by default, which avoids inadvertently deleting a recording if disk space is low). No longer storing Priority and Lifetime in the directory name avoids starting a new recording if one of these is changed in the timer and the recording is re-started for some reason. Instead of Priority and Lifetime, the directory name now contains the channel number from which the recording was made, and the "resume id" of this instance of VDR. This avoids problems if several VDR instances record the same show on different channels, or even on the same channel. The '-' between channel number and resumeId prevents older versions of VDR from "seeing" these recordings, which makes sure they won't even try to replay them, or remove them in case the disk runs full. + The semantics of PlayTs*() have been changed. These functions are now required to return the given Length (which is TS_SIZE) if they have processed the TS packet. + The files "index", "info", "marks" and "resume" within a TS recording directory are now created without the ".vdr" extension. + The "resume" file is no longer a binary file, but contains tagged lines to be able to store additional information, like the selected audio or subtitle track. + cDevice::StillPicture() will now be called with either TS or PES data. + cDvbPlayer::Goto() no longer appends a "sequence end code" to the data. If the output device needs this, it has to take care of it by itself. - Fixed cPatPmtParser::ParsePmt() to reset vpid and vtype when switching from a video to an audio channel (thanks to Reinhard Nissl). - cDvbDevice now uses the FE_CAN_2G_MODULATION flag to determine whether a device can handle DVB-S2. The #define is still there to allow people with older drivers who don't need DVB-S2 to use this version without pathcing.
Diffstat (limited to 'device.h')
-rw-r--r--device.h19
1 files changed, 11 insertions, 8 deletions
diff --git a/device.h b/device.h
index 2ce658c..7c4a709 100644
--- a/device.h
+++ b/device.h
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: device.h 2.3 2008/09/14 13:44:54 kls Exp $
+ * $Id: device.h 2.4 2009/01/05 16:28:06 kls Exp $
*/
#ifndef __DEVICE_H
@@ -518,8 +518,7 @@ protected:
///< Data points to exactly one complete TS packet of the given Length
///< (which is always TS_SIZE).
///< PlayTsVideo() shall process the packet either as a whole (returning
- ///< a positive number, which needs not necessarily be Length) or not at all
- ///< (returning 0 or -1 and setting 'errno' to EAGAIN).
+ ///< Length) or not at all (returning 0 or -1 and setting 'errno' accordingly).
///< The default implementation collects all incoming TS payload belonging
///< to one PES packet and calls PlayVideo() with the resulting packet.
virtual int PlayTsAudio(const uchar *Data, int Length);
@@ -527,8 +526,7 @@ protected:
///< Data points to exactly one complete TS packet of the given Length
///< (which is always TS_SIZE).
///< PlayTsAudio() shall process the packet either as a whole (returning
- ///< a positive number, which needs not necessarily be Length) or not at all
- ///< (returning 0 or -1 and setting 'errno' to EAGAIN).
+ ///< Length) or not at all (returning 0 or -1 and setting 'errno' accordingly).
///< The default implementation collects all incoming TS payload belonging
///< to one PES packet and calls PlayAudio() with the resulting packet.
virtual int PlayTsSubtitle(const uchar *Data, int Length);
@@ -536,8 +534,7 @@ protected:
///< Data points to exactly one complete TS packet of the given Length
///< (which is always TS_SIZE).
///< PlayTsSubtitle() shall process the packet either as a whole (returning
- ///< a positive number, which needs not necessarily be Length) or not at all
- ///< (returning 0 or -1 and setting 'errno' to EAGAIN).
+ ///< Length) or not at all (returning 0 or -1 and setting 'errno' accordingly).
///< The default implementation collects all incoming TS payload belonging
///< to one PES packet and displays the resulting subtitle via the OSD.
public:
@@ -573,6 +570,10 @@ public:
///< all registered cAudio objects are notified.
virtual void StillPicture(const uchar *Data, int Length);
///< Displays the given I-frame as a still picture.
+ ///< Data points either to TS (first byte is 0x47) or PES (first byte
+ ///< is 0x00) data of the given Length. The default implementation
+ ///< converts TS to PES and calls itself again, allowing a derived class
+ ///< to display PES if it can't handle TS directly.
virtual bool Poll(cPoller &Poller, int TimeoutMs = 0);
///< Returns true if the device itself or any of the file handles in
///< Poller is ready for further action.
@@ -600,12 +601,14 @@ public:
///< which is necessary for trick modes like 'fast forward'.
///< Data points to a single TS packet, Length is always TS_SIZE (the total
///< size of a single TS packet).
+ ///< If Data is NULL any leftover data from a previous call will be
+ ///< discarded.
///< A derived device can reimplement this function to handle the
///< TS packets itself. Any packets the derived function can't handle
///< must be sent to the base class function. This applies especially
///< to the PAT/PMT packets.
///< Returns -1 in case of error, otherwise the number of actually
- ///< processed bytes is returned, which may be less than Length.
+ ///< processed bytes is returned, which must be Length.
///< PlayTs() shall process the packet either as a whole (returning
///< a positive number, which needs not necessarily be Length) or not at all
///< (returning 0 or -1 and setting 'errno' to EAGAIN).