I've learned a little more about the photo properties. It seems that Windows just doesn't "play that game" and use standard EXIF tags. I've seen lists of tag ID's, with some marked as "Windows" for the caption/description/keywords, but at some point they must have changed their minds. As it turns out, if you set properties in images now, they actually show up in the XMP block. Vista is good enough that if it updates an image, it will copy EXIF/IPTC data to the XMP block as well. XMP is an XML block of data that can contain known or arbitrary fields such as title/caption/author, but also custom application-specific stuff. Parsing it is pretty easy, though a bit manual. To make it worse, it seems that applications aren't 100% consistent with placement. This leads to "well-behaved" apps writing the same data to multiple spots (otherwise Photoshop can read the caption but Picasa can't, as a made-up example). Apparently XMP is an Adobe standard (SDK here).
I'm going to try to get some general code written to handle XMP (or first see what's out there, like this), but for now I'm using XPath queries to find what I need. For all I know, WPF classes might handle this better, but with GDI+ you're on your own. Is there any interest in a lightweight .NET XMP library? Anyway, mystery solved!
posted @ Friday, April 27, 2007 3:10 PM