Soundux/src/core/global/globals.hpp

26 lines
862 B
C++
Raw Normal View History

2021-01-27 12:38:03 +01:00
#pragma once
#include "../../helper/audio/audio.hpp"
#include "../../helper/threads/processing.hpp"
2021-01-27 12:38:03 +01:00
#include "../../ui/ui.hpp"
#include "../config/config.hpp"
#include "../hotkeys/hotkeys.hpp"
2021-01-28 18:16:23 +01:00
#include "objects.hpp"
2021-01-27 12:38:03 +01:00
#include <memory>
namespace Soundux
{
namespace Globals
{
inline Objects::Data gData;
inline Objects::Audio gAudio;
2021-01-27 12:38:03 +01:00
inline Objects::Config gConfig;
inline Objects::Hotkeys gHotKeys;
2021-01-27 12:38:03 +01:00
inline Objects::Settings gSettings;
inline std::unique_ptr<Objects::Window> gGui;
inline Objects::ProcessingQueue<std::uintptr_t> gQueue;
2021-01-27 12:38:03 +01:00
/* Allows for fast & easy sound access, is populated on start up */
inline std::shared_mutex gSoundsMutex;
inline std::map<std::uint32_t, std::reference_wrapper<Objects::Sound>> gSounds;
2021-01-27 12:38:03 +01:00
} // namespace Globals
} // namespace Soundux