Ardour Scripting 101

What?

  • Scripting allows to add functionality to Ardour’s core

  • Scripts can hook into different parts of Ardour

  • Some scripts are shipped by default

  • Scripting language is Lua

  • New Ardour releases include new features and scripts

Where?

In the file system

  • Users can add further scripts to their installation

  • Linux: $HOME/.config/ardour5/scripts

In the application

  • Menu → Window → Scripting

  • Menu → Edit → Scripted Actions (and Hooks)

  • Menu → Session → Scripting

  • Mixer-strip → context menu (right click) → New Lua Proc

How?

Minimal code example

ardour {
  ["type"]    = "EditorAction",
  name        = "Rewind",
}

function factory (unused_params)
  return function ()
    Session:goto_start()  -- rewind the transport
  end
end

Mastering Lua?

Conclusion

  • Scripting allows to add "missing" functionality

  • Available Lua API is already huge

  • Still, there are some missing parts and inconsistencies

Extra

(Ardour Lua) Plugin of the month