#include "SoundSystem.h" #include using namespace crepe; SoundSystem SoundSystem::instance { }; std::unique_ptr SoundSystem::sound(const std::string & src) { auto res = std::make_unique(src); return SoundSystem::sound(std::move(res)); } std::unique_ptr SoundSystem::sound(std::unique_ptr res) { Sound * out = new Sound(std::move(res), SoundSystem::instance); return std::unique_ptr(out); } SoundSystem::SoundSystem() { engine.init(); } SoundSystem::~SoundSystem() { engine.deinit(); }