SDLPP::SoundClip Class Reference

#include <sdlpp_sound.h>

Inheritance diagram for SDLPP::SoundClip:

List of all members.

Public Member Functions

 SoundClip (const xstring &filename="", ResourceFile *rf=0)
 SoundClip (std::istream *is)
 SoundClip (const SoundClip &rhs)
SoundClipoperator= (const SoundClip &rhs)
void play (bool loop=false)

Protected Member Functions

void destroy ()


class SoundManager

Detailed Description

SoundClip is a finite (usually short) audio clip. It is loaded from WAV files and can be played to provide sound effects. The clip can be played multiple times, even concurrently, without duplicating its data. SoundClips in their nature allocate memory. In order to make their usage simple and still not waste resources by duplicating clips in memory, SoundClip objects include built in reference counting, so they can be passed by value on the stack without too much overhead.

Constructor & Destructor Documentation

SDLPP::SoundClip::SoundClip ( const xstring filename = "",
ResourceFile rf = 0 

Construct a sound clip and optionally load it from a WAV from file.

SDLPP::SoundClip::SoundClip ( std::istream *  is  ) 

Construct a sound clip by loading a WAV from an input stream.

Member Function Documentation

void SDLPP::SoundClip::play ( bool  loop = false  ) 

Start playback of this sound clip.

The documentation for this class was generated from the following files:
Generated on Wed May 26 17:41:01 2010 for SDLPP by  doxygen 1.6.3