Image::XWD - X Window Dump image reader
use Image::XWD; my $img = new Image::XWD; $img->read_file('foo.xwd'); my $window_name = $img->get_window_name(); # get the window name saved by xwd(1) my ($r,$g,$b) = $img->xy_rgb(100,200); # get pixel at (100,200)
Image::XWD can be used to read the screenshot created by xwd(1).
Constructs a new
Reads the given filename to the memory. Specify '-' as filename to read from stdin.
Returns the width of the image in pixels.
Returns the heigth of the image in pixels.
Returns the window name saved by xwd(1). If the image contains no window name undef is returned. (Note that this differs from emty string as window name.)
Get the color of the pixel in RGB. The upper left corner is (0, 0) and the lower right corner is ($img->get_width()-1, $img->get_heigth()-1).
xwd(1), xwud(1), gimp(1), /usr/include/X11/XWDFile.h
MÃ¡rton NÃ©meth, <email@example.com>
Copyright (C) 2008 by MÃ¡rton NÃ©meth
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.8 or, at your option, any later version of Perl 5 you may have available.