summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--CONTRIBUTORS1
-rw-r--r--HISTORY3
-rw-r--r--remux.c27
3 files changed, 16 insertions, 15 deletions
diff --git a/CONTRIBUTORS b/CONTRIBUTORS
index 9af0b378..e95b6ef0 100644
--- a/CONTRIBUTORS
+++ b/CONTRIBUTORS
@@ -977,6 +977,7 @@ Reinhard Nissl <rnissl@gmx.de>
immediately with softdevices
for fixing cDvbSpuBitmap::putPixel()
for implementing cAudioRepacker in remux.c
+ for modifying handling of audio packets for radio channels in remux.c
Richard Robson <richard_robson@beeb.net>
for reporting freezing replay if a timer starts while in Transfer Mode from the
diff --git a/HISTORY b/HISTORY
index 7cbc3179..94ba2dc7 100644
--- a/HISTORY
+++ b/HISTORY
@@ -3724,4 +3724,5 @@ Video Disk Recorder Revision History
dynamically detects the number of slots a CI provides.
- Implemented cAudioRepacker for better handling of audio PES packets (thanks to
Reinhard Nissl).
-
+- Modified handling of audio packets for radio channels in remux.c (thanks to
+ Reinhard Nissl).
diff --git a/remux.c b/remux.c
index 66477f12..4ecb5b83 100644
--- a/remux.c
+++ b/remux.c
@@ -11,7 +11,7 @@
* The cDolbyRepacker code was originally written by Reinhard Nissl <rnissl@gmx.de>,
* and adapted to the VDR coding style by Klaus.Schmidinger@cadsoft.de.
*
- * $Id: remux.c 1.38 2005/08/26 13:34:07 kls Exp $
+ * $Id: remux.c 1.39 2005/08/26 13:35:53 kls Exp $
*/
#include "remux.h"
@@ -1817,19 +1817,6 @@ uchar *cRemux::Get(int &Count, uchar *PictureType)
return resultBuffer->Get(Count);
#endif
- // Special VPID case to enable recording radio channels:
-
- if (isRadio) {
- // XXX actually '0' should be enough, but '1' must be used with encrypted channels (driver bug?)
- // XXX also allowing 0x1FFF to not break Michael Paar's original patch,
- // XXX but it would probably be best to only use '0'
- // Force syncing of radio channels to avoid "no useful data" error
- synced = true;
- if (PictureType)
- *PictureType = I_FRAME;
- return resultBuffer->Get(Count);
- }
-
// Check for frame borders:
if (PictureType)
@@ -1874,6 +1861,18 @@ uchar *cRemux::Get(int &Count, uchar *PictureType)
l = GetPacketLength(data, resultCount, i);
if (l < 0)
return resultData;
+ if (isRadio) {
+ if (!synced) {
+ if (PictureType)
+ *PictureType = I_FRAME;
+ resultSkipped = i; // will drop everything before this position
+ synced = true;
+ }
+ else if (Count)
+ return resultData;
+ else if (PictureType)
+ *PictureType = I_FRAME;
+ }
}
if (synced) {
if (!Count)