You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Interpolating RGB values without gamma correct produces darker "dirtier" colors than they should be.
The solution would be to move values to linear space, interpolate and bring it back to gamma space.
//pseudocode for R channelvarcolor_hex='#FF0000';varcolor=hex2bytes(color_hex);varbyte_r=color[0];varfloat_r=byte_r/255;varlinear_r=Math.pow(float_r,2.2);varinter_r=interpolate(linear_r,linear_r_2,t);vargamma_r=Math.pow(inter_r,1/2.2);varout_r=Math.floor(gamma_r*255);
The text was updated successfully, but these errors were encountered:
Are you considering adding it in the future?
Interpolating RGB values without gamma correct produces darker "dirtier" colors than they should be.
The solution would be to move values to linear space, interpolate and bring it back to gamma space.
The text was updated successfully, but these errors were encountered: