Skip to content

Commit

Permalink
constexpr pSoundVolumeLevels
Browse files Browse the repository at this point in the history
  • Loading branch information
captainurist committed Nov 9, 2023
1 parent d199fcc commit debe437
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
7 changes: 4 additions & 3 deletions src/Media/Audio/AudioPlayer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,10 @@
std::unique_ptr<AudioPlayer> pAudioPlayer;
SoundList *pSoundList;

std::array<float, 10> pSoundVolumeLevels = {
{0.0000000f, 0.1099999f, 0.2199999f, 0.3300000f, 0.4399999f, 0.5500000f,
0.6600000f, 0.7699999f, 0.8799999f, 0.9700000f}};
static constexpr std::array<float, 10> pSoundVolumeLevels = {{
0.0000000f, 0.1099999f, 0.2199999f, 0.3300000f, 0.4399999f,
0.5500000f, 0.6600000f, 0.7699999f, 0.8799999f, 0.9700000f
}};

std::map<uint32_t, SoundInfo> mapSounds;

Expand Down
2 changes: 0 additions & 2 deletions src/Media/Audio/AudioPlayer.h
Original file line number Diff line number Diff line change
Expand Up @@ -193,6 +193,4 @@ class SoundList {
extern std::unique_ptr<AudioPlayer> pAudioPlayer;
extern SoundList *pSoundList;

extern std::array<float, 10> pSoundVolumeLevels;

void PlayLevelMusic();

0 comments on commit debe437

Please sign in to comment.