summaryrefslogtreecommitdiff
path: root/remux.h
diff options
context:
space:
mode:
authorKlaus Schmidinger <Klaus (dot) Schmidinger (at) tvdr (dot) de>2009-11-22 15:58:00 +0100
committerKlaus Schmidinger <Klaus (dot) Schmidinger (at) tvdr (dot) de>2009-11-22 15:58:00 +0100
commitea01358b3bca9d55402ba632c95cdd6458abfdb3 (patch)
tree3a92e952e0c8de3cf109748da749b2841fed0da0 /remux.h
parent06bf4c453e22a9bf03f5ec46f7b45593e2cb326c (diff)
downloadvdr-patches-ea01358b3bca9d55402ba632c95cdd6458abfdb3.tar.gz
vdr-patches-ea01358b3bca9d55402ba632c95cdd6458abfdb3.tar.bz2
Version 1.7.10
- Updated the Italian OSD texts (thanks to Diego Pierotto). - Fixed wrong bracketing in cChannel::SubtitlingType() etc. (thanks to Rolf Ahrenberg). - Fixed not logging changes for channels that have no number (reported by Timothy D. Lenz). - Changed the project's URLs and email to tvdr.de. - Added Lithuanian language translations (thanks to Valdemaras Pipiras). - Updated Chinese language texts (thanks to Nan Feng). - Only checking DVB_API_VERSION to be >=5 in order to stay compileable in case the DVB API version number is increased (the API claims to always be backward compatible). - Fixed saving terminal settings when running in background (thanks to Manuel Reimer). - Fixed cFrameDetector::Analyze() to handle video streams where the frame type is not detectable from the first TS packet of a frame. - Fixed writing the PCR pid into the PMT in cPatPmtGenerator::GeneratePmt() (reported by Rene van den Braken). - Added Slovakian language texts (thanks to Milan Hrala). - Fixed EntriesOnSameFileSystem() to avoid using f_fsid, which may be 0 (thanks to Frank Schmirler). - Fixed starting a recording at an I-frame. - Fixed generating the index for recordings from channels that put a whole GOP into one payload unit. - The index file for TS recordings is now regenerated on-the-fly if a recording is replayed that has no index. This can also be used to re-create a broken index file by manually deleting the index file and then replaying the recording (at least until the index file has been generated). - The cRingBufferLinear::Read() function now returns -1 and sets errno to EAGAIN if the buffer is already full. - Fixed handling DVB subtitles for PES recordings (thanks to Rolf Ahrenberg). - Added the audio id to the call of PlayAudio() in cDevice::PlayTsAudio() (thanks to Andreas Schaefers). - Fixed references to old *.vdr file names in MANUAL (reported by Arthur Konovalov). - Reverted "Removed limitation to PAL resolution from SPU handling" because it cause nothing but trouble. Besides, the core VDR doesn't use this, anyway. - Fixed the default value for "Pause key handling" in the MANUAL (reported by Diego Pierotto).
Diffstat (limited to 'remux.h')
-rw-r--r--remux.h20
1 files changed, 17 insertions, 3 deletions
diff --git a/remux.h b/remux.h
index e6025fa..ad099c6 100644
--- a/remux.h
+++ b/remux.h
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: remux.h 2.19 2009/08/16 15:15:33 kls Exp $
+ * $Id: remux.h 2.20 2009/11/21 15:55:34 kls Exp $
*/
#ifndef __REMUX_H
@@ -49,6 +49,7 @@ public:
#define TS_ADAPT_TP_PRIVATE 0x02
#define TS_ADAPT_EXTENSION 0x01
+#define PATPID 0x0000 // PAT PID (constant 0)
#define MAXPID 0x2000 // for arrays that use a PID as the index
inline bool TsHasPayload(const uchar *p)
@@ -238,8 +239,11 @@ public:
///< Returns the PMT pid as defined by the current PAT.
///< If no PAT has been received yet, -1 will be returned.
int Vpid(void) { return vpid; }
- ///< Returns the video pid as defined by the current PMT.
+ ///< Returns the video pid as defined by the current PMT, or 0 if no video
+ ///< pid has been detected, yet.
int Vtype(void) { return vtype; }
+ ///< Returns the video stream type as defined by the current PMT, or 0 if no video
+ ///< stream type has been detected, yet.
};
// TS to PES converter:
@@ -299,6 +303,8 @@ void PesDump(const char *Name, const u_char *Data, int Length);
// Frame detector:
+#define MIN_TS_PACKETS_FOR_FRAME_DETECTOR 2
+
class cFrameDetector {
private:
enum { MaxPtsValues = 150 };
@@ -320,7 +326,15 @@ private:
bool scanning;
uint32_t scanner;
public:
- cFrameDetector(int Pid, int Type);
+ cFrameDetector(int Pid = 0, int Type = 0);
+ ///< Sets up a frame detector for the given Pid and stream Type.
+ ///< If no Pid and Type is given, they need to be set by a separate
+ ///< call to SetPid().
+ void SetPid(int Pid, int Type);
+ ///< Sets the Pid and stream Type to detect frames for.
+ void Reset(void);
+ ///< Resets any counters and flags used while syncing and prepares
+ ///< the frame detector for actual work.
int Analyze(const uchar *Data, int Length);
///< Analyzes the TS packets pointed to by Data. Length is the number of
///< bytes Data points to, and must be a multiple of 188.