plugins/invert: adjust to colormanagement.glsl changes
The current version didn't compile, because the nitsToEncoding and encodingToNits expect different arguments than before
This commit is contained in:
parent
298486d47a
commit
d8e1637dcd
2 changed files with 4 additions and 4 deletions
|
@ -13,12 +13,12 @@ void main()
|
||||||
tex = adjustSaturation(tex);
|
tex = adjustSaturation(tex);
|
||||||
|
|
||||||
// to preserve perceptual contrast, apply the inversion in gamma 2.2 space
|
// to preserve perceptual contrast, apply the inversion in gamma 2.2 space
|
||||||
tex = nitsToEncoding(tex, gamma22_EOTF, destinationReferenceLuminance);
|
tex = nitsToEncoding(tex, gamma22_EOTF, 0.0, destinationReferenceLuminance);
|
||||||
tex.rgb /= max(0.001, tex.a);
|
tex.rgb /= max(0.001, tex.a);
|
||||||
tex.rgb = vec3(1.0) - tex.rgb;
|
tex.rgb = vec3(1.0) - tex.rgb;
|
||||||
tex *= modulation;
|
tex *= modulation;
|
||||||
tex.rgb *= tex.a;
|
tex.rgb *= tex.a;
|
||||||
tex = encodingToNits(tex, gamma22_EOTF, destinationReferenceLuminance);
|
tex = encodingToNits(tex, gamma22_EOTF, 0.0, destinationReferenceLuminance);
|
||||||
|
|
||||||
gl_FragColor = nitsToDestinationEncoding(tex);
|
gl_FragColor = nitsToDestinationEncoding(tex);
|
||||||
}
|
}
|
||||||
|
|
|
@ -17,12 +17,12 @@ void main()
|
||||||
tex = adjustSaturation(tex);
|
tex = adjustSaturation(tex);
|
||||||
|
|
||||||
// to preserve perceptual contrast, apply the inversion in gamma 2.2 space
|
// to preserve perceptual contrast, apply the inversion in gamma 2.2 space
|
||||||
tex = nitsToEncoding(tex, gamma22_EOTF, destinationReferenceLuminance);
|
tex = nitsToEncoding(tex, gamma22_EOTF, 0.0, destinationReferenceLuminance);
|
||||||
tex.rgb /= max(0.001, tex.a);
|
tex.rgb /= max(0.001, tex.a);
|
||||||
tex.rgb = vec3(1.0) - tex.rgb;
|
tex.rgb = vec3(1.0) - tex.rgb;
|
||||||
tex *= modulation;
|
tex *= modulation;
|
||||||
tex.rgb *= tex.a;
|
tex.rgb *= tex.a;
|
||||||
tex = encodingToNits(tex, gamma22_EOTF, destinationReferenceLuminance);
|
tex = encodingToNits(tex, gamma22_EOTF, 0.0, destinationReferenceLuminance);
|
||||||
|
|
||||||
fragColor = nitsToDestinationEncoding(tex);
|
fragColor = nitsToDestinationEncoding(tex);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue