summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--CONTRIBUTORS1
-rw-r--r--HISTORY3
-rw-r--r--dvbplayer.c11
-rw-r--r--recording.c7
-rw-r--r--recording.h3
5 files changed, 21 insertions, 4 deletions
diff --git a/CONTRIBUTORS b/CONTRIBUTORS
index 6554e8ec..c6085514 100644
--- a/CONTRIBUTORS
+++ b/CONTRIBUTORS
@@ -1076,6 +1076,7 @@ Reinhard Nissl <rnissl@gmx.de>
for fixing replaying recordings of radio channels with many audio tracks
for speeding up cRemux::ScanVideoPacket()
for implementing cDevice::ForceTransferMode()
+ for changing the behaviour when hitting the end of a recording in fast forward mode
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 5b3e5613..01ef15e3 100644
--- a/HISTORY
+++ b/HISTORY
@@ -4492,3 +4492,6 @@ Video Disk Recorder Revision History
respectively.
- The initial channel and volume can now be defined in the "Setup/Miscellaneous"
menu (based on a patch from Thomas Keil).
+- When hitting the end of a recording in fast forward mode, VDR no longer switches
+ back to normal speed if the recording is already finished (thanks to Reinhard
+ Nissl).
diff --git a/dvbplayer.c b/dvbplayer.c
index f61e0c91..2f23e310 100644
--- a/dvbplayer.c
+++ b/dvbplayer.c
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: dvbplayer.c 1.43 2006/02/19 14:20:15 kls Exp $
+ * $Id: dvbplayer.c 1.44 2006/04/09 13:47:11 kls Exp $
*/
#include "dvbplayer.h"
@@ -399,12 +399,19 @@ void cDvbPlayer::Action(void)
if (playMode == pmFast || (playMode == pmSlow && playDir == pdBackward)) {
uchar FileNumber;
int FileOffset;
- int Index = index->GetNextIFrame(readIndex, playDir == pdForward, &FileNumber, &FileOffset, &Length, true);
+ bool TimeShiftMode = index->IsStillRecording();
+ int Index = index->GetNextIFrame(readIndex, playDir == pdForward, &FileNumber, &FileOffset, &Length, TimeShiftMode);
if (Index >= 0) {
if (!NextFile(FileNumber, FileOffset))
continue;
}
else {
+ if (!TimeShiftMode && playDir == pdForward) {
+ // hit end of recording: signal end of file but don't change playMode
+ readIndex = -1;
+ eof = true;
+ continue;
+ }
// hit begin of recording: wait for device buffers to drain
// before changing play mode:
if (!DeviceFlush(100))
diff --git a/recording.c b/recording.c
index 379627c0..fa21df21 100644
--- a/recording.c
+++ b/recording.c
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: recording.c 1.143 2006/03/26 09:11:00 kls Exp $
+ * $Id: recording.c 1.144 2006/04/09 13:49:51 kls Exp $
*/
#include "recording.h"
@@ -1368,6 +1368,11 @@ int cIndexFile::Get(uchar FileNumber, int FileOffset)
return -1;
}
+bool cIndexFile::IsStillRecording()
+{
+ return f >= 0;
+}
+
// --- cFileName -------------------------------------------------------------
#include <errno.h>
diff --git a/recording.h b/recording.h
index f0c3c0e5..28656855 100644
--- a/recording.h
+++ b/recording.h
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: recording.h 1.53 2006/02/25 12:24:46 kls Exp $
+ * $Id: recording.h 1.54 2006/04/09 13:47:11 kls Exp $
*/
#ifndef __RECORDING_H
@@ -210,6 +210,7 @@ public:
int Last(void) { CatchUp(); return last; }
int GetResume(void) { return resumeFile.Read(); }
bool StoreResume(int Index) { return resumeFile.Save(Index); }
+ bool IsStillRecording(void);
};
class cFileName {