summaryrefslogtreecommitdiff
path: root/cutter.c
diff options
context:
space:
mode:
authorKlaus Schmidinger <vdr@tvdr.de>2006-02-04 14:12:17 +0100
committerKlaus Schmidinger <vdr@tvdr.de>2006-02-04 14:12:17 +0100
commit116abbe05e491b61c6cd3541e5c8db1e72122ab6 (patch)
tree77045ab0c2615389d3bc51274a029733b876c6df /cutter.c
parentc7120275206511042ddca4f56239ae5e0cb83835 (diff)
downloadvdr-116abbe05e491b61c6cd3541e5c8db1e72122ab6.tar.gz
vdr-116abbe05e491b61c6cd3541e5c8db1e72122ab6.tar.bz2
Improved cUnbufferedFile
Diffstat (limited to 'cutter.c')
-rw-r--r--cutter.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/cutter.c b/cutter.c
index 6d3a152d..ee4b1a5f 100644
--- a/cutter.c
+++ b/cutter.c
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: cutter.c 1.12 2006/01/27 13:45:00 kls Exp $
+ * $Id: cutter.c 1.13 2006/02/04 13:40:20 kls Exp $
*/
#include "cutter.h"
@@ -66,6 +66,8 @@ void cCuttingThread::Action(void)
toFile = toFileName->Open();
if (!fromFile || !toFile)
return;
+ fromFile->SetReadAhead(MEGABYTE(20));
+ toFile->SetReadAhead(MEGABYTE(20));
int Index = Mark->position;
Mark = fromMarks.Next(Mark);
int FileSize = 0;
@@ -90,6 +92,7 @@ void cCuttingThread::Action(void)
if (fromIndex->Get(Index++, &FileNumber, &FileOffset, &PictureType, &Length)) {
if (FileNumber != CurrentFileNumber) {
fromFile = fromFileName->SetOffset(FileNumber, FileOffset);
+ fromFile->SetReadAhead(MEGABYTE(20));
CurrentFileNumber = FileNumber;
}
if (fromFile) {
@@ -122,6 +125,7 @@ void cCuttingThread::Action(void)
error = "toFile 1";
break;
}
+ toFile->SetReadAhead(MEGABYTE(20));
FileSize = 0;
}
LastIFrame = 0;
@@ -162,6 +166,7 @@ void cCuttingThread::Action(void)
error = "toFile 2";
break;
}
+ toFile->SetReadAhead(MEGABYTE(20));
FileSize = 0;
}
}