Gosu::SampleInstance Class Reference

An instance of a Sample playing. More...

List of all members.

Public Member Functions

 SampleInstance (int handle, int extra)
bool playing () const
void stop ()
void changeVolume (double volume)
void changePan (double pan)
void changeSpeed (double speed)


Detailed Description

An instance of a Sample playing.

Can be used to stop sounds dynamically, or to check if they are finished. It is recommended that you throw away sample instances if possible, as they could accidentally refer to sounds played very long ago.


Constructor & Destructor Documentation

Gosu::SampleInstance::SampleInstance ( int  handle,
int  extra 
)

Called by Sample, do not use.


Member Function Documentation

void Gosu::SampleInstance::changeVolume ( double  volume  ) 

Parameters:
volume Can be anything from 0.0 (silence) to 1.0 (full volume).

void Gosu::SampleInstance::changePan ( double  pan  ) 

Parameters:
pan Can be anything from -1.0 (left) to 1.0 (right).

void Gosu::SampleInstance::changeSpeed ( double  speed  ) 

Parameters:
speed Playback speed is only limited by FMOD's capatibilities and can accept very high or low values. Use 1.0 for normal playback speed.


The documentation for this class was generated from the following file:

Generated on Fri Sep 12 21:50:23 2008 for Gosu by  doxygen 1.5.5