Spectacle only supports 24bpp and will not work correctly with a 30bpp X11 display. It loses a few bits, resulting in wrong colors. Reproducible: Always Steps to Reproduce: 1. Set the display depth to 30 bpp in your Xorg configuration. E.g. NVIDIA drivers support this; recommended to use 364.12 (beta as of writing) or newer as that fixes a number of issues related to full 30bpp support. 2. Run Spectacle and take a screenshot Actual Results: 24bpp Screenshot with mangled colors Expected Results: 30bpp Screenshot with correct colors (converted to 24bpp or 48bpp if the file format does not support it)
Right, this is something we're interested in. Do you know what the pixel format is in a 30bpp XImage? Or could you point us to someone who does?
Created attachment 98112 [details] xdpyinfo output
Whew, no idea if that helps, but I’ve attached xdpyinfo output.
Goldmine. Thanks, I'll get this done in time for the next release (16.04)
Awesome. Poke me if you need me to test patches. I’m lachs0r @ freenode.
Git commit 83ef53e30c593642416a2d8c2f6ef950ffe112f3 by Boudhayan Gupta. Committed on 27/03/2016 at 16:04. Pushed by bgupta into branch 'Applications/16.04'. Use QImage's 30bpp BGR image format for 30bpp XImage FIXED-IN: 16.04 M +3 -12 src/PlatformBackends/X11ImageGrabber.cpp http://commits.kde.org/kscreengenie/83ef53e30c593642416a2d8c2f6ef950ffe112f3
Is this fixed? I have no way to test.
Yes, it is. At least I get correct colors now :) Now if it could save at higher bit depth as well, that would be the icing on the cake.
Qt's image processor can only handle 8 bits per component. Format_BGR30 just downscales 10bits of precision to 8bits. You'll have to file a QTBUG for this :-(
Looks like it’s regressed as of Spectacle 21.08.3. More precisely it looks like the color channels are swapped.
(In reply to Mia Herkt from comment #10) > Looks like it’s regressed as of Spectacle 21.08.3. More precisely it looks > like the color channels are swapped. Actually fixed in e6d64481699c5bfac8d552455c0ffc2a8ac68f4f: https://invent.kde.org/graphics/spectacle/-/commit/e6d64481699c5bfac8d552455c0ffc2a8ac68f4f