I write an application with WebGL. In my fragment shader I set constant color to fragment but in my canvas I actually get a slightly different color. For example I write this code to my fragment shader:
precision mediump float;
void main(void){
gl_FragColor = vec4(0.0, 0.0, 1.0, 1.0);
}
In my canvas i see color #0005FA which is not what i want.
On the other hand when I set output color for example to vec4(1.0) then in my canvas I get correct color #FFFFFF.
I got this problem when using Google chrome. In Firefox colors are just fine. I use Debian OS, maybe it is related with this problem.
The difference in colors is not noticable but ruins my debbuging. I cannot properly read values. Does anybody know how to solve this?