iluvperl
Programmer
- Jan 22, 2006
- 107
I am trying to load an image into a SWF file. It should be simple but I am getting the error "Can't get the width and height of /home/everyday/public_html/pictures/100.jpg at /home/everyday/public_html/lib/SWF/Builder.pm line 189".
I was using a partial file path originally, but it didn't make any difference. The image is in the right place and permissions are set. I just don't see what the problem is.
Anyone familiar with this?
Thanks!
Code:
#!/usr/bin/perl -w
use strict;
use CGI::Carp qw(fatalsToBrowser);
use lib "/home/everyday/public_html/lib";
use SWF::Builder;
my $movie = SWF::Builder->new
( FrameRate => 15,
FrameSize => [15, 15, 400, 400],
BackgroundColor => 'ffffff'
);
my $jpeg = $movie->new_jpeg('/home/everyday/public_html/pictures/100.jpg');
$jpeg->place;
$movie->save('winter.swf');
I was using a partial file path originally, but it didn't make any difference. The image is in the right place and permissions are set. I just don't see what the problem is.
Anyone familiar with this?
Thanks!