Struct openal::Source
[−]
[src]
pub struct Source<'a> { /* fields omitted */ }
Represents a static source.
Static sources will have buffers queued that will never change, they're useful for sound effects and similar.
Methods
impl<'a> Source<'a>
[src]
fn stream(self) -> Stream<'a>
Returns a streaming source.
fn state(&self) -> State
Gets the state.
fn play(&mut self)
Plays the source.
fn pause(&mut self)
Pauses the source.
fn stop(&mut self)
Stops the source.
fn rewind(&mut self)
Rewinds the source.
fn cone_inner_angle(&self) -> f32
Gets the cone inner angle.
fn set_cone_inner_angle(&mut self, value: f32)
Sets the cone inner angle.
fn cone_outer_angle(&self) -> f32
Gets the cone outer angle.
fn set_cone_outer_angle(&mut self, value: f32)
Sets the cone outer angle.
fn pitch(&self) -> f32
Gets the pitch.
fn set_pitch(&mut self, value: f32)
Sets the pitch.
fn position(&self) -> Position
Gets the position.
fn set_position(&self, value: &Position)
Sets the position.
fn direction(&self) -> Direction
Gets the direction.
fn set_direction(&self, value: &Direction)
Sets the direction.
fn velocity(&self) -> Velocity
Gets the velocity.
fn set_velocity(&self, value: &Velocity)
Sets the velocity.
fn is_relative(&self) -> bool
Checks if the source is relative.
fn enable_relative(&mut self)
Makes the source relative.
fn disable_relative(&mut self)
Makes the source absolute.
fn is_looping(&self) -> bool
Checks if the source is looping.
fn enable_looping(&mut self)
Makes the source looping.
fn disable_looping(&mut self)
Makes the source one-shot.
fn gain(&self) -> f32
Gets the gain.
fn set_gain(&mut self, value: f32)
Sets the gain.
fn min_gain(&self) -> f32
Gets the minimum gain.
fn set_min_gain(&mut self, value: f32)
Sets the minimum gain.
fn max_gain(&self) -> f32
Gets the maximum gain.
fn set_max_gain(&mut self, value: f32)
Sets the minimum gain.
fn offset(&self, offset: Offset) -> Offset
Gets the offset in the specified representation.
fn set_offset(&mut self, value: Offset)
Sets the offset.
fn queued(&self) -> usize
Gets how many buffers are queued.
fn processed(&self) -> usize
Gets how many buffers have been processed.
fn push<'b: 'a>(&'b mut self, buffer: &'b Buffer<'b>) -> Result<(), Error>
Pushes a buffer into the source's queue.
Trait Implementations
impl<'a> PartialEq for Source<'a>
[src]
fn eq(&self, __arg_0: &Source<'a>) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &Source<'a>) -> bool
This method tests for !=
.