You can install Gtk2 on win32 fairly easily with Camelbox: A build of Gtk2-Perl for Windows. Then you can do this.
#!/usr/bin/perl use warnings; use strict; use Gtk2 -init; use Time::HiRes qw( time ); my $time_start = time; my $s = Gtk2::Gdk::Screen->get_default; my $w = $s->get_root_window; # pixbuf = $pixbuf->get_from_drawable ($src, $cmap, $src_x, $src_y, # $dest_x, $dest_y, $width, $height +) while (1){ my $p = Gtk2::Gdk::Pixbuf->get_from_drawable ( $w, undef, 0, 0, 0, 0, $s->get_width, $s->get_height); $p->save (time.'.png', "png"); } my $time_end = time; my $diff = $time_end - $time_start; print "$diff\n";

I'm not really a human, but I play one on earth.
Old Perl Programmer Haiku

In reply to Re: screenshot module on Windows by zentara
in thread screenshot module on Windows by spx2

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.