I used the DirectXTex
library to capture a screenshot of a DX11 game and save it to a file. The problem is that it works great when I save it as jpeg but if I save it as png the image would become super bright and washed out. I checked the image using TweakPNG
and found out the gamma was set to 1.0 and that's what's causing the problem.
I checked images taken by some other software including the snipping tool and they seem to use 0.45455 as gamma or they leave out the gamma value altogether.
I don't know if DirectXTex
will let me specify a gamma value or not. I'm not even sure if WIC
has this functionality as I can't seem to find useful information either on MSDN or other sites.