home *** CD-ROM | disk | FTP | other *** search
/ Australian Personal Computer 2004 July / APC0407D2.iso / workshop / apache / files / ActivePerl-5.6.1.638-MSWin32-x86.msi / _8f178ec825efb2c660e976055a3501cb < prev    next >
Encoding:
Text File  |  2004-04-13  |  1.2 KB  |  45 lines

  1.  
  2. =head1 NAME
  3.  
  4. Tk::Animation - Display sequence of Tk::Photo images
  5.  
  6. =for pm Tk/Animation.pm
  7.  
  8. =for category Tk Image Classes
  9.  
  10. =head1 SYNOPSIS
  11.  
  12.   use Tk::Animation
  13.   my $img = $widget->Animation('-format' => 'gif', -file => 'somefile.gif');
  14.  
  15.   $img->add_frames(@images);
  16.  
  17.   $img->start_animation($period);
  18.   $img->stop_animation;
  19.  
  20.  
  21. =head1 DESCRIPTION
  22.  
  23. In the simple case when C<Animation> is passed a GIF89 style GIF with
  24. multiple 'frames', it will build an internal array of C<Photo> images.
  25.  
  26. The C<add_frames> method adds images to the sequence. It is provided
  27. to allow animations to be constructed from separate images.
  28. All images must be C<Photo>s and should all be the same size.
  29.  
  30. C<start_animation($period)> then initiates a C<repeat> with specified I<$period>
  31. to sequence through these images. As for raw C<repeat> I<$period> is in milli-seconds,
  32. for a 50Hz monitor it should be at least 20mS.
  33.  
  34. C<stop_animation> cancels the C<repeat> and resets the image to the first
  35. image in the sequence.
  36.  
  37. =head1 BUGS
  38.  
  39. The 'period' should probably be a property of the Animation object
  40. rather than specified at 'start' time. It may even be embedded
  41. in the GIF.
  42.  
  43. =cut
  44.  
  45.