make shaderCatalog shared_ptr

This commit is contained in:
jrkb 2023-05-29 09:56:03 +02:00
parent 49b32d3f39
commit 610ce89bfa
2 changed files with 2 additions and 2 deletions

View file

@ -22,7 +22,7 @@ void GPUFontAtlasLayerCombo::setup(const ComboIdentifier & identifier,
#else
string shaderDir = "data/ofxGPUFont/shaders/GL3";
#endif
shaderCatalog = std::make_unique <ofxGPUFont::ShaderCatalog>(shaderDir);
shaderCatalog = std::make_shared <ofxGPUFont::ShaderCatalog>(shaderDir);
//backgroundShader = shaderCatalog->get("background");
fontShader = shaderCatalog->get("font");

View file

@ -105,7 +105,7 @@ class GPUFontAtlasLayerCombo : public AtlasLayerCombo {
// because OpenGL still requires a non-zero VAO to be bound for the draw call.
GLuint emptyVAO;
std::unique_ptr <ofxGPUFont::ShaderCatalog> shaderCatalog;
std::shared_ptr <ofxGPUFont::ShaderCatalog> shaderCatalog;
//std::shared_ptr <ShaderCatalog::Entry> backgroundShader;
std::shared_ptr <ofxGPUFont::ShaderCatalog::Entry> fontShader;