An audio player.
More...
◆ Player()
AudioManager::Player::Player |
( |
boost::recursive_mutex * |
mutex | ) |
|
Constructor.
- Parameters
-
[in] | mutex | Mutex to handle concurrent updates. |
◆ ~Player()
AudioManager::Player::~Player |
( |
| ) |
|
◆ FillBuffer()
ALsizei AudioManager::Player::FillBuffer |
( |
| ) |
|
|
private |
Fills the audio buffer.
- Returns
- Size of the data added to the buffer.
◆ GetPosition()
float AudioManager::Player::GetPosition |
( |
| ) |
|
Get the playing position of the current track.
- Returns
- Playing position.
- Todo:
- Is this in seconds?
◆ Pause()
void AudioManager::Player::Pause |
( |
| ) |
|
◆ Play()
void AudioManager::Player::Play |
( |
const Ogre::String & |
file | ) |
|
Plays an audio file.
- Parameters
-
[in] | file | Path to the file to play |
◆ Resume()
void AudioManager::Player::Resume |
( |
| ) |
|
Resumes the playback of a paused player.
If no track was paused, an error wilt be printed and nothing will be done.
◆ SetLoop()
void AudioManager::Player::SetLoop |
( |
const float |
loop | ) |
|
Sets the loop for the current track.
- Parameters
-
◆ Stop()
void AudioManager::Player::Stop |
( |
| ) |
|
◆ Update()
void AudioManager::Player::Update |
( |
| ) |
|
Updates the audio player.
- Todo:
- Understand and document.
◆ buffer_
char* AudioManager::Player::buffer_ |
|
private |
◆ file_
Ogre::String AudioManager::Player::file_ |
|
private |
Name of the file currently being played.
◆ loop_
float AudioManager::Player::loop_ |
|
private |
Loop point for the current track.
◆ source_
ALuint AudioManager::Player::source_ |
|
private |
◆ stream_finished_
bool AudioManager::Player::stream_finished_ |
|
private |
Indicates if the stream is finished.
◆ update_mutex_
boost::recursive_mutex* AudioManager::Player::update_mutex_ |
|
private |
Mutex to handle concurrent update on the player.
◆ vorbis_file_
OggVorbis_File AudioManager::Player::vorbis_file_ |
|
private |
◆ vorbis_info_
vorbis_info* AudioManager::Player::vorbis_info_ |
|
private |
◆ vorbis_section_
int AudioManager::Player::vorbis_section_ |
|
private |
The documentation for this class was generated from the following files: