lua: changes to a few Lua scripts because of Readable->AudioRedable and AudioRegion as IS-A AudioReader API changes

This commit is contained in:
Paul Davis 2020-09-20 16:37:32 -06:00
parent b2a4fe1b50
commit 6481b555ea
3 changed files with 6 additions and 4 deletions

View File

@ -25,7 +25,8 @@ function factory () return function ()
-- to read the Region data, we use the Readable interface of the Region
-- http://manual.ardour.org/lua-scripting/class_reference/#ARDOUR:Readable
local rd = r:to_readable ()
local a = r.to_audioregion()
local rd = a:to_readable ()
local n_samples = rd:readable_length ()
local n_channels = rd:n_channels ()

View File

@ -63,7 +63,7 @@ function factory () return function ()
local rb = ARDOUR.LuaAPI.Rubberband (ar, false)
-- the rubberband-filter also implements the readable API.
-- https://manual.ardour.org/lua-scripting/class_reference/#ARDOUR:Readable
-- https://manual.ardour.org/lua-scripting/class_reference/#ARDOUR:AudioReadable
-- This allows to read from the master-source of the given audio-region.
-- Any prior time-stretch or pitch-shift are ignored when reading, however
-- processing retains the previous settings

View File

@ -22,8 +22,9 @@ function factory () return function ()
end
-- to read the Region data, we use the Readable interface of the Region
-- http://manual.ardour.org/lua-scripting/class_reference/#ARDOUR:Readable
local rd = r:to_readable ()
-- http://manual.ardour.org/lua-scripting/class_reference/#ARDOUR:AudioReadable
local a = r.to_audioregion
local rd = a:to_readable ()
local n_samples = rd:readable_length ()
local n_channels = rd:n_channels ()