]> git.alsa-project.org Git - alsa-tools.git/commitdiff
document -P option everywhere;
authorClemens Ladisch <clemens@ladisch.de>
Fri, 2 Jul 2004 12:21:13 +0000 (12:21 +0000)
committerClemens Ladisch <clemens@ladisch.de>
Fri, 2 Jul 2004 12:21:13 +0000 (12:21 +0000)
actually use the parameter's value instead of the default path

seq/sbiload/README
seq/sbiload/sbiload.c

index a44d4e8e241f50f23375d2fcb6e799d7d856200d..4014c802b8eee8a6059fd076275c0d0edd26a4b3 100644 (file)
@@ -23,11 +23,12 @@ sound card. You need to load snd-synth-opl3 module.
 Usage
 -----
 
-       loadsbi [-p client:port] [-l] [-v level] instfile drumfile
+       loadsbi [-p client:port] [-4] [-l] [-P path] [-v level] instfile drumfile
 
          -p, --port=client:port  - An ALSA client and port number to use
          -4  --opl3              - Four operators (OPL3) file type
          -l, --list              - List possible output ports
+         -P, --path=path         - Specify the patch path
          -v, --verbose=level     - Verbose level
 
 Because you may have more than one sound card and each sound
index 0e55ccfb89b19d42f561acdee50b170f42ce97b8..93e12bf23fc8a50b1d5f07b98b52aa82bd76b36d 100644 (file)
 #include <sys/time.h>
 #include <unistd.h>
 
-/*
- * Load a SBI FM instrument patch
- *     sbiload [-p client:port] [-4] [-l] [-v level] instfile drumfile
- *
- *     -p client:port  - An ALSA client and port number to load instrument to
- *      -4              - four operators file type
- *     -l              - List possible output ports that could be used
- *     -v level        - Verbose level
- */
-
 typedef struct sbi_header
 {
   char key[4];
@@ -182,7 +172,7 @@ static void
 show_usage () {
   char **cpp;
   static char *msg[] = {
-    "Usage: sbiload [-p client:port] [-4] [-l] [-v level] instfile drumfile",
+    "Usage: sbiload [-p client:port] [-4] [-l] [-P path] [-v level] instfile drumfile",
     "",
     "  -p client:port  - A alsa client and port number to send midi to",
     "  -4              - four operators file type (default = two ops)",
@@ -455,7 +445,7 @@ load_file (int bank, char *filename) {
     fd = open (filename, O_RDONLY);
   else {
     char path[1024];
-    snprintf(path, sizeof(path), "%s/%s", PATCHDIR, filename);
+    snprintf(path, sizeof(path), "%s/%s", patchdir, filename);
     fd = open (path, O_RDONLY);
   }
 
@@ -590,11 +580,12 @@ finish_client ()
 
 /*
  * Load a .SBI FM instrument patch
- *   sbiload [-p client:port] [-l] [-v level] instfile drumfile
+ *   sbiload [-p client:port] [-l] [-P path] [-v level] instfile drumfile
  *
  *   -p, --port=client:port  - An ALSA client and port number to use
  *   -4  --opl3              - four operators file type
  *   -l, --list              - List possible output ports that could be used
+ *   -P, --path=path         - Specify the patch path
  *   -v, --verbose=level     - Verbose level
  */
 int