Hallo an alle !
Hallo Klaus !!
Habe heute versucht vdr mit mehreren video directories zu nutzen.
-v /video0
In recordings habe ich aber nur Aufnahmen von /video0 gehabt.
hier ist kleines Patch:
diff -Nu ./vdr-1.3.22.orig/recording.c ./vdr/recording.c
--- ./vdr-1.3.22.orig/recording.c 2005-02-12 11:17:47.000000000 +0100
+++ ./vdr/recording.c 2005-03-22 09:37:52.000000000 +0100
@@ -671,9 +671,14 @@
bool cRecordings::Load(void)
{
+ cVideoDirectory Dir;
lastUpdate = time(NULL); // doing this first to make sure we don't miss anything
Clear();
- ScanVideoDir(VideoDirectory);
+
+ do {
+ ScanVideoDir(Dir.Name());
+ }while(Dir.Next());
+
Sort();
return Count() > 0;
}
diff -Nu ./vdr-1.3.22.orig/videodir.c ./vdr/videodir.c
--- ./vdr-1.3.22.orig/videodir.c 2004-12-26 12:52:12.000000000 +0100
+++ ./vdr/videodir.c 2005-03-22 09:46:06.000000000 +0100
@@ -20,23 +20,6 @@
const char *VideoDirectory = VIDEODIR;
-class cVideoDirectory {
-private:
- char *name, *stored, *adjusted;
- int length, number, digits;
-public:
- cVideoDirectory(void);
- ~cVideoDirectory();
- int FreeMB(int *UsedMB = NULL);
- const char *Name(void) { return name ? name : VideoDirectory; }
- const char *Stored(void) { return stored; }
- int Length(void) { return length; }
- bool IsDistributed(void) { return name != NULL; }
- bool Next(void);
- void Store(void);
- const char *Adjust(const char *FileName);
- };
-
cVideoDirectory::cVideoDirectory(void)
{
length = strlen(VideoDirectory);
diff -Nu ./vdr-1.3.22.orig/videodir.h ./vdr/videodir.h
--- ./vdr-1.3.22.orig/videodir.h 2004-12-26 12:52:56.000000000 +0100
+++ ./vdr/videodir.h 2005-03-22 09:32:16.000000000 +0100
@@ -15,6 +15,23 @@
extern const char *VideoDirectory;
+class cVideoDirectory {
+private:
+ char *name, *stored, *adjusted;
+ int length, number, digits;
+public:
+ cVideoDirectory(void);
+ ~cVideoDirectory();
+ int FreeMB(int *UsedMB = NULL);
+ const char *Name(void) { return name ? name : VideoDirectory; }
+ const char *Stored(void) { return stored; }
+ int Length(void) { return length; }
+ bool IsDistributed(void) { return name != NULL; }
+ bool Next(void);
+ void Store(void);
+ const char *Adjust(const char *FileName);
+};
+
int OpenVideoFile(const char *FileName, int Flags);
int CloseVideoFile(int FileHandle);
bool RenameVideoFile(const char *OldName, const char *NewName);