View Issue Details
|ID||Category||Date Submitted||Last Update|
|0008784||bugs||2021-08-02 14:09||2021-08-05 06:21|
|Reporter||Werner Back||Assigned To|
|Fixed in Version|
|Summary||0008784: LUA: Store Mixer Settings has pan wrong|
|Description||I used the "Store Mixer Settings" Lua script to save a "scene", but when I restore from that file the pans are set wrong. I checked the saved values and it looks as if the way the numbers are stored is wrong. It looks like the following:|
but should look like
(this example is for "center position").
If I correct this manually in the file the pans look alright.
|Steps To Reproduce||Store + recall mixer settings with LUA script.|
|Tags||No tags attached.|
Oh, just saw that it's a locale problem. LUA replaces the "." with "," in german environments.
Something like that should work:
if pan ~= false then
local strPan = tostring(pan)
pan = strPan:gsub(",", ".")
Ah, I played a little with LUA (without understanding everything ;)) and it seems that this works:
Replace the following line:
if pan:isnil() then pan = false else pan = pan:get_value() end --sometimes a route doesn't have pan, like the master.
if pan:isnil() then pan = false else pan = ARDOUR.LuaAPI.ascii_dtostr(pan:get_value()) end --sometimes a route doesn't have pan, like the master.
Probably there are some more parameters where this problem occurs? I couldn't find out what "send_string" does? Guess that's Mixbus only, right? Since the LUA script's author is "Mixbus Team", is it possible, that this bug doesn't appear in Mixbus?
This works for me now.
a_db2b41821.lua (10,885 bytes)