Add Icon to ADM/BWF script, and preseed it
This commit is contained in:
parent
4acd0e9f29
commit
5880e51e92
@ -1547,6 +1547,9 @@ LuaInstance::pre_seed_scripts ()
|
|||||||
int id = 0;
|
int id = 0;
|
||||||
pre_seed_script ("Mixer Screenshot", id);
|
pre_seed_script ("Mixer Screenshot", id);
|
||||||
pre_seed_script ("List Plugins", id);
|
pre_seed_script ("List Plugins", id);
|
||||||
|
#ifdef Mixbus
|
||||||
|
pre_seed_script ("Import ADM BWF File", id);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
bool
|
bool
|
||||||
|
@ -2,7 +2,7 @@ ardour {
|
|||||||
["type"] = "EditorAction",
|
["type"] = "EditorAction",
|
||||||
name = "Import ADM BWF File",
|
name = "Import ADM BWF File",
|
||||||
author = "Ardour Team",
|
author = "Ardour Team",
|
||||||
description = [[...]]
|
description = [[Load dynamic meta-data from an ADM file, import audio channels to the timeline and copy fixed settings for export.]]
|
||||||
}
|
}
|
||||||
|
|
||||||
function factory () return function ()
|
function factory () return function ()
|
||||||
@ -132,3 +132,14 @@ function factory () return function ()
|
|||||||
Session:surround_master():surround_return():set_bed_mix (true, rv['file'], imap:to_array ())
|
Session:surround_master():surround_return():set_bed_mix (true, rv['file'], imap:to_array ())
|
||||||
print ("OK")
|
print ("OK")
|
||||||
end end
|
end end
|
||||||
|
|
||||||
|
function icon (params) return function (ctx, width, height, fg)
|
||||||
|
local wh = math.min (width, height)
|
||||||
|
ctx:set_source_rgba (ARDOUR.LuaAPI.color_to_rgba (fg))
|
||||||
|
ctx:arc (0.5 * width - wh * 0.3, 0.5 * height, wh * .275, -0.5 * math.pi , 0.5 * math.pi)
|
||||||
|
ctx:close_path ()
|
||||||
|
ctx:fill ()
|
||||||
|
ctx:arc (0.5 * width + wh * 0.3, 0.5 * height, wh * .275, 0.5 * math.pi , 1.5 * math.pi)
|
||||||
|
ctx:close_path ()
|
||||||
|
ctx:fill ()
|
||||||
|
end end
|
||||||
|
Loading…
Reference in New Issue
Block a user