From 7a0f588bcbb04eab7a50adf1cf321e2e679933da Mon Sep 17 00:00:00 2001 From: themancalledjakob Date: Mon, 29 May 2023 08:03:15 +0200 Subject: [PATCH] add gl_max_uniform_block_size --- src/gpufont/font.cpp | 2 +- src/gpufont/font.hpp | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/src/gpufont/font.cpp b/src/gpufont/font.cpp index 7321744..3aa8abc 100644 --- a/src/gpufont/font.cpp +++ b/src/gpufont/font.cpp @@ -3,6 +3,6 @@ namespace ofxGPUFont { GLint Font::gl_max_texture_size = -1; -//GLint Font::gl_max_uniform_block_size = -1; +GLint Font::gl_max_uniform_block_size = -1; } diff --git a/src/gpufont/font.hpp b/src/gpufont/font.hpp index 71f60d5..3524366 100644 --- a/src/gpufont/font.hpp +++ b/src/gpufont/font.hpp @@ -441,6 +441,11 @@ class Font { glGetIntegerv(GL_MAX_TEXTURE_SIZE, &gl_max_texture_size); cout << "GL_MAX_TEXTURE_SIZE: " << ofToString(gl_max_texture_size) << endl; } + if(gl_max_uniform_block_size == -1){ + glGetIntegerv(GL_MAX_UNIFORM_BLOCK_SIZE, &gl_max_uniform_block_size); + cout << "GL_MAX_UNIFORM_BLOCK_SIZE: " << ofToString(gl_max_uniform_block_size) << endl; + } + if(hinting){ loadFlags = FT_LOAD_NO_BITMAP; @@ -1429,6 +1434,7 @@ class Font { std::unordered_map glyphs; static GLint gl_max_texture_size; + static GLint gl_max_uniform_block_size; public: // ID of the shader program to use.