‘Glossed’ properties on TCustomExifData

[While I’ve included the following as a secondary readme file in the CCR Exif ZIP, it seems appropriate to post the text here as well.]

In the main, TCustomExifData presents tag data ‘as is’, albeit without being strict about what type an underlying tag reports itself to be if the element size is the same — thus, signed data is silently casted to unsigned data or vice versa if required. Some property values, however, are what I call ‘glossed’ slightly:

Author

  • The property getter first attempts to retrieve the ttWindowsAuthor tag, and if that doesn’t exist or is empty, the ttArtist tag. Note that this behaviour mimics that of Windows Explorer.
  • The property setter always sets the ttWindowsAuthor tag if it already exists or the new value includes non-ASCII characters; the ttArtist tag is then set if the new value only includes ASCII characters, otherwise it is deleted.

Comments

  • The property getter looks firstly for ttWindowsComments, and secondly for ttUserComment; once again, this behaviour is to mimic that of Windows Explorer.
  • The property setter always sets ttWindowsComments, and if it already exists, ttUserComment.

DateTime, DataTimeOriginal, DateTimeDigitized

  • In the property getter, if the corresponding SubSecTime tag exists, its value is merged into the result.
  • In the property setter, the corresponding SubSecTime tag is set too if it already exists or AlwaysWritePreciseTimes is True.  Because of this behaviour, the SubsecTime, SubsecTimeOriginal and SubsecTimeDigitized properties can generally be ignored.

ExifVersion, GPSVersion

  • Internally the data for these properties are stored differently. To abstract away from this, sub-classes from a common ancestor are used to expose them in a consistent manner.

GPSDateTimeUTC

  • Returns and sets the combined values of GPSTimeStampXXX and GPSDateStamp (if you’re wondering, the latter are relative to UTC to begin with).
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s