Ember
A C++ 20 'game engine' built with SDL3 with wide platform support.
Classes | Functions | Variables
ember_audio.h File Reference
#include "core/engine.h"

Go to the source code of this file.

Classes

class  Audio
 Audio struct. More...
 

Functions

bool InitAudio ()
 Initialize Sound Engine. More...
 
void CloseAudio ()
 Close Sound Engine and free allocated resources. More...
 
void Audio_SetMasterVolume (float volume)
 Change the [audio engine] global volume. More...
 

Variables

constexpr int NUM_CHANNELS = 2
 
constexpr int SAMPLE_RATE = 48000
 
std::unordered_map< std::string, Audio * > audios
 

Function Documentation

◆ Audio_SetMasterVolume()

void Audio_SetMasterVolume ( float  volume)

Change the [audio engine] global volume.

Parameters
volumeAudio volume from [0.0f -> 1.f]
Version
  • 0.0.3
    Returns
    void

◆ CloseAudio()

void CloseAudio ( )

Close Sound Engine and free allocated resources.

Version
0.0.3
Returns
void

◆ InitAudio()

bool InitAudio ( )

Initialize Sound Engine.

  • mini-audio backend
Version
0.0.3
Returns
bool

Variable Documentation

◆ audios

std::unordered_map<std::string, Audio*> audios
inline

◆ NUM_CHANNELS

constexpr int NUM_CHANNELS = 2
constexpr

◆ SAMPLE_RATE

constexpr int SAMPLE_RATE = 48000
constexpr