Uniforms limit in shaders ,OpenGL 4.0
Hi All. I have a frag shader that does multi - source phong point lightning . I define an array of structs which hold all the properties needed for each light source.I have 5 uniforms in each struct.Then I noticed
that passing more than25-30 (haven't checked the exact number)structs in the array the program linkage fails.So I guess I pass the uniforms limit for that shader.Anybody can tell me what is the limit ?
Also , in such a case what is the best way to process multiple lightsource using forward rendering without getting restricted by number of uniforms? So uniform buffers solve this problem ?
Tags for this Thread