Guide
Studio overview
Mora Studio is a native Common Lisp livecoding environment that shares one Lisp image with the running language.
Mora Studio is the native editor and performance environment for Mora. It brings code, feedback, and the running system into one place: a Common Lisp listener, structural source editing, source-linked pattern feedback, interactive controls, and an OpenGL canvas.
Mora Studio is a native Common Lisp livecoding environment. The editor and the running language share the same Lisp image, so a pattern, transform, visual operator, or application object can be inspected and redefined while the session continues.
Structural editing and contextual documentation help keep short forms readable. Inline views reveal the pattern, inline controls let you perform a value or write it into the score, and the inspector exposes the objects that evaluation created. The inspector’s Samples tab browses your indexed samples and stem library by original filename, with tags, waveforms, explicit native preview, and context-correct stem insertion. PHALAR recommendations can be requested from the code itself, including in zen. The performance canvas supports procedural shaders and ordered post-processing.
Studio is an interface to Mora, not a requirement for the language. The pattern system and runtime can be used from SBCL without loading OpenGL or opening a GL window. Studio itself renders with OpenGL 4.1 core.
From your Mora checkout, start Studio with the normal launcher:
make studioThe launcher brings the language, audio backend, native canvas, sample tools, and remote-development interfaces together and opens the native editor. Install the native libraries and the SuperDirt receiver first; Installation and setup covers both.
Keys are shown with macOS modifiers. Evaluate a form with Cmd+Return or its Control equivalent. F10 toggles desktop fullscreen; F11 toggles zen/performance presentation. F6 switches the inspector between Inspector and Samples, and Cmd+Option+P shows Samples; both leave zen so that the pane is visible. In the editor, Shift+Return at a typed stem or part selector requests stem recommendations against the playing mix and lists them under the form, which keeps the workflow in zen. The full table is in Keybindings and presentation.
With Studio and SuperDirt configured, this form installs a repeating sound pattern:
(d1! (s "bd ~ sn [hh hh]"))Edit the form and evaluate it again to replace that channel’s pattern; editing the text alone does not generally install the change. To stop the channel, assign silence to it:
(d1! (silence))(d1!) with no pattern is not a stop command. To silence the whole session, use hush.
The next forms set the tempo, install a pattern, replace it with a modified one, and stop it. Evaluate them one at a time:
(bpm 140)
(d1! (s "bd hh sn hh"))
(d1! (>> (s "bd [hh hh] sn hh")
(gain 0.9)))
(d1! (silence))Re-evaluating a form replaces the addressed material according to its assignment policy. Interactive controls have their own explicit choice between performing a value and writing code; see Inline controls. For channels and tempo in general, see Channels, tempo, and transport.
The editor supports:
- Lisp-aware indentation and matching parentheses
- syntax highlighting
- structural navigation and paredit operations
- selection and clipboard use
- multiple cursors
- undo and redo
- files
- a REPL
Search, completion, and signature help are described in Discovering forms.
Evaluation runs on a worker thread rather than inside the frame renderer, and session changes are marshaled onto the session thread.
Studio ties feedback to the source that produced it. Source-linked feedback includes evaluation flashes, playing-token highlights, channel annotations, and pattern views.
Each link runs from the installed pattern to its source occurrence, not from a search for matching text, so that editing unrelated source does not extinguish an otherwise valid playing annotation.
A token highlight or event visualization follows the installed pattern, not the measured sound. Inline views explains the difference between score views and measured-signal views.
A custom language extension supports precise source attribution by taking part in Mora’s provenance protocol. Editor assistance in general depends on good source provenance and documentation, including from extensions. See Extending Mora.
Studio is also a Lisp listener. Documentation, macro expansion, object inspection, references, disassembly, thread inspection, and definition navigation work against the running image. This is useful for learning an unfamiliar operator and for extending Mora itself. Ordinary Lisp variables and functions can hold reusable musical and visual material.
For what the inspector shows after evaluation, see What remains after evaluation and Common Lisp and CLOS.
Useful listener commands include:
,help
,describe notes
,sig piano-roll
,apropos pattern
,channels
,settings
,themeThese are Studio comma commands, not Lisp forms for a .mora score file.
Errors appear as a compact summary banner, with a history in the console. The banner is a transient performance display. The debugger and restart workflow is separate: you enter it explicitly, and it is not the intended on-stage error workflow. Hiding a pane does not dismiss a condition.
Studio needs native GLFW, libffi, and font libraries, and a graphics driver supporting OpenGL 4.1 core / GLSL 410. SuperDirt, audio capture, MIDI devices, and optional model services each have their own setup; Runtime requirements links to each.
Source references
Repository-relative paths in the Mora source where these mechanisms are implemented.
-
scripts/studio.lisp -
mora.asd -
src/studio/ -
src/samples-studio/