Pass max colors as a uniform to the shaders.