TDME2 1.9.121
|
Sound audio entity implementation. More...
#include <tdme/audio/Sound.h>
Public Member Functions | |
Sound (const string &id, const string &pathName, const string &fileName) | |
Protected constructor. More... | |
bool | isPlaying () override |
void | rewind () override |
Rewinds this audio entity. More... | |
void | play () override |
Plays this audio entity. More... | |
void | pause () override |
Pauses this audio entity. More... | |
void | stop () override |
Stops this audio entity. More... | |
![]() | |
virtual const string & | getId () const |
virtual const bool | isLooping () const |
virtual void | setLooping (bool looping) |
Set looping. More... | |
virtual const bool | isFixed () const |
virtual void | setFixed (bool fixed) |
Set this entity fixed, means the sound will always played no matter where the position and listener is located. More... | |
virtual const float | getPitch () const |
virtual void | setPitch (float pitch) |
Set up pitch. More... | |
virtual const float | getGain () const |
virtual void | setGain (float gain) |
Set up gain. More... | |
virtual const Vector3 & | getSourcePosition () const |
virtual void | setSourcePosition (const Vector3 &sourcePosition) |
Set source position. More... | |
virtual const Vector3 & | getSourceDirection () const |
virtual void | setSourceDirection (const Vector3 &sourceDirection) |
Set source direction. More... | |
virtual const Vector3 & | getSourceVelocity () const |
virtual void | getSourceVelocity (const Vector3 &sourceVelocity) |
Set source velocity. More... | |
virtual bool | isPlaying ()=0 |
virtual void | rewind ()=0 |
Rewinds this audio entity. More... | |
virtual void | play ()=0 |
Plays this audio entity. More... | |
virtual void | pause ()=0 |
Pauses this audio entity. More... | |
virtual void | stop ()=0 |
Stops this audio entity. More... | |
Protected Member Functions | |
bool | initialize () override |
Initiates this OpenAL entity to OpenAl. More... | |
void | update () override |
Commits properties to OpenAl. More... | |
void | dispose () override |
Dispose this entity from OpenAL. More... | |
![]() | |
AudioEntity (const string &id) | |
Constructor. More... | |
virtual | ~AudioEntity () |
Constructor. More... | |
virtual bool | initialize ()=0 |
Initiates this OpenAL entity to OpenAl. More... | |
virtual void | update ()=0 |
Commits properties to OpenAl. More... | |
virtual void | dispose ()=0 |
Dispose this entity from OpenAL. More... | |
Private Attributes | |
bool | initiated |
string | pathName |
string | fileName |
string | bufferId |
uint32_t | alBufferId |
uint32_t | alSourceId |
Friends | |
class | Audio |
Additional Inherited Members | |
![]() | |
string | id |
bool | looping |
bool | fixed |
float | pitch |
float | gain |
Vector3 | sourcePosition |
Vector3 | sourceDirection |
Vector3 | sourceVelocity |
Sound | ( | const string & | id, |
const string & | pathName, | ||
const string & | fileName | ||
) |
|
overrideprotectedvirtual |
|
overrideprotectedvirtual |
Initiates this OpenAL entity to OpenAl.
Implements AudioEntity.
|
overridevirtual |
|
overridevirtual |
|
overridevirtual |
|
overridevirtual |
|
overridevirtual |
|
overrideprotectedvirtual |