SUPERB
Flows

send reference

Generated from the source by scripts/reference.py. Do not edit this file. The short page, with the examples, is [send](send.md).

Reference

Every function of the send flow: what it takes, what it returns, what it refuses, and how it undoes. A Result<T> is Ok(T) or a SuperbError; the errors listed are the ones you can cause.

add

pub fn add( session: &mut Session, track: TrackId, bus: TrackId, level_db: f32, tap: SendTap, ) -> Result<SendId>

Adds a send from a track into a bus at level_db, tapped before or after the fader (SendTap::PreFader / SendTap::PostFader).

Takes

  • session: &mut Session — the open session, borrowed mutably
  • track: TrackId — the track's id, from track::add or session.memory.tracks()
  • bus: TrackId — the bus track that receives the copy
  • level_db: f32 — the send level in decibels
  • tap: SendTap — SendTap::PostFader (after the strip's fader and pan) or SendTap::PreFader (before)

Returns Result<SendId> — the new send's id

Errors an unknown track or bus; a target that is not a bus; the master as source or target; a bus sending to itself.

Undo one undo step; rebuilds the mixer (at once while a device plays, otherwise at the next start).

Made of Memory::allocate_send_id → TrackSend::with_id → AddSend through session::structural; rebuilds the mixer.

Example

let s = send::add(&mut session, vox, verb, -12.0, SendTap::PostFader)?;

remove

pub fn remove(session: &mut Session, send: SendId) -> Result<()>

Removes a send.

Takes

  • session: &mut Session — the open session, borrowed mutably
  • send: SendId — the send's id, from send::add or track.sends()

Returns Result<()> — nothing

Errors an unknown send.

Undo one undo step; rebuilds the mixer (at once while a device plays, otherwise at the next start).

Made of RemoveSend through session::structural; rebuilds the mixer.

Example

send::remove(&mut session, s)?;

level

pub fn level(session: &mut Session, send: SendId, db: f32) -> Result<()>

Sets a send's level in dB. Moves within Session::COALESCE_WINDOW of each other are one undo step.

Takes

  • session: &mut Session — the open session, borrowed mutably
  • send: SendId — the send's id, from send::add or track.sends()
  • db: f32 — a level in decibels; 0.0 is unity, negative is quieter

Returns Result<()> — nothing

Errors an unknown send.

Undo one undo step per drag: calls within Session::COALESCE_WINDOW (half a second) merge; the live send hears it at once.

Made of set_send_level_db through session::edit → SendParams::set_level_db on the live send.

Example

send::level(&mut session, s, -6.0)?;

enable

pub fn enable(session: &mut Session, send: SendId, on: bool) -> Result<()>

Switches a send on or off. State, like mute: saved, heard at the next block, not an undo step.

Takes

  • session: &mut Session — the open session, borrowed mutably
  • send: SendId — the send's id, from send::add or track.sends()
  • on: bool — true to switch on, false to switch off

Returns Result<()> — nothing

Errors an unknown send.

Undo none: state, not an edit (saved through the state file, see session::state_file); the live send hears it at once.

Made of SendState::enabled through session::set_state → SendParams::set_enabled on the live send.

Example

send::enable(&mut session, s, false)?;

On this page