#include <Music.hpp>
Inheritance diagram for sf::Music:
Public Member Functions | |
Music (std::size_t BufferSize=44100) | |
Construct the music with a buffer size. | |
~Music () | |
Destructor. | |
bool | Open (const std::string &Filename) |
Open a music file (doesn't play it -- call Play() for that). | |
void | SetLoop (bool Loop) |
Set the music loop state. | |
bool | GetLoop () const |
Tell whether or not the music is looping. | |
float | GetDuration () const |
Get the sound duration. | |
void | Play () |
Start playing the audio stream. | |
void | Stop () |
Stop playing the audio stream. | |
unsigned int | GetChannelsCount () const |
Return the number of channels (1 = mono, 2 = stereo, . | |
unsigned int | GetSampleRate () const |
Get the sound frequency (sample rate). | |
Status | GetStatus () const |
Get the status of the sound (stopped, paused, playing). | |
Protected Member Functions | |
void | Initialize (unsigned int ChannelsCount, unsigned int SampleRate) |
Set the audio stream parameters, you must call it before Play(). |
Definition at line 47 of file Music.hpp.
sf::Music::Music | ( | std::size_t | BufferSize = 44100 |
) |
bool sf::Music::Open | ( | const std::string & | Filename | ) |
void sf::Music::SetLoop | ( | bool | Loop | ) |
bool sf::Music::GetLoop | ( | ) | const |
float sf::Music::GetDuration | ( | ) | const |
void sf::SoundStream::Play | ( | ) | [inherited] |
Start playing the audio stream.
Reimplemented from sf::Sound.
Definition at line 84 of file SoundStream.cpp.
void sf::SoundStream::Stop | ( | ) | [inherited] |
Stop playing the audio stream.
Reimplemented from sf::Sound.
Definition at line 113 of file SoundStream.cpp.
unsigned int sf::SoundStream::GetChannelsCount | ( | ) | const [inherited] |
Return the number of channels (1 = mono, 2 = stereo, .
..)
Definition at line 124 of file SoundStream.cpp.
unsigned int sf::SoundStream::GetSampleRate | ( | ) | const [inherited] |
Get the sound frequency (sample rate).
Definition at line 133 of file SoundStream.cpp.
Sound::Status sf::SoundStream::GetStatus | ( | ) | const [inherited] |
Get the status of the sound (stopped, paused, playing).
Reimplemented from sf::Sound.
Definition at line 142 of file SoundStream.cpp.
void sf::SoundStream::Initialize | ( | unsigned int | ChannelsCount, | |
unsigned int | SampleRate | |||
) | [protected, inherited] |
Set the audio stream parameters, you must call it before Play().
ChannelsCount | : Number of channels | |
SampleRate | : Sample rate |
Definition at line 63 of file SoundStream.cpp.