Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Explore custom metadata namespace for additional metadata #1789

Open
RhetTbull opened this issue Jan 25, 2025 · 0 comments
Open

Explore custom metadata namespace for additional metadata #1789

RhetTbull opened this issue Jan 25, 2025 · 0 comments

Comments

@RhetTbull
Copy link
Owner

See also #1788

Currently, the timezone name for a photo cannot be preserved on export. Both the XMP sidecar format and the --exiftool option preserve the UTC offset but this does not preserve the named timezone (e.g. America/Los_Angeles). When restoring a photo with osxphotos import, osxphotos will select a timezone that matches the UTC offset for the photo but this does not guarantee that it is the correct timezone name. The metadata standards do not allow the specification of the name, only the UTC offset.

It is possible to declare custom namespaces in XMP and this is allowed by the XMP spec. Thus osxphotos could create one to store the timezone name (and perhaps other metadata in the future). For example, the following XMP snippet stores the timezone name and does not seem to cause issues with exiftool:

</rdf:Description>
      <rdf:Description rdf:about=""
            xmlns:osxphotos="http://ns.osxphotos.com/1.0/">
         <osxphotos:timezone>America/Los_Angeles</osxphotos:timezone>
</rdf:Description>

However, exiftool will not read or apply this custom namespace without using a custom config file. This is probably fine as OSXPhotos could read the data directly with CoreGraphics at the time of import or by parsing the XMP file.

Need to play with this and verify that creating a custom sidecar namespace doesn't break other tools like DigiKam and Lightroom.

We could create a separate option to enable this, perhaps --extra-metadata that would output the OSXPhotos specific namespace when using --sidecar.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant