UGDK  0.5.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
ugdk::audio::Music Class Reference

#include <ugdk/audio/music.h>

Public Member Functions

void Play ()
 Plays this music once. More...
 
void PlayForever ()
 Plays this music until told to stop. More...
 
void Play (int loops)
 Plays this music the given number of times. More...
 
void Stop ()
 Stops playing this music. More...
 
bool IsPlaying () const
 Return whether this music is playing or not. More...
 
void Pause ()
 Pauses the music, allowing it to be resumed from the same point. More...
 
void Unpause ()
 Unpauses the music if it's the last played music. More...
 
bool IsPaused () const
 Return whether this can be unpaused. More...
 
void SetVolume (double vol)
 Sets the volume. 0.0 is quiet, 1.0 is the full volume. More...
 
double Volume ()
 Returns this music's current volume, between 0.0 and 1.0. More...
 

Friends

class Manager
 

Detailed Description

Note: This class cannot be directly instantiated. Please use AudioManager's LoadMusic.

See also
AudioManager

Member Function Documentation

bool ugdk::audio::Music::IsPaused ( ) const

Return whether this can be unpaused.

bool ugdk::audio::Music::IsPlaying ( ) const

Return whether this music is playing or not.

void ugdk::audio::Music::Pause ( )

Pauses the music, allowing it to be resumed from the same point.

void ugdk::audio::Music::Play ( )

Plays this music once.

void ugdk::audio::Music::Play ( int  loops)

Plays this music the given number of times.

void ugdk::audio::Music::PlayForever ( )

Plays this music until told to stop.

void ugdk::audio::Music::SetVolume ( double  vol)

Sets the volume. 0.0 is quiet, 1.0 is the full volume.

Parameters
vol0.0 (quiet) <= vol <= 1.0 (loud)
void ugdk::audio::Music::Stop ( )

Stops playing this music.

void ugdk::audio::Music::Unpause ( )

Unpauses the music if it's the last played music.

double ugdk::audio::Music::Volume ( )

Returns this music's current volume, between 0.0 and 1.0.

Friends And Related Function Documentation

friend class Manager
friend

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