in reply to Re: Grabbing Jpeg Captions
in thread Grabbing Jpeg Captions

I remember seeing Image::Info in my searches but it didn't look like it read captions. I downloaded and tried it anyways to see and it doesn't. I thought perhaps "Comments" could some how translate into being captions but no such luck. Thank you for the sugestion though.

Replies are listed 'Best First'.
Re: Re: Re: Grabbing Jpeg Captions
by MidLifeXis (Monsignor) on Sep 30, 2003 at 17:20 UTC

    Since I don't know what a JPEG caption is... :)

    I assume that you did a print Data::Dumper->Dumper(image_info(foo)...) and it isn't hidden in there somewhere.

    What is a JPEG caption? Perhaps a patch to the Image::Info code would be appropriate.

      The caption is a text description embbed in the jpeg. Its basically suppose to be a description of the image. Its part of a jpeg standard part of the IPTC Information. I found this page which had some information on it. I found a perl module JFIF::JPEG which does read captions from most of the files. Unfortunately it doesn't read all the jpegs neccessary for my tasks. The funny thing is the code I posted does get a caption if its there reguardless of what the jpeg format it was saved in. But some times if there is no caption, it just grabs a chunk of the jpeg. I've been trying to detect when it does that but it has been difficult.