Now that is a mystery. Your script works fine here with my
test 30D CR2 image. Here is my terminal session:<br
/><br />
<code>
> cp ../pics/Canon30D_IMG_0092.CR2 tmp/a.cr2
> ./exiftool tmp/a.cr2 -imagedescription
> ./ttt
> ./exiftool tmp/a.cr2 -imagedescription
Image Description : A499JKLLL
> more ttt
#!/usr/bin/perl -w
BEGIN { push INC, 'lib' }
use Image::ExifTool 'ImageInfo';
#use IO::File;
#use Time::Local;
my $exifTool = new Image::ExifTool;
$photodirectory = "tmp/";
$file = "a.cr2";
my $info = $exifTool->ImageInfo($photodirectory.$file);
$exifTool->SetNewValue("ImageDescription",
"A499JKLLL");
$exifTool->WriteInfo($photodirectory.$file);
my $err = $exifTool->GetValue('Error');
$err and warn "Error: $err\n";
my $warn = $exifTool->GetValue('Warning');
$warn and warn "Warning: $warn\n";
exit;
>
</code><br />
Notice I added a few lines at the end of the script to print
errors and warnings... they didn't print anything for me,
but they might help you diagnose the problem you are
having.<br /><br />
- Phil
To write a respons, access
http://ww
w.cpanforum.com/response_form/2346
To see the full thread, access
http://www.cpan
forum.com/threads/2338
--
You are getting this messages from www.cpanforum.com
To change your subscription information visit http://www.cpanforum.
com/mypan/
|