aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Hanspeter Portner <dev@open-music-kontrollers.ch>2015-05-01 20:29:42 +0200
committerGravatar Hanspeter Portner <dev@open-music-kontrollers.ch>2015-05-01 20:29:42 +0200
commit3cd00fc1aaee6124bb19b71ff21ea178a405927f (patch)
tree77a43f82e754da5b5a0fdc8def2fb84e8924caef
parentee62cc1d380a6f6b2f544d3b86022bbc6c57205e (diff)
downloadchimaera_sc-3cd00fc1aaee6124bb19b71ff21ea178a405927f.zip
chimaera_sc-3cd00fc1aaee6124bb19b71ff21ea178a405927f.tar.gz
chimaera_sc-3cd00fc1aaee6124bb19b71ff21ea178a405927f.tar.bz2
chimaera_sc-3cd00fc1aaee6124bb19b71ff21ea178a405927f.tar.xz
major rework.
* change to Artistic License 2.0 * externalize initialization to ChimaeraConfig * fix handling of 'immediate' timestamps
-rw-r--r--COPYING201
-rw-r--r--README.md23
-rw-r--r--classes/ChimaeraCal.sc182
-rw-r--r--classes/ChimaeraConf.sc106
-rw-r--r--classes/ChimaeraDump.sc158
-rw-r--r--classes/ChimaeraGroup.sc28
-rw-r--r--classes/ChimaeraIn.sc37
-rw-r--r--classes/ChimaeraInDummy.sc45
-rw-r--r--classes/ChimaeraInTuio2.sc56
-rw-r--r--classes/ChimaeraMap.sc28
-rw-r--r--classes/ChimaeraOut.sc56
-rw-r--r--classes/ChimaeraOutMidi.sc52
-rw-r--r--classes/ChimaeraOutSCSynth2F.sc52
-rw-r--r--classes/ChimaeraOutSCSynth4F.sc56
-rwxr-xr-xignore/cal_gui.sc56
-rwxr-xr-xignore/custom.sc83
-rwxr-xr-xignore/custom_to_midi.sc101
-rwxr-xr-xignore/dummy_to_midi.sc58
-rwxr-xr-xignore/dummy_to_scsynth2F.sc62
-rwxr-xr-xignore/dump_gui.sc56
-rwxr-xr-xignore/group_gui.sc35
-rw-r--r--ignore/instruments/2F/anabase.sc28
-rw-r--r--ignore/instruments/2F/analog.sc28
-rw-r--r--ignore/instruments/2F/anamin.sc28
-rw-r--r--ignore/instruments/2F/blip.sc28
-rw-r--r--ignore/instruments/2F/degree.sc28
-rw-r--r--ignore/instruments/2F/filter.sc28
-rw-r--r--ignore/instruments/2F/grain.sc28
-rw-r--r--ignore/instruments/2F/pluck.sc28
-rw-r--r--ignore/instruments/2F/pluck_cubic.sc28
-rw-r--r--ignore/instruments/2F/pluck_vlf.sc28
-rw-r--r--ignore/instruments/2F/sine.sc28
-rw-r--r--ignore/instruments/2F/syncsaw.sc28
-rw-r--r--ignore/instruments/2F/theremin.sc28
-rw-r--r--ignore/instruments/2F/wind.sc28
-rw-r--r--ignore/instruments/4F/anabase.sc28
-rw-r--r--ignore/instruments/4F/cello.sc28
-rw-r--r--ignore/instruments/4F/pluck.sc28
-rw-r--r--ignore/instruments2F.sc28
-rw-r--r--ignore/instruments4F.sc28
-rwxr-xr-xignore/introspect.sc37
-rwxr-xr-xignore/mfr14.sc87
-rwxr-xr-xignore/osc_to_scsynth2F.sc28
-rwxr-xr-xignore/oscmidi_to_midi.sc89
-rwxr-xr-xignore/scsynth_to_scsynth2F.sc72
-rwxr-xr-xignore/scsynth_to_scsynth4F.sc73
-rwxr-xr-xignore/tuio2_to_midi.sc59
-rwxr-xr-xignore/tuio2_to_scsynth2F.sc64
-rwxr-xr-xignore/tuio2_to_scsynth4F.sc66
49 files changed, 1194 insertions, 1444 deletions
diff --git a/COPYING b/COPYING
new file mode 100644
index 0000000..ddb9a46
--- /dev/null
+++ b/COPYING
@@ -0,0 +1,201 @@
+ The Artistic License 2.0
+
+ Copyright (c) 2000-2006, The Perl Foundation.
+
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+Preamble
+
+This license establishes the terms under which a given free software
+Package may be copied, modified, distributed, and/or redistributed.
+The intent is that the Copyright Holder maintains some artistic
+control over the development of that Package while still keeping the
+Package available as open source and free software.
+
+You are always permitted to make arrangements wholly outside of this
+license directly with the Copyright Holder of a given Package. If the
+terms of this license do not permit the full use that you propose to
+make of the Package, you should contact the Copyright Holder and seek
+a different licensing arrangement.
+
+Definitions
+
+ "Copyright Holder" means the individual(s) or organization(s)
+ named in the copyright notice for the entire Package.
+
+ "Contributor" means any party that has contributed code or other
+ material to the Package, in accordance with the Copyright Holder's
+ procedures.
+
+ "You" and "your" means any person who would like to copy,
+ distribute, or modify the Package.
+
+ "Package" means the collection of files distributed by the
+ Copyright Holder, and derivatives of that collection and/or of
+ those files. A given Package may consist of either the Standard
+ Version, or a Modified Version.
+
+ "Distribute" means providing a copy of the Package or making it
+ accessible to anyone else, or in the case of a company or
+ organization, to others outside of your company or organization.
+
+ "Distributor Fee" means any fee that you charge for Distributing
+ this Package or providing support for this Package to another
+ party. It does not mean licensing fees.
+
+ "Standard Version" refers to the Package if it has not been
+ modified, or has been modified only in ways explicitly requested
+ by the Copyright Holder.
+
+ "Modified Version" means the Package, if it has been changed, and
+ such changes were not explicitly requested by the Copyright
+ Holder.
+
+ "Original License" means this Artistic License as Distributed with
+ the Standard Version of the Package, in its current version or as
+ it may be modified by The Perl Foundation in the future.
+
+ "Source" form means the source code, documentation source, and
+ configuration files for the Package.
+
+ "Compiled" form means the compiled bytecode, object code, binary,
+ or any other form resulting from mechanical transformation or
+ translation of the Source form.
+
+
+Permission for Use and Modification Without Distribution
+
+(1) You are permitted to use the Standard Version and create and use
+Modified Versions for any purpose without restriction, provided that
+you do not Distribute the Modified Version.
+
+
+Permissions for Redistribution of the Standard Version
+
+(2) You may Distribute verbatim copies of the Source form of the
+Standard Version of this Package in any medium without restriction,
+either gratis or for a Distributor Fee, provided that you duplicate
+all of the original copyright notices and associated disclaimers. At
+your discretion, such verbatim copies may or may not include a
+Compiled form of the Package.
+
+(3) You may apply any bug fixes, portability changes, and other
+modifications made available from the Copyright Holder. The resulting
+Package will still be considered the Standard Version, and as such
+will be subject to the Original License.
+
+
+Distribution of Modified Versions of the Package as Source
+
+(4) You may Distribute your Modified Version as Source (either gratis
+or for a Distributor Fee, and with or without a Compiled form of the
+Modified Version) provided that you clearly document how it differs
+from the Standard Version, including, but not limited to, documenting
+any non-standard features, executables, or modules, and provided that
+you do at least ONE of the following:
+
+ (a) make the Modified Version available to the Copyright Holder
+ of the Standard Version, under the Original License, so that the
+ Copyright Holder may include your modifications in the Standard
+ Version.
+
+ (b) ensure that installation of your Modified Version does not
+ prevent the user installing or running the Standard Version. In
+ addition, the Modified Version must bear a name that is different
+ from the name of the Standard Version.
+
+ (c) allow anyone who receives a copy of the Modified Version to
+ make the Source form of the Modified Version available to others
+ under
+
+ (i) the Original License or
+
+ (ii) a license that permits the licensee to freely copy,
+ modify and redistribute the Modified Version using the same
+ licensing terms that apply to the copy that the licensee
+ received, and requires that the Source form of the Modified
+ Version, and of any works derived from it, be made freely
+ available in that license fees are prohibited but Distributor
+ Fees are allowed.
+
+
+Distribution of Compiled Forms of the Standard Version
+or Modified Versions without the Source
+
+(5) You may Distribute Compiled forms of the Standard Version without
+the Source, provided that you include complete instructions on how to
+get the Source of the Standard Version. Such instructions must be
+valid at the time of your distribution. If these instructions, at any
+time while you are carrying out such distribution, become invalid, you
+must provide new instructions on demand or cease further distribution.
+If you provide valid instructions or cease distribution within thirty
+days after you become aware that the instructions are invalid, then
+you do not forfeit any of your rights under this license.
+
+(6) You may Distribute a Modified Version in Compiled form without
+the Source, provided that you comply with Section 4 with respect to
+the Source of the Modified Version.
+
+
+Aggregating or Linking the Package
+
+(7) You may aggregate the Package (either the Standard Version or
+Modified Version) with other packages and Distribute the resulting
+aggregation provided that you do not charge a licensing fee for the
+Package. Distributor Fees are permitted, and licensing fees for other
+components in the aggregation are permitted. The terms of this license
+apply to the use and Distribution of the Standard or Modified Versions
+as included in the aggregation.
+
+(8) You are permitted to link Modified and Standard Versions with
+other works, to embed the Package in a larger work of your own, or to
+build stand-alone binary or bytecode versions of applications that
+include the Package, and Distribute the result without restriction,
+provided the result does not expose a direct interface to the Package.
+
+
+Items That are Not Considered Part of a Modified Version
+
+(9) Works (including, but not limited to, modules and scripts) that
+merely extend or make use of the Package, do not, by themselves, cause
+the Package to be a Modified Version. In addition, such works are not
+considered parts of the Package itself, and are not subject to the
+terms of this license.
+
+
+General Provisions
+
+(10) Any use, modification, and distribution of the Standard or
+Modified Versions is governed by this Artistic License. By using,
+modifying or distributing the Package, you accept this license. Do not
+use, modify, or distribute the Package, if you do not accept this
+license.
+
+(11) If your Modified Version has been derived from a Modified
+Version made by someone other than you, you are nevertheless required
+to ensure that your Modified Version complies with the requirements of
+this license.
+
+(12) This license does not grant you the right to use any trademark,
+service mark, tradename, or logo of the Copyright Holder.
+
+(13) This license includes the non-exclusive, worldwide,
+free-of-charge patent license to make, have made, use, offer to sell,
+sell, import and otherwise transfer the Package with respect to any
+patent claims licensable by the Copyright Holder that are necessarily
+infringed by the Package. If you institute patent litigation
+(including a cross-claim or counterclaim) against any party alleging
+that the Package constitutes direct or contributory patent
+infringement, then this Artistic License to you shall terminate on the
+date that such litigation is filed.
+
+(14) Disclaimer of Warranty:
+THE PACKAGE IS PROVIDED BY THE COPYRIGHT HOLDER AND CONTRIBUTORS "AS
+IS' AND WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES. THE IMPLIED
+WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR
+NON-INFRINGEMENT ARE DISCLAIMED TO THE EXTENT PERMITTED BY YOUR LOCAL
+LAW. UNLESS REQUIRED BY LAW, NO COPYRIGHT HOLDER OR CONTRIBUTOR WILL
+BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
+DAMAGES ARISING IN ANY WAY OUT OF THE USE OF THE PACKAGE, EVEN IF
+ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff --git a/README.md b/README.md
index d87cb8f..7237aa0 100644
--- a/README.md
+++ b/README.md
@@ -3,7 +3,8 @@
### Install
-To install the _Chimaera_ extension, simply copy this folder into your SuperCollider user extension directory directory
+To install the _Chimaera_ extension, simply copy this folder into your
+SuperCollider user extension directory.
sc3> Platform.userExtensionDir.postln;
@@ -13,4 +14,22 @@ or alternatively into the system-wide extension directory.
### Usage
-There are a bunch of examples in the _ignore_ directory which show the usage of the extension classes. Run and adapt them to your needs.
+There are a bunch of examples in the _ignore_ directory which show the usage of
+the extension classes. Run and adapt them to your needs.
+
+### License
+
+Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
+
+This is free software: you can redistribute it and/or modify
+it under the terms of the Artistic License 2.0 as published by
+The Perl Foundation.
+
+This source is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+Artistic License 2.0 for more details.
+
+You should have received a copy of the Artistic License 2.0
+along the source as a COPYING file. If not, obtain it from
+<http://www.perlfoundation.org/artistic_license_2_0>.
diff --git a/classes/ChimaeraCal.sc b/classes/ChimaeraCal.sc
index 52ade9f..ff2f41d 100644
--- a/classes/ChimaeraCal.sc
+++ b/classes/ChimaeraCal.sc
@@ -1,24 +1,18 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
ChimaeraCal {
@@ -33,87 +27,89 @@ ChimaeraCal {
}
init {|s, conf|
- win = Window.new("Chimaera Calibration Wizard", Rect(0, 0, 400, 250), false).front;
+ Routine.run({
+ win = Window.new("Chimaera Calibration Wizard", Rect(0, 0, 400, 250), false).front;
- desc = [
- "Start calibration procedure",
- "Determine the quiescent state of each sensor: Do not bring any magnetic source near the sensor array for some seconds and procede.",
- "Determine the threshold of each sensor: move the magnet at a fixed distance along the sensor array. This distance represents the sensors threshold, e.g. touch events will be triggered only above this threshold. Start left with one polarity, go right, return left, turn the polarity around, go right, return left and procede. This also gathers the first point for the 5-point sensor-distance curve-fit.",
- "Gather second point for 5-point sensor-distance curve-fit. Move both poles of the magnet at a fixed vicinity y1>0 (e.g. 0.25) over the given sensor only. Fill in your vicinity into the box and procede.",
- "Gather third point for 5-point sensor-distance curve-fit. Move both poles of the magnet at a fixed vicinity y2>y1 (e.g. 0.5) over the given sensor only. Fill in your vicinity into the box and procede.",
- "Gather fourth point for 5-point sensor-distance curve-fit. Move both poles of the magnet at a fixed vicinity y3>y2 (e.g. 0.75) over the given sensor only. Fill in your vicinity into the box and procede.",
- "Gather fithth point for 5-point sensor-distance curve-fit. Move both poles of the magnet at a fixed vicinity y4=1 over the given sensor only. This vicinity represents the maximal sensor value and hence the smallest distance (or even none) from the case.",
- "Determine the sensitivity of each sensor: move the magnet along the sensor array at a fixed vicinity (e.g. 0.75). Start left with one polarity, go right, return left, turn the polarity around, go right, return left and procede.",
- "You can now save your calibration data to EEPROM, so the device will load it at future boots.",
- ];
+ desc = [
+ "Start calibration procedure",
+ "Determine the quiescent state of each sensor: Do not bring any magnetic source near the sensor array for some seconds and procede.",
+ "Determine the threshold of each sensor: move the magnet at a fixed distance along the sensor array. This distance represents the sensors threshold, e.g. touch events will be triggered only above this threshold. Start left with one polarity, go right, return left, turn the polarity around, go right, return left and procede. This also gathers the first point for the 5-point sensor-distance curve-fit.",
+ "Gather second point for 5-point sensor-distance curve-fit. Move both poles of the magnet at a fixed vicinity y1>0 (e.g. 0.25) over the given sensor only. Fill in your vicinity into the box and procede.",
+ "Gather third point for 5-point sensor-distance curve-fit. Move both poles of the magnet at a fixed vicinity y2>y1 (e.g. 0.5) over the given sensor only. Fill in your vicinity into the box and procede.",
+ "Gather fourth point for 5-point sensor-distance curve-fit. Move both poles of the magnet at a fixed vicinity y3>y2 (e.g. 0.75) over the given sensor only. Fill in your vicinity into the box and procede.",
+ "Gather fithth point for 5-point sensor-distance curve-fit. Move both poles of the magnet at a fixed vicinity y4=1 over the given sensor only. This vicinity represents the maximal sensor value and hence the smallest distance (or even none) from the case.",
+ "Determine the sensitivity of each sensor: move the magnet along the sensor array at a fixed vicinity (e.g. 0.75). Start left with one polarity, go right, return left, turn the polarity around, go right, return left and procede.",
+ "You can now save your calibration data to EEPROM, so the device will load it at future boots.",
+ ];
- text = StaticText.new(win, Rect(10, 90, 380, 140));
- text.string = desc[0];
+ text = StaticText.new(win, Rect(10, 90, 380, 140));
+ text.string = desc[0];
- acts = [
- { conf.sendMsg("/calibration/start"); },
- { conf.sendMsg("/calibration/zero"); },
- { conf.sendMsg("/calibration/min", {|msg|
- AppClock.sched(0, {
- num.visible=true;
- is.string="Sensor #"++msg[0];
- is.visible=true;
- });
- })},
- { conf.sendMsg("/calibration/mid", num.value); },
- { conf.sendMsg("/calibration/mid", num.value); },
- { conf.sendMsg("/calibration/mid", num.value, {|msg|
- AppClock.sched(0, {
- num.value=1;
- num.visible=false;
- });
- })},
- { conf.sendMsg("/calibration/max", {|msg|
- AppClock.sched(0, {
- num.visible=true;
- is.visible=false;
- });
- })},
- { conf.sendMsg("/calibration/end", num.value, {|msg|
- AppClock.sched(0, {
- num.value=0;
- num.visible=false;
- is.visible=false;
- });
- })},
- { conf.sendMsg("/calibration/save", 0); },
- ];
+ acts = [
+ { conf.sendMsg("/calibration/start"); },
+ { conf.sendMsg("/calibration/zero"); },
+ { conf.sendMsg("/calibration/min", {|msg|
+ AppClock.sched(0, {
+ num.visible=true;
+ is.string="Sensor #"++msg[0];
+ is.visible=true;
+ });
+ })},
+ { conf.sendMsg("/calibration/mid", num.value); },
+ { conf.sendMsg("/calibration/mid", num.value); },
+ { conf.sendMsg("/calibration/mid", num.value, {|msg|
+ AppClock.sched(0, {
+ num.value=1;
+ num.visible=false;
+ });
+ })},
+ { conf.sendMsg("/calibration/max", {|msg|
+ AppClock.sched(0, {
+ num.visible=true;
+ is.visible=false;
+ });
+ })},
+ { conf.sendMsg("/calibration/end", num.value, {|msg|
+ AppClock.sched(0, {
+ num.value=0;
+ num.visible=false;
+ is.visible=false;
+ });
+ })},
+ { conf.sendMsg("/calibration/save", 0); },
+ ];
- button = Button.new(win, Rect(10, 10, 380, 40));
- button.states = [
- ["Start Calibration"],
- ["Step 1: Quiescence"],
- ["Step 2: Threshold @ y=0"],
- ["Step 3: Curve fit @ y1>0"],
- ["Step 4: Curve fit @ y2>y1"],
- ["Step 5: Curve fit @ y3>y2"],
- ["Step 6: Curve fit @ y=1"],
- ["Step 6: Sensitivity @ y=?"],
- ["Save Calibration"],
- ];
- button.action = { |b|
- var i, j;
- i = b.value;
- if(i == 0) {j=desc.size-1} {j=i-1};
- [i, j].postln;
- acts[j].value();
- text.string = desc[i];
- };
+ button = Button.new(win, Rect(10, 10, 380, 40));
+ button.states = [
+ ["Start Calibration"],
+ ["Step 1: Quiescence"],
+ ["Step 2: Threshold @ y=0"],
+ ["Step 3: Curve fit @ y1>0"],
+ ["Step 4: Curve fit @ y2>y1"],
+ ["Step 5: Curve fit @ y3>y2"],
+ ["Step 6: Curve fit @ y=1"],
+ ["Step 6: Sensitivity @ y=?"],
+ ["Save Calibration"],
+ ];
+ button.action = { |b|
+ var i, j;
+ i = b.value;
+ if(i == 0) {j=desc.size-1} {j=i-1};
+ [i, j].postln;
+ acts[j].value();
+ text.string = desc[i];
+ };
- is= StaticText.new(win, Rect(10, 50, 190, 40));
- is.visible = false;
- is.string = "unknown";
+ is= StaticText.new(win, Rect(10, 50, 190, 40));
+ is.visible = false;
+ is.string = "unknown";
- num = NumberBox.new(win, Rect(200, 50, 190, 40));
- num.clipLo = 0.0;
- num.clipHi = 1.0;
- num.decimals = 3;
- num.visible = false;
- num.value = 0.0;
+ num = NumberBox.new(win, Rect(200, 50, 190, 40));
+ num.clipLo = 0.0;
+ num.clipHi = 1.0;
+ num.decimals = 3;
+ num.visible = false;
+ num.value = 0.0;
+ }, clock:AppClock);
}
}
diff --git a/classes/ChimaeraConf.sc b/classes/ChimaeraConf.sc
index 134690f..f8820a5 100644
--- a/classes/ChimaeraConf.sc
+++ b/classes/ChimaeraConf.sc
@@ -1,42 +1,38 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
ChimaeraConf {
- var tx, rx, count, success, fail, cb;
+ var tx, <rx, count, success, fail, cb;
- *new {|s, iTx, iRx|
- ^super.new.init(s, iTx, iRx);
+ *new {|s, addr="chimaera.local", prot=\udp, target=\lang, rate=3000, offset=0.0025|
+ ^super.new.init(s, addr, prot, target, rate, offset);
}
*initClass {
}
- initConn {|iTx, iRx|
- tx = iTx;
- rx = iRx;
+ init {|s, addr, prot, target, rate, offset|
+ var port;
+ tx = NetAddr(addr, 4444);
+ rx = NetAddr(addr, 3333);
cb = Order.new;
count = 1000.rand;
+ // create success callback function
success = OSCFunc({|msg, time, addr, port|
var id;
var dest;
@@ -45,8 +41,9 @@ ChimaeraConf {
id = msg.removeAt(0);
dest = msg.removeAt(0);
this.success(id, dest, msg);
- }, "/success", rx);
+ }, "/success", tx);
+ // create fail callback function
fail = OSCFunc({|msg, time, addr, port|
var id;
var dest;
@@ -55,45 +52,78 @@ ChimaeraConf {
id = msg.removeAt(0);
dest = msg.removeAt(0);
this.fail(id, dest, msg);
- }, "/fail", rx);
- }
+ }, "/fail", tx);
+
+ // set port depending on target
+ if(target == \lang, {
+ port = NetAddr.langPort
+ }, { // target == \serv
+ port = s.addr.port
+ });
- init {|s, iTx, iRx|
- this.initConn(iTx, iRx);
+ // initialization
+ this.sendMsg("/engines/enabled", false);
+ this.sendMsg("/engines/reset");
+ this.sendMsg("/engines/offset", offset);
+ if(prot == \udp, {
+ this.sendMsg("/engines/address", "this:"++port, {
+ this.sendMsg("/engines/server", false);
+ this.sendMsg("/engines/mode", "osc.udp");
+ this.sendMsg("/engines/enabled", true);
+ });
+ }, { // prot == \tcp
+ if(target == \lang, {
+ this.sendMsg("/engines/server", true);
+ this.sendMsg("/engines/mode", "osc.tcp");
+ this.sendMsg("/engines/enabled", true, {|msg| rx.connect;});
+ }, { // target == \serv
+ this.sendMsg("/engines/address", "this:"++port, {
+ this.sendMsg("/engines/server", false);
+ this.sendMsg("/engines/mode", "osc.tcp");
+ this.sendMsg("/engines/enabled", true);
+ });
+ });
+ });
+ if(rate > 2000, {
+ this.sendMsg("/engines/parallel", true);
+ }, {
+ this.sendMsg("/engines/parallel", false);
+ });
+ this.sendMsg("/sensors/rate", rate);
}
success {|id, dest, msg|
- if (cb[id].isFunction) {
+ if(cb[id].isFunction, {
cb.[id].value(msg);
- };
+ });
cb.removeAt(id);
("Chimaera request #"++id+"succeeded:"+dest).postln;
}
fail {|id, dest, msg|
- if (cb[id].notNil) {
+ if(cb[id].notNil, {
cb.removeAt(id);
("Chimaera request #"++id+"failed:"+dest+"("++msg[0]++")").postln;
- };
+ });
}
sendMsg {|... args|
var path, callback, res;
path = args.removeAt(0);
- if(args[args.size-1].isFunction) {
+ if(args[args.size-1].isFunction, {
callback = args.pop;
- } {
+ }, {
callback = true;
- };
+ });
cb[count] = callback;
- if( (args[args.size-1].isArray) && (args[args.size-1].isString.not) ) {
+ if( (args[args.size-1].isArray) && (args[args.size-1].isString.not), {
var arr = args.pop;
args = args ++ arr;
tx.performList(\sendMsg, path, count, args);
- } {
+ }, {
tx.performList(\sendMsg, path, count, args);
- };
+ });
// send timeout to ourselfs
AppClock.sched(1, {
diff --git a/classes/ChimaeraDump.sc b/classes/ChimaeraDump.sc
index 02b1d92..9e56afb 100644
--- a/classes/ChimaeraDump.sc
+++ b/classes/ChimaeraDump.sc
@@ -1,109 +1,101 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
ChimaeraDump {
var win, view, arr, cb, fps;
- *new {|s, conf, rx|
- ^super.new.init(s, conf, rx);
+ *new {|s, conf, n|
+ ^super.new.init(s, conf, n);
}
*initClass {
//TODO
}
- init {|s, conf, rx|
+ init {|s, conf, n|
+ var geo;
+ var h = 100;
+ var h1 = 1 / h;
+ var w = 6;
+ var w2 = w - 2;
+ var m = 2200;
+ var sc = 1 / m * h;
+ var d = 2048 * sc;
+ var t = 2032 * sc; //TODO
+ var p0, p1, p2, p3;
+
conf.sendMsg("/engines/dump/enabled", true); // enable sensor array dump
- conf.sendMsg("/sensors/number", {|n|
- var geo;
- var h = 100;
- var h1 = 1 / h;
- var w = 6;
- var w2 = w - 2;
- var m = 2200;
- var sc = 1 / m * h;
- var d = 2048 * sc;
- var t = 2032 * sc; //TODO
- var p0, p1, p2, p3;
- n = n[0];
- n.postln;
+ arr = Int8Array.newClear(n*2);
+ geo = Rect(0, 0, n*w, h*2);
+ p0 = Point.new(0, h-d);
+ p1 = Point.new(n*w, h-d);
+ p2 = Point.new(0, h+d);
+ p3 = Point.new(n*w, h+d);
- arr = Int8Array.newClear(n*2);
- geo = Rect(0, 0, n*w, h*2);
- p0 = Point.new(0, h-d);
- p1 = Point.new(n*w, h-d);
- p2 = Point.new(0, h+d);
- p3 = Point.new(n*w, h+d);
-
- Routine.run({
- win = Window.new("Chimaera Sensor Dump", geo, false).front;
- view = UserView(win, geo);
- view.drawFunc = {
- Pen.strokeColor = Color.black;
- Pen.line(p0, p1);
- Pen.stroke;
- Pen.line(p2, p3);
+ Routine.run({
+ win = Window.new("Chimaera Sensor Dump", geo, false).front;
+ view = UserView(win, geo);
+ view.drawFunc = {
+ // draw grid lines
+ Pen.strokeColor = Color.black;
+ Pen.line(p0, p1);
+ Pen.stroke;
+ Pen.line(p2, p3);
+ Pen.stroke;
+ for(1,n-1, {|i|
+ Pen.line(Point.new(i*16*w, 0), Point.new(i*16*w, 2*h));
Pen.stroke;
- for(1,n-1, {|i|
- Pen.line(Point.new(i*16+0.5*w, 0), Point.new(i*16+0.5*w, 2*h));
- Pen.stroke;
- });
+ });
- for(0,n-1, {|i|
- var msb, lsb, val;
- lsb = arr[i*2+1];
- if(lsb < 0) {lsb = 256+lsb};
- msb = arr[i*2] << 8;
- val = msb | lsb;
- val = val * sc;
- if(val.abs >= t) {
- Pen.fillColor = Color.yellow;
+ // draw bars
+ for(0,n-1, {|i|
+ var msb, lsb, val;
+ lsb = arr[i*2+1];
+ if(lsb < 0) {lsb = 256+lsb};
+ msb = arr[i*2] << 8;
+ val = msb | lsb;
+ val = val * sc;
+ if(val.abs >= t) {
+ Pen.fillColor = Color.yellow;
+ } {
+ if(val < 0) {
+ var red = 0 - val * h1;
+ Pen.fillColor = Color.new(red, 0, 0);
} {
- if(val < 0) {
- var red = 0 - val * h1;
- Pen.fillColor = Color.new(red, 0, 0);
- } {
- var green = val * h1;
- Pen.fillColor = Color.new(0, green, 0);
- };
+ var green = val * h1;
+ Pen.fillColor = Color.new(0, green, 0);
};
- Pen.addRect(Rect(i*w+1, h, w2, val));
- Pen.fill;
- });
- };
- }, clock:AppClock);
+ };
+ Pen.addRect(Rect(i*w+1, h, w2, val));
+ Pen.fill;
+ });
+ };
+ }, clock:AppClock);
- fps = Routine.run({
- while(true) {
- view.refresh;
- (1/30).wait;
- }
- }, clock:AppClock);
+ fps = Routine.run({
+ while(true) {
+ view.refresh;
+ (1/30).wait;
+ }
+ }, clock:AppClock);
- cb = OSCFunc({|msg, time, addr, port|
- arr = msg[2];
- }, "/dump", rx);
- });
+ cb = OSCFunc({|msg, time, addr, port|
+ arr = msg[2];
+ }, "/dump", conf.rx);
}
}
diff --git a/classes/ChimaeraGroup.sc b/classes/ChimaeraGroup.sc
index 26a0f16..b96baa3 100644
--- a/classes/ChimaeraGroup.sc
+++ b/classes/ChimaeraGroup.sc
@@ -1,24 +1,18 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
ChimaeraGroup {
diff --git a/classes/ChimaeraIn.sc b/classes/ChimaeraIn.sc
index 8b6ef52..a3478ef 100644
--- a/classes/ChimaeraIn.sc
+++ b/classes/ChimaeraIn.sc
@@ -1,38 +1,33 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
ChimaeraIn {
+ classvar immediate;
var engine;
- *new {|s, conf, rx, iEngine|
- ^super.new.init(s, conf, rx, iEngine);
+ *new {|s, conf, iEngine|
+ ^super.new.init(s, conf, iEngine);
}
*initClass {
- //TODO
+ immediate = 2085978496;
}
- init {|s, conf, rx, iEngine|
+ init {|s, conf, iEngine|
engine = iEngine;
}
}
diff --git a/classes/ChimaeraInDummy.sc b/classes/ChimaeraInDummy.sc
index 7a606ef..db4b5f0 100644
--- a/classes/ChimaeraInDummy.sc
+++ b/classes/ChimaeraInDummy.sc
@@ -1,49 +1,44 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
ChimaeraInDummy : ChimaeraIn {
- var on, off, set, idle, lastTime;
+ var on, off, set, idle;
- init {|s, conf, rx, iEngine|
+ init {|s, conf, iEngine|
engine = iEngine;
conf.sendMsg("/engines/dummy/enabled", true); // enable dummy output engine
conf.sendMsg("/engines/dummy/redundancy", false); // disable redundant output
+ conf.sendMsg("/engines/dummy/derivatives", true); // enable derivatives
on = OSCFunc({ |msg, time, addr, port|
- engine.on(time, msg[1], msg[2], msg[3], msg[4], msg[5]) // sid, gid, pid, x, z
- }, "/on", rx);
+ engine.on(time, msg[1], msg[2], msg[3], msg[4], msg[5], msg[6], msg[7]) // sid, gid, pid, x, z, vx, vz
+ }, "/on", conf.rx);
off = OSCFunc({ |msg, time, addr, port|
engine.off(time, msg[1]) // sid
- }, "/off", rx);
+ }, "/off", conf.rx);
set = OSCFunc({ |msg, time, addr, port|
- engine.set(time, msg[1], msg[2], msg[3]) // sid, x, z
- }, "/set", rx);
+ engine.set(time, msg[1], msg[2], msg[3], msg[4], msg[5]) // sid, x, z, vx, vz
+ }, "/set", conf.rx);
idle = OSCFunc({ |msg, time, addr, port|
engine.idle(time);
- }, "/idle", rx);
+ }, "/idle", conf.rx);
}
}
diff --git a/classes/ChimaeraInTuio2.sc b/classes/ChimaeraInTuio2.sc
index e0b3df3..83cd0b8 100644
--- a/classes/ChimaeraInTuio2.sc
+++ b/classes/ChimaeraInTuio2.sc
@@ -1,30 +1,24 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
ChimaeraInTuio2 : ChimaeraIn {
var firstFrame, frm, tok, alv, blobs, blobsOld, lastFid, lastTime, ignore;
- init {|s, conf, rx, iEngine|
+ init {|s, conf, iEngine|
engine = iEngine;
firstFrame = 1;
@@ -35,16 +29,14 @@ ChimaeraInTuio2 : ChimaeraIn {
ignore = false;
conf.sendMsg("/engines/tuio2/enabled", true); // enable Tuio2 output engine
+ conf.sendMsg("/engines/tuio2/derivatives", true); // enable derivatives
frm = OSCFunc({ |msg, time, addr, port|
- var fid, timestamp;
+ var fid;
fid = msg[1];
- timestamp = time; //msg[2]; // TODO sclang does not support the OSC timestamp as argument
- // dim = msg[3];
- // src = msg[4];
- if( (fid < lastFid) || (timestamp < lastTime), {
+ if( (fid < lastFid) || (time < lastTime), {
["TUIO2 packet missing or late"].postln;
ignore = true;
}, {
@@ -52,11 +44,11 @@ ChimaeraInTuio2 : ChimaeraIn {
});
lastFid = fid;
- lastTime = timestamp;
- }, "/tuio2/frm", rx);
+ lastTime = time;
+ }, "/tuio2/frm", conf.rx);
tok = OSCFunc({ |msg, time, addr, port|
- var o, sid, pid, gid, x, z;
+ var o, sid, pid, gid, x, z, vx, vz;
if(ignore == false, {
sid = msg[1];
@@ -65,10 +57,12 @@ ChimaeraInTuio2 : ChimaeraIn {
x = msg[4];
z = msg[5];
//a = msg[6]; // not used
+ vx = msg[7];
+ vz = msg[8];
- blobs[sid] = [time, sid, gid, pid, x, z];
+ blobs[sid] = [time, sid, gid, pid, x, z, vx, vz];
});
- }, "/tuio2/tok", rx);
+ }, "/tuio2/tok", conf.rx);
alv = OSCFunc({ |msg, time, addr, port|
var n, tmp;
@@ -94,14 +88,14 @@ ChimaeraInTuio2 : ChimaeraIn {
msg do: {|v|
var b = blobs[v];
if(blobsOld.indexOf(v).isNil, {
- engine.on(b[0], b[1], b[2], b[3], b[4], b[5]); // time, sid, gid, pid, x, z
+ engine.on(b[0], b[1], b[2], b[3], b[4], b[5], b[6], b[7]); // time, sid, gid, pid, x, z, vx, vz
}, {
- engine.set(b[0], b[1], b[4], b[5]); // time, sid, x, z
+ engine.set(b[0], b[1], b[4], b[5], b[6], b[7]); // time, sid, x, z, vx, vz
});
};
blobsOld = msg;
});
- }, "/tuio2/alv", rx);
+ }, "/tuio2/alv", conf.rx);
}
}
diff --git a/classes/ChimaeraMap.sc b/classes/ChimaeraMap.sc
index ed14010..19f7d04 100644
--- a/classes/ChimaeraMap.sc
+++ b/classes/ChimaeraMap.sc
@@ -1,24 +1,18 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
ChimaeraMapLinearCPS {
diff --git a/classes/ChimaeraOut.sc b/classes/ChimaeraOut.sc
index 8460b82..d5addd5 100644
--- a/classes/ChimaeraOut.sc
+++ b/classes/ChimaeraOut.sc
@@ -1,52 +1,64 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
ChimaeraOut {
+ classvar <immediate;
+
*new {|s, n, groups|
^super.new.init(s, n, groups);
}
*initClass {
- //TODO
+ immediate = 2085978496;
+ }
+
+ *timeToLatency {|time|
+ var latency;
+
+ if(time <= immediate, {
+ latency = 0;
+ }, {
+ latency = time - SystemClock.seconds;
+
+ if(latency < 0, {
+ ("message late"+(latency*1000)+"ms").postln;
+ });
+ });
+
+ ^latency;
}
init {|s, n, groups|
"init".postln;
}
- on { |time, sid, gid, pid, x, z|
+ on {|time, sid, gid, pid, x, z, vx, vz|
"on".postln;
}
- off { |time, sid|
+ off {|time, sid|
"off".postln;
}
- set { |time, sid, x, z|
+ set {|time, sid, x, z, vx, vz|
"set".postln;
}
- idle { |time|
+ idle {|time|
"idle".postln;
}
}
diff --git a/classes/ChimaeraOutMidi.sc b/classes/ChimaeraOutMidi.sc
index f8a57cc..4d80660 100644
--- a/classes/ChimaeraOutMidi.sc
+++ b/classes/ChimaeraOutMidi.sc
@@ -1,24 +1,18 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
ChimaeraOutMidi : ChimaeraOut {
@@ -26,8 +20,8 @@ ChimaeraOutMidi : ChimaeraOut {
init {|s, n, groups|
MIDIClient.init;
- //midio = MIDIOut(0, MIDIClient.destinations[0].uid); // use this on MacOS, Windows to connect to the MIDI stream of choice
- midio = MIDIOut(0); // use this on Linux, as patching is usually done via ALSA/JACK
+ //midio = MIDIOut(0, MIDIClient.destinations[0].uid); // use this on Windows
+ midio = MIDIOut(0); // use this on Linux/OSX
midio.latency = 0; // send MIDI with no delay, instantaneously
control = 0x07; // volume
@@ -39,11 +33,10 @@ ChimaeraOutMidi : ChimaeraOut {
lookup = Order.new; // lookup table of currently active keys
}
- on { |time, sid, gid, pid, x, z| // set callback function for blob on-events
+ on {|time, sid, gid, pid, x, z, vx, vz| // set callback function for blob on-events
var midikey, midinote, cc;
- midio.latency = time - SystemClock.seconds;
- if(midio.latency < 0) { ("message late"+(midio.latency*1000)+"ms").postln; };
+ midio.latency = ChimaeraOut.timeToLatency(time);
midikey = x*ran+bot;
midinote = midikey.round;
@@ -61,11 +54,10 @@ ChimaeraOutMidi : ChimaeraOut {
}
}
- off { |time, sid| // set callback function for blob off-events
+ off {|time, sid| // set callback function for blob off-events
var midinote, gid;
- midio.latency = time - SystemClock.seconds;
- if(midio.latency < 0) { ("message late"+(midio.latency*1000)+"ms").postln; };
+ midio.latency = ChimaeraOut.timeToLatency(time);
gid = lookup[sid][0];
midinote = lookup[sid][1];
@@ -74,11 +66,10 @@ ChimaeraOutMidi : ChimaeraOut {
lookup[sid] = nil;
}
- set { |time, sid, x, z| // set callback function for blob set-events
+ set {|time, sid, x, z, vx, vz| // set callback function for blob set-events
var midikey, midinote, gid, cc;
- midio.latency = time - SystemClock.seconds;
- if(midio.latency < 0) { ("message late"+(midio.latency*1000)+"ms").postln; };
+ midio.latency = ChimaeraOut.timeToLatency(time);
midikey = x*ran+bot;
gid = lookup[sid][0];
@@ -95,8 +86,7 @@ ChimaeraOutMidi : ChimaeraOut {
}
}
- idle { |time|
- midio.latency = time - SystemClock.seconds;
- if(midio.latency < 0) { ("message late"+(midio.latency*1000)+"ms").postln; };
+ idle {|time|
+ midio.latency = ChimaeraOut.timeToLatency(time);
}
}
diff --git a/classes/ChimaeraOutSCSynth2F.sc b/classes/ChimaeraOutSCSynth2F.sc
index 8ae9f03..89d8675 100644
--- a/classes/ChimaeraOutSCSynth2F.sc
+++ b/classes/ChimaeraOutSCSynth2F.sc
@@ -1,24 +1,18 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
ChimaeraOutSCSynth2F : ChimaeraOut {
@@ -36,31 +30,27 @@ ChimaeraOutSCSynth2F : ChimaeraOut {
}
}
- on { |time, sid, gid, pid, x, z| // set callback function for blob on-events
- var lag = time - SystemClock.seconds;
- if(lag < 0) { ("message late"+(lag*1000)+"ms").postln; };
+ on {|time, sid, gid, pid, x, z, vx, vz| // set callback function for blob on-events
+ var lag = ChimaeraOut.timeToLatency(time);
s.sendMsg('/s_new', instruments[gid], sid+sidOffset, \addToHead, gid+gidOffset, 4, pid, 'out', gid, 'gate', 1);
- s.sendBundle(lag, ['/n_setn', sid+sidOffset, 0, 2, x, z]);
+ s.sendBundle(lag, ['/n_setn', sid+sidOffset, 0, 4, x, z, vx, vz]);
}
- off { |time, sid| // set callback function for blob off-events
- var lag = time - SystemClock.seconds;
- if(lag < 0) { ("message late"+(lag*1000)+"ms").postln; };
+ off {|time, sid| // set callback function for blob off-events
+ var lag = ChimaeraOut.timeToLatency(time);
s.sendBundle(lag, ['/n_set', sid+sidOffset, 'gate', 0]);
}
- set { |time, sid, x, z| // set callback function for blob set-events
- var lag = time - SystemClock.seconds;
- if(lag < 0) { ("message late"+(lag*1000)+"ms").postln; };
+ set {|time, sid, x, z, vx, vz| // set callback function for blob set-events
+ var lag = ChimaeraOut.timeToLatency(time);
- s.sendBundle(lag, ['/n_setn', sid+sidOffset, 0, 2, x, z]);
+ s.sendBundle(lag, ['/n_setn', sid+sidOffset, 0, 4, x, z, vx, vz]);
}
- idle { |time|
- var lag = time - SystemClock.seconds;
- if(lag < 0) { ("message late"+(lag*1000)+"ms").postln; };
+ idle {|time|
+ var lag = ChimaeraOut.timeToLatency(time);
instruments do: {|v, gid|
s.sendBundle(lag, ['/n_set', gid+gidOffset, 'gate', 0]);
diff --git a/classes/ChimaeraOutSCSynth4F.sc b/classes/ChimaeraOutSCSynth4F.sc
index b3d5f1e..eb5a1f0 100644
--- a/classes/ChimaeraOutSCSynth4F.sc
+++ b/classes/ChimaeraOutSCSynth4F.sc
@@ -1,24 +1,18 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
ChimaeraOutSCSynth4F : ChimaeraOut {
@@ -38,25 +32,23 @@ ChimaeraOutSCSynth4F : ChimaeraOut {
lookup = Order.new; // lookup table of currently active blobs
}
- on { |time, sid, gid, pid, x, z| // set callback function for blob on-events
- var lag = time - SystemClock.seconds;
- if(lag < 0) { ("message late"+(lag*1000)+"ms").postln; };
+ on {|time, sid, gid, pid, x, z, vx, vz| // set callback function for blob on-events
+ var lag = ChimaeraOut.timeToLatency(time);
lookup[sid] = gid;
if(gid==0) {
s.sendMsg('/s_new', instruments[gid], sid+sidOffset, \addToHead, grp, 4, pid, 'out', gid, 'gate', 1);
- s.sendBundle(lag, ['/n_setn', sid+sidOffset, 0, 2, x, z]);
+ s.sendBundle(lag, ['/n_setn', sid+sidOffset, 0, 4, x, z, vx, vz]);
} {
s.sendBundle(lag, ['/n_set', grp, 9, pid]);
- s.sendBundle(lag, ['/n_setn', grp, 5, 2, x, z]);
+ s.sendBundle(lag, ['/n_setn', grp, 5, 4, x, z, vx, vz]);
};
}
- off { |time, sid| // set callback function for blob off-events
+ off {|time, sid| // set callback function for blob off-events
+ var lag = ChimaeraOut.timeToLatency(time);
var gid;
- var lag = time - SystemClock.seconds;
- if(lag < 0) { ("message late"+(lag*1000)+"ms").postln; };
gid = lookup[sid];
@@ -67,23 +59,21 @@ ChimaeraOutSCSynth4F : ChimaeraOut {
lookup[sid] = nil;
}
- set { |time, sid, x, z| // set callback function for blob set-events
+ set {|time, sid, x, z, vx, vz| // set callback function for blob set-events
+ var lag = ChimaeraOut.timeToLatency(time);
var gid;
- var lag = time - SystemClock.seconds;
- if(lag < 0) { ("message late"+(lag*1000)+"ms").postln; };
gid = lookup[sid];
if(gid==0) {
- s.sendBundle(lag, ['/n_setn', sid+sidOffset, 0, 2, x, z]);
+ s.sendBundle(lag, ['/n_setn', sid+sidOffset, 0, 4, x, z, vx, vz]);
} {
- s.sendBundle(lag, ['/n_setn', grp, 5, 2, x, z]);
+ s.sendBundle(lag, ['/n_setn', grp, 5, 4, x, z, vx, vz]);
};
}
- idle { |time|
- var lag = time - SystemClock.seconds;
- if(lag < 0) { ("message late"+(lag*1000)+"ms").postln; };
+ idle {|time|
+ var lag = ChimaeraOut.timeToLatency(time);
s.sendBundle(lag, ['/n_set', 0+gidOffset, 'gate', 0]);
}
diff --git a/ignore/cal_gui.sc b/ignore/cal_gui.sc
index 6fea817..482f128 100755
--- a/ignore/cal_gui.sc
+++ b/ignore/cal_gui.sc
@@ -1,45 +1,31 @@
#!/usr/bin/env sclang
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
{
- var hostname, rx, tx, chimconf, chimdump, chimcal;
-
- hostname = "hostname".unixCmdGetStdOutLines[0]++".local";
-
- tx = NetAddr("chimaera.local", 4444);
-
- thisProcess.openUDPPort(3333); // open port 3333 to listen for dump messages
- rx = NetAddr("chimaera.local", 3333);
-
- chimconf = ChimaeraConf(s, tx, tx);
-
- chimconf.sendMsg("/engines/enabled", true); // enable output
- chimconf.sendMsg("/engines/address", hostname++":"++3333); // send output stream to port 3333
- chimconf.sendMsg("/engines/offset", 0.002); // add 2ms offset to bundle timestamps
- chimconf.sendMsg("/engines/reset"); // reset all output engines
-
- chimdump = ChimaeraDump(s, chimconf, rx);
- chimcal = ChimaeraCal(s, chimconf);
+ var chimconf, chimdump, chimcal;
+
+ chimconf = ChimaeraConf(s,
+ addr:"chimaera.local", rate:1000);
+
+ chimconf.sendMsg("/sensors/number", {|msg|
+ var n=msg[0];
+ chimdump = ChimaeraDump(s, conf:chimconf, n:n);
+ chimcal = ChimaeraCal(s, conf:chimconf);
+ });
}.value;
diff --git a/ignore/custom.sc b/ignore/custom.sc
index eb0214b..032ade3 100755
--- a/ignore/custom.sc
+++ b/ignore/custom.sc
@@ -1,61 +1,58 @@
#!/usr/bin/env sclang
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
{
- var hostname, rx, tx, rate, chimconf, chimin, chimout;
-
- hostname = "hostname".unixCmdGetStdOutLines[0]++".local";
-
- tx = NetAddr ("chimaera.local", 4444);
+ var chimconf;
- chimconf = ChimaeraConf(s, tx, tx);
-
- rate = 3000;
- chimconf.sendMsg("/engines/reset");
- chimconf.sendMsg("/engines/address", hostname++":"++3333); // send output stream to port 3333
- chimconf.sendMsg("/engines/offset", 0.002);
+ chimconf = ChimaeraConf(s,
+ addr:"chimaera.local");
chimconf.sendMsg("/engines/custom/reset");
chimconf.sendMsg("/engines/custom/append", "frame", "/frm", "i($f)");
chimconf.sendMsg("/engines/custom/append", "idle", "/idl", "i($f)");
- //chimconf.sendMsg("/engines/custom/append", "end", "/end", "");
-
- chimconf.sendMsg("/engines/custom/append", "on", "/gate", "i($g 8* $b 8%+) i(1)");
- chimconf.sendMsg("/engines/custom/append", "off", "/gate", "i($g 8* $b 8%+) i(0)");
- chimconf.sendMsg("/engines/custom/append", "set", "/cv1", "i($g 8* $b 8%+) f($x 2* 1-)");
- chimconf.sendMsg("/engines/custom/append", "set", "/cv2", "i($g 8* $b 8%+) f($z 0.5* 0.5+)");
-
- //chimconf.sendMsg("/engines/custom/append", "on", "/midi", "m($g 8* $b 8%+ 0x90 $b 0x7f& 0x7f)");
- //chimconf.sendMsg("/engines/custom/append", "off", "/midi", "m($g 8* $b 8%+ 0x80 $b 0x7f& 0x7f)");
- //chimconf.sendMsg("/engines/custom/append", "set", "/midi", "m($g 8* $b 8%+ 0xc0 0x27 $z 0x3fff* 0x7f&)");
- //chimconf.sendMsg("/engines/custom/append", "set", "/midi", "m($g 8* $b 8%+ 0xc0 0x07 $z 0x3fff* 7<<)");
+ chimconf.sendMsg("/engines/custom/append", "end", "/end", "");
+
+ chimconf.sendMsg("/engines/custom/append",
+ "on", "/gate", "i($g 8* $b 8%+) i(1)");
+ chimconf.sendMsg("/engines/custom/append",
+ "off", "/gate", "i($g 8* $b 8%+) i(0)");
+ chimconf.sendMsg("/engines/custom/append",
+ "set", "/cv1", "i($g 8* $b 8%+) f($x 2* 1-)");
+ chimconf.sendMsg("/engines/custom/append",
+ "set", "/cv2", "i($g 8* $b 8%+) f($z 0.5* 0.5+)");
+
+ /*
+ chimconf.sendMsg("/engines/custom/append",
+ "on", "/midi", "m($g 8* $b 8%+ 0x90 $b 0x7f& 0x7f)");
+ chimconf.sendMsg("/engines/custom/append",
+ "off", "/midi", "m($g 8* $b 8%+ 0x80 $b 0x7f& 0x7f)");
+ chimconf.sendMsg("/engines/custom/append",
+ "set", "/midi", "m($g 8* $b 8%+ 0xc0 0x27 $z 0x3fff* 0x7f&)");
+ chimconf.sendMsg("/engines/custom/append",
+ "set", "/midi", "m($g 8* $b 8%+ 0xc0 0x07 $z 0x3fff* 7<<)");
+ */
chimconf.sendMsg("/engines/custom/enabled", true);
- chimconf.sendMsg("/sensors/rate", rate);
- chimconf.sendMsg("/sensors/group/reset"); // reset groups
- chimconf.sendMsg("/sensors/group/attributes/0", 0.0, 1.0, false, true, false); // add group
- chimconf.sendMsg("/sensors/group/attributes/1", 0.0, 1.0, true, false, false); // add group
+ chimconf.sendMsg("/sensors/group/reset");
+ chimconf.sendMsg("/sensors/group/attributes/0",
+ 0.0, 1.0, false, true, false);
+ chimconf.sendMsg("/sensors/group/attributes/1",
+ 0.0, 1.0, true, false, false);
}.value;
diff --git a/ignore/custom_to_midi.sc b/ignore/custom_to_midi.sc
index 80eb912..727b1eb 100755
--- a/ignore/custom_to_midi.sc
+++ b/ignore/custom_to_midi.sc
@@ -1,91 +1,68 @@
#!/usr/bin/env sclang
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
{
- var rx, tx, rate, chimconf, chimin, chimout, midio, on , off, bend, control;
-
- thisProcess.openUDPPort(3333); // open port 3333 to listen for Tuio messages
-
- rx = NetAddr ("chimaera.local", 3333);
- tx = NetAddr ("chimaera.local", 4444);
-
- chimconf = ChimaeraConf(s, tx, tx);
+ var chimconf, midio, on , off, bend, control;
- rate = 3000;
- chimconf.sendMsg("/engines/reset");
- chimconf.sendMsg("/engines/offset", 0.0025);
+ chimconf = ChimaeraConf(s,
+ addr:"chimaera.local", prot:\tcp, target:\lang);
- chimconf.sendMsg("/engines/enabled", false);
- chimconf.sendMsg("/engines/server", true);
- chimconf.sendMsg("/engines/mode", "osc.tcp");
- chimconf.sendMsg("/engines/enabled", true, {|msg| rx.connect;}); // connect via TCP
-
chimconf.sendMsg("/engines/custom/reset");
- chimconf.sendMsg("/engines/custom/append", "on", "/noteOn", "i($g) i(35.5 $n 18% 6/- $n 3/ $x @@ $g[*+) i(0x7f)");
- chimconf.sendMsg("/engines/custom/append", "off", "/noteOff", "i($g) i(35.5 $n 18% 6/- $n 3/ $g]*+) i(0x7f)");
- chimconf.sendMsg("/engines/custom/append", "set", "/bend", "i($g) i($x $g]- 0x2000* 0x1fff+)");
- chimconf.sendMsg("/engines/custom/append", "set", "/control", "i($g) i(0x27) i($z 0x3fff* 0x7f&)");
- chimconf.sendMsg("/engines/custom/append", "set", "/control", "i($g) i(0x07) i($z 0x3fff* 7>>)");
-
+ chimconf.sendMsg("/engines/custom/append",
+ "on", "/noteOn", "i($g) i(35.5 $n 18% 6/- $n 3/ $x @@ $g[*+) i(0x7f)");
+ chimconf.sendMsg("/engines/custom/append",
+ "off", "/noteOff", "i($g) i(35.5 $n 18% 6/- $n 3/ $g]*+) i(0x7f)");
+ chimconf.sendMsg("/engines/custom/append",
+ "set", "/bend", "i($g) i($x $g]- 0x2000* 0x1fff+)");
+ chimconf.sendMsg("/engines/custom/append",
+ "set", "/control", "i($g) i(0x27) i($z 0x3fff* 0x7f&)");
+ chimconf.sendMsg("/engines/custom/append",
+ "set", "/control", "i($g) i(0x07) i($z 0x3fff* 7>>)");
chimconf.sendMsg("/engines/custom/enabled", true);
- chimconf.sendMsg("/sensors/rate", rate);
- chimconf.sendMsg("/sensors/group/reset"); // reset groups
- chimconf.sendMsg("/sensors/group/attributes/0", 0.0, 1.0, false, true, false); // add group
- chimconf.sendMsg("/sensors/group/attributes/1", 0.0, 1.0, true, false, false); // add group
+ chimconf.sendMsg("/sensors/group/reset");
+ chimconf.sendMsg("/sensors/group/attributes/0",
+ 0.0, 1.0, false, true, false);
+ chimconf.sendMsg("/sensors/group/attributes/1",
+ 0.0, 1.0, true, false, false);
MIDIClient.init;
- //midio = MIDIOut(0, MIDIClient.destinations[0].uid); // use this on MacOS, Windows to connect to the MIDI stream of choice
- midio = MIDIOut(0); // use this on Linux, as patching is usually done via ALSA/JACK
- midio.latency = 0; // send MIDI with no delay, instantaneously
+ //midio = MIDIOut(0, MIDIClient.destinations[0].uid); // use this on Windows
+ midio = MIDIOut(0); // use this on Linux/OSX
on = OSCFunc({|msg, time, addr, port|
- midio.latency = time - SystemClock.seconds;
- if(midio.latency < 0) {("message late"+(midio.latency*1000)+"ms").postln};
-
+ midio.latency = ChimaeraOut.timeToLatency(time);
midio.noteOn(msg[1], msg[2], msg[3]);
- }, "/noteOn", rx);
+ }, "/noteOn", chimconf.rx);
off = OSCFunc({|msg, time, addr, port|
- midio.latency = time - SystemClock.seconds;
- if(midio.latency < 0) {("message late"+(midio.latency*1000)+"ms").postln};
-
+ midio.latency = ChimaeraOut.timeToLatency(time);
midio.noteOff(msg[1], msg[2], msg[3]);
- }, "/noteOff", rx);
+ }, "/noteOff", chimconf.rx);
bend = OSCFunc({|msg, time, addr, port|
- midio.latency = time - SystemClock.seconds;
- if(midio.latency < 0) {("message late"+(midio.latency*1000)+"ms").postln};
-
+ midio.latency = ChimaeraOut.timeToLatency(time);
midio.bend(msg[1], msg[2]);
- }, "/bend", rx);
+ }, "/bend", chimconf.rx);
control = OSCFunc({|msg, time, addr, port|
- midio.latency = time - SystemClock.seconds;
- if(midio.latency < 0) {("message late"+(midio.latency*1000)+"ms").postln};
-
+ midio.latency = ChimaeraOut.timeToLatency(time);
midio.control(msg[1], msg[2], msg[3]);
- }, "/control", rx);
+ }, "/control", chimconf.rx);
}.value;
diff --git a/ignore/dummy_to_midi.sc b/ignore/dummy_to_midi.sc
index 28a2a9d..2e7594f 100755
--- a/ignore/dummy_to_midi.sc
+++ b/ignore/dummy_to_midi.sc
@@ -1,57 +1,39 @@
#!/usr/bin/env sclang
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
{
- var rx, tx, rate, chimconf, chimin, chimout;
-
- thisProcess.openUDPPort(3333); // open port 3333 to listen for Tuio messages
-
- rx = NetAddr ("chimaera.local", 3333);
- tx = NetAddr ("chimaera.local", 4444);
-
- chimconf = ChimaeraConf(s, tx, tx);
+ var chimconf, chimin, chimout;
- rate = 3000;
- chimconf.sendMsg("/engines/reset");
- chimconf.sendMsg("/engines/offset", 0.0025);
-
- chimconf.sendMsg("/engines/enabled", false);
- chimconf.sendMsg("/engines/server", true);
- chimconf.sendMsg("/engines/mode", "osc.tcp");
- chimconf.sendMsg("/engines/enabled", true, {|msg| rx.connect;}); // connect via TCP
+ chimconf = ChimaeraConf(s,
+ addr:"chimaera.local", prot:\tcp);
- chimconf.sendMsg("/sensors/rate", rate);
- chimconf.sendMsg("/sensors/group/reset"); // reset groups
- chimconf.sendMsg("/sensors/group/attributes/0", 0.0, 1.0, false, true, false); // add group
- chimconf.sendMsg("/sensors/group/attributes/1", 0.0, 1.0, true, false, false); // add group
+ chimconf.sendMsg("/sensors/group/reset");
+ chimconf.sendMsg("/sensors/group/attributes/0",
+ 0.0, 1.0, false, true, false);
+ chimconf.sendMsg("/sensors/group/attributes/1",
+ 0.0, 1.0, true, false, false);
chimconf.sendMsg("/sensors/number", {|msg|
var n = msg[0];
chimout = ChimaeraOutMidi(s, n, [\base, \lead]);
chimout.control = 0x07;
chimout.doublePrecision = true;
- chimin = ChimaeraInDummy(s, chimconf, rx, chimout);
+ chimin = ChimaeraInDummy(s, chimconf, chimout);
});
}.value;
diff --git a/ignore/dummy_to_scsynth2F.sc b/ignore/dummy_to_scsynth2F.sc
index 25fcf74..7e08693 100755
--- a/ignore/dummy_to_scsynth2F.sc
+++ b/ignore/dummy_to_scsynth2F.sc
@@ -1,26 +1,20 @@
#!/usr/bin/env sclang
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
s.options.blockSize = 0x10;
@@ -29,33 +23,23 @@ s.latency = nil;
s.boot;
s.doWhenBooted({
- var rx, tx, rate, chimconf, chimin, chimout;
-
- thisProcess.openUDPPort(3333); // open port 3333 to listen for Tuio messages
-
- rx = NetAddr ("chimaera.local", 3333);
- tx = NetAddr ("chimaera.local", 4444);
-
- chimconf = ChimaeraConf(s, tx, tx);
+ var chimconf, chimin, chimout;
- rate = 3000;
- chimconf.sendMsg("/engines/reset");
- chimconf.sendMsg("/engines/offset", 0.0025);
-
- chimconf.sendMsg("/engines/enabled", false);
- chimconf.sendMsg("/engines/server", true);
- chimconf.sendMsg("/engines/mode", "osc.tcp");
- chimconf.sendMsg("/engines/enabled", true, {|msg| rx.connect;}); // connect via TCP
+ chimconf = ChimaeraConf(s,
+ addr:"chimaera.local", prot:\tcp);
- chimconf.sendMsg("/sensors/rate", rate);
- chimconf.sendMsg("/sensors/group/reset"); // reset groups
- chimconf.sendMsg("/sensors/group/attributes/0", 0.0, 1.0, false, true, false); // add group
- chimconf.sendMsg("/sensors/group/attributes/1", 0.0, 1.0, true, false, false); // add group
+ chimconf.sendMsg("/sensors/group/reset");
+ chimconf.sendMsg("/sensors/group/attributes/0",
+ 0.0, 1.0, false, true, false);
+ chimconf.sendMsg("/sensors/group/attributes/1",
+ 0.0, 1.0, true, false, false);
chimconf.sendMsg("/sensors/number", {|msg|
var n = msg[0];
chimout = ChimaeraOutSCSynth2F(s, n, [\base, \lead]);
- chimin = ChimaeraInDummy(s, chimconf, rx, chimout);
- Routine.run({"./instruments2F.sc".load.value(n, \base, \lead);}, clock:AppClock);
+ chimin = ChimaeraInDummy(s, chimconf, chimout);
+ Routine.run({
+ "./instruments2F.sc".load.value(n, \base, \lead);
+ }, clock:AppClock);
});
})
diff --git a/ignore/dump_gui.sc b/ignore/dump_gui.sc
index 7c6ec18..8725f16 100755
--- a/ignore/dump_gui.sc
+++ b/ignore/dump_gui.sc
@@ -1,52 +1,30 @@
#!/usr/bin/env sclang
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
{
- var hostname, rx, tx, rate, chimconf, chimdump;
-
- hostname = "hostname".unixCmdGetStdOutLines[0]++".local";
-
- tx = NetAddr("chimaera.local", 4444);
+ var chimconf, chimdump;
- thisProcess.openUDPPort(3333); // open port 3333 to listen for dump messages
- rx = NetAddr("chimaera.local", 3333);
+ chimconf = ChimaeraConf(s,
+ addr:"chimaera.local", rate:1000);
- chimconf = ChimaeraConf(s, tx, tx);
-
- rate = 2500;
- chimconf.sendMsg("/engines/reset"); // reset all output engines
- chimconf.sendMsg("/engines/offset", 0.002);
- chimconf.sendMsg("/engines/address", hostname++":"++3333, {
- chimconf.sendMsg("/engines/server", false);
- chimconf.sendMsg("/engines/mode", "osc.udp");
- chimconf.sendMsg("/engines/enabled", true);
+ chimconf.sendMsg("/sensors/number", {|msg|
+ var n=msg[0];
+ chimdump = ChimaeraDump(s, conf:chimconf, n:n);
});
-
- chimconf.sendMsg("/sensors/rate", rate);
-
- chimconf.sendMsg("/calibration/reset"); // uncomment to reset quiescent output
-
- chimdump = ChimaeraDump(s, chimconf, rx);
}.value;
diff --git a/ignore/group_gui.sc b/ignore/group_gui.sc
index 826a2b0..5689e4c 100755
--- a/ignore/group_gui.sc
+++ b/ignore/group_gui.sc
@@ -1,34 +1,27 @@
#!/usr/bin/env sclang
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
{
- var tx, chimconf, chimgroup;
-
- tx = NetAddr("chimaera.local", 4444);
+ var chimconf, chimgroup;
- chimconf = ChimaeraConf(s, tx, tx);
+ chimconf = ChimaeraConf(s,
+ addr:"chimaera.local");
chimgroup = ChimaeraGroup(s, chimconf);
}.value;
diff --git a/ignore/instruments/2F/anabase.sc b/ignore/instruments/2F/anabase.sc
index e3c945f..371826f 100644
--- a/ignore/instruments/2F/anabase.sc
+++ b/ignore/instruments/2F/anabase.sc
@@ -1,24 +1,18 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
{|synthname, n|
diff --git a/ignore/instruments/2F/analog.sc b/ignore/instruments/2F/analog.sc
index f60594a..2781e5a 100644
--- a/ignore/instruments/2F/analog.sc
+++ b/ignore/instruments/2F/analog.sc
@@ -1,24 +1,18 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
{|synthname, n|
diff --git a/ignore/instruments/2F/anamin.sc b/ignore/instruments/2F/anamin.sc
index 9447c08..06949bb 100644
--- a/ignore/instruments/2F/anamin.sc
+++ b/ignore/instruments/2F/anamin.sc
@@ -1,24 +1,18 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
{|synthname, n|
diff --git a/ignore/instruments/2F/blip.sc b/ignore/instruments/2F/blip.sc
index 275b5d2..9cb065c 100644
--- a/ignore/instruments/2F/blip.sc
+++ b/ignore/instruments/2F/blip.sc
@@ -1,24 +1,18 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
{|synthname, n|
diff --git a/ignore/instruments/2F/degree.sc b/ignore/instruments/2F/degree.sc
index 19142bb..2002c3d 100644
--- a/ignore/instruments/2F/degree.sc
+++ b/ignore/instruments/2F/degree.sc
@@ -1,24 +1,18 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
{|synthname, n|
diff --git a/ignore/instruments/2F/filter.sc b/ignore/instruments/2F/filter.sc
index 1c2f97a..d66913e 100644
--- a/ignore/instruments/2F/filter.sc
+++ b/ignore/instruments/2F/filter.sc
@@ -1,24 +1,18 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
{|synthname, n|
diff --git a/ignore/instruments/2F/grain.sc b/ignore/instruments/2F/grain.sc
index 433f9cc..b832ccb 100644
--- a/ignore/instruments/2F/grain.sc
+++ b/ignore/instruments/2F/grain.sc
@@ -1,24 +1,18 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
{|synthname, n|
diff --git a/ignore/instruments/2F/pluck.sc b/ignore/instruments/2F/pluck.sc
index 49d2679..3d7a6e2 100644
--- a/ignore/instruments/2F/pluck.sc
+++ b/ignore/instruments/2F/pluck.sc
@@ -1,24 +1,18 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
{|synthname, n|
diff --git a/ignore/instruments/2F/pluck_cubic.sc b/ignore/instruments/2F/pluck_cubic.sc
index 7d19ba2..f4f93be 100644
--- a/ignore/instruments/2F/pluck_cubic.sc
+++ b/ignore/instruments/2F/pluck_cubic.sc
@@ -1,24 +1,18 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
{|synthname, n|
diff --git a/ignore/instruments/2F/pluck_vlf.sc b/ignore/instruments/2F/pluck_vlf.sc
index 071730d..4108808 100644
--- a/ignore/instruments/2F/pluck_vlf.sc
+++ b/ignore/instruments/2F/pluck_vlf.sc
@@ -1,24 +1,18 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
{|synthname, n|
diff --git a/ignore/instruments/2F/sine.sc b/ignore/instruments/2F/sine.sc
index 2241124..bfdb367 100644
--- a/ignore/instruments/2F/sine.sc
+++ b/ignore/instruments/2F/sine.sc
@@ -1,24 +1,18 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
{|synthname, n|
diff --git a/ignore/instruments/2F/syncsaw.sc b/ignore/instruments/2F/syncsaw.sc
index 5d365d3..0265664 100644
--- a/ignore/instruments/2F/syncsaw.sc
+++ b/ignore/instruments/2F/syncsaw.sc
@@ -1,24 +1,18 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
{|synthname, n|
diff --git a/ignore/instruments/2F/theremin.sc b/ignore/instruments/2F/theremin.sc
index f5147ac..2f8185e 100644
--- a/ignore/instruments/2F/theremin.sc
+++ b/ignore/instruments/2F/theremin.sc
@@ -1,24 +1,18 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
{|synthname, n|
diff --git a/ignore/instruments/2F/wind.sc b/ignore/instruments/2F/wind.sc
index 086b327..a5ee031 100644
--- a/ignore/instruments/2F/wind.sc
+++ b/ignore/instruments/2F/wind.sc
@@ -1,24 +1,18 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
{|synthname, n|
diff --git a/ignore/instruments/4F/anabase.sc b/ignore/instruments/4F/anabase.sc
index c06f5f5..8665625 100644
--- a/ignore/instruments/4F/anabase.sc
+++ b/ignore/instruments/4F/anabase.sc
@@ -1,24 +1,18 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
{|synthname, n|
diff --git a/ignore/instruments/4F/cello.sc b/ignore/instruments/4F/cello.sc
index 52c2f7d..0a0c215 100644
--- a/ignore/instruments/4F/cello.sc
+++ b/ignore/instruments/4F/cello.sc
@@ -1,24 +1,18 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
{|synthname, n|
diff --git a/ignore/instruments/4F/pluck.sc b/ignore/instruments/4F/pluck.sc
index 9aedf41..d4e9649 100644
--- a/ignore/instruments/4F/pluck.sc
+++ b/ignore/instruments/4F/pluck.sc
@@ -1,24 +1,18 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
{|synthname, n|
diff --git a/ignore/instruments2F.sc b/ignore/instruments2F.sc
index 2188393..6c26fcc 100644
--- a/ignore/instruments2F.sc
+++ b/ignore/instruments2F.sc
@@ -1,24 +1,18 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
{|n, baseSym, leadSym|
diff --git a/ignore/instruments4F.sc b/ignore/instruments4F.sc
index 98bee60..ec5b6a2 100644
--- a/ignore/instruments4F.sc
+++ b/ignore/instruments4F.sc
@@ -1,24 +1,18 @@
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
{|n|
diff --git a/ignore/introspect.sc b/ignore/introspect.sc
index b77e1ee..ed805f6 100755
--- a/ignore/introspect.sc
+++ b/ignore/introspect.sc
@@ -1,41 +1,30 @@
#!/usr/bin/env sclang
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
{
- var hostname;
var chimconf;
- var tx;
var success, fail;
var handleQueryResponse;
var win, tree, view, dict, bound, line, gray, grays, dark, darks;
- hostname = "hostname".unixCmdGetStdOutLines[0]++".local";
-
- tx = NetAddr ("chimaera.local", 4444);
-
- chimconf = ChimaeraConf(s, tx, tx);
+ chimconf = ChimaeraConf(s,
+ addr:"chimaera.local");
win = Window.new("Chimaera Configuration Wizard", Rect(0, 0, 1024, 640), true).front;
win.onClose = {0.exit};
diff --git a/ignore/mfr14.sc b/ignore/mfr14.sc
deleted file mode 100755
index 9e5b7ea..0000000
--- a/ignore/mfr14.sc
+++ /dev/null
@@ -1,87 +0,0 @@
-#!/usr/bin/env optsclang
-
-/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
- *
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
- *
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
- *
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
- */
-
-s.options.blockSize = 0x10;
-s.options.memSize = 0x10000;
-s.options.numInputBusChannels = 0;
-s.options.numOutputBusChannels = 10;
-s.latency = nil;
-s.boot;
-
-s.doWhenBooted({
- var gidOffset, mix;
-
- gidOffset = 100;
-
- s.sendMsg('/g_new', 0+gidOffset, \addToHead.asInt, 0);
- s.sendMsg('/g_new', 1+gidOffset, \addToHead.asInt, 0);
- s.sendMsg('/g_new', 2+gidOffset, \addToHead.asInt, 0);
- s.sendMsg('/g_new', 3+gidOffset, \addToHead.asInt, 0);
- s.sendMsg('/g_new', 4+gidOffset, \addToHead.asInt, 0);
- s.sendMsg('/g_new', 5+gidOffset, \addToHead.asInt, 0);
- s.sendMsg('/g_new', 6+gidOffset, \addToHead.asInt, 0);
- s.sendMsg('/g_new', 7+gidOffset, \addToHead.asInt, 0);
-
- s.sendMsg('/g_new', 8+gidOffset, \addToHead.asInt, 0); // mix
- s.sync;
-
- SynthDef(\mixer, {|g0=0.5, g1=0.5, g2=0.5, g3=0.5, g4=0.5, g5=0.5, g6=0.5, g7=0.5|
- var a0, a1, a2, a3, a4, a5, a6, a7;
- var p0, p1, p2, p3, p4, p5, p6, p7;
-
- // audio from SuperCollider
- a0 = InFeedback.ar(2) * g0; // base1
- a1 = InFeedback.ar(3) * g1; // lead1
- a2 = InFeedback.ar(4) * g2; // base2
- a3 = InFeedback.ar(5) * g3; // lead2
- a4 = InFeedback.ar(6) * g4; // base3
- a5 = InFeedback.ar(7) * g5; // lead3
- a6 = InFeedback.ar(8) * g6; // base4
- a7 = InFeedback.ar(9) * g7; // lead4
-
- // mix four mono channels to stereo
- p0 = Pan2.ar(a0, -1);
- p1 = Pan2.ar(a1, 1);
- p2 = Pan2.ar(a2, -1);
- p3 = Pan2.ar(a3, 1);
- p4 = Pan2.ar(a4, -1);
- p5 = Pan2.ar(a5, 1);
- p6 = Pan2.ar(a6, -1);
- p7 = Pan2.ar(a7, 1);
-
- OffsetOut.ar([0,1], Mix.ar([p0, p1, p2, p3, p4, p5, p6, p7]));
- }).add;
- s.sync;
-
- mix = Synth(\mixer, target:8+gidOffset, addAction:\addToHead);
- s.sync;
-
- // /n_set iif 108 0 0.5
-
- //"./instruments2F.sc".load.value(96, \base1, \lead1); // mini
- "./instruments2F.sc".load.value(128, \base2, \lead2); // midi
- //"./instruments2F.sc".load.value(128, \base3, \lead3); // medi
- "./instruments2F.sc".load.value(160, \base4, \lead4); // maxi
-})
diff --git a/ignore/osc_to_scsynth2F.sc b/ignore/osc_to_scsynth2F.sc
index 7ea196a..3f24dfb 100755
--- a/ignore/osc_to_scsynth2F.sc
+++ b/ignore/osc_to_scsynth2F.sc
@@ -1,26 +1,20 @@
#!/usr/bin/env optsclang
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
s.options.blockSize = 0x10;
diff --git a/ignore/oscmidi_to_midi.sc b/ignore/oscmidi_to_midi.sc
index 8795ea1..26f689f 100755
--- a/ignore/oscmidi_to_midi.sc
+++ b/ignore/oscmidi_to_midi.sc
@@ -1,61 +1,35 @@
#!/usr/bin/env sclang
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
{
- var rx, tx, rate, chimconf, midio, func, immediate, protocol;
+ var chimconf, midio, func;
- immediate = 2085978496;
- thisProcess.openUDPPort(3333); // open port 3333 to listen for Tuio messages
+ chimconf = ChimaeraConf(s,
+ addr:"chimaera.local", prot:\tcp);
- rx = NetAddr ("chimaera.local", 3333);
- tx = NetAddr ("chimaera.local", 4444);
+ chimconf.sendMsg("/sensors/group/reset");
+ chimconf.sendMsg("/sensors/group/attributes/0",
+ 0.0, 1.0, false, true, false);
+ chimconf.sendMsg("/sensors/group/attributes/1",
+ 0.0, 1.0, true, false, false);
- chimconf = ChimaeraConf(s, tx, tx);
-
- rate = 3000;
- protocol = \tcp; // choose between \udp and \tcp (TCP is recommended because of the MIDI note-off problem)
- chimconf.sendMsg("/engines/reset"); // reset all output engines
- chimconf.sendMsg("/engines/offset", 0.002);
-
- chimconf.sendMsg("/engines/enabled", false);
- if(protocol == \tcp, {
- chimconf.sendMsg("/engines/server", true);
- chimconf.sendMsg("/engines/mode", "osc.tcp");
- chimconf.sendMsg("/engines/enabled", true, {|msg| rx.connect.postln;}); // connect via TCP
- }, { // protocol == \udp
- chimconf.sendMsg("/engines/server", false);
- chimconf.sendMsg("/engines/mode", "osc.udp");
- chimconf.sendMsg("/engines/enabled", true);
- });
-
- chimconf.sendMsg("/sensors/rate", rate);
- chimconf.sendMsg("/sensors/group/reset"); // reset groups
- chimconf.sendMsg("/sensors/group/attributes/0", 0.0, 1.0, false, true, false); // add group
- chimconf.sendMsg("/sensors/group/attributes/1", 0.0, 1.0, true, false, false); // add group
-
- chimconf.sendMsg("/engines/oscmidi/enabled", true); // enable OSCMidi output engine
+ chimconf.sendMsg("/engines/oscmidi/enabled", true);
chimconf.sendMsg("/engines/oscmidi/multi", true);
chimconf.sendMsg("/engines/oscmidi/format", "int32");
chimconf.sendMsg("/engines/oscmidi/path", "/midi");
@@ -66,27 +40,20 @@
var bot = 3*12 - 0.5 - (n % 18 / 6);
var ran = n/3;
chimconf.sendMsg("/engines/oscmidi/reset");
- chimconf.sendMsg("/engines/oscmidi/attributes/0", "control_change", bot, ran, 0x07);
- chimconf.sendMsg("/engines/oscmidi/attributes/1", "control_change", bot, ran, 0x07);
+ chimconf.sendMsg("/engines/oscmidi/attributes/0",
+ "control_change", bot, ran, 0x07);
+ chimconf.sendMsg("/engines/oscmidi/attributes/1",
+ "control_change", bot, ran, 0x07);
}, clock:AppClock);
});
MIDIClient.init;
- //midio = MIDIOut(0, MIDIClient.destinations[0].uid); // use this on MacOS, Windows to connect to the MIDI stream of choice
- midio = MIDIOut(0); // use this on Linux, as patching is usually done via ALSA/JACK
+ //midio = MIDIOut(0, MIDIClient.destinations[0].uid); // use this on Windows
+ midio = MIDIOut(0); // use this on Linux/OSX
// OSC MIDI responder
func = OSCFunc({|msg, time, addr, port|
- // handle time stamp
- if(time <= immediate, { // no time synchronization
- midio.latency = 0; // schedule MIDI for immediate execution
- }, {
- midio.latency = time - SystemClock.seconds;
- if(midio.latency < 0, {
- midio.latency = 0; // schedule MIDI for immediate execution
- ("message late"+(midio.latency*1000)+"ms").postln
- });
- });
+ midio.latency = ChimaeraOut.timeToLatency(time);
msg.removeAt(0); // remove path
msg.do({|i| // iterate over all MIDI messages
@@ -96,5 +63,5 @@
var dat1 = (i & 0x7f0000) >> 16; // data byte 1
midio.write(3, hiStatus, loStatus, dat0, dat1);
});
- }, "/midi", rx);
+ }, "/midi", chimconf.rx);
}.value;
diff --git a/ignore/scsynth_to_scsynth2F.sc b/ignore/scsynth_to_scsynth2F.sc
index b3ccdde..83fbfd0 100755
--- a/ignore/scsynth_to_scsynth2F.sc
+++ b/ignore/scsynth_to_scsynth2F.sc
@@ -1,26 +1,20 @@
#!/usr/bin/env sclang
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
s.options.protocol = \tcp;
@@ -35,41 +29,31 @@ Routine.run({
}, clock:AppClock);
s.doWhenBooted({
- var hostname, tx, chimconf, rate, sidOffset, gidOffset;
-
- hostname = "hostname".unixCmdGetStdOutLines[0]++".local";
+ var chimconf, sidOffset, gidOffset;
gidOffset = 100;
sidOffset = 200;
- tx = NetAddr ("chimaera.local", 4444);
-
- chimconf = ChimaeraConf(s, tx, tx);
-
- rate = 3000;
- chimconf.sendMsg("/engines/enabled", false);
- chimconf.sendMsg("/engines/reset");
- chimconf.sendMsg("/engines/offset", 0.0025);
- chimconf.sendMsg("/engines/address", hostname++":"++s.addr.port, {
- chimconf.sendMsg("/engines/server", false);
- chimconf.sendMsg("/engines/mode", "osc.tcp");
- chimconf.sendMsg("/engines/enabled", true);
- });
-
- chimconf.sendMsg("/sensors/rate", rate);
- chimconf.sendMsg("/sensors/group/reset"); // reset groups
- chimconf.sendMsg("/sensors/group/attributes/0", 0.0, 1.0, false, true, false); // add group
- chimconf.sendMsg("/sensors/group/attributes/1", 0.0, 1.0, true, false, false); // add group
-
- chimconf.sendMsg("/engines/scsynth/enabled", true); // enable scsynth output engine
- chimconf.sendMsg("/engines/scsynth/derivatives", false);
- chimconf.sendMsg("/engines/scsynth/attributes/0", \base, sidOffset, 0+gidOffset, 0, 0, true, true, \addToHead.asInt, false);
- chimconf.sendMsg("/engines/scsynth/attributes/1", \lead, sidOffset, 1+gidOffset, 1, 0, true, true, \addToHead.asInt, false);
-
s.sendMsg('/g_new', 0+gidOffset, \addToHead.asInt, 0);
s.sendMsg('/g_new', 1+gidOffset, \addToHead.asInt, 0);
s.sync;
+ chimconf = ChimaeraConf(s,
+ addr:"chimaera.local", prot:\tcp, target:\serv);
+
+ chimconf.sendMsg("/sensors/group/reset");
+ chimconf.sendMsg("/sensors/group/attributes/0",
+ 0.0, 1.0, false, true, false);
+ chimconf.sendMsg("/sensors/group/attributes/1",
+ 0.0, 1.0, true, false, false);
+
+ chimconf.sendMsg("/engines/scsynth/enabled", true);
+ chimconf.sendMsg("/engines/scsynth/derivatives", true);
+ chimconf.sendMsg("/engines/scsynth/attributes/0",
+ \base, sidOffset, 0+gidOffset, 0, 0, true, true, \addToHead.asInt, false);
+ chimconf.sendMsg("/engines/scsynth/attributes/1",
+ \lead, sidOffset, 1+gidOffset, 1, 0, true, true, \addToHead.asInt, false);
+
chimconf.sendMsg("/sensors/number", {|msg|
var n=msg[0];
Routine.run({
diff --git a/ignore/scsynth_to_scsynth4F.sc b/ignore/scsynth_to_scsynth4F.sc
index 690f3f5..b604183 100755
--- a/ignore/scsynth_to_scsynth4F.sc
+++ b/ignore/scsynth_to_scsynth4F.sc
@@ -1,26 +1,20 @@
#!/usr/bin/env sclang
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
s.options.protocol = \tcp;
@@ -35,41 +29,30 @@ Routine.run({
}, clock:AppClock);
s.doWhenBooted({
- var hostname, tx, chimconf, rate, sidOffset, gidOffset, grp;
-
- hostname = "hostname".unixCmdGetStdOutLines[0]++".local";
+ var chimconf, sidOffset, gidOffset, grp;
gidOffset = 100;
sidOffset = 200;
grp = 0+gidOffset;
- tx = NetAddr ("chimaera.local", 4444);
-
- chimconf = ChimaeraConf(s, tx, tx);
-
- rate = 3000;
- chimconf.sendMsg("/engines/enabled", false);
- chimconf.sendMsg("/engines/reset");
- chimconf.sendMsg("/engines/offset", 0.0025);
- chimconf.sendMsg("/engines/address", hostname++":"++s.addr.port, {
- chimconf.sendMsg("/engines/server", false);
- chimconf.sendMsg("/engines/mode", "osc.tcp");
- chimconf.sendMsg("/engines/enabled", true);
- });
+ s.sendMsg('/g_new', grp, \addToHead.asInt, 0);
+ s.sync;
- chimconf.sendMsg("/sensors/rate", rate);
- chimconf.sendMsg("/sensors/group/reset"); // reset groups
- chimconf.sendMsg("/sensors/group/attributes/0", 0.0, 1.0, false, true, false); // add group
- chimconf.sendMsg("/sensors/group/attributes/1", 0.0, 1.0, true, false, false); // add group
+ chimconf = ChimaeraConf(s,
+ addr:"chimaera.local", prot:\tcp, target:\serv);
- chimconf.sendMsg("/engines/scsynth/enabled", true); // enable scsynth output engine
- chimconf.sendMsg("/engines/scsynth/derivatives", false);
- //chimconf.sendMsg("/engines/scsynth/derivatives", true); // for cello instrument
- chimconf.sendMsg("/engines/scsynth/attributes/0", \base, sidOffset, grp, 0, 0, true, true, \addToHead.asInt, false);
- chimconf.sendMsg("/engines/scsynth/attributes/1", \lead, sidOffset, grp, 0, 5, false, false, \addToHead.asInt, true);
+ chimconf.sendMsg("/sensors/group/reset");
+ chimconf.sendMsg("/sensors/group/attributes/0",
+ 0.0, 1.0, false, true, false);
+ chimconf.sendMsg("/sensors/group/attributes/1",
+ 0.0, 1.0, true, false, false);
- s.sendMsg('/g_new', grp, \addToHead.asInt, 0);
- s.sync;
+ chimconf.sendMsg("/engines/scsynth/enabled", true);
+ chimconf.sendMsg("/engines/scsynth/derivatives", true);
+ chimconf.sendMsg("/engines/scsynth/attributes/0",
+ \base, sidOffset, grp, 0, 0, true, true, \addToHead.asInt, false);
+ chimconf.sendMsg("/engines/scsynth/attributes/1",
+ \lead, sidOffset, grp, 0, 5, false, false, \addToHead.asInt, true);
chimconf.sendMsg("/sensors/number", {|msg|
var n=msg[0];
@@ -77,4 +60,4 @@ s.doWhenBooted({
"./instruments4F.sc".load.value(n);
}, clock:AppClock);
});
-})
+});
diff --git a/ignore/tuio2_to_midi.sc b/ignore/tuio2_to_midi.sc
index 8be0818..a4b4c5d 100755
--- a/ignore/tuio2_to_midi.sc
+++ b/ignore/tuio2_to_midi.sc
@@ -1,58 +1,39 @@
#!/usr/bin/env sclang
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
{
- var hostname, rx, tx, chimconf, rate, chimin, chimout;
-
- hostname = "hostname".unixCmdGetStdOutLines[0]++".local";
+ var chimconf, chimin, chimout;
- thisProcess.openUDPPort(3333); // open port 3333 to listen for Tuio messages
+ chimconf = ChimaeraConf(s,
+ addr:"chimaera.local");
- rx = NetAddr("chimaera.local", 3333);
- tx = NetAddr("chimaera.local", 4444);
-
- chimconf = ChimaeraConf(s, tx, tx);
-
- rate = 3000;
- chimconf.sendMsg("/engines/reset");
- chimconf.sendMsg("/engines/offset", 0.0025);
- chimconf.sendMsg("/engines/address", hostname++":"++3333, {
- chimconf.sendMsg("/engines/server", false);
- chimconf.sendMsg("/engines/mode", "osc.udp");
- chimconf.sendMsg("/engines/enabled", true);
- });
+ chimconf.sendMsg("/sensors/group/reset");
+ chimconf.sendMsg("/sensors/group/attributes/0",
+ 0.0, 1.0, false, true, false);
+ chimconf.sendMsg("/sensors/group/attributes/1",
+ 0.0, 1.0, true, false, false);
- chimconf.sendMsg("/sensors/rate", rate);
- chimconf.sendMsg("/sensors/group/reset"); // reset groups
- chimconf.sendMsg("/sensors/group/attributes/0", 0.0, 1.0, false, true, false); // add group
- chimconf.sendMsg("/sensors/group/attributes/1", 0.0, 1.0, true, false, false); // add group
chimconf.sendMsg("/sensors/number", {|msg|
var n = msg[0];
chimout = ChimaeraOutMidi(s, n, [\base, \lead]);
chimout.control = 0x07;
chimout.doublePrecision = true;
- chimin = ChimaeraInTuio2(s, chimconf, rx, chimout);
+ chimin = ChimaeraInTuio2(s, chimconf, chimout);
});
}.value;
diff --git a/ignore/tuio2_to_scsynth2F.sc b/ignore/tuio2_to_scsynth2F.sc
index 5c0beca..92f4585 100755
--- a/ignore/tuio2_to_scsynth2F.sc
+++ b/ignore/tuio2_to_scsynth2F.sc
@@ -1,26 +1,20 @@
#!/usr/bin/env sclang
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
s.options.blockSize = 0x10;
@@ -29,35 +23,23 @@ s.latency = nil;
s.boot;
s.doWhenBooted({
- var hostname, rx, tx, chimconf, rate, chimin, chimout;
-
- hostname = "hostname".unixCmdGetStdOutLines[0]++".local";
-
- thisProcess.openUDPPort(3333); // open port 3333 to listen for Tuio messages
+ var chimconf, chimin, chimout;
- rx = NetAddr ("chimaera.local", 3333);
- tx = NetAddr ("chimaera.local", 4444);
-
- chimconf = ChimaeraConf(s, tx, tx);
-
- rate = 3000;
- chimconf.sendMsg("/engines/reset");
- chimconf.sendMsg("/engines/offset", 0.0025);
- chimconf.sendMsg("/engines/address", hostname++":"++3333, {
- chimconf.sendMsg("/engines/server", false);
- chimconf.sendMsg("/engines/mode", "osc.udp");
- chimconf.sendMsg("/engines/enabled", true);
- });
+ chimconf = ChimaeraConf(s,
+ addr:"chimaera.local");
- chimconf.sendMsg("/sensors/rate", rate);
- chimconf.sendMsg("/sensors/group/reset"); // reset groups
- chimconf.sendMsg("/sensors/group/attributes/0", 0.0, 1.0, false, true, false); // add group
- chimconf.sendMsg("/sensors/group/attributes/1", 0.0, 1.0, true, false, false); // add group
+ chimconf.sendMsg("/sensors/group/reset");
+ chimconf.sendMsg("/sensors/group/attributes/0",
+ 0.0, 1.0, false, true, false);
+ chimconf.sendMsg("/sensors/group/attributes/1",
+ 0.0, 1.0, true, false, false);
chimconf.sendMsg("/sensors/number", {|msg|
var n = msg[0];
chimout = ChimaeraOutSCSynth2F(s, n, [\base, \lead]);
- chimin = ChimaeraInTuio2(s, chimconf, rx, chimout);
- Routine.run({"./instruments2F.sc".load.value(n, \base, \lead);}, clock:AppClock);
+ chimin = ChimaeraInTuio2(s, chimconf, chimout);
+ Routine.run({
+ "./instruments2F.sc".load.value(n, \base, \lead);
+ }, clock:AppClock);
});
})
diff --git a/ignore/tuio2_to_scsynth4F.sc b/ignore/tuio2_to_scsynth4F.sc
index 636dbd4..23ea06e 100755
--- a/ignore/tuio2_to_scsynth4F.sc
+++ b/ignore/tuio2_to_scsynth4F.sc
@@ -1,26 +1,20 @@
#!/usr/bin/env sclang
/*
- * Copyright (c) 2014 Hanspeter Portner (dev@open-music-kontrollers.ch)
+ * Copyright (c) 2015 Hanspeter Portner (dev@open-music-kontrollers.ch)
*
- * This software is provided 'as-is', without any express or implied
- * warranty. In no event will the authors be held liable for any damages
- * arising from the use of this software.
+ * This is free software: you can redistribute it and/or modify
+ * it under the terms of the Artistic License 2.0 as published by
+ * The Perl Foundation.
*
- * Permission is granted to anyone to use this software for any purpose,
- * including commercial applications, and to alter it and redistribute it
- * freely, subject to the following restrictions:
+ * This source is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * Artistic License 2.0 for more details.
*
- * 1. The origin of this software must not be misrepresented; you must not
- * claim that you wrote the original software. If you use this software
- * in a product, an acknowledgment in the product documentation would be
- * appreciated but is not required.
- *
- * 2. Altered source versions must be plainly marked as such, and must not be
- * misrepresented as being the original software.
- *
- * 3. This notice may not be removed or altered from any source
- * distribution.
+ * You should have received a copy of the Artistic License 2.0
+ * along the source as a COPYING file. If not, obtain it from
+ * http://www.perlfoundation.org/artistic_license_2_0.
*/
s.options.blockSize = 0x10;
@@ -29,35 +23,23 @@ s.latency = nil;
s.boot;
s.doWhenBooted({
- var hostname, rx, tx, chimconf, rate, chimin, chimout;
-
- hostname = "hostname".unixCmdGetStdOutLines[0]++".local";
-
- thisProcess.openUDPPort(3333); // open port 3333 to listen for Tuio messages
+ var chimconf, chimin, chimout;
- rx = NetAddr ("chimaera.local", 3333);
- tx = NetAddr ("chimaera.local", 4444);
-
- chimconf = ChimaeraConf(s, tx, tx);
-
- rate = 3000;
- chimconf.sendMsg("/engines/reset");
- chimconf.sendMsg("/engines/offset", 0.0025);
- chimconf.sendMsg("/engines/address", hostname++":"++3333, {
- chimconf.sendMsg("/engines/server", false);
- chimconf.sendMsg("/engines/mode", "osc.udp");
- chimconf.sendMsg("/engines/enabled", true);
- });
+ chimconf = ChimaeraConf(s,
+ addr:"chimaera.local");
- chimconf.sendMsg("/sensors/rate", rate);
- chimconf.sendMsg("/sensors/group/reset"); // reset groups
- chimconf.sendMsg("/sensors/group/attributes/0", 0.0, 1.0, false, true, false); // add group
- chimconf.sendMsg("/sensors/group/attributes/1", 0.0, 1.0, true, false, false); // add group
+ chimconf.sendMsg("/sensors/group/reset");
+ chimconf.sendMsg("/sensors/group/attributes/0",
+ 0.0, 1.0, false, true, false);
+ chimconf.sendMsg("/sensors/group/attributes/1",
+ 0.0, 1.0, true, false, false);
chimconf.sendMsg("/sensors/number", {|msg|
var n = msg[0];
- chimout = ChimaeraOutSCSynth4F(s, n, [\base]);
- chimin = ChimaeraInTuio2(s, chimconf, rx, chimout);
- Routine.run({"./instruments4F.sc".load.value(n);}, clock:AppClock);
+ chimout = ChimaeraOutSCSynth4F(s, n, [\base, \lead]);
+ chimin = ChimaeraInTuio2(s, chimconf, chimout);
+ Routine.run({
+ "./instruments4F.sc".load.value(n, \base, \lead);
+ }, clock:AppClock);
});
})