Skip to content

Commit

Permalink
feat(core): Allow to get the map of registered faders.
Browse files Browse the repository at this point in the history
  • Loading branch information
na2axl committed Mar 11, 2024
1 parent 0232292 commit ee8291d
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
7 changes: 7 additions & 0 deletions include/SparkyStudios/Audio/Amplitude/Sound/Fader.h
Original file line number Diff line number Diff line change
Expand Up @@ -269,6 +269,13 @@ namespace SparkyStudios::Audio::Amplitude
*/
static void LockRegistry();

/**
* @brief Gets the list of registered Faders.
*
* @return The registry of Faders.
*/
static const std::map<std::string, Fader*>& GetRegistry();

/**
* @brief Look up a Fader by name.
*
Expand Down
5 changes: 5 additions & 0 deletions src/Sound/Fader.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -292,4 +292,9 @@ namespace SparkyStudios::Audio::Amplitude
{
lockFaders() = true;
}

const std::map<std::string, Fader*>& Fader::GetRegistry()
{
return faderRegistry();
}
} // namespace SparkyStudios::Audio::Amplitude

0 comments on commit ee8291d

Please sign in to comment.