diff options
-rw-r--r-- | HISTORY | 4 | ||||
-rw-r--r-- | README | 14 | ||||
-rw-r--r-- | README.DE | 15 | ||||
-rw-r--r-- | control-image.c | 8 | ||||
-rw-r--r-- | image.c | 20 | ||||
-rw-r--r-- | setup-image.h | 1 |
6 files changed, 49 insertions, 13 deletions
@@ -1,6 +1,10 @@ VDR Plugin 'image' Revision History ----------------------------------- +2005-10-29 +- Deny VDR-EITScanner on active Live Audio +- Add plugin options to specify directory of configuration data (wished by Ronny Kornexl) + 2005-10-22 - add FFMDIR to liboutput/Makefile, for build again ffmpeg directory @@ -71,8 +71,18 @@ as mplayer/mp3 plugin). The file ./scripts/imageplugin.sh could go to /usr/bin, or any other folder in your path. You can also use the plugin options (vdr -help after installing the plugin) to specify the path's to the files, if you don't want to those files in you system. -[ e.g.: ./vdr '-Pimage -C /path/imageplugin.sh -m /path/mount.sh' ...] -The install.sh in the examples folder will try a automatic install, give it a try if it fails else. +[ e.g.: ./vdr '-Pimage -C /usr/local/bin/imageplugin.sh -m /usr/local/bin/mount.sh' ...] + +All plugin options : + + -m CMD, --mount=CMD use CMD to mount/unmount/eject image sources + (default: "mount.sh") + -C CMD, --convert=CMD use CMD when converting images + (default: "imageplugin.sh") + -c PATH, --config=PATH to specify directory of configuration data + relative to VDR Plugin configuration directory + (default: "" ) + Manual: ------------ @@ -55,8 +55,8 @@ Später zum Ausführen wird nur noch libavcodec1(libavcodec.so) und "netpbm" benöt -Im ./examples Ordner liegt eine Beispiel imagesources.conf, dies ggf. -anpassen und in das plugins Verzeichnis des config Ordners legen. +Im ./examples Ordner liegt eine Beispieldatei imagesources.conf, dies ggf. +anpassen und in das Verzeichnis plugins Verzeichnis des config Ordners legen. Die Syntax der Datei ist: <Pfad>;<Name im vdr Menu>;<0/1>;<Suchmuster für Dateien die angezeigt werden sollen> @@ -74,8 +74,17 @@ Die Datei imageplugin.sh sollte nach /usr/bin kopiert werden, bzw. in einen ande gemeinsamen Ordner innerhalb Such-Path kopieren werden, alternativ können als Kommandozeilenoption die gewählten Pfade zu dem Skript beim vdr Start übergeben werden. -[z.B.: ./vdr '-Pimage -C /pfad/imageplugin.sh -m /pfad/mount.sh' ...] +[z.B.: ./vdr '-Pimage -C /usr/local/bin/imageplugin.sh -m /usr/local/bin/mount.sh' ...] +Alle Plugin Optionen : + + -m CMD, --mount=CMD verwendetes CMD für mount/unmount/eject der Bildquellen + (default: "mount.sh") + -C CMD, --convert=CMD verwendetes CMD fpr die Konvertieren der Bilder + (default: "imageplugin.sh") + -c PATH, --config=PATH zum spezifizieren des Verzeichnisses der Konfigurationsdateien + relativ zum VDR Plugin Konfiguration-Verzeichnis + (default: "" ) Bedienung: ----------------- diff --git a/control-image.c b/control-image.c index 294dfd0..0182687 100644 --- a/control-image.c +++ b/control-image.c @@ -33,7 +33,7 @@ #include <vdr/status.h> #include <vdr/tools.h> #include <vdr/plugin.h> - +#include <vdr/eitscan.h> // --- cImageControl --------------------------------------------------------- @@ -302,6 +302,10 @@ eOSState cImageControl::ProcessKey(eKeys nKey) // Check for next image SlideImage(); + // Deny EITScanner on Live Audio + if(ImageSetup.m_bLiveAudio) + EITScanner.Activity(); + eOSState eOSRet = osContinue; if(m_pImageMenu @@ -618,7 +622,7 @@ eOSState cImageControl::ProcessKeyCommands(eKeys nKey) return osContinue; // Load additional Commands - pCmd->Load(AddDirectory(cPlugin::ConfigDirectory(), "imagecmds.conf")); + pCmd->Load(AddDirectory(cPlugin::ConfigDirectory(g_szConfigDirectory), "imagecmds.conf")); if(pCmd->Count() <= 0) { delete pCmd; @@ -59,17 +59,23 @@ bool cPluginImage::SetupParse(const char *szName, const char *szValue) return ImageSetup.SetupParse(szName,szValue); } +const char *g_szConfigDirectory = NULL; + const char *cPluginImage::CommandLineHelp(void) { static char *help_str=0; free(help_str); // for easier orientation, this is column 80| asprintf(&help_str," -m CMD, --mount=CMD use CMD to mount/unmount/eject image sources\n" - " (default: %s)\n" - " -C CMD, --convert=CMD use CMD when converting Images\n" - " (default: %s)\n", + " (default: \"%s\")\n" + " -C CMD, --convert=CMD use CMD when converting images\n" + " (default: \"%s\")\n" + " -c PATH, --config=PATH to specify directory of configuration data\n" + " relative to VDR Plugin configuration directory\n" + " (default: \"%s\")\n", g_szMountScript, - g_szConvertScript + g_szConvertScript, + g_szConfigDirectory?g_szConfigDirectory:"" ); return help_str; } @@ -79,14 +85,16 @@ bool cPluginImage::ProcessArgs(int argc, char *argv[]) static struct option long_options[] = { { "mount", required_argument, NULL, 'm' }, { "convert", required_argument, NULL, 'C' }, + { "config", required_argument, NULL, 'c' }, { NULL } }; int c, option_index = 0; - while((c=getopt_long(argc,argv,"m:C:",long_options,&option_index))!=-1) { + while((c=getopt_long(argc,argv,"m:C:c:",long_options,&option_index))!=-1) { switch (c) { case 'm': g_szMountScript=optarg;break; case 'C': g_szConvertScript=optarg;break; + case 'c': g_szConfigDirectory=optarg;break; default: return false; } } @@ -99,7 +107,7 @@ bool cPluginImage::Start(void) return false; } - ImageSources.Load(AddDirectory(ConfigDirectory(), "imagesources.conf")); + ImageSources.Load(AddDirectory(ConfigDirectory(g_szConfigDirectory), "imagesources.conf")); if(ImageSources.Count()<1) { esyslog("imageplugin: you must have defined at least one source in imagesources.conf"); return false; diff --git a/setup-image.h b/setup-image.h index 47ae885..117c69e 100644 --- a/setup-image.h +++ b/setup-image.h @@ -24,6 +24,7 @@ #define ___SETUP_IMAGE_H extern const char *g_szConvertScript; +extern const char *g_szConfigDirectory; #include <vdr/menuitems.h> |