Struct web_audio_api::node::AudioBufferSourceNode[][src]

pub struct AudioBufferSourceNode { /* fields omitted */ }
Expand description

An audio source from an in-memory audio asset in an AudioBuffer

Note: do not forget to start() the node.

Implementations

impl AudioBufferSourceNode[src]

pub fn new<C: AsBaseAudioContext>(
    context: &C,
    options: AudioBufferSourceNodeOptions
) -> Self
[src]

Trait Implementations

impl AudioControllableSourceNode for AudioBufferSourceNode[src]

fn controller(&self) -> &Controller[src]

fn loop_(&self) -> bool[src]

fn set_loop(&self, loop_: bool)[src]

fn loop_start(&self) -> f64[src]

fn set_loop_start(&self, loop_start: f64)[src]

fn loop_end(&self) -> f64[src]

fn set_loop_end(&self, loop_end: f64)[src]

fn seek(&self, timestamp: f64)[src]

impl AudioNode for AudioBufferSourceNode[src]

fn registration(&self) -> &AudioContextRegistration[src]

fn channel_config_raw(&self) -> &ChannelConfig[src]

fn number_of_inputs(&self) -> u32[src]

The number of inputs feeding into the AudioNode. For source nodes, this will be 0.

fn number_of_outputs(&self) -> u32[src]

The number of outputs coming out of the AudioNode.

fn id(&self) -> &AudioNodeId[src]

fn channel_config_cloned(&self) -> ChannelConfig[src]

fn context(&self) -> &BaseAudioContext[src]

The BaseAudioContext which owns this AudioNode.

fn connect<'a>(&self, dest: &'a dyn AudioNode) -> &'a dyn AudioNode[src]

Connect the output of this AudioNode to the input of another node.

fn connect_at<'a>(
    &self,
    dest: &'a dyn AudioNode,
    output: u32,
    input: u32
) -> Result<&'a dyn AudioNode, IndexSizeError>
[src]

Connect a specific output of this AudioNode to a specific input of another node.

fn disconnect<'a>(&self, dest: &'a dyn AudioNode) -> &'a dyn AudioNode[src]

Disconnects all outputs of the AudioNode that go to a specific destination AudioNode.

fn disconnect_all(&self)[src]

Disconnects all outgoing connections from the AudioNode.

fn channel_count_mode(&self) -> ChannelCountMode[src]

Represents an enumerated value describing the way channels must be matched between the node’s inputs and outputs. Read more

fn set_channel_count_mode(&self, v: ChannelCountMode)[src]

fn channel_interpretation(&self) -> ChannelInterpretation[src]

Represents an enumerated value describing the meaning of the channels. This interpretation will define how audio up-mixing and down-mixing will happen. Read more

fn set_channel_interpretation(&self, v: ChannelInterpretation)[src]

fn channel_count(&self) -> usize[src]

Represents an integer used to determine how many channels are used when up-mixing and down-mixing connections to any inputs to the node. Read more

fn set_channel_count(&self, v: usize)[src]

impl AudioScheduledSourceNode for AudioBufferSourceNode[src]

fn scheduler(&self) -> &Scheduler[src]

fn start_at(&self, start: f64)[src]

Schedule playback start at this timestamp

fn stop_at(&self, stop: f64)[src]

Stop playback at this timestamp

fn start(&self)[src]

Play immediately

fn stop(&self)[src]

Stop immediately

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

pub fn type_id(&self) -> TypeId[src]

Gets the TypeId of self. Read more

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

pub fn borrow(&self) -> &T[src]

Immutably borrows from an owned value. Read more

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

pub fn borrow_mut(&mut self) -> &mut T[src]

Mutably borrows from an owned value. Read more

impl<T> From<T> for T[src]

pub fn from(t: T) -> T[src]

Performs the conversion.

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

pub fn into(self) -> U[src]

Performs the conversion.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]

Performs the conversion.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>[src]

Performs the conversion.