41 class SoundBuffer_Session_Impl;
170 std::shared_ptr<SoundBuffer_Session_Impl> impl;
void add_filter(SoundFilter &filter)
Adds the sound filter to the session. See SoundFilter for details.
SoundBuffer_Session provides control over a playing soundeffect.
Definition: soundbuffer_session.h:50
float get_position_relative() const
Returns the sample position relative to the full length.
bool is_playing()
Returns true if the session is playing.
SoundOutput interface in ClanLib.
Definition: soundoutput.h:47
float get_pan() const
Returns the current pan (in a measure from -1 -> 1).
void set_volume(float new_volume)
Sets the volume of the session in a relative measure (0->1)
bool is_null() const
Returns true if this object is invalid.
Definition: soundbuffer_session.h:58
Sample interface in ClanLib.
Definition: soundbuffer.h:55
bool get_looping() const
Returns whether this session loops.
bool set_position_relative(float new_pos)
Sets the relative position of the session.
Sound Filter Class.
Definition: soundfilter.h:43
void throw_if_null() const
Throw an exception if this object is invalid.
void stop()
Stops playback of the session.
void set_pan(float new_pan)
Sets the panning of the session played in measures from -1 -> 1.
int get_position() const
Returns the current sample position of the playback.
float get_volume() const
Returns the linear relative volume of the soundeffect.
bool set_end_position(int pos)
Sets the end position within the current stream.
void remove_filter(SoundFilter &filter)
Remove the sound filter from the session. See SoundFilter for details.
bool set_position(int new_pos)
Sets the session position to 'new_pos'.
friend class SoundOutput_Impl
Definition: soundbuffer_session.h:173
int get_frequency() const
Returns the frequency of the session.
virtual ~SoundBuffer_Session()
int get_length() const
Returns the total length (in samples) of the sound buffer played.
SoundBuffer_Session()
Creates a null instance.
void play()
Starts playback of the session.
void set_frequency(int new_freq)
Sets the frequency of the session.
void set_looping(bool loop)
Determines whether this session should loop.