Struct Buffered Playback Output
pub struct BufferedPlaybackOutput { /* private fields */ }Expand description
Own the automatic worker’s unique prepared callback transport through the actual output Processor path. Prepare validates target rate/channel/render bounds and allocates scratch; process renders/publishes atomics/copies only. Configure transport exclusively before transferring into PreparedOutput or open_output. No duplicate consumer, clock mapping or callback mailbox exists. Reset pauses retaining cursor/queue; reader seek needs reclaimed stopped playback plus its matching control worker. into_playback reclaims only this directly owned stopped processor; it does not reclaim an inaccessible native open_output closure. Native live seek/recovery remains separately integrated.
Implementations§
§impl BufferedPlaybackOutput
impl BufferedPlaybackOutput
pub fn new(playback: BufferedPlayback) -> Self
pub fn playback(&self) -> &BufferedPlayback
pub fn playback_mut(&mut self) -> &mut BufferedPlayback
pub fn monitor(&self) -> BufferedPlaybackOutputMonitor
pub fn statistics(&self) -> BufferedPlaybackOutputStatistics
pub fn into_playback(self) -> BufferedPlayback
Trait Implementations§
§impl Processor for BufferedPlaybackOutput
impl Processor for BufferedPlaybackOutput
fn prepare(&mut self, config: ProcessConfig) -> Result<(), PrepareError>
fn process(&mut self, block: &mut ProcessBlock<'_, '_, '_>) -> ProcessStatus
fn reset(&mut self)
fn deactivate(&mut self)
§fn start_audio(&mut self) -> Result<(), ProcessError>
fn start_audio(&mut self) -> Result<(), ProcessError>
Optional explicit audio-owner session start, after prepare and before
rendering. Default is a no-op. Consumers using these hooks call once on
the audio owner and stop there before transfer/deactivation. Failure must
leave this processor stopped; earlier successful nodes may be stopped.
Hooks follow prepared callback allocation/locking/I/O obligations. Existing
adapters do not implicitly opt in; explicit graph sessions supply them.
§fn stop_audio(&mut self)
fn stop_audio(&mut self)
End an explicitly started session on its audio owner, without deactivation
or storage destruction. Default no-op; preparation/history may be retained.
§fn try_reset(&mut self) -> Result<(), ProcessError>
fn try_reset(&mut self) -> Result<(), ProcessError>
Attempt history reset without allocating or changing configuration.
Existing processors delegate to their successful legacy reset by default.
A refusal may follow earlier reset work; consumers must remain faulted.
§fn latency_samples(&self) -> u32
fn latency_samples(&self) -> u32
Prepared algorithmic latency in samples. Changes are advertised by adapters
using their format’s restart/latency protocol outside the audio callback.
§fn tail(&self) -> Tail
fn tail(&self) -> Tail
Decay policy after input stops. Adapters must map this to the host protocol.