[][src]Struct rodio::source::Spatial

pub struct Spatial<I> where
    I: Source,
    I::Item: Sample + Debug
{ /* fields omitted */ }

Combines channels in input into a single mono source, then plays that mono sound to each channel at the volume given for that channel.

Methods

impl<I> Spatial<I> where
    I: Source,
    I::Item: Sample + Debug
[src]

pub fn new(
    input: I,
    emitter_position: [f32; 3],
    left_ear: [f32; 3],
    right_ear: [f32; 3]
) -> Spatial<I> where
    I: Source,
    I::Item: Sample
[src]

pub fn set_positions(
    &mut self,
    emitter_pos: [f32; 3],
    left_ear: [f32; 3],
    right_ear: [f32; 3]
)
[src]

Sets the position of the emitter and ears in the 3D world.

Trait Implementations

impl<I: Clone> Clone for Spatial<I> where
    I: Source,
    I::Item: Sample + Debug
[src]

impl<I: Debug> Debug for Spatial<I> where
    I: Source,
    I::Item: Sample + Debug
[src]

impl<I> ExactSizeIterator for Spatial<I> where
    I: Source + ExactSizeIterator,
    I::Item: Sample + Debug
[src]

impl<I> Iterator for Spatial<I> where
    I: Source,
    I::Item: Sample + Debug
[src]

type Item = I::Item

The type of the elements being iterated over.

impl<I> Source for Spatial<I> where
    I: Source,
    I::Item: Sample + Debug
[src]

Auto Trait Implementations

impl<I> RefUnwindSafe for Spatial<I> where
    I: RefUnwindSafe,
    <I as Iterator>::Item: RefUnwindSafe

impl<I> Send for Spatial<I> where
    I: Send,
    <I as Iterator>::Item: Send

impl<I> Sync for Spatial<I> where
    I: Sync,
    <I as Iterator>::Item: Sync

impl<I> Unpin for Spatial<I> where
    I: Unpin,
    <I as Iterator>::Item: Unpin

impl<I> UnwindSafe for Spatial<I> where
    I: UnwindSafe,
    <I as Iterator>::Item: UnwindSafe

Blanket Implementations

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

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

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

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

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

impl<I> IntoIterator for I where
    I: Iterator
[src]

type Item = <I as Iterator>::Item

The type of the elements being iterated over.

type IntoIter = I

Which kind of iterator are we turning this into?

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

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.

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.