fragRGB: gain and offset have to be applied on linear intensity, of course