Skip to main content

Module stage

Module stage 

Source
Expand description

Stage stream metadata (record-along): what a stream is, and where on the sender’s loop each frame belongs. The stream crate carries both as opaque bytes.

Positions are in ticks of the loop (the app’s own unit), so senders and listeners with different sample rates agree; a listener turns them into its own frames with Grid.

Structs§

Grid
A loop in one side’s frames.
LoopMarker
Where a frame’s first sample belongs on the sender’s loop: the sender’s frame within its loop and its loop length, so a listener at any sample rate places it by ratio, exactly when the rates match.
StageStreamMeta
Once per stream, in StreamInfo::meta.

Enums§

StageKind
Dry (the sender’s own voices) or a mix (with other people’s audio in it).

Functions§

frame_meta
Frame metadata: the send time (8 bytes, microseconds since the Unix epoch), then an optional loop marker (4 + 8 + 8 bytes, little endian).
marker_of
The loop marker in a frame’s metadata.
take_stream
A dry take as a recorded stream: interleaved f32 samples whose first sample belongs at start_frame on the loop, stamped with meta (meta.start_tick is set, for people and other apps). 10 ms frames, each with its exact loop marker.