add gl_max_uniform_block_size

This commit is contained in:
jrkb 2023-05-29 08:03:15 +02:00
parent c1fd3abce1
commit 7a0f588bcb
2 changed files with 7 additions and 1 deletions

View file

@ -3,6 +3,6 @@
namespace ofxGPUFont { namespace ofxGPUFont {
GLint Font::gl_max_texture_size = -1; GLint Font::gl_max_texture_size = -1;
//GLint Font::gl_max_uniform_block_size = -1; GLint Font::gl_max_uniform_block_size = -1;
} }

View file

@ -441,6 +441,11 @@ class Font {
glGetIntegerv(GL_MAX_TEXTURE_SIZE, &gl_max_texture_size); glGetIntegerv(GL_MAX_TEXTURE_SIZE, &gl_max_texture_size);
cout << "GL_MAX_TEXTURE_SIZE: " << ofToString(gl_max_texture_size) << endl; 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){ if(hinting){
loadFlags = FT_LOAD_NO_BITMAP; loadFlags = FT_LOAD_NO_BITMAP;
@ -1429,6 +1434,7 @@ class Font {
std::unordered_map <GlyphIdentity, Glyph> glyphs; std::unordered_map <GlyphIdentity, Glyph> glyphs;
static GLint gl_max_texture_size; static GLint gl_max_texture_size;
static GLint gl_max_uniform_block_size;
public: public:
// ID of the shader program to use. // ID of the shader program to use.