Monday, March 09, 2009

Help With XWD

Since we went live on the new desktop we have had a nagging issue with screendumps. From time to time the "import" command once activated would log you off the server and return you to the XDM chooser. I have never been able to replicate it reliably for debugging until today. I had always suspect it was a crash of gnome-session or the parent dbus process. Turns out it's a crash of X on the thin clients, which makes it a lot harder to patch and fix. We are not ready at this point to push out a new build to our 550 devices.

So I have been looking at our good old friend, xwd. It would perfectly meet my needs, and doesn't crash in the same place as import. The problem is there seems to be an endian issue when using Compiz. The shot below shows what is dumped when Compiz is active. Ideas and technical information is appreciated. I don't mind using convert on a second pass to revert the original colors, but am not sure what exactly is wrong with the image.

7 comments:

Corsac said...

What about gnome-screenshot or xfce4-screenshooter?

Dave Richards said...

corsac: I already replaced gnome-screenshot because it wasn't robust enough. I'll check xfce4. I'm looking for a command line method to dump the file, and then pass it to our customized gui helpers.

Steven said...

I can't help you with xwd either, but I put a shortcut to scot for my users. But I haven't tried it with compiz.

Alex Hudson said...

Looks like the XWD is missing the red part of colours for all of the screen capture _except_ the terminal you're running the command from (if you look, the background is white and the menu bar etc. are grey - basically correct colours).

I imagine this is because it has an alpha channel available for compositing or something, but you can't post-process it to be correct - it must be a bug in xwd or something.

Corsac said...

xfce4-screenshooter will bring in some xfce lib (not that much though: http://packages.debian.org/sid/xfce4-screenshooter-plugin and xfce4-panel can be left out, it's only for the panel plugin)

Sandaruwan said...

Did you try "-xy" and/or "-icmap" options?

Dave Richards said...

sandaruwan: Thanks for the tip but already tested. -xy crashes xwd with compiz running, -icmap produces the same output.