OpenGTA/OpenGTA-win/frgbridge.cpp

23 lines
361 B
C++
Raw Permalink Normal View History

2018-09-22 21:26:15 +00:00
#include "frgbridge.h"
#include "include/Engine.h"
#include <memory>
#include <mutex>
std::unique_ptr<SE::TShaderManager> shaderManager;
SE::TShaderManager& GetShaderManager()
{
static std::once_flag onceFlag;
std::call_once(onceFlag,
[] {
shaderManager = std::make_unique<SE::TShaderManager>();
});
return *shaderManager.get();
}