In OpenGL I can access the number of supported vertex shader uniforms by requesting “GL_MAX_VERTEX_UNIFORM_COMPONENTS” which will let me know how many “float” values can be assigned. This works with any any combination of float, vec2, vec3, etc.
However in OpenGL ES I can only access the number of supported vertex shader uniform vectors by requesting “GL_MAX_VERTEX_UNIFORM_VECTORS” which will let me know how many “vec4” values can be assigned.
My question is simple. If I set a uniform using “glUniform1f” or “glUniform2f”, etc, does it expand to fill an entire “vec4” worth of space on the GPU, or are those values packed in memory to only fill the required space? Or heaven forbid is it vendor specific?
I just need to figure out if I need to “prepack” my uniforms before sending them to the GPU. Thanks!