Writing to Com.apple.quicktime.description in MOV so that iOS Photos can read it

Started by jimbolaya1312, December 05, 2022, 04:47:47 AM

Previous topic - Next topic

jimbolaya1312

Hello everybody,

I am new to exiftool and hope you can help me with adding a description to MOV files. The description must be readable by the Photos app on an iPhone. I have hundreds of videos which I have converted to MOV on my windows PC. Before I import those videos to iPhone I need to add a description which can be used to find the correct video using the iOS Photos app.

To figure out which metadata field can be read by iOS I started adding the description "My Description" to a video directly on the iPhone using the Photos app by clicking on the (i) and then adding it in the field "Add a caption". Then I uploaded the video (IMG-2352.mov) to metadata2go.com and figured out, that "My Description" was written to the field Com.apple.quicktime.description

Now I tried to write such a description to other videos using the following exiftool commands:

exiftool -m -P -overwrite_original_in_place -ItemList:Title=MyTitle -ItemList:Description=MyDescription "IMG-2353.mov"

exiftool -m -P -overwrite_original_in_place -UserData:Title=MyTitle -UserData:Description=MyDescription "IMG-2354.mov"

exiftool -m -P -overwrite_original_in_place -Keys:DisplayName=MyTitle -Keys:Description=MyDescription "IMG-2355.mov"

Afterwards I always verified with exiftool that the description was added.

Unfortunately after uploading those videos to the iPhone for none of those videos the description was visible on the iPhone. I was not able to find the videos using the search feature of the iOS Photos app.

==> Which exiftool command is required so that a text is written into the the field Com.apple.quicktime.description of MOVs? <==


I have uploaded the video where I initially successfully added "My Description" using my iPhone here => IMG-2352.mov

Furthermore here is a video where no description is written yet - how can an iOS-readable description (Caption) be added here using exiftool? => IMG-2360.mov

Any help is highly appreciated!

Regards
Jan

P.S. To illustrate how text can be added to videos on iOS and then - most importantly for me - later be used to find videos in the Photos app, I have added some screenshots:

Image 1 Added a description to IMG-2352.mov:


Image 2 No description yet on IMG-2360.mov:


Image 3 Found the video IMG-2352.mov by searching the description:

wywh

Movie metadata is such a mess and a moving target that I edit only dates and locations in them and have all descriptions in a spreadsheet so I can fill them in later if the standard gets more robust.

I have edited some movie descriptions on the macOS via 'Keys:Description' but iPadOS 16.1.1 does not seem to currently read that. AFAIR iPad OS got support for description display quite lately.

I did a quick test in my movie descriptions and at the moment macOS 13.0.1 and iPadOS 16.1.1 (exported to iPad from macOS 12, if that matters) both seem to read this particular ItemList tag:

exiftool -m -P -overwrite_original_in_place -ItemList:ID-a9des:Description='ItemList ID-a9des Description' movie.mp4

exiftool -a -G1:7 -s -ItemList:Description movie.mp4
[ItemList:ID-a9des] Description                 : ItemList ID-a9des Description

Some of my slightly older movies had also 'ItemList:ID-desc:Description' but neither macOS nor iPadOS apps display it.

See also:

https://exiftool.org/forum/index.php?topic=13817.msg74437#msg74437

https://exiftool.org/forum/index.php?topic=12176

- Matti

jimbolaya1312

Matti, thanks for your quick reply!

I have tried both following command (the first was suggested from you the second without the ID-a9des):

exiftool -m -P -overwrite_original_in_place -ItemList:ID-a9des:Description=MyDescription testvideo.mov
exiftool -a -G1:7 -s -ItemList:Description testvideo.mov
[ItemList:ID-a9des] Description                 : MyDescription

exiftool -m -P -overwrite_original_in_place -ItemList:Description=MyDescription testvideo2.mov
exiftool -a -G1:7 -s -ItemList:Description testvideo2.mov
[ItemList:ID-a9des] Description                 : MyDescription

After uploading both MOVs to my iPhone 12 Pro (iOS 16.1.2) and also to my iPad (iOS 16.1.1) I did unfortunately NOT see the caption MyDescription in the Photos app for both videos. I am uploading the videos using the Windows iCloud software and I am sure that this upload process does not strip off any metadata.

May I ask some further questions:

1: Is that :ID-a9des part after -Itemlist important to target that specific Com.apple.quicktime.description field?

2: Can you confirm that when you open your movie.mp4 in the iOS Photos app and then click on (i) then you see "ItemList ID-a9des Description" as Caption for that video, correct?

3: Maybe it is because you are using MP4 and I am using MOV. I am willing to reconvert all my videos to MP4. Would you kindly upload an example MP4-File with empty description so that I can extract the MP4-specs and re-convert my videos according to your MP4-Specs? Alternatively you would maybe share your ffmpeg conversion settings?

Looking forward to your reply :-)

Regards
Jan

StarGeek

Quote from: jimbolaya1312 on December 05, 2022, 10:52:08 AM3: Maybe it is because you are using MP4 and I am using MOV. I am willing to reconvert all my videos to MP4. Would you kindly upload an example MP4-File with empty description so that I can extract the MP4-specs and re-convert my videos according to your MP4-Specs? Alternatively you would maybe share your ffmpeg conversion settings?

There shouldn't be any difference between a MOV and an MP4.  But as for conversion, I use this ffmpeg command to remux (not recompress) from one container to another, such as would be the case for MOV->MP4 conversion
ffmpeg -hide_banner -i input.MOV -c copy -map 0 -map_metadata 0 output.MP4

Also, try using the command in FAQ #3 on a file that shows the data in your Apple app to see where exiftool finds the data.

I can't access your example file because that site requires me to turn off my ad blocker, which isn't going to happen.  Google drive or dropbox are better locations to share files, as they don't have such limitations.
* Did you read FAQ #3 and use the command listed there?
* Please use the Code button for exiftool code/output.
 
* Please include your OS, Exiftool version, and type of file you're processing (MP4, JPG, etc).

wywh

Quote from: jimbolaya1312 on December 05, 2022, 10:52:08 AM1: Is that :ID-a9des part after -Itemlist important to target that specific Com.apple.quicktime.description field?

2: Can you confirm that when you open your movie.mp4 in the iOS Photos app and then click on (i) then you see "ItemList ID-a9des Description" as Caption for that video, correct?

3: Maybe it is because you are using MP4 and I am using MOV. I am willing to reconvert all my videos to MP4. Would you kindly upload an example MP4-File with empty description so that I can extract the MP4-specs and re-convert my videos according to your MP4-Specs? Alternatively you would maybe share your ffmpeg conversion settings?

With ExifTool 12.50 '-ItemList:Description=Description' seemed to add the same tag as the more specific '-ItemList:ID-a9des:Description=Description'.

But a few years ago I had to use '-ItemList:ID-a9aut:Author=Author' because the generic '-ItemList:Author=Author' adds 'ItemList:ID-auth' instead 'ItemList:ID-a9aut' which is the one that worked in macOS 11 Big Sur QuickTime Player and Photos.app 6.0. So I did it the hard way so we know what we are talking about.

At least in my quick test with a few years' movies only 'ItemList:ID-a9des' showed the description in iPad Photos. But that was the only such movie and all other movie had a duplicate of both kinds of ItemList tags so it seemed iPadOS reads only ID-a9des.

I now tested mixed .mp4, .m4v and .mov movies. With dates and recent macOS versions there are slight differences how each wrapper is read.

https://discussions.apple.com/docs/DOC-250002750

And somewhere in my tests I suspected that the workflow and in which order the tags were added had an effect to the end result. Also locations and timezones and GPS times are flies in the ointment. Oh, so many variations!

I would not re-wrap movie to .mp4 just because of this unless you find a solid workflow that works. But be prepared that the workflow might fail without notice.

Some links that refer to my headaches with movie metadata and how Photos.app might incorrectly display it:

https://exiftool.org/forum/index.php?topic=14245.msg76782#msg76782

https://exiftool.org/forum/index.php?topic=14237.msg76753#msg76753

p.s. When doing tests, notice that the transfer via a USB cable from a mobile device to a Mac is supposed to transfer the unmodified original, not the edited version. The caption is not embedded in the original, so it is not transferred.

The only easy way to transfer the edits from an iPhone or iPad losslessly, including the albums, caption, locations, adjusted dates is iCloud Photos Library. If you do not want to upload all photos from your Mac to iCloud, only download the photos from your iOS device, create a new, empty Photos library to use with iCloud. Once the photos have been downloaded from iCloud to this library, you can disable iCloud Photos again and import from this library to your main photos library.

Also AirDrop can be used to transfer the modified version with added metadata.

https://discussions.apple.com/thread/253793893?answerId=257117279022#257117279022

- Matti

jimbolaya1312

I identified the problem. It's the Windows iCloud software! Uploading videos using the Windows iCloud software results in the keywords being stripped off! I would have never thought that.. I only realized this when I sent the a video (to which I added a caption using exiftool) to my Gmail account and downloaded it from the Gmail app to my iPhone Photo app - et voilá there was the caption from exiftool visible in the Photos app for the first time.

The Windows iCloud software sucks.

This command now works for me:
exiftool-12.47.exe -m -P -overwrite_original_in_place -Keys:Description="My Descriptionn Added By Exiftool" "testvideo.mov"

Instead of uploading videos via Windows iCloud to my iPhone I am now using the Synology Diskstation and the DS File iOS App. This way the description is not stripped off.

jimbolaya1312

Well, there is just one more thing..

I just realized that adding descriptions which contain German Umlaute (ü, ö or ä) results in iOS not being able to read/show the description which have been added using this command:

exiftool -m -P -overwrite_original_in_place -Keys:Description="Die Ärzte" "2022-08-24-Die-Ärzte.mov"
Warning: FileName encoding not specified - 2022-08-24-22h30m30 Die ─rzte.mov
    1 image files updated

For adding keywords with Umlaute to photos I am using the following parameters and that works fine for photos. However this does not work for videos because the Description is then: Die Ã,,rzte

-codedcharacterset=UTF8 -charset latin2
I think there are two problems to be solved:

1) How can I specify the filename encoding so that Umlaute in the filenames are OK?
2) How can I specify that Umlaute in the Keys:Description are OK?

Any help is highly appreciated!

StarGeek

Quote from: jimbolaya1312 on December 05, 2022, 05:33:59 PM1) How can I specify the filename encoding so that Umlaute in the filenames are OK?

FAQ #18 deals with Windows and accented characters.

I was never able to get accented characters to work in Windows command line until I used this StackOverflow answer.  It does have the side effect of changing fonts in the GUIs of some older programs.
* Did you read FAQ #3 and use the command listed there?
* Please use the Code button for exiftool code/output.
 
* Please include your OS, Exiftool version, and type of file you're processing (MP4, JPG, etc).

jimbolaya1312

Quote from: StarGeek on December 05, 2022, 06:00:09 PMFAQ #18 deals with Windows and accented characters.

Thanks! My first problem (Umlate in filenames) is solved. However I did not have to change the code page neither in cmd nor in intl.cpl.

I simply used this command:

exiftool -m -P -overwrite_original_in_place -charset filename=latin2 -Keys:Description="Keyword without Umlate" "2022-08-24-Die-Ärzte.mov"

However my second problem (Umlaute in Keywords) is not yet solved. Can anyone tell me how I can add Umlaute (e.g. "Die Ärzte") in Keys:Description so that iOS displays the text?

Phil Harvey

1. I am presuming you tried this (although you didn't say it specifically)?:

exiftool -keys:description="Die Ärzte" -charset latin2 FILE

2. Do you have any files where iOS displays special characters properly?

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

jimbolaya1312

Quote from: Phil Harvey on December 06, 2022, 08:25:21 PM1. I am presuming you tried this (although you didn't say it specifically)?:

exiftool -keys:description="Die Ärzte" -charset latin2 FILE

Hi Phil, thanks for your reply.

I just tried it:

exiftool -keys:description="Die Ärzte" -charset latin2 testvideo9.mov
    1 image files updated

The result is that the special character Ä is not correctly displayed in Windows and on iOS it is not visible at all:





I also tested this with chcp 65001 beforehand, no other result.

Quote from: Phil Harvey on December 06, 2022, 08:25:21 PM2. Do you have any files where iOS displays special characters properly?

Good idea! I have just recorded a video on iPhona and added "Die Ärzte" using the iPhone Photos app.
Here it is: IMG-2501-Special-Character-added-on-iPhone.MOV

I did some tests with that video: Interestingly using right-click / properties / details on Windows also does NOT display the special characters correctly but only like in above screenshot ( Die Ã,,rzte ).

I then did this:
exiftool -a -G1:7 -s IMG-2501-Special-Character-added-on-iPhone.MOV > out.txt
And searched for "Die" and found only one part where it was added:

[Keys:ID-description] Description              : Die Ärzte

Can you advise anything else I should try?

Is anybody able to add those German special characters to a MOV and it's still readable on iOS?

wywh

macOS 13.0.1 Preview.app shows correct umlauts so I guess also iOS devices will if the Keys tag works also there.

exiftool -a -G1 -s IMG-2501-Special-Character-added-on-iPhone.MOV
[Keys]          Description                     : Die Ärzte

I was surprised to hear that Windows iCloud software results in the keywords being stripped off. Have you researched it further?

https://discussions.apple.com/community/icloud/icloud_on_my_pc

https://www.apple.com/feedback/icloud.html

I have never really used iCloud Photos because I want to have control to myself and spreading photos to various cloud services can easily yield duplicates that are hard to weed out later.

...So far I have been happy to get the metadata tags work correctly on macOS Photos.app (and Preview.app and QuickTime Player.app) and have not yet paid much attention how they behave on iOS devices where the support for displaying them was only recently added.

- Matti

jimbolaya1312

Hi Matti,

no, I havent researched furhter on the iCloud Windows problem. I tested it a couple of times and the keywords in MOVs are always removed while using the iCloud Software to transfer to MOVs to iPhone. I have a workaround for this, using Synology Disk station and the iOS App DS File - this way MOVs can be transferred to iPhone without loosing keywords.

My only problem left is, that I cannot add German special characters (e.g. "Die Ärzte") as description to MOV files using exiftool in a way that iOS still displays them.

Could you maybe change the Description in my IMG-2501-Special-Character-added-on-iPhone.MOV to "Die Ärzte changed" and re-upload it? Then I would download it to my iPhone and see if the description is still displayed. If yes, then the problem is not exiftool but my Windows environment (although I already tried the StackOverflow hint from StarGeek posted earlier).

wywh

OK:

exiftool -m -P -overwrite_original_in_place -Keys:Description='Die Ärzte changed' IMG-2501-Special-Character-added-on-iPhone.MOV

[Keys]          Description                     : Die Ärzte changed

https://www.dropbox.com/s/50y32ao1win7weh/IMG-2501-Special-Character-added-on-iPhone.MOV?dl=0

- Matti

jimbolaya1312

Thanks! That worked. See screenshot below. I'm one step closer ;-)

May I ask, which operation system are you using and did you apply any changes to your OS settings like suggested here on StackOverflow?

And also, which exiftool version are you using? Maybe that is also important..