syBR::AudioCore::MusicSystem Class Reference

Base music system class. More...

#include <MusicSystem.hpp>

List of all members.

Public Member Functions

 MusicSystem ()
 Constructor.
virtual ~MusicSystem ()
 Destructor.
virtual bool play (const std::string &file)=0
 Play a music.
virtual bool update ()=0
 Update the music.
virtual bool pause ()=0
 Pause the music.
virtual void stop ()=0
 Stop the music.


Detailed Description

Base music system class.

This is the music object which allows to manage the music. This is a pure abstract class which needs a concrete implementation (using OpenAL, DirectSound or any other sound library).


Constructor & Destructor Documentation

syBR::AudioCore::MusicSystem::MusicSystem (  ) 

Constructor.

syBR::AudioCore::MusicSystem::~MusicSystem (  )  [virtual]

Destructor.


Member Function Documentation

virtual bool syBR::AudioCore::MusicSystem::play ( const std::string &  file  )  [pure virtual]

Play a music.

Parameters:
file Filename
Returns:
One of these:
  • true if music is now playing
  • false otherwise

virtual bool syBR::AudioCore::MusicSystem::update (  )  [pure virtual]

Update the music.

This must be often called in order to stream the music.

Returns:
One of these:
  • true if the music is still playing
  • false if the end of the music file has been reached

virtual bool syBR::AudioCore::MusicSystem::pause (  )  [pure virtual]

Pause the music.

It works as a toggle :

Returns:
One of these:
  • true if the music is now paused
  • false otherwise

virtual void syBR::AudioCore::MusicSystem::stop (  )  [pure virtual]

Stop the music.


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

Copyright © 2008 by Sebastien Frippiat
Creative Commons License
This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 License.
Last modified Tue Dec 30 17:57:33 2008