[Demudi-commits] r1037 - in liblscp/trunk/debian: . patches
Free Ekanayaka
free-guest at alioth.debian.org
Thu Jan 25 11:33:46 CET 2007
Author: free-guest
Date: 2007-01-25 11:33:36 +0100 (Thu, 25 Jan 2007)
New Revision: 1037
Added:
liblscp/trunk/debian/patches/
liblscp/trunk/debian/patches/00_cvs-makefile.dpatch
liblscp/trunk/debian/patches/00list
liblscp/trunk/debian/patches/10_cvs-snapshot.dpatch
Modified:
liblscp/trunk/debian/changelog
liblscp/trunk/debian/control
liblscp/trunk/debian/rules
Log:
* New cvs snapshot
Modified: liblscp/trunk/debian/changelog
===================================================================
--- liblscp/trunk/debian/changelog 2007-01-24 10:34:03 UTC (rev 1036)
+++ liblscp/trunk/debian/changelog 2007-01-25 10:33:36 UTC (rev 1037)
@@ -1,3 +1,9 @@
+liblscp (0.5.2-1+cvs070120) UNRELEASED; urgency=low
+
+ * New cvs snapshot
+
+ -- Free Ekanayaka <freee at debian.org> Sat, 20 Jan 2007 12:45:43 +0100
+
liblscp (0.5.2-1) UNRELEASED; urgency=low
[ Rui Nuno Capela ]
Modified: liblscp/trunk/debian/control
===================================================================
--- liblscp/trunk/debian/control 2007-01-24 10:34:03 UTC (rev 1036)
+++ liblscp/trunk/debian/control 2007-01-25 10:33:36 UTC (rev 1037)
@@ -3,7 +3,7 @@
Priority: optional
Maintainer: Matt Flax <flatmax at pgb.unsw.edu.au>
Uploaders: Free Ekanayaka <freee at debian.org>
-Build-Depends: debhelper (>= 4.0.0)
+Build-Depends: debhelper (>= 4.0.0), dpatch, automake1.9, libtool
Standards-Version: 3.7.2
Package: liblscp-dev
@@ -27,6 +27,8 @@
Section: libs
Architecture: any
Depends: ${shlibs:Depends}, ${misc:Depends}
+Conflicts: liblscp
+Replaces: liblscp
Description: LinuxSampler Control Protocol wrapper library
This package is for use with the LinuxSampler audio sampling
engine / library and packages.
Added: liblscp/trunk/debian/patches/00_cvs-makefile.dpatch
===================================================================
--- liblscp/trunk/debian/patches/00_cvs-makefile.dpatch 2007-01-24 10:34:03 UTC (rev 1036)
+++ liblscp/trunk/debian/patches/00_cvs-makefile.dpatch 2007-01-25 10:33:36 UTC (rev 1037)
@@ -0,0 +1,47 @@
+#! /bin/sh -e
+## 00_cvs-makefile.dpatch by Free Ekanayaka <freee at debian.org>
+##
+## All lines beginning with `## DP:' are a description of the patch.
+## DP: No description.
+
+if [ $# -lt 1 ]; then
+ echo "`basename $0`: script expects -patch|-unpatch as argument" >&2
+ exit 1
+fi
+
+[ -f debian/patches/00patch-opts ] && . debian/patches/00patch-opts
+patch_opts="${patch_opts:--f --no-backup-if-mismatch} ${2:+-d $2}"
+
+case "$1" in
+ -patch) patch -p1 ${patch_opts} < $0;;
+ -unpatch) patch -R -p1 ${patch_opts} < $0;;
+ *)
+ echo "`basename $0`: script expects -patch|-unpatch as argument" >&2
+ exit 1;;
+esac
+
+exit 0
+
+ at DPATCH@
+--- liblscp-0.5.2/Makefile.cvs 1970-01-01 01:00:00.000000000 +0100
++++ liblscp/Makefile.cvs 2005-08-24 20:00:54.000000000 +0200
+@@ -0,0 +1,19 @@
++all: configure
++
++configure: configure.ac Makefile.am src/Makefile.am lscp/Makefile.am doc/Makefile.am examples/Makefile.am
++ @aclocal
++ @libtoolize --force --copy
++ @autoheader
++ @automake --add-missing --copy
++ @autoconf
++
++clean:
++ @if [ -f Makefile ]; then make distclean; fi || true
++ @rm -rvf *.cache *.log *.status *.m4
++ @rm -rvf examples/Makefile.in
++ @rm -rvf doc/Makefile.in
++ @rm -rvf lscp/Makefile.in
++ @rm -rvf src/Makefile.in src/config.h.in src/config.h src/stamp-h.*
++ @rm -rvf Makefile.in config.* stamp-h.*
++ @rm -rvf missing install-sh mkinstalldirs depcomp ltmain.sh
++ @rm -rvf configure *.spec
Added: liblscp/trunk/debian/patches/00list
===================================================================
--- liblscp/trunk/debian/patches/00list 2007-01-24 10:34:03 UTC (rev 1036)
+++ liblscp/trunk/debian/patches/00list 2007-01-25 10:33:36 UTC (rev 1037)
@@ -0,0 +1,2 @@
+00_cvs-makefile
+10_cvs-snapshot
Added: liblscp/trunk/debian/patches/10_cvs-snapshot.dpatch
===================================================================
--- liblscp/trunk/debian/patches/10_cvs-snapshot.dpatch 2007-01-24 10:34:03 UTC (rev 1036)
+++ liblscp/trunk/debian/patches/10_cvs-snapshot.dpatch 2007-01-25 10:33:36 UTC (rev 1037)
@@ -0,0 +1,487 @@
+#! /bin/sh -e
+## 10cvs-snapshot.dpatch by Free Ekanayaka <freee at debian.org>
+##
+## All lines beginning with `## DP:' are a description of the patch.
+## DP: No description.
+
+if [ $# -lt 1 ]; then
+ echo "`basename $0`: script expects -patch|-unpatch as argument" >&2
+ exit 1
+fi
+
+[ -f debian/patches/00patch-opts ] && . debian/patches/00patch-opts
+patch_opts="${patch_opts:--f --no-backup-if-mismatch} ${2:+-d $2}"
+
+case "$1" in
+ -patch) patch -p1 ${patch_opts} < $0;;
+ -unpatch) patch -R -p1 ${patch_opts} < $0;;
+ *)
+ echo "`basename $0`: script expects -patch|-unpatch as argument" >&2
+ exit 1;;
+esac
+
+exit 0
+
+ at DPATCH@
+Index: liblscp/ChangeLog
+diff -u liblscp/ChangeLog:1.51 liblscp/ChangeLog:1.52
+--- liblscp/ChangeLog:1.51 Thu Jan 11 15:25:04 2007
++++ liblscp/ChangeLog Mon Jan 15 11:08:28 2007
+@@ -3,6 +3,13 @@
+
+ ChangeLog
+
++0.5.3 2007-01-15 Added new client interface functions, for sampler
++ channel effect sends control:
++ lscp_set_fxsend_midi_controller();
++ lscp_set_fxsend_level();
++
++ Added new field member to lscp_fxsend_info_t (level).
++
+ 0.5.2 2007-01-11 Added new client interface functions, for sampler
+ channel effect sends control:
+ lscp_create_fxsend();
+@@ -15,7 +22,7 @@
+ lscp_get_volume();
+ lscp_set_volume();
+
+- Audio routing representation changed integer array.
++ Audio routing representation changed to integer array.
+
+ 0.5.1 2006-12-22 Added support for new (un)subscribable events:
+ LSCP_EVENT_AUDIO_OUTPUT_DEVICE_COUNT,
+Index: liblscp/configure.ac
+diff -u liblscp/configure.ac:1.11 liblscp/configure.ac:1.12
+--- liblscp/configure.ac:1.11 Thu Jan 11 15:25:04 2007
++++ liblscp/configure.ac Mon Jan 15 11:08:28 2007
+@@ -2,7 +2,7 @@
+ AC_INIT(src/client.c)
+ AM_CONFIG_HEADER(src/config.h)
+
+-AM_INIT_AUTOMAKE(liblscp, 0.5.2)
++AM_INIT_AUTOMAKE(liblscp, 0.5.3)
+
+ #------------------------------------------------------------------------------------
+ # Rules for library version information:
+@@ -20,7 +20,7 @@
+ # 6. If any interfaces have been removed since the last public release, then set age
+ # to 0.
+
+-SHARED_VERSION_INFO="3:0:0"
++SHARED_VERSION_INFO="3:0:1"
+
+ AC_SUBST(SHARED_VERSION_INFO)
+
+Index: liblscp/liblscp.spec.in
+diff -u liblscp/liblscp.spec.in:1.28 liblscp/liblscp.spec.in:1.29
+--- liblscp/liblscp.spec.in:1.28 Fri Dec 22 00:35:52 2006
++++ liblscp/liblscp.spec.in Mon Jan 15 11:08:28 2007
+@@ -1,7 +1,7 @@
+
+ %define name @PACKAGE@
+ %define version @VERSION@
+-%define release 13
++%define release 14
+ %define prefix @prefix@
+
+ Summary: LinuxSampler control protocol API.
+@@ -63,6 +63,14 @@
+ %{prefix}/include/lscp
+
+ %changelog
++* Mon Jan 15 2007 Rui Nuno Capela <rncbc at users.sourceforge.net>
++- New 0.5.3 release.
++
++* Thu Jan 11 2007 Rui Nuno Capela <rncbc at users.sourceforge.net>
++- Sampler channel effect sends control and global volume support.
++- Audio routing representation changed to integer array.
++- New 0.5.2 release.
++
+ * Fri Dec 22 2006 Rui Nuno Capela <rncbc at users.sourceforge.net>
+ - Added support for new (un)subscribable events.
+ - Examples update.
+Index: liblscp/debian/README.Debian
+diff -u liblscp/debian/README.Debian:1.6 liblscp/debian/README.Debian:1.7
+Index: liblscp/debian/changelog
+diff -u liblscp/debian/changelog:1.21 liblscp/debian/changelog:1.23
+Index: liblscp/doc/reference.dox
+diff -u liblscp/doc/reference.dox:1.14 liblscp/doc/reference.dox:1.15
+--- liblscp/doc/reference.dox:1.14 Thu Jan 11 12:33:04 2007
++++ liblscp/doc/reference.dox Mon Jan 15 11:08:28 2007
+@@ -152,7 +152,9 @@
+ @ref lscp_get_fxsends (client, channel);
+ @ref lscp_list_fxsends (client, channel);
+ @ref lscp_get_fxsend_info (client, channel, fxsend);
++ @ref lscp_set_fxsend_midi_controller (client, channel, fxsend, midi_controller);
+ @ref lscp_set_fxsend_audio_channel (client, channel, fxsend, audio_src, audio_dst);
++ @ref lscp_set_fxsend_level (client, channel, fxsend, level);
+
+ </pre>Specific to MIDI instrument mapping interface:<pre>
+
+Index: liblscp/examples/example_client.c
+diff -u liblscp/examples/example_client.c:1.27 liblscp/examples/example_client.c:1.28
+--- liblscp/examples/example_client.c:1.27 Thu Jan 11 15:25:04 2007
++++ liblscp/examples/example_client.c Mon Jan 15 11:08:28 2007
+@@ -273,9 +273,10 @@
+ return 1;
+ }
+ printf("{\n");
+- printf(" fxsend_info.engine_name = %s\n", pFxSendInfo->name);
+- printf(" fxsend_info.midi_controller = %d\n", pFxSendInfo->midi_controller);
+- printf(" fxsend_info.audio_routing = "); client_test_isplit(pFxSendInfo->audio_routing);
++ printf(" fxsend_info.engine_name = %s\n", pFxSendInfo->name);
++ printf(" fxsend_info.midi_controller = %d\n", pFxSendInfo->midi_controller);
++ printf(" fxsend_info.audio_routing = "); client_test_isplit(pFxSendInfo->audio_routing);
++ printf(" fxsend_info.level = %g\n", pFxSendInfo->level);
+ printf(" }\n");
+ return 0;
+ }
+@@ -347,6 +348,7 @@
+ typedef lscp_engine_info_t * engine_info;
+ typedef lscp_channel_info_t * channel_info;
+ typedef lscp_buffer_fill_t * buffer_fill;
++typedef lscp_fxsend_info_t * fxsend_info;
+ typedef lscp_midi_instrument_t * midi_instruments;
+ typedef lscp_midi_instrument_info_t *midi_instrument_info;
+
+@@ -363,8 +365,7 @@
+ void client_test_engine ( lscp_client_t *pClient, const char *pszEngine, const char *pszAudioDriver, int iAudioDevice, const char *pszMidiDriver, int iMidiDevice )
+ {
+ int iSamplerChannel;
+- lscp_midi_instrument_t midi_instr;
+- int i, j, k;
++ int iFxSend;
+
+ printf("\n--- pszEngine=\"%s\" pszAudioDevice=\"%s\" iAudioDevice=%d pszMidiDevice=\"%s\" iMidiDevice=%d ---\n", pszEngine, pszAudioDriver, iAudioDevice, pszMidiDriver, iMidiDevice);
+ CLIENT_TEST(pClient, engine_info, lscp_get_engine_info(pClient, pszEngine));
+@@ -392,40 +393,17 @@
+ CLIENT_TEST(pClient, status, lscp_set_channel_volume(pClient, iSamplerChannel, 0.5));
+ CLIENT_TEST(pClient, status, lscp_set_channel_mute(pClient, iSamplerChannel, 1));
+ CLIENT_TEST(pClient, status, lscp_set_channel_solo(pClient, iSamplerChannel, 1));
++ CLIENT_TEST(pClient, int, iFxSend = lscp_create_fxsend(pClient, iSamplerChannel, 90, "DummyFxSend"));
++ CLIENT_TEST(pClient, int, lscp_get_fxsends(pClient, iSamplerChannel));
++ CLIENT_TEST(pClient, isplit, lscp_list_fxsends(pClient, iSamplerChannel));
++ CLIENT_TEST(pClient, fxsend_info, lscp_get_fxsend_info(pClient, iSamplerChannel, iFxSend));
++ CLIENT_TEST(pClient, status, lscp_set_fxsend_midi_controller(pClient, iSamplerChannel, iFxSend, 99));
++ CLIENT_TEST(pClient, status, lscp_set_fxsend_audio_channel(pClient, iSamplerChannel, iFxSend, 0, 1));
++ CLIENT_TEST(pClient, status, lscp_set_fxsend_level(pClient, iSamplerChannel, iFxSend, 0.12f));
++ CLIENT_TEST(pClient, status, lscp_destroy_fxsend(pClient, iSamplerChannel, iFxSend));
+ CLIENT_TEST(pClient, channel_info, lscp_get_channel_info(pClient, iSamplerChannel));
+ CLIENT_TEST(pClient, status, lscp_reset_channel(pClient, iSamplerChannel));
+ CLIENT_TEST(pClient, status, lscp_remove_channel(pClient, iSamplerChannel));
+-
+- for (i = 0; i < 2; i++) {
+- CLIENT_TEST(pClient, int, lscp_add_midi_instrument_map(pClient, NULL));
+- for (j = 0; j < 4; j++) {
+- for (k = 0; k < 8; k++) {
+- midi_instr.map = i;
+- midi_instr.bank = j;
+- midi_instr.prog = k;
+- CLIENT_TEST(pClient, status, lscp_map_midi_instrument(pClient, &midi_instr, pszEngine, "DefaultInstrument.gig", 0, 1.0f, LSCP_LOAD_ON_DEMAND, "DummyName"));
+- }
+- }
+- CLIENT_TEST(pClient, status, lscp_set_midi_instrument_map_name(pClient, i, "DummyMapName"));
+- }
+-
+- CLIENT_TEST(pClient, int, lscp_get_midi_instruments(pClient, LSCP_MIDI_MAP_ALL));
+- CLIENT_TEST(pClient, midi_instruments, lscp_list_midi_instruments(pClient, LSCP_MIDI_MAP_ALL));
+-
+- for (i = 0; i < 2; i++) {
+- for (j = 0; j < 4; j++) {
+- for (k = 0; k < 8; k++) {
+- midi_instr.map = i;
+- midi_instr.bank = j;
+- midi_instr.prog = k;
+- CLIENT_TEST(pClient, midi_instrument_info, lscp_get_midi_instrument_info(pClient, &midi_instr));
+- CLIENT_TEST(pClient, status, lscp_unmap_midi_instrument(pClient, &midi_instr));
+- }
+- }
+- CLIENT_TEST(pClient, int, lscp_remove_midi_instrument_map(pClient, i));
+- }
+-
+- CLIENT_TEST(pClient, status, lscp_clear_midi_instruments(pClient, LSCP_MIDI_MAP_ALL));
+ }
+
+
+@@ -547,6 +525,8 @@
+ int iAudio, iAudioDevice, iMidi, iMidiDevice;
+ int iNewAudioDevice, iNewMidiDevice;
+ int *piAudioDevices, *piMidiDevices;
++ lscp_midi_instrument_t midi_instr;
++ int i, j, k;
+
+ g_test_step = step;
+ g_test_count = 0;
+@@ -604,6 +584,34 @@
+ CLIENT_TEST(pClient, status, lscp_destroy_audio_device(pClient, iNewAudioDevice));
+ }
+
++ for (i = 0; i < 2; i++) {
++ CLIENT_TEST(pClient, int, lscp_add_midi_instrument_map(pClient, NULL));
++ for (j = 0; j < 4; j++) {
++ for (k = 0; k < 8; k++) {
++ midi_instr.map = i;
++ midi_instr.bank = j;
++ midi_instr.prog = k;
++ CLIENT_TEST(pClient, status, lscp_map_midi_instrument(pClient, &midi_instr, pszEngine, "DefaultInstrument.gig", 0, 1.0f, LSCP_LOAD_ON_DEMAND, "DummyName"));
++ }
++ }
++ CLIENT_TEST(pClient, status, lscp_set_midi_instrument_map_name(pClient, i, "DummyMapName"));
++ }
++ CLIENT_TEST(pClient, int, lscp_get_midi_instruments(pClient, LSCP_MIDI_MAP_ALL));
++ CLIENT_TEST(pClient, midi_instruments, lscp_list_midi_instruments(pClient, LSCP_MIDI_MAP_ALL));
++ for (i = 0; i < 2; i++) {
++ for (j = 0; j < 4; j++) {
++ for (k = 0; k < 8; k++) {
++ midi_instr.map = i;
++ midi_instr.bank = j;
++ midi_instr.prog = k;
++ CLIENT_TEST(pClient, midi_instrument_info, lscp_get_midi_instrument_info(pClient, &midi_instr));
++ CLIENT_TEST(pClient, status, lscp_unmap_midi_instrument(pClient, &midi_instr));
++ }
++ }
++ CLIENT_TEST(pClient, int, lscp_remove_midi_instrument_map(pClient, i));
++ }
++ CLIENT_TEST(pClient, status, lscp_clear_midi_instruments(pClient, LSCP_MIDI_MAP_ALL));
++
+ CLIENT_TEST(pClient, status, lscp_set_volume(pClient, 0.123f));
+ CLIENT_TEST(pClient, int, (int) (100.0f * lscp_get_volume(pClient)));
+
+Index: liblscp/examples/example_server.c
+diff -u liblscp/examples/example_server.c:1.25 liblscp/examples/example_server.c:1.26
+--- liblscp/examples/example_server.c:1.25 Thu Jan 11 12:33:04 2007
++++ liblscp/examples/example_server.c Mon Jan 15 11:08:28 2007
+@@ -44,6 +44,7 @@
+ static int iSamplerChannel = 0;
+ static int iAudioDevice = 0;
+ static int iMidiDevice = 0;
++ static int iFxSend = 0;
+ static int iMidiMaps = 0;
+ static int iMidiInstruments = 0;
+ static float fVolume = 1.0f;
+@@ -420,6 +421,21 @@
+ sprintf(szTemp, "%g\r\n", fVolume);
+ pszResult = szTemp;
+ }
++ else if (lscp_parser_test2(&tok, "FX_SEND", "INFO")) {
++ // Getting effect send informations:
++ // GET FX_SEND INFO <sampler-channel> <fx-send-id>
++ pszResult = "NAME: DummyFxSend\r\n"
++ "MIDI_CONTROLLER: 99\r\n"
++ "AUDIO_OUTPUT_ROUTING: 0,1\r\n"
++ "LEVEL: 0.15\r\n"
++ ".\r\n";
++ }
++ else if (lscp_parser_test(&tok, "FX_SENDS")) {
++ // Get ammount of effect sends on a sampler channel:
++ // GET FX_SENDS <sampler-channel>
++ sprintf(szTemp, "%d\r\n", iFxSend);
++ pszResult = szTemp;
++ }
+ else if (lscp_parser_test(&tok, "MIDI_INSTRUMENTS")) {
+ // Get the total count of MIDI instrument map entries:
+ // GET MIDI_INSTRUMENTS
+@@ -513,6 +529,18 @@
+ strcat(szTemp, "\r\n");
+ pszResult = szTemp;
+ }
++ else if (lscp_parser_test(&tok, "FX_SENDS")) {
++ // Listing all effect sends on a sampler channel:
++ // LIST FX_SENDS <sampler-channel>
++ szTemp[0] = (char) 0;
++ for (i = 0; i < iFxSend && strlen(szTemp) < sizeof(szTemp) - 8; i++) {
++ if (i > 0)
++ strcat(szTemp, ",");
++ sprintf(szTemp + strlen(szTemp), "%d", i);
++ }
++ strcat(szTemp, "\r\n");
++ pszResult = szTemp;
++ }
+ else if (lscp_parser_test(&tok, "MIDI_INSTRUMENTS")) {
+ // Getting indeces of all MIDI instrument map entries:
+ // LIST MIDI_INSTRUMENTS
+@@ -592,6 +620,21 @@
+ // SET VOLUME <volume>
+ fVolume = lscp_parser_nextnum(&tok);
+ }
++ else if (lscp_parser_test(&tok, "FX_SEND")) {
++ if (lscp_parser_test(&tok, "MIDI_CONTROLLER")) {
++ // Altering effect send MIDI controller:
++ // SET FX_SEND MIDI_CONTROLLER <sampler-channel> <fx-send-id> <midi-ctrl>
++ }
++ else if (lscp_parser_test(&tok, "AUDIO_OUTPUT_CHANNEL")) {
++ // Altering effect send audio routing:
++ // SET FX_SEND AUDIO_OUTPUT_CHANNEL <sampler-channel> <fx-send-id> <midi-ctrl> <audio-src> <audio-dst>
++ }
++ else if (lscp_parser_test(&tok, "LEVEL")) {
++ // Altering effect send audio level:
++ // SET FX_SEND LEVEL <sampler-channel> <fx-send-id> <midi-ctrl> <volume>
++ }
++ else ret = LSCP_FAILED;
++ }
+ else if (lscp_parser_test2(&tok, "MIDI_INSTRUMENT_MAP", "NAME")) {
+ // Setting MIDI instrument map name:
+ // SET MIDI_INSTRUMENT_MAP NAME <midi-map> <map-name>
+@@ -690,13 +733,24 @@
+ ret = LSCP_FAILED;
+ }
+ }
++ else if (lscp_parser_test(&tok, "FX_SEND")) {
++ // Adding an effect send to a sampler channel:
++ // CREATE FX_SEND <sampler-channel> <midi-ctrl> [<name>]
++ if (iFxSend < 8) {
++ sprintf(szTemp, "OK[%d]\r\n", iFxSend++);
++ pszResult = szTemp;
++ } else {
++ iFxSend = 0;
++ ret = LSCP_FAILED;
++ }
++ }
+ else ret = LSCP_FAILED;
+ }
+ else if (lscp_parser_test(&tok, "DESTROY")) {
+ if (lscp_parser_test(&tok, "AUDIO_OUTPUT_DEVICE")) {
+ // Destroying an audio output device.
+ // DESTROY AUDIO_OUTPUT_DEVICE <audio-device-id>
+- if (lscp_parser_nextint(&tok) < iAudioDevice)
++ if (lscp_parser_nextint(&tok) >= 0 && iAudioDevice > 0)
+ iAudioDevice--;
+ else
+ ret = LSCP_FAILED;
+@@ -704,11 +758,19 @@
+ else if (lscp_parser_test(&tok, "MIDI_INPUT_DEVICE")) {
+ // Destroying an MIDI intput device.
+ // DESTROY MIDI_INPUT_DEVICE <midi-device-id>
+- if (lscp_parser_nextint(&tok) < iMidiDevice)
++ if (lscp_parser_nextint(&tok) >= 0 && iMidiDevice > 0)
+ iMidiDevice--;
+ else
+ ret = LSCP_FAILED;
+ }
++ else if (lscp_parser_test(&tok, "FX_SEND")) {
++ // Removing an effect send from a sampler channel:
++ // CREATE FX_SEND <sampler-channel> <fx-send-id>
++ if (lscp_parser_nextint(&tok) >= 0 && iFxSend > 0)
++ iFxSend--;
++ else
++ ret = LSCP_FAILED;
++ }
+ else ret = LSCP_FAILED;
+ }
+ else if (lscp_parser_test2(&tok, "MAP", "MIDI_INSTRUMENT")) {
+Index: liblscp/lscp/client.h
+diff -u liblscp/lscp/client.h:1.23 liblscp/lscp/client.h:1.24
+--- liblscp/lscp/client.h:1.23 Thu Jan 11 15:25:04 2007
++++ liblscp/lscp/client.h Mon Jan 15 11:08:28 2007
+@@ -104,6 +104,7 @@
+ char * name;
+ int midi_controller;
+ int * audio_routing;
++ float level;
+
+ } lscp_fxsend_info_t;
+
+@@ -111,9 +112,9 @@
+ /** MIDI instrument parameter struct. */
+ typedef struct _lscp_midi_instrument_t
+ {
+- int map;
+- int bank;
+- int prog;
++ int map;
++ int bank;
++ int prog;
+
+ } lscp_midi_instrument_t;
+
+@@ -263,6 +264,8 @@
+ lscp_fxsend_info_t * lscp_get_fxsend_info (lscp_client_t *pClient, int iSamplerChannel, int iFxSend);
+
+ lscp_status_t lscp_set_fxsend_audio_channel (lscp_client_t *pClient, int iSamplerChannel, int iFxSend, int iAudioSrc, int iAudioDst);
++lscp_status_t lscp_set_fxsend_midi_controller (lscp_client_t *pClient, int iSamplerChannel, int iFxSend, int iMidiController);
++lscp_status_t lscp_set_fxsend_level (lscp_client_t *pClient, int iSamplerChannel, int iFxSend, float fLevel);
+
+ //-------------------------------------------------------------------------
+ // MIDI instrument mapping control functions.
+Index: liblscp/src/client.c
+diff -u liblscp/src/client.c:1.41 liblscp/src/client.c:1.42
+--- liblscp/src/client.c:1.41 Thu Jan 11 15:25:04 2007
++++ liblscp/src/client.c Mon Jan 15 11:08:28 2007
+@@ -2035,6 +2035,11 @@
+ pFxSendInfo->audio_routing = lscp_isplit_create(pszToken, ",");
+ }
+ }
++ else if (strcasecmp(pszToken, "LEVEL") == 0) {
++ pszToken = lscp_strtok(NULL, pszCrlf, &(pch));
++ if (pszToken)
++ pFxSendInfo->level = (float) atof(lscp_ltrim(pszToken));
++ }
+ pszToken = lscp_strtok(NULL, pszSeps, &(pch));
+ }
+ }
+@@ -2073,6 +2078,53 @@
+
+
+ /**
++ * Alter effect send's MIDI controller:
++ * SET FX_SEND MIDI_CONTROLLER <sampler-chan> <fx-send-id> <midi-ctrl>
++ *
++ * @param pClient Pointer to client instance structure.
++ * @param iSamplerChannel Sampler channel number.
++ * @param iFxSend Effect send number.
++ * @param iMidiController MIDI controller used to alter the effect,
++ * usually a number between 0 and 127.
++ *
++ * @returns LSCP_OK on success, LSCP_FAILED otherwise.
++ */
++lscp_status_t lscp_set_fxsend_midi_controller ( lscp_client_t *pClient, int iSamplerChannel, int iFxSend, int iMidiController )
++{
++ char szQuery[LSCP_BUFSIZ];
++
++ if (iSamplerChannel < 0 || iFxSend < 0 || iMidiController < 0 || iMidiController > 127)
++ return LSCP_FAILED;
++
++ sprintf(szQuery, "SET FX_SEND MIDI_CONTROLLER %d %d %d %d\r\n", iSamplerChannel, iFxSend, iMidiController);
++ return lscp_client_query(pClient, szQuery);
++}
++
++
++/**
++ * Alter effect send's audio level:
++ * SET FX_SEND LEVEL <sampler-chan> <fx-send-id> <level>
++ *
++ * @param pClient Pointer to client instance structure.
++ * @param iSamplerChannel Sampler channel number.
++ * @param iFxSend Effect send number.
++ * @param fLevel Effect send volume level.
++ *
++ * @returns LSCP_OK on success, LSCP_FAILED otherwise.
++ */
++lscp_status_t lscp_set_fxsend_level ( lscp_client_t *pClient, int iSamplerChannel, int iFxSend, float fLevel )
++{
++ char szQuery[LSCP_BUFSIZ];
++
++ if (iSamplerChannel < 0 || iFxSend < 0 || fLevel < 0.0f)
++ return LSCP_FAILED;
++
++ sprintf(szQuery, "SET FX_SEND LEVEL %d %d %d %g\r\n", iSamplerChannel, iFxSend, fLevel);
++ return lscp_client_query(pClient, szQuery);
++}
++
++
++/**
+ * Create a new MIDI instrument map:
+ * ADD MIDI_INSTRUMENT_MAP [<name>]
+ *
+Index: liblscp/src/common.c
+diff -u liblscp/src/common.c:1.31 liblscp/src/common.c:1.32
+--- liblscp/src/common.c:1.31 Thu Jan 11 15:25:04 2007
++++ liblscp/src/common.c Mon Jan 15 11:08:28 2007
+@@ -1070,6 +1070,7 @@
+ pFxSendInfo->name = NULL;
+ pFxSendInfo->midi_controller = 0;
+ pFxSendInfo->audio_routing = NULL;
++ pFxSendInfo->level = 0.0f;
+ }
+
+ void lscp_fxsend_info_free ( lscp_fxsend_info_t *pFxSendInfo )
Modified: liblscp/trunk/debian/rules
===================================================================
--- liblscp/trunk/debian/rules 2007-01-24 10:34:03 UTC (rev 1036)
+++ liblscp/trunk/debian/rules 2007-01-25 10:33:36 UTC (rev 1037)
@@ -6,6 +6,12 @@
# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1
+DEBIAN_VERSION=$(shell dpkg-parsechangelog |grep ^Version: | cut -f 2 -d " ")
+UPSTREAM_VERSION=$(shell echo $(DEBIAN_VERSION) | sed -e 's/\(.*\)-.*/\1/g')
+DEBIAN_REVISION=$(shell echo $(DEBIAN_VERSION) | sed -e 's/.*-\([^\+]*\).*/\1/g')
+
+include /usr/share/dpatch/dpatch.make
+
# This is the debhelper compatibility version to use.
export DH_COMPAT=4
@@ -22,10 +28,14 @@
INSTALL_PROGRAM += -s
endif
-config.status: configure
+config.status: patch-stamp
dh_testdir
# Add here commands to configure the package.
- chmod a+x ./configure
+ifneq (,$(findstring +cvs,$(DEBIAN_VERSION)))
+ $(MAKE) -f Makefile.cvs clean
+ $(MAKE) -f Makefile.cvs
+ chmod a+x configure
+endif
CXXFLAGS="$(CFLAGS)" ./configure --host=$(DEB_HOST_GNU_TYPE) --build=$(DEB_BUILD_GNU_TYPE) --prefix=/usr --mandir=\$${prefix}/share/man --infodir=\$${prefix}/share/info
@@ -41,7 +51,7 @@
touch build-stamp
-clean:
+clean: unpatch
dh_testdir
dh_testroot
-rm -f build-stamp config.log
@@ -97,5 +107,12 @@
dh_md5sums -a
dh_builddeb -a
+update-cvs-snapshot:
+
+ cat debian/patches/10_cvs-snapshot.dpatch | head -25 > debian/patches/10_cvs-snapshot.dpatch
+ cvs -z3 -d :pserver:anonymous at cvs.linuxsampler.org:/var/cvs/linuxsampler \
+ rdiff -u -r liblscp_$(shell echo $(UPSTREAM_VERSION) | tr "." "_") -D today liblscp|\
+ filterdiff -x "debian/*" -p1 >> debian/patches/10_cvs-snapshot.dpatch
+ dch -v $(UPSTREAM_VERSION)-$(DEBIAN_REVISION)+cvs`date +%y%m%d` -m "New cvs snapshot"
binary: binary-indep binary-arch
.PHONY: build clean binary-indep binary-arch binary install
More information about the Demudi-commits
mailing list