diff options
author | Klaus Schmidinger <vdr@tvdr.de> | 2009-04-05 14:15:25 +0200 |
---|---|---|
committer | Klaus Schmidinger <vdr@tvdr.de> | 2009-04-05 14:15:25 +0200 |
commit | 0a2de94d07bbfea2e480c69ce3722744c375d477 (patch) | |
tree | b88703e8dceb45f00bd14034f657f188938cef22 | |
parent | daa67997058b3387f55c69b5a67eb853b3d8a6e1 (diff) | |
download | vdr-0a2de94d07bbfea2e480c69ce3722744c375d477.tar.gz vdr-0a2de94d07bbfea2e480c69ce3722744c375d477.tar.bz2 |
Fixed detecting the frame rate for radio recordings
-rw-r--r-- | HISTORY | 1 | ||||
-rw-r--r-- | remux.c | 12 |
2 files changed, 7 insertions, 6 deletions
@@ -6024,3 +6024,4 @@ Video Disk Recorder Revision History - Making sure any floating point numbers written use a decimal point (thanks to Oliver Endriss for pointing out a problem with the F record in the info file of a recording). +- Fixed detecting the frame rate for radio recordings. @@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: remux.c 2.16 2009/03/27 13:49:58 kls Exp $ + * $Id: remux.c 2.17 2009/04/05 14:07:48 kls Exp $ */ #include "remux.h" @@ -758,7 +758,7 @@ int cFrameDetector::Analyze(const uchar *Data, int Length) if (DebugFrames && !synced) dbgframes("/"); } - for (int i = PayloadOffset; i < TS_SIZE; i++) { + for (int i = PayloadOffset; scanning && i < TS_SIZE; i++) { scanner <<= 8; scanner |= Data[i]; switch (type) { @@ -813,12 +813,12 @@ int cFrameDetector::Analyze(const uchar *Data, int Length) return Processed; newFrame = true; independentFrame = true; - if (synced) - scanning = false; - else { + if (!synced) { framesInPayloadUnit = 1; - numIFrames++; + if (TsPayloadStart(Data)) + numIFrames++; } + scanning = false; break; default: esyslog("ERROR: unknown stream type %d (PID %d) in frame detector", type, pid); pid = 0; // let's just ignore any further data |