tags:

views:

128

answers:

3

Sorry for the question marks, but a simple (I think) question has an impossible solution. From file system, if I click on an image file "Properties | Details tab" I access to many metadata. I need to access from a WPF application to the Description properties (Title, Subject, Rating, Tag and Comment). In particular Tag.

I have found a lot of articles, many are very old. A few in WPF and Imaging library. But no one access to that properties. So the question marks: are these properties on image? On file system? I think they are on the image..I don0t undestand where are these properties and why is so difficult to access...

Can someone help me?

Thanks in advance,

 Marco Parenzan
A: 

I think you are refering to the EXIF metadata

here is how to access it from an image object in .NET

Eric
I have tried. That properties are not here.
Marco Parenzan
Missing properties is a very common problem.
AMissico
A: 

You are referring to EXIF or Exchangeable Image File format data.

http://www.exif.org http://en.wikipedia.org/wiki/Exchangeable_image_file_format

Yes, there is code to allow accessing this. I would strongly suggest using an existing library over rolling you own with .net framework methods. Plainly put, they suck, are poorly documented and will result in bald spots on your head where there should be none.

See here for more info.

Sky Sanders
I don't think you can blame the .NET Framework methods. The problem is there is no true standards for any of the metadata in use. Therefore, Microsoft gave us basic methods and it is up to us to work out the details depending on our requirements.
AMissico
I have tried the library. it extracts only EXIF info. Not the Description Info
Marco Parenzan
A: 

The best tool I found to read metadata is ExifTool by Phil Harvey at http://www.sno.phy.queensu.ca/~phil/exiftool. The tool is written in Perl, but there is no need to install Perl. The tool has a complete command line syntax for anything you want to do. You can read nearly everything and write most things.

AMissico
Thanks. It works. Incredible tool! Now I know that they are xmp info, that I have seen are RDF info. Now I see how to capture in a way. Thanks. Any one knows how to manage these info natively in .NET?
Marco Parenzan
I am working on a library that wraps the command line interface. I am taking a break from it. Do you want what I have?
AMissico
Thanks but these are the only two commands I need:"exiftool(-k).exe" -Subject="aa;bb;cc" 14092009006-001.jpg"exiftool(-k).exe" -Subject 14092009006-001.jpg Marco
Marco Parenzan