Skip to content

Class Engine::Sound

ClassList > Engine > Sound

Engine wrapper for audio.

  • #include <Sound.hpp>

Public Functions

Type Name
float GetVolume () const
bool IsLooping () const
bool IsPlaying () const
void Play ()
void SetLooping (const bool value)
void SetVolume (const float volume)
Sound ()
Sound (const std::string & path, const bool isLoop=false)
Sound (const char * fileType, const unsigned char * data, int dataSize, const bool isLoop=false)
Sound (const Sound & other)
Sound (Sound && other) noexcept
void Stop ()
void Update ()
Restarts a looped sound after it reaches its end.
Sound & operator= (const Sound & other)
Sound & operator= (Sound && other) noexcept
~Sound ()

Public Functions Documentation

function GetVolume

inline float Engine::Sound::GetVolume () const

function IsLooping

inline bool Engine::Sound::IsLooping () const

function IsPlaying

inline bool Engine::Sound::IsPlaying () const

function Play

inline void Engine::Sound::Play () 

function SetLooping

inline void Engine::Sound::SetLooping (
    const bool value
) 

function SetVolume

inline void Engine::Sound::SetVolume (
    const float volume
) 

function Sound [⅕]

inline Engine::Sound::Sound () 

function Sound [⅖]

inline Engine::Sound::Sound (
    const std::string & path,
    const bool isLoop=false
) 

function Sound [⅗]

inline Engine::Sound::Sound (
    const char * fileType,
    const unsigned char * data,
    int dataSize,
    const bool isLoop=false
) 

function Sound [⅘]

inline Engine::Sound::Sound (
    const Sound & other
) 

function Sound [5/5]

inline Engine::Sound::Sound (
    Sound && other
) noexcept

function Stop

inline void Engine::Sound::Stop () 

function Update

Restarts a looped sound after it reaches its end.

inline void Engine::Sound::Update () 


function operator=

inline Sound & Engine::Sound::operator= (
    const Sound & other
) 

function operator=

inline Sound & Engine::Sound::operator= (
    Sound && other
) noexcept

function ~Sound

inline Engine::Sound::~Sound () 


The documentation for this class was generated from the following file /home/runner/work/r-type/r-type/Engine/include/Assets/Sound.hpp