Another script to skip during unit-tests
authorRobin Gareus <robin@gareus.org>
Fri, 6 Sep 2019 16:17:23 +0000 (18:17 +0200)
committerRobin Gareus <robin@gareus.org>
Fri, 6 Sep 2019 16:17:23 +0000 (18:17 +0200)
scripts/__plugin_modulation.lua [new file with mode: 0644]
scripts/_plugin_modulation.lua [deleted file]

diff --git a/scripts/__plugin_modulation.lua b/scripts/__plugin_modulation.lua
new file mode 100644 (file)
index 0000000..bb94b64
--- /dev/null
@@ -0,0 +1,46 @@
+--- session-script example to modulate plugin parameter(s) globally
+--
+-- Ardour > Menu > Session > Scripting > Add Lua Script
+--   "Add" , select "Modulate Plugin Parameter",  click "Add" + OK.
+--
+-----------------------------------------------------------------------------
+-- This script currently assumes you have a track named "Audio"
+-- which as a plugin at the top, where the first parameter has a range > 200
+-- e.g. "No Delay Line"
+--
+-- edit below..
+
+
+-- plugin descriptor
+ardour {
+       ["type"]    = "session",
+       name        = "Modulate Plugin Parameter",
+       license     = "MIT",
+       author      = "Ardour Lua Task Force",
+       description = [[An example session to modulate a plugin parameter.]]
+}
+
+function factory () -- generate a new script instance
+
+       local count = 0 -- script-instance "global" variable
+
+       -- the "run" function called at the beginning of every process cycle
+       return function (n_samples)
+               count = (count + 1) % 200; -- count process cycles
+               local tri = math.abs (100 - count) -- triangle wave 0..100
+
+               -- get the track named "Audio"
+               -- see also http://manual.ardour.org/lua-scripting/class_reference/#ARDOUR:Session
+               -- and http://manual.ardour.org/lua-scripting/class_reference/#ARDOUR:Route
+               local route = Session:route_by_name ("Audio")
+               assert (not route:isnil ()) -- make sure it exists
+
+               -- the 1st plugin (from top) on that track, ardour starts counting at zero
+               -- see also http://manual.ardour.org/lua-scripting/class_reference/#ARDOUR:Processor
+               local plugin = route:nth_plugin (0)
+               assert (not plugin:isnil ()) -- make sure it exists
+
+               -- modulate the plugin's first parameter (0)  from  200 .. 300
+               ARDOUR.LuaAPI.set_processor_param (plugin, 0, 200.0 + tri)
+       end
+end
diff --git a/scripts/_plugin_modulation.lua b/scripts/_plugin_modulation.lua
deleted file mode 100644 (file)
index 81b0bcd..0000000
+++ /dev/null
@@ -1,46 +0,0 @@
---- session-script example to modulate plugin parameter(s) globally
---
--- Ardour > Menu > Session > Scripting > Add Lua Script
---   "Add" , select "Modulate Plugin Parameter",  click "Add" + OK.
---
------------------------------------------------------------------------------
--- This script currently assumes you have a track named "Audio"
--- which as a plugin at the top, where the first parameter has a range > 200
--- e.g. "No Delay Line"
--- 
--- edit below..
-
-
--- plugin descriptor
-ardour {
-       ["type"]    = "session",
-       name        = "Modulate Plugin Parameter",
-       license     = "MIT",
-       author      = "Ardour Lua Task Force",
-       description = [[An example session to modulate a plugin parameter.]]
-}
-
-function factory () -- generate a new script instance
-
-       local count = 0 -- script-instance "global" variable
-
-       -- the "run" function called at the beginning of every process cycle
-       return function (n_samples)
-               count = (count + 1) % 200; -- count process cycles
-               local tri = math.abs (100 - count) -- triangle wave 0..100
-
-               -- get the track named "Audio"
-               -- see also http://manual.ardour.org/lua-scripting/class_reference/#ARDOUR:Session
-               -- and http://manual.ardour.org/lua-scripting/class_reference/#ARDOUR:Route
-               local route = Session:route_by_name ("Audio")
-               assert (not route:isnil ()) -- make sure it exists
-
-               -- the 1st plugin (from top) on that track, ardour starts counting at zero
-               -- see also http://manual.ardour.org/lua-scripting/class_reference/#ARDOUR:Processor
-               local plugin = route:nth_plugin (0)
-               assert (not plugin:isnil ()) -- make sure it exists
-
-               -- modulate the plugin's first parameter (0)  from  200 .. 300
-               ARDOUR.LuaAPI.set_processor_param (plugin, 0, 200.0 + tri)
-       end
-end