ExifTool Forum

ExifTool => Bug Reports / Feature Requests => Topic started by: van Dusen on May 31, 2011, 11:21:39 AM

Title: Export to MIE: IPTC:CodedCharacterSet not considered
Post by: van Dusen on May 31, 2011, 11:21:39 AM
Concerns ExifTool.exe v8.57 on WinXP Pro SP3

When exporting tags from an image file to a MIE file, then an existing tag "IPTC:CodedCharacterSet" will be not written to the MIE.
UTF8-encoded ANSI (Latin1), Non-ASCII characters from source file will be written "as is" (as UTF8-encoded characters) to the MIE,
but UTF8-encoded non-ANSI (Latin1), non-ASCII characters will be lost and written as (replaced by) "?" characters to the MIE (ExifTool prompts the message "Warning: Some character(s) could not be encoded in Latin" in this case)

To avoid this, I have to process the source image and the MIE in three steps:
1.) List all IPTC tags and check, whether any IPTC value contains non-ASCII characters.
2.) If non-ASCII chars are found, then creating the MIE file by writing a single tag to it ("-IPTC:CodedCharacterSet=utf8 {destination MIE}")
3.) Export all tags from source image to MIE ("-tagsFromFile {source image} {destination MIE}")

I don't know, whether this is by design or a bug, but if it is by design: does anyone know a way to export all tags - including IPTC tags containing unicode characters - properly to a MIE file in one step?

Thanks a lot in advance!

Greetings, van Dusen
Title: Re: Export to MIE: IPTC:CodedCharacterSet not considered
Post by: Phil Harvey on May 31, 2011, 11:48:11 AM
Native MIE information is UTF-8, but it must be properly decoded when copying to MIE for this to work.  In case the encoding is not known or incorrect, you can always write native IPTC information to a MIE file to preserve whatever encoding was used.

- Phil