in reply to advice for a project

I worked on something alike myself in the past. I used a "Pipes and Filters architecture". I liked the idea to be able to plug in new filters for new file formats along the way. I was playing with the concept of content-based-routing of files. I can assure you it was a lot of work! Like most of my projects it was never finished ;-)

Many people work(ed) on file extraction tools and there are many around, commercial and non-commercial. You might want to take a look at initiatives like: the Metadata Extraction Tool which supports a lot of formats including popular image formats and audio/video formats! It's not a Perl solution though...

Beware! It’s a * lot * of work to build a tool like this yourself. It’s probably the lesser evil to find something off-the-shelve. Important criteria for selecting such a tool (IMHO):

HTH