Raw Files: exif:DateTimeOriginal

Discussion of Photoshop Scripting, Photoshop Actions and Photoshop Automation in General

Moderators: Tom, Kukurykus

Andrew

Raw Files: exif:DateTimeOriginal

Post by Andrew »

I am noticing some interesting behaviour around the property of a files creation date / time. In fact I guess this amounts to an 'anomaly'.

With my CR2 images if I import them (regardless of whether I use Photoshop / Bridge to do this or not) and look at the metadata using File Info, there is no exif:DateTimeOriginal entry. This is even true if I look in the advanced tag page, or if I save the xmp file from the advanced tag page.

BUT, if I use

alert(activeDocument.xmpMetadata.rawData);

there is the entry after all.

If I then convert the file to a tif file, the entry appears at that point in the file info and everything comes back to where you would expect it to be.

The conclusion is only that if you need to access the creation date of the image for a raw file, use activeDocument.xmpMetadata.rawData.

There is one nice workaround to this that I am going to use as an optional renaming method in the CF downloader I am currently creating. The image creation date is also recorded as the File Creation Date on the CF card. This provides an opportunity to avoid a significant amount of processing time since accessing activeDocument.xmpMetadata.rawData requires opening an image, while the file sytem file creation date is a property of the JS file object.

I find creation time one of the more important aspects of an images metadata from a processing point of view since it helps me to remember what the lighting / color temperature conditions are likely to have been. Also of course it is a good candidate for a file naming system since it puts your images in date order.

Andrew
kipcole9

Raw Files: exif:DateTimeOriginal

Post by kipcole9 »

Mike, I am pretty new at PS scripting, but I am noticing some strange behaviour in the same area that maybe you can shed some light on.

I am using the basic activeDocument.info.exif approach to extracting exif data. I have two documents, both of which show the full camera data in the "file info display". However only one of the documents returns the camera data in the script (tested over several images revolving into these two cases).

That is:
1. Both images show all the relevanta data in the "file info" display, and the data also display in other exif aware apps like BreezeBrowser.
2. Only one document returns the camera data in the activeDocument.info.exif structure.

Regards,

--Kip
Andrew

Raw Files: exif:DateTimeOriginal

Post by Andrew »

Kip, try using the file info pallete in PS, advanced tag, then save the two metadata files. See if they look the same. Are both files of the same type (extension).

You could also try saving the data exposed by activeDocument.xmpMetadata.rawData to external files and comparing those. With luck you will at least find out what is happening by these two tests.

Andrew
kipcole9

Raw Files: exif:DateTimeOriginal

Post by kipcole9 »

Thanks Andrew, will try that this evening. BTW, I discovered that if I re-process the original raw file then the data *does* appear in activeDocument.info.exif.

I think that the document that works "correctly" was only every processed in CS2, and the one that does not was either CS or PS7 (I think CS). Maybe this account for the difference, but does not explain it.

Cheers, --Kip