Definitions for Keys:CameraLensModel and Keys:CameraFocalLength35mmEquivalent

Started by wywh, August 20, 2024, 12:06:35 PM

Previous topic - Next topic

wywh

Would it be possible to add definitions for Keys:CameraLensModel and Keys:CameraFocalLength35mmEquivalent?

exiftool -a -G1 -s -n -Keys:All source.mov
[Keys]          CameraLensModel                 : iPhone 12 mini back camera 4.2mm f/1.6
[Keys]          CameraFocalLength35mmEquivalent : 27

[Keys]          CreationDate                    : 2024:08:11 14:30:19+03:00
[Keys]          GPSCoordinates                  : 29.9792 31.1342 138.5
[Keys]          LocationName                    : Kirdāsah, Giza, Egypt
[Keys]          LocationAccuracyHorizontal      : 110.666667
[Keys]          Make                            : Apple
[Keys]          Model                           : iPhone 12 mini
[Keys]          Software                        : 17.5.1
[Keys]          Title                           : Title
[Keys]          DisplayName                     : DisplayName
[Keys]          Description                     : Description
[Keys]          Keywords                        : Keyword 1,Keyword 2
[Keys]          UserRating                      : 4

exiftool -m -P -overwrite_original '-Keys:CameraLensModel=iPhone 12 mini back camera 4.2mm f/1.6' destination.mov
Warning: Tag 'Keys:CameraLensModel' is not defined
Nothing to do.

exiftool -m -P -overwrite_original '-Keys:CameraFocalLength35mmEquivalent=27' destination.mov
Warning: Tag 'Keys:CameraFocalLength35mmEquivalent' is not defined
Nothing to do.

- Matti

Phil Harvey

Hi Matti,

I would have to see the -v output to see the ID's for these tags.

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

wywh

I hope this helps:

exiftool -v 2024-0811-1430-19.mov
  ExifToolVersion = 12.92
  FileName = 2024-0811-1430-19.mov
  Directory = .
  FileSize = 131349215
  FileModifyDate = 1723375819
  FileAccessDate = 1724176623
  FileInodeChangeDate = 1724176632
  FilePermissions = 33152
  FileType = MOV
  FileTypeExtension = MOV
  MIMEType = video/quicktime
  FileType (SubDirectory) -->
  + [BinaryData directory, 12 bytes]
  | MajorBrand = qt 
  | MinorVersion =
  | CompatibleBrands = qt 
  Movie (SubDirectory) -->
  + [Movie directory]
  | MovieHeader (SubDirectory) -->
  | + [BinaryData directory, 100 bytes]
  | | MovieHeaderVersion = 0
  | | CreateDate = 3806220619
  | | ModifyDate = 3806220619
  | | TimeScale = 600
  | | Duration = 72751
  | | PreferredRate = 65536
  | | PreferredVolume = 256
  | | MatrixStructure = 1 0 0 0 1 0 0 0 16384
  | | PreviewTime = 0
  | | PreviewDuration = 0
  | | PosterTime = 0
  | | SelectionTime = 0
  | | SelectionDuration = 0
  | | CurrentTime = 0
  | | NextTrackID = 6
  | Track (SubDirectory) -->
  | + [Track directory]
  | | TrackHeader (SubDirectory) -->
  | | + [BinaryData directory, 84 bytes]
  | | | TrackHeaderVersion = 0
  | | | TrackCreateDate = 3806220619
  | | | TrackModifyDate = 3806220619
  | | | TrackID = 1
  | | | TrackDuration = 72751
  | | | TrackLayer = 0
  | | | TrackVolume = 0
  | | | MatrixStructure = 1 0 0 0 1 0 0 0 16384
  | | | ImageWidth = 125829120
  | | | ImageHeight = 70778880
  | | TrackAperture (SubDirectory) -->
  | | + [TrackAperture directory]
  | | | CleanApertureDimensions = 0 1920 1080
  | | | ProductionApertureDimensions = 0 1920 1080
  | | | EncodedPixelsDimensions = 0 1920 1080
  | | Unknown_edts = .elst.../.
  | | Media (SubDirectory) -->
  | | + [Media directory]
  | | | MediaHeader (SubDirectory) -->
  | | | + [BinaryData directory, 24 bytes]
  | | | | MediaHeaderVersion = 0
  | | | | MediaCreateDate = 3806220619
  | | | | MediaModifyDate = 3806220619
  | | | | MediaTimeScale = 600
  | | | | MediaDuration = 72751
  | | | | MediaLanguageCode = 21956
  | | | Handler (SubDirectory) -->
  | | | + [BinaryData directory, 41 bytes]
  | | | | HandlerClass = mhlr
  | | | | HandlerType = vide
  | | | | HandlerVendorID = appl
  | | | | HandlerDescription = .Core Media Video
  | | | MediaInfo (SubDirectory) -->
  | | | + [MediaInfo directory]
  | | | | VideoHeader (SubDirectory) -->
  | | | | + [BinaryData directory, 12 bytes]
  | | | | | GraphicsMode = 64
  | | | | | OpColor = 32768 32768 32768
  | | | | Handler (SubDirectory) -->
  | | | | + [BinaryData directory, 48 bytes]
  | | | | | HandlerClass = dhlr
  | | | | | HandlerType = alis
  | | | | | HandlerVendorID = appl
  | | | | | HandlerDescription = .Core Media Data Handler
  | | | | DataInfo (SubDirectory) -->
  | | | | + [DataInfo directory]
  | | | | | DataRef (SubDirectory) -->
  | | | | | + [DataRef directory]
  | | | | | | Unknown_alis = .
  | | | | SampleTable (SubDirectory) -->
  | | | | + [SampleTable directory]
  | | | | | VideoSampleDesc (SubDirectory) -->
  | | | | | + [BinaryData directory, 288 bytes]
  | | | | | | CompressorID = hvc1
  | | | | | | VendorID =
  | | | | | | SourceImageWidth = 1920
  | | | | | | SourceImageHeight = 1080
  | | | | | | XResolution = 72
  | | | | | | YResolution = 72
  | | | | | | CompressorName = .HEVC
  | | | | | | BitDepth = 24
  | | | | | SampleGroupDescription = .tscl.....x
  | | | | | SampleGroupDescription = .sync....
  | | | | | SampleToGroup = sync.......................................................[snip]
  | | | | | VideoFrameRate = "...........................................+.........]...[snip]
  | | | | | CompositionTimeToSample = ....H............H............H............H.....[snip]
  | | | | | CompositionToDecodeTimelineMapping = 1....I../
  | | | | | SyncSampleTable = ~...F^v..........6.N.f.~.............&.>.V.n.............[snip]
  | | | | | IdependentAndDisposableSamples =  .................... ....................[snip]
  | | | | | SampleToChunk = ...........................................................[snip]
  | | | | | SampleSizes = ...m...YOpt.....V.Y...v.N.I>..}.SwUv.....M.j..{..dK.H...].EfZ[snip]
  | | | | | ChunkOffset = ...[.=5.h..3....&.9,..3..:.g@..F..M.wU..\.pd.{kO.q..y.B..c...[snip]
  | | Meta (SubDirectory) -->
  | | + [Meta directory]
  | | | Handler (SubDirectory) -->
  | | | + [BinaryData directory, 26 bytes]
  | | | | HandlerClass =
  | | | | HandlerType = mdta
  | | | | HandlerVendorID =
  | | | | HandlerDescription =
  | | | Keys (SubDirectory) -->
  | | | + [Keys directory]
  | | | | Added ItemList Tag 1.1 = (mdta) camera.lens_model (Unknown)
  | | | | Added ItemList Tag 1.2 = (mdta) camera.focal_length.35mm_equivalent (Unknown)
  | | | | Added ItemList Tag 1.3 = (mdta) keywords
  | | | | Added ItemList Tag 1.4 = (mdta) rating.user
  | | | ItemList (SubDirectory) -->
  | | | + [ItemList directory]
  | | | | CameraLensModel-fin-FI = iPhone 12 mini back camera 4.2mm f/1.6
  | | | | CameraFocalLength35mmEquivalent-fin-FI = 27
  | Track (SubDirectory) -->
  | + [Track directory]
  | | TrackHeader (SubDirectory) -->
  | | + [BinaryData directory, 84 bytes]
  | | | TrackHeaderVersion = 0
  | | | TrackCreateDate = 3806220619
  | | | TrackModifyDate = 3806220619
  | | | TrackID = 2
  | | | TrackDuration = 72750
  | | | TrackLayer = 0
  | | | TrackVolume = 256
  | | | MatrixStructure = 1 0 0 0 1 0 0 0 16384
  | | | ImageWidth = 0
  | | | ImageHeight = 0
  | | Unknown_edts = .elst.....@.
  | | Media (SubDirectory) -->
  | | + [Media directory]
  | | | MediaHeader (SubDirectory) -->
  | | | + [BinaryData directory, 24 bytes]
  | | | | MediaHeaderVersion = 0
  | | | | MediaCreateDate = 3806220619
  | | | | MediaModifyDate = 3806220619
  | | | | MediaTimeScale = 44100
  | | | | MediaDuration = 5349376
  | | | | MediaLanguageCode = 21956
  | | | Handler (SubDirectory) -->
  | | | + [BinaryData directory, 41 bytes]
  | | | | HandlerClass = mhlr
  | | | | HandlerType = soun
  | | | | HandlerVendorID = appl
  | | | | HandlerDescription = .Core Media Audio
  | | | MediaInfo (SubDirectory) -->
  | | | + [MediaInfo directory]
  | | | | AudioHeader (SubDirectory) -->
  | | | | + [BinaryData directory, 8 bytes]
  | | | | | Balance = 0
  | | | | Handler (SubDirectory) -->
  | | | | + [BinaryData directory, 48 bytes]
  | | | | | HandlerClass = dhlr
  | | | | | HandlerType = alis
  | | | | | HandlerVendorID = appl
  | | | | | HandlerDescription = .Core Media Data Handler
  | | | | DataInfo (SubDirectory) -->
  | | | | + [DataInfo directory]
  | | | | | DataRef (SubDirectory) -->
  | | | | | + [DataRef directory]
  | | | | | | Unknown_alis = .
  | | | | SampleTable (SubDirectory) -->
  | | | | + [SampleTable directory]
  | | | | | AudioSampleDesc (SubDirectory) -->
  | | | | | + [BinaryData directory, 60 bytes]
  | | | | | | AudioFormat = mp4a
  | | | | | | AudioVendorID =
  | | | | | | AudioChannels = 2
  | | | | | | AudioBitsPerSample = 16
  | | | | | | AudioSampleRate = 44100
  | | | | | + [AudioSampleDesc directory]
  | | | | | | Wave (SubDirectory) -->
  | | | | | | + [Wave directory]
  | | | | | | | PurchaseFileFormat = mp4a
  | | | | | | | Unknown_mp4a =
  | | | | | | | Unknown_esds = ....".....@.................
  | | | | | SampleGroupDescription = .roll....
  | | | | | SampleToGroup = roll..h.
  | | | | | TimeToSampleTable = ..h.
  | | | | | SampleToChunk = ..+........................................................[snip]
  | | | | | SampleSizes = .h..".?...................!....."............................[snip]
  | | | | | ChunkOffset = ..{...|.......?...O...&..,..3Z.:o.@..F..M..T.0\..d..k".q..y.m[snip]
  | Track (SubDirectory) -->
  | + [Track directory]
  | | TrackHeader (SubDirectory) -->
  | | + [BinaryData directory, 84 bytes]
  | | | TrackHeaderVersion = 0
  | | | TrackCreateDate = 3806220619
  | | | TrackModifyDate = 3806220619
  | | | TrackID = 3
  | | | TrackDuration = 72751
  | | | TrackLayer = 0
  | | | TrackVolume = 0
  | | | MatrixStructure = 1 0 0 0 1 0 0 0 16384
  | | | ImageWidth = 0
  | | | ImageHeight = 0
  | | Unknown_edts = .elst.../.
  | | TrackRef (SubDirectory) -->
  | | + [TrackRef directory]
  | | | ContentDescribes = 1
  | | | Unknown_cdep = .
  | | Media (SubDirectory) -->
  | | + [Media directory]
  | | | MediaHeader (SubDirectory) -->
  | | | + [BinaryData directory, 24 bytes]
  | | | | MediaHeaderVersion = 0
  | | | | MediaCreateDate = 3806220619
  | | | | MediaModifyDate = 3806220619
  | | | | MediaTimeScale = 600
  | | | | MediaDuration = 72751
  | | | | MediaLanguageCode = 21956
  | | | Handler (SubDirectory) -->
  | | | + [BinaryData directory, 44 bytes]
  | | | | HandlerClass = mhlr
  | | | | HandlerType = meta
  | | | | HandlerVendorID = appl
  | | | | HandlerDescription = .Core Media Metadata
  | | | MediaInfo (SubDirectory) -->
  | | | + [MediaInfo directory]
  | | | | GenMediaHeader (SubDirectory) -->
  | | | | + [GenMediaHeader directory]
  | | | | | GenMediaInfo (SubDirectory) -->
  | | | | | + [BinaryData directory, 16 bytes]
  | | | | | | GenMediaVersion = 0
  | | | | | | GenFlags = 0 0 0
  | | | | | | GenGraphicsMode = 64
  | | | | | | GenOpColor = 32768 32768 32768
  | | | | | | GenBalance = 0
  | | | | Handler (SubDirectory) -->
  | | | | + [BinaryData directory, 48 bytes]
  | | | | | HandlerClass = dhlr
  | | | | | HandlerType = alis
  | | | | | HandlerVendorID = appl
  | | | | | HandlerDescription = .Core Media Data Handler
  | | | | DataInfo (SubDirectory) -->
  | | | | + [DataInfo directory]
  | | | | | DataRef (SubDirectory) -->
  | | | | | + [DataRef directory]
  | | | | | | Unknown_alis = .
  | | | | SampleTable (SubDirectory) -->
  | | | | + [SampleTable directory]
  | | | | | MetaSampleDesc (SubDirectory) -->
  | | | | | + [BinaryData directory, 24 bytes]
  | | | | | | MetaFormat = mebx
  | | | | | | MetaType = .ekeys
  | | | | | + [MetaSampleDesc directory]
  | | | | | | Keys (SubDirectory) -->
  | | | | | Warning = [minor] The ExtractEmbedded option may find more tags in the media data
  | | | | | TimeToSampleTable = ..../
  | | | | | SampleToChunk = ....
  | | | | | SampleSizes = ..
  | | | | | ChunkOffset = ....v
  | Track (SubDirectory) -->
  | + [Track directory]
  | | TrackHeader (SubDirectory) -->
  | | + [BinaryData directory, 84 bytes]
  | | | TrackHeaderVersion = 0
  | | | TrackCreateDate = 3806220619
  | | | TrackModifyDate = 3806220619
  | | | TrackID = 4
  | | | TrackDuration = 72751
  | | | TrackLayer = 0
  | | | TrackVolume = 0
  | | | MatrixStructure = 1 0 0 0 1 0 0 0 16384
  | | | ImageWidth = 0
  | | | ImageHeight = 0
  | | Unknown_edts = .elst.../.
  | | TrackRef (SubDirectory) -->
  | | + [TrackRef directory]
  | | | ContentDescribes = 1
  | | | Unknown_cdep = .
  | | Media (SubDirectory) -->
  | | + [Media directory]
  | | | MediaHeader (SubDirectory) -->
  | | | + [BinaryData directory, 24 bytes]
  | | | | MediaHeaderVersion = 0
  | | | | MediaCreateDate = 3806220619
  | | | | MediaModifyDate = 3806220619
  | | | | MediaTimeScale = 600
  | | | | MediaDuration = 72751
  | | | | MediaLanguageCode = 21956
  | | | Handler (SubDirectory) -->
  | | | + [BinaryData directory, 44 bytes]
  | | | | HandlerClass = mhlr
  | | | | HandlerType = meta
  | | | | HandlerVendorID = appl
  | | | | HandlerDescription = .Core Media Metadata
  | | | MediaInfo (SubDirectory) -->
  | | | + [MediaInfo directory]
  | | | | GenMediaHeader (SubDirectory) -->
  | | | | + [GenMediaHeader directory]
  | | | | | GenMediaInfo (SubDirectory) -->
  | | | | | + [BinaryData directory, 16 bytes]
  | | | | | | GenMediaVersion = 0
  | | | | | | GenFlags = 0 0 0
  | | | | | | GenGraphicsMode = 64
  | | | | | | GenOpColor = 32768 32768 32768
  | | | | | | GenBalance = 0
  | | | | Handler (SubDirectory) -->
  | | | | + [BinaryData directory, 48 bytes]
  | | | | | HandlerClass = dhlr
  | | | | | HandlerType = alis
  | | | | | HandlerVendorID = appl
  | | | | | HandlerDescription = .Core Media Data Handler
  | | | | DataInfo (SubDirectory) -->
  | | | | + [DataInfo directory]
  | | | | | DataRef (SubDirectory) -->
  | | | | | + [DataRef directory]
  | | | | | | Unknown_alis = .
  | | | | SampleTable (SubDirectory) -->
  | | | | + [SampleTable directory]
  | | | | | MetaSampleDesc (SubDirectory) -->
  | | | | | + [BinaryData directory, 24 bytes]
  | | | | | | MetaFormat = mebx
  | | | | | | MetaType = ...keys
  | | | | | + [MetaSampleDesc directory]
  | | | | | | Keys (SubDirectory) -->
  | | | | | | Unknown_lidp = .
  | | | | | | Unknown_lidl = ......
  | | | | | TimeToSampleTable = %........W....d...q....W...........5.......x........(..[snip]
  | | | | | SampleToChunk = U..........................................................[snip]
  | | | | | SampleSizes = ...ddddddddddddd.dddddddddddddddddddddddddddddddddddddddddddd[snip]
  | | | | | ChunkOffset = V,.),.13Ju@..@..F..MuOT.@\.jd..k..q|..5e.aq....qE..n..@.dY..&[snip]
  | Track (SubDirectory) -->
  | + [Track directory]
  | | TrackHeader (SubDirectory) -->
  | | + [BinaryData directory, 84 bytes]
  | | | TrackHeaderVersion = 0
  | | | TrackCreateDate = 3806220619
  | | | TrackModifyDate = 3806220619
  | | | TrackID = 5
  | | | TrackDuration = 72751
  | | | TrackLayer = 0
  | | | TrackVolume = 0
  | | | MatrixStructure = 1 0 0 0 1 0 0 0 16384
  | | | ImageWidth = 0
  | | | ImageHeight = 0
  | | Unknown_edts = .elst.../.
  | | TrackRef (SubDirectory) -->
  | | + [TrackRef directory]
  | | | ContentDescribes = 1
  | | | Unknown_cdep = .
  | | Media (SubDirectory) -->
  | | + [Media directory]
  | | | MediaHeader (SubDirectory) -->
  | | | + [BinaryData directory, 24 bytes]
  | | | | MediaHeaderVersion = 0
  | | | | MediaCreateDate = 3806220619
  | | | | MediaModifyDate = 3806220619
  | | | | MediaTimeScale = 600
  | | | | MediaDuration = 72751
  | | | | MediaLanguageCode = 21956
  | | | Handler (SubDirectory) -->
  | | | + [BinaryData directory, 44 bytes]
  | | | | HandlerClass = mhlr
  | | | | HandlerType = meta
  | | | | HandlerVendorID = appl
  | | | | HandlerDescription = .Core Media Metadata
  | | | MediaInfo (SubDirectory) -->
  | | | + [MediaInfo directory]
  | | | | GenMediaHeader (SubDirectory) -->
  | | | | + [GenMediaHeader directory]
  | | | | | GenMediaInfo (SubDirectory) -->
  | | | | | + [BinaryData directory, 16 bytes]
  | | | | | | GenMediaVersion = 0
  | | | | | | GenFlags = 0 0 0
  | | | | | | GenGraphicsMode = 64
  | | | | | | GenOpColor = 32768 32768 32768
  | | | | | | GenBalance = 0
  | | | | Handler (SubDirectory) -->
  | | | | + [BinaryData directory, 48 bytes]
  | | | | | HandlerClass = dhlr
  | | | | | HandlerType = alis
  | | | | | HandlerVendorID = appl
  | | | | | HandlerDescription = .Core Media Data Handler
  | | | | DataInfo (SubDirectory) -->
  | | | | + [DataInfo directory]
  | | | | | DataRef (SubDirectory) -->
  | | | | | + [DataRef directory]
  | | | | | | Unknown_alis = .
  | | | | SampleTable (SubDirectory) -->
  | | | | + [SampleTable directory]
  | | | | | MetaSampleDesc (SubDirectory) -->
  | | | | | + [BinaryData directory, 24 bytes]
  | | | | | | MetaFormat = mebx
  | | | | | | MetaType = ..5keys
  | | | | | + [MetaSampleDesc directory]
  | | | | | | Keys (SubDirectory) -->
  | | | | | TimeToSampleTable = "...........................................+.........][snip]
  | | | | | SampleToChunk = ...........................................................[snip]
  | | | | | SampleSizes = .............................................................[snip]
  | | | | | ChunkOffset = ...J.9......I&..,.]3N]:e.@..F..MzcT..\.~d.lk..q}Oy.......D..B[snip]
  | Meta (SubDirectory) -->
  | + [Meta directory]
  | | Handler (SubDirectory) -->
  | | + [BinaryData directory, 26 bytes]
  | | | HandlerClass =
  | | | HandlerType = mdta
  | | | HandlerVendorID =
  | | | HandlerDescription =
  | | Keys (SubDirectory) -->
  | | + [Keys directory]
  | | | Added ItemList Tag 2.1 = (mdta) location.accuracy.horizontal
  | | | Added ItemList Tag 2.2 = (mdta) location.ISO6709
  | | | Added ItemList Tag 2.3 = (mdta) make
  | | | Added ItemList Tag 2.4 = (mdta) model
  | | | Added ItemList Tag 2.5 = (mdta) software
  | | | Added ItemList Tag 2.6 = (mdta) creationdate
  | | | Added ItemList Tag 2.7 = (mdta) keywords
  | | | Added ItemList Tag 2.8 = (mdta) rating.user
  | | ItemList (SubDirectory) -->
  | | + [ItemList directory]
  | | | LocationAccuracyHorizontal = 110.666667
  | | | GPSCoordinates = +xx.xxxx+xxx.xxxx+xxx.xxx/
  | | | Make = Apple
  | | | Model = iPhone 12 mini
  | | | Software = 17.5.1
  | | | CreationDate = 2024-08-11T14:30:19+0300
  | | | Keywords = xx
  | | | UserRating = 4
  MediaDataSize = 131251956
  MediaDataOffset = 97259
  MediaData

- Matti

Phil Harvey

Done.  ExifTool 12.93 is available with support for these tags.

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

wywh

Quote from: Phil Harvey on August 20, 2024, 02:55:06 PMExifTool 12.93 is available with support for these tags.

Somehow v12.93 still fails to insert those tags although they no longer are listed as (Unknown). I really need to insert them to re-encoded .m4v but it fails also to .mov:

exiftool -m -P -overwrite_original '-Keys:CameraLensModel=iPhone 12 mini back camera 4.2mm f/1.6' movie.mov
Warning: Tag 'Keys:CameraLensModel' is not defined
Nothing to do.

exiftool -m -P -overwrite_original '-Keys:CameraFocalLength35mmEquivalent=27' movie.mov
Warning: Tag 'Keys:CameraFocalLength35mmEquivalent' is not defined
Nothing to do.

exiftool -v iphone.mov
  ExifToolVersion = 12.93
  FileName = iphone.mov
  Directory = .
  FileSize = 131349215
  FileModifyDate = 1723375819
  FileAccessDate = 1724184330
  FileInodeChangeDate = 1724184329
  FilePermissions = 33152
  FileType = MOV
  FileTypeExtension = MOV
  MIMEType = video/quicktime
  FileType (SubDirectory) -->
  + [BinaryData directory, 12 bytes]
  | MajorBrand = qt 
  | MinorVersion =
  | CompatibleBrands = qt 
  Movie (SubDirectory) -->
  + [Movie directory]
  | MovieHeader (SubDirectory) -->
  | + [BinaryData directory, 100 bytes]
  | | MovieHeaderVersion = 0
  | | CreateDate = 3806220619
  | | ModifyDate = 3806220619
  | | TimeScale = 600
  | | Duration = 72751
  | | PreferredRate = 65536
  | | PreferredVolume = 256
  | | MatrixStructure = 1 0 0 0 1 0 0 0 16384
  | | PreviewTime = 0
  | | PreviewDuration = 0
  | | PosterTime = 0
  | | SelectionTime = 0
  | | SelectionDuration = 0
  | | CurrentTime = 0
  | | NextTrackID = 6
  | Track (SubDirectory) -->
  | + [Track directory]
  | | TrackHeader (SubDirectory) -->
  | | + [BinaryData directory, 84 bytes]
  | | | TrackHeaderVersion = 0
  | | | TrackCreateDate = 3806220619
  | | | TrackModifyDate = 3806220619
  | | | TrackID = 1
  | | | TrackDuration = 72751
  | | | TrackLayer = 0
  | | | TrackVolume = 0
  | | | MatrixStructure = 1 0 0 0 1 0 0 0 16384
  | | | ImageWidth = 125829120
  | | | ImageHeight = 70778880
  | | TrackAperture (SubDirectory) -->
  | | + [TrackAperture directory]
  | | | CleanApertureDimensions = 0 1920 1080
  | | | ProductionApertureDimensions = 0 1920 1080
  | | | EncodedPixelsDimensions = 0 1920 1080
  | | Unknown_edts = .elst.../.
  | | Media (SubDirectory) -->
  | | + [Media directory]
  | | | MediaHeader (SubDirectory) -->
  | | | + [BinaryData directory, 24 bytes]
  | | | | MediaHeaderVersion = 0
  | | | | MediaCreateDate = 3806220619
  | | | | MediaModifyDate = 3806220619
  | | | | MediaTimeScale = 600
  | | | | MediaDuration = 72751
  | | | | MediaLanguageCode = 21956
  | | | Handler (SubDirectory) -->
  | | | + [BinaryData directory, 41 bytes]
  | | | | HandlerClass = mhlr
  | | | | HandlerType = vide
  | | | | HandlerVendorID = appl
  | | | | HandlerDescription = .Core Media Video
  | | | MediaInfo (SubDirectory) -->
  | | | + [MediaInfo directory]
  | | | | VideoHeader (SubDirectory) -->
  | | | | + [BinaryData directory, 12 bytes]
  | | | | | GraphicsMode = 64
  | | | | | OpColor = 32768 32768 32768
  | | | | Handler (SubDirectory) -->
  | | | | + [BinaryData directory, 48 bytes]
  | | | | | HandlerClass = dhlr
  | | | | | HandlerType = alis
  | | | | | HandlerVendorID = appl
  | | | | | HandlerDescription = .Core Media Data Handler
  | | | | DataInfo (SubDirectory) -->
  | | | | + [DataInfo directory]
  | | | | | DataRef (SubDirectory) -->
  | | | | | + [DataRef directory]
  | | | | | | Unknown_alis = .
  | | | | SampleTable (SubDirectory) -->
  | | | | + [SampleTable directory]
  | | | | | VideoSampleDesc (SubDirectory) -->
  | | | | | + [BinaryData directory, 288 bytes]
  | | | | | | CompressorID = hvc1
  | | | | | | VendorID =
  | | | | | | SourceImageWidth = 1920
  | | | | | | SourceImageHeight = 1080
  | | | | | | XResolution = 72
  | | | | | | YResolution = 72
  | | | | | | CompressorName = .HEVC
  | | | | | | BitDepth = 24
  | | | | | SampleGroupDescription = .tscl.....x
  | | | | | SampleGroupDescription = .sync....
  | | | | | SampleToGroup = sync.......................................................[snip]
  | | | | | VideoFrameRate = "...........................................+.........]...[snip]
  | | | | | CompositionTimeToSample = ....H............H............H............H.....[snip]
  | | | | | CompositionToDecodeTimelineMapping = 1....I../
  | | | | | SyncSampleTable = ~...F^v..........6.N.f.~.............&.>.V.n.............[snip]
  | | | | | IdependentAndDisposableSamples =  .................... ....................[snip]
  | | | | | SampleToChunk = ...........................................................[snip]
  | | | | | SampleSizes = ...m...YOpt.....V.Y...v.N.I>..}.SwUv.....M.j..{..dK.H...].EfZ[snip]
  | | | | | ChunkOffset = ...[.=5.h..3....&.9,..3..:.g@..F..M.wU..\.pd.{kO.q..y.B..c...[snip]
  | | Meta (SubDirectory) -->
  | | + [Meta directory]
  | | | Handler (SubDirectory) -->
  | | | + [BinaryData directory, 26 bytes]
  | | | | HandlerClass =
  | | | | HandlerType = mdta
  | | | | HandlerVendorID =
  | | | | HandlerDescription =
  | | | Keys (SubDirectory) -->
  | | | + [Keys directory]
  | | | | Added ItemList Tag 1.1 = (mdta) camera.lens_model
  | | | | Added ItemList Tag 1.2 = (mdta) camera.focal_length.35mm_equivalent
  | | | | Added ItemList Tag 1.3 = (mdta) keywords
  | | | | Added ItemList Tag 1.4 = (mdta) rating.user
  | | | ItemList (SubDirectory) -->
  | | | + [ItemList directory]
  | | | | LensModel-fin-FI = iPhone 12 mini back camera 4.2mm f/1.6
  | | | | FocalLengthIn35mmFormat-fin-FI = 27
  | Track (SubDirectory) -->
  | + [Track directory]
  | | TrackHeader (SubDirectory) -->
  | | + [BinaryData directory, 84 bytes]
  | | | TrackHeaderVersion = 0
  | | | TrackCreateDate = 3806220619
  | | | TrackModifyDate = 3806220619
  | | | TrackID = 2
  | | | TrackDuration = 72750
  | | | TrackLayer = 0
  | | | TrackVolume = 256
  | | | MatrixStructure = 1 0 0 0 1 0 0 0 16384
  | | | ImageWidth = 0
  | | | ImageHeight = 0
  | | Unknown_edts = .elst.....@.
  | | Media (SubDirectory) -->
  | | + [Media directory]
  | | | MediaHeader (SubDirectory) -->
  | | | + [BinaryData directory, 24 bytes]
  | | | | MediaHeaderVersion = 0
  | | | | MediaCreateDate = 3806220619
  | | | | MediaModifyDate = 3806220619
  | | | | MediaTimeScale = 44100
  | | | | MediaDuration = 5349376
  | | | | MediaLanguageCode = 21956
  | | | Handler (SubDirectory) -->
  | | | + [BinaryData directory, 41 bytes]
  | | | | HandlerClass = mhlr
  | | | | HandlerType = soun
  | | | | HandlerVendorID = appl
  | | | | HandlerDescription = .Core Media Audio
  | | | MediaInfo (SubDirectory) -->
  | | | + [MediaInfo directory]
  | | | | AudioHeader (SubDirectory) -->
  | | | | + [BinaryData directory, 8 bytes]
  | | | | | Balance = 0
  | | | | Handler (SubDirectory) -->
  | | | | + [BinaryData directory, 48 bytes]
  | | | | | HandlerClass = dhlr
  | | | | | HandlerType = alis
  | | | | | HandlerVendorID = appl
  | | | | | HandlerDescription = .Core Media Data Handler
  | | | | DataInfo (SubDirectory) -->
  | | | | + [DataInfo directory]
  | | | | | DataRef (SubDirectory) -->
  | | | | | + [DataRef directory]
  | | | | | | Unknown_alis = .
  | | | | SampleTable (SubDirectory) -->
  | | | | + [SampleTable directory]
  | | | | | AudioSampleDesc (SubDirectory) -->
  | | | | | + [BinaryData directory, 60 bytes]
  | | | | | | AudioFormat = mp4a
  | | | | | | AudioVendorID =
  | | | | | | AudioChannels = 2
  | | | | | | AudioBitsPerSample = 16
  | | | | | | AudioSampleRate = 44100
  | | | | | + [AudioSampleDesc directory]
  | | | | | | Wave (SubDirectory) -->
  | | | | | | + [Wave directory]
  | | | | | | | PurchaseFileFormat = mp4a
  | | | | | | | Unknown_mp4a =
  | | | | | | | Unknown_esds = ....".....@.................
  | | | | | SampleGroupDescription = .roll....
  | | | | | SampleToGroup = roll..h.
  | | | | | TimeToSampleTable = ..h.
  | | | | | SampleToChunk = ..+........................................................[snip]
  | | | | | SampleSizes = .h..".?...................!....."............................[snip]
  | | | | | ChunkOffset = ..{...|.......?...O...&..,..3Z.:o.@..F..M..T.0\..d..k".q..y.m[snip]
  | Track (SubDirectory) -->
  | + [Track directory]
  | | TrackHeader (SubDirectory) -->
  | | + [BinaryData directory, 84 bytes]
  | | | TrackHeaderVersion = 0
  | | | TrackCreateDate = 3806220619
  | | | TrackModifyDate = 3806220619
  | | | TrackID = 3
  | | | TrackDuration = 72751
  | | | TrackLayer = 0
  | | | TrackVolume = 0
  | | | MatrixStructure = 1 0 0 0 1 0 0 0 16384
  | | | ImageWidth = 0
  | | | ImageHeight = 0
  | | Unknown_edts = .elst.../.
  | | TrackRef (SubDirectory) -->
  | | + [TrackRef directory]
  | | | ContentDescribes = 1
  | | | Unknown_cdep = .
  | | Media (SubDirectory) -->
  | | + [Media directory]
  | | | MediaHeader (SubDirectory) -->
  | | | + [BinaryData directory, 24 bytes]
  | | | | MediaHeaderVersion = 0
  | | | | MediaCreateDate = 3806220619
  | | | | MediaModifyDate = 3806220619
  | | | | MediaTimeScale = 600
  | | | | MediaDuration = 72751
  | | | | MediaLanguageCode = 21956
  | | | Handler (SubDirectory) -->
  | | | + [BinaryData directory, 44 bytes]
  | | | | HandlerClass = mhlr
  | | | | HandlerType = meta
  | | | | HandlerVendorID = appl
  | | | | HandlerDescription = .Core Media Metadata
  | | | MediaInfo (SubDirectory) -->
  | | | + [MediaInfo directory]
  | | | | GenMediaHeader (SubDirectory) -->
  | | | | + [GenMediaHeader directory]
  | | | | | GenMediaInfo (SubDirectory) -->
  | | | | | + [BinaryData directory, 16 bytes]
  | | | | | | GenMediaVersion = 0
  | | | | | | GenFlags = 0 0 0
  | | | | | | GenGraphicsMode = 64
  | | | | | | GenOpColor = 32768 32768 32768
  | | | | | | GenBalance = 0
  | | | | Handler (SubDirectory) -->
  | | | | + [BinaryData directory, 48 bytes]
  | | | | | HandlerClass = dhlr
  | | | | | HandlerType = alis
  | | | | | HandlerVendorID = appl
  | | | | | HandlerDescription = .Core Media Data Handler
  | | | | DataInfo (SubDirectory) -->
  | | | | + [DataInfo directory]
  | | | | | DataRef (SubDirectory) -->
  | | | | | + [DataRef directory]
  | | | | | | Unknown_alis = .
  | | | | SampleTable (SubDirectory) -->
  | | | | + [SampleTable directory]
  | | | | | MetaSampleDesc (SubDirectory) -->
  | | | | | + [BinaryData directory, 24 bytes]
  | | | | | | MetaFormat = mebx
  | | | | | | MetaType = .ekeys
  | | | | | + [MetaSampleDesc directory]
  | | | | | | Keys (SubDirectory) -->
  | | | | | Warning = [minor] The ExtractEmbedded option may find more tags in the media data
  | | | | | TimeToSampleTable = ..../
  | | | | | SampleToChunk = ....
  | | | | | SampleSizes = ..
  | | | | | ChunkOffset = ....v
  | Track (SubDirectory) -->
  | + [Track directory]
  | | TrackHeader (SubDirectory) -->
  | | + [BinaryData directory, 84 bytes]
  | | | TrackHeaderVersion = 0
  | | | TrackCreateDate = 3806220619
  | | | TrackModifyDate = 3806220619
  | | | TrackID = 4
  | | | TrackDuration = 72751
  | | | TrackLayer = 0
  | | | TrackVolume = 0
  | | | MatrixStructure = 1 0 0 0 1 0 0 0 16384
  | | | ImageWidth = 0
  | | | ImageHeight = 0
  | | Unknown_edts = .elst.../.
  | | TrackRef (SubDirectory) -->
  | | + [TrackRef directory]
  | | | ContentDescribes = 1
  | | | Unknown_cdep = .
  | | Media (SubDirectory) -->
  | | + [Media directory]
  | | | MediaHeader (SubDirectory) -->
  | | | + [BinaryData directory, 24 bytes]
  | | | | MediaHeaderVersion = 0
  | | | | MediaCreateDate = 3806220619
  | | | | MediaModifyDate = 3806220619
  | | | | MediaTimeScale = 600
  | | | | MediaDuration = 72751
  | | | | MediaLanguageCode = 21956
  | | | Handler (SubDirectory) -->
  | | | + [BinaryData directory, 44 bytes]
  | | | | HandlerClass = mhlr
  | | | | HandlerType = meta
  | | | | HandlerVendorID = appl
  | | | | HandlerDescription = .Core Media Metadata
  | | | MediaInfo (SubDirectory) -->
  | | | + [MediaInfo directory]
  | | | | GenMediaHeader (SubDirectory) -->
  | | | | + [GenMediaHeader directory]
  | | | | | GenMediaInfo (SubDirectory) -->
  | | | | | + [BinaryData directory, 16 bytes]
  | | | | | | GenMediaVersion = 0
  | | | | | | GenFlags = 0 0 0
  | | | | | | GenGraphicsMode = 64
  | | | | | | GenOpColor = 32768 32768 32768
  | | | | | | GenBalance = 0
  | | | | Handler (SubDirectory) -->
  | | | | + [BinaryData directory, 48 bytes]
  | | | | | HandlerClass = dhlr
  | | | | | HandlerType = alis
  | | | | | HandlerVendorID = appl
  | | | | | HandlerDescription = .Core Media Data Handler
  | | | | DataInfo (SubDirectory) -->
  | | | | + [DataInfo directory]
  | | | | | DataRef (SubDirectory) -->
  | | | | | + [DataRef directory]
  | | | | | | Unknown_alis = .
  | | | | SampleTable (SubDirectory) -->
  | | | | + [SampleTable directory]
  | | | | | MetaSampleDesc (SubDirectory) -->
  | | | | | + [BinaryData directory, 24 bytes]
  | | | | | | MetaFormat = mebx
  | | | | | | MetaType = ...keys
  | | | | | + [MetaSampleDesc directory]
  | | | | | | Keys (SubDirectory) -->
  | | | | | | Unknown_lidp = .
  | | | | | | Unknown_lidl = ......
  | | | | | TimeToSampleTable = %........W....d...q....W...........5.......x........(..[snip]
  | | | | | SampleToChunk = U..........................................................[snip]
  | | | | | SampleSizes = ...ddddddddddddd.dddddddddddddddddddddddddddddddddddddddddddd[snip]
  | | | | | ChunkOffset = V,.),.13Ju@..@..F..MuOT.@\.jd..k..q|..5e.aq....qE..n..@.dY..&[snip]
  | Track (SubDirectory) -->
  | + [Track directory]
  | | TrackHeader (SubDirectory) -->
  | | + [BinaryData directory, 84 bytes]
  | | | TrackHeaderVersion = 0
  | | | TrackCreateDate = 3806220619
  | | | TrackModifyDate = 3806220619
  | | | TrackID = 5
  | | | TrackDuration = 72751
  | | | TrackLayer = 0
  | | | TrackVolume = 0
  | | | MatrixStructure = 1 0 0 0 1 0 0 0 16384
  | | | ImageWidth = 0
  | | | ImageHeight = 0
  | | Unknown_edts = .elst.../.
  | | TrackRef (SubDirectory) -->
  | | + [TrackRef directory]
  | | | ContentDescribes = 1
  | | | Unknown_cdep = .
  | | Media (SubDirectory) -->
  | | + [Media directory]
  | | | MediaHeader (SubDirectory) -->
  | | | + [BinaryData directory, 24 bytes]
  | | | | MediaHeaderVersion = 0
  | | | | MediaCreateDate = 3806220619
  | | | | MediaModifyDate = 3806220619
  | | | | MediaTimeScale = 600
  | | | | MediaDuration = 72751
  | | | | MediaLanguageCode = 21956
  | | | Handler (SubDirectory) -->
  | | | + [BinaryData directory, 44 bytes]
  | | | | HandlerClass = mhlr
  | | | | HandlerType = meta
  | | | | HandlerVendorID = appl
  | | | | HandlerDescription = .Core Media Metadata
  | | | MediaInfo (SubDirectory) -->
  | | | + [MediaInfo directory]
  | | | | GenMediaHeader (SubDirectory) -->
  | | | | + [GenMediaHeader directory]
  | | | | | GenMediaInfo (SubDirectory) -->
  | | | | | + [BinaryData directory, 16 bytes]
  | | | | | | GenMediaVersion = 0
  | | | | | | GenFlags = 0 0 0
  | | | | | | GenGraphicsMode = 64
  | | | | | | GenOpColor = 32768 32768 32768
  | | | | | | GenBalance = 0
  | | | | Handler (SubDirectory) -->
  | | | | + [BinaryData directory, 48 bytes]
  | | | | | HandlerClass = dhlr
  | | | | | HandlerType = alis
  | | | | | HandlerVendorID = appl
  | | | | | HandlerDescription = .Core Media Data Handler
  | | | | DataInfo (SubDirectory) -->
  | | | | + [DataInfo directory]
  | | | | | DataRef (SubDirectory) -->
  | | | | | + [DataRef directory]
  | | | | | | Unknown_alis = .
  | | | | SampleTable (SubDirectory) -->
  | | | | + [SampleTable directory]
  | | | | | MetaSampleDesc (SubDirectory) -->
  | | | | | + [BinaryData directory, 24 bytes]
  | | | | | | MetaFormat = mebx
  | | | | | | MetaType = ..5keys
  | | | | | + [MetaSampleDesc directory]
  | | | | | | Keys (SubDirectory) -->
  | | | | | TimeToSampleTable = "...........................................+.........][snip]
  | | | | | SampleToChunk = ...........................................................[snip]
  | | | | | SampleSizes = .............................................................[snip]
  | | | | | ChunkOffset = ...J.9......I&..,.]3N]:e.@..F..MzcT..\.~d.lk..q}Oy.......D..B[snip]
  | Meta (SubDirectory) -->
  | + [Meta directory]
  | | Handler (SubDirectory) -->
  | | + [BinaryData directory, 26 bytes]
  | | | HandlerClass =
  | | | HandlerType = mdta
  | | | HandlerVendorID =
  | | | HandlerDescription =
  | | Keys (SubDirectory) -->
  | | + [Keys directory]
  | | | Added ItemList Tag 2.1 = (mdta) location.accuracy.horizontal
  | | | Added ItemList Tag 2.2 = (mdta) location.ISO6709
  | | | Added ItemList Tag 2.3 = (mdta) make
  | | | Added ItemList Tag 2.4 = (mdta) model
  | | | Added ItemList Tag 2.5 = (mdta) software
  | | | Added ItemList Tag 2.6 = (mdta) creationdate
  | | | Added ItemList Tag 2.7 = (mdta) keywords
  | | | Added ItemList Tag 2.8 = (mdta) rating.user
  | | ItemList (SubDirectory) -->
  | | + [ItemList directory]
  | | | LocationAccuracyHorizontal = 110.666667
  | | | GPSCoordinates = +xx.xxxx+xxx.xxxx+xxx.xxx/
  | | | Make = Apple
  | | | Model = iPhone 12 mini
  | | | Software = 17.5.1
  | | | CreationDate = 2024-08-11T14:30:19+0300
  | | | Keywords = xx
  | | | UserRating = 4
  MediaDataSize = 131251956
  MediaDataOffset = 97259
  MediaData

- Matti

Phil Harvey

Hi Matti.  You're using the wrong tag names.  Look at the ExifTool -s output for the correct ones or check the QuickTime Keys tag name documentation.

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

wywh

Quote from: Phil Harvey on August 20, 2024, 04:17:19 PMYou're using the wrong tag names

Oh doh! I did not notice that updating to v12.93 slightly changed the tag names:

exiftool -ver
12.92
exiftool -a -G1 -s -n -Keys:All 2024-0811-1430-19.mov
[Keys]          CameraLensModel                 : iPhone 12 mini back camera 4.2mm f/1.6
[Keys]          CameraFocalLength35mmEquivalent : 27

exiftool -ver
12.93
exiftool -a -G1 -s -n -Keys:All 2024-0811-1430-19.mov
[Keys]          LensModel                       : iPhone 12 mini back camera 4.2mm f/1.6
[Keys]          FocalLengthIn35mmFormat         : 27

-> But those tags seem to go to incorrect places and Photos.app does not read them like it does in iPhone movies:

exiftool -m -P -overwrite_original '-Keys:LensModel=iPhone 12 mini back camera 4.2mm f/1.6' test.mov
exiftool -m -P -overwrite_original '-Keys:FocalLengthIn35mmFormat=27' test.mov

exiftool -a -G5 -s -n -Keys:All test.mov
[MOV-Movie-Meta-Keys] LensModel                 : iPhone 12 mini back camera 4.2mm f/1.6
[MOV-Movie-Meta-Keys] FocalLengthIn35mmFormat   : 27

In the iPhone just those two Keys tags are in slightly different place than all other Keys tags (MOV vs MOV-Movie-Meta-Keys):

exiftool -a -G5 -s -n -Keys:All iphone.mov
[MOV-Movie-Meta-Keys] LocationAccuracyHorizontal: 110.666667
[MOV-Movie-Meta-Keys] GPSCoordinates            : xx.xxxx xx.xxxx xx.xxx
[MOV-Movie-Meta-Keys] Make                      : Apple
[MOV-Movie-Meta-Keys] Model                     : iPhone 12 mini
[MOV-Movie-Meta-Keys] Software                  : 17.5.1
[MOV-Movie-Meta-Keys] CreationDate              : 2024:08:11 14:30:19+03:00
[MOV-Movie-Meta-Keys] Keywords                  : xx
[MOV-Movie-Meta-Keys] UserRating                : 4
[MOV]           LensModel                       : iPhone 12 mini back camera 4.2mm f/1.6
[MOV]           FocalLengthIn35mmFormat         : 27

Those two tags seem to appear in iOS/iPadOS 17.

- Matti

Phil Harvey

Movie metadata is a real pain.  Could you send me a sample so I can take a look?  philharvey66 at gmail.com

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

Phil Harvey

I got your sample.  I see this:

> exiftool IMG_0619.MOV "-lensmodel*" -G5
[MOV-Movie-Track-Meta-Keys] Lens Model (und-FI) : iPad Air (5th generation) back camera 3mm f/1.8
[MOV]           Lens Model                      : iPad Air (5th generation) back camera 3mm f/1.8

The LensModel information is unfortunately stored at the track level, while ExifTool can create only top-level metadata in MOV videos.

The metadata path "[MOV]" is actually wrong -- I'll fix this.  This default-languge LensModel tag doesn't actually exist in the file.  It is a synthesized tag used for convenience only since otherwise you would have to specify LensModel-und-FI.  I should change the reported metadata path for this and make it either the same as the actual tag, or something like "Synthesized", I'm not sure which is better. [Edit: I've gone with the former.]

- Phil

Edit: This could be intentional by Apple.  The tags written to the video track are associated only with the camera optics, so it is true they aren't related to other tracks.  The distinction is fine, and one could easily see the bright young programmers at Apple putting the metadata there and totally ignoring the inconvenience that this would cause for everyone else.
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

wywh

In exiftool 12.93 it is possible to copy LensModel and FocalLengthIn35mmFormat to a .mov as a block (?) like this:

exiftool -m -tagsFromFile IMG_0619.MOV -All test.mov                   

exiftool -a -G5 -s '-Model*' '-LensModel*' '-FocalLengthIn35mmFormat*' .

======== ./IMG_0619.MOV
[MOV-Movie-Meta-Keys] Model                     : iPad Air (5th generation)
[MOV-Movie-Track-Meta-Keys] LensModel-und-FI    : iPad Air (5th generation) back camera 3mm f/1.8
[MOV-Movie-Track-Meta-Keys] FocalLengthIn35mmFormat-und-FI: 30 mm
[MOV]           LensModel                       : iPad Air (5th generation) back camera 3mm f/1.8
[MOV]           FocalLengthIn35mmFormat         : 30 mm

======== ./test.mov
[MOV-Movie-UserData] Model                      : iPad Air (5th generation)
[MOV-Movie-UserData-XMP] Model                  : iPad Air (5th generation)
[MOV-Movie-Meta-Keys] LensModel-und-FI          : iPad Air (5th generation) back camera 3mm f/1.8
[MOV-Movie-UserData-XMP] LensModel              : iPad Air (5th generation) back camera 3mm f/1.8
[MOV-Movie-Meta-Keys] FocalLengthIn35mmFormat-und-FI: 30 mm
[MOV-Movie-UserData-XMP] FocalLengthIn35mmFormat: 30 mm
[MOV]           LensModel                       : iPad Air (5th generation) back camera 3mm f/1.8
[MOV]           FocalLengthIn35mmFormat         : 30 mm

But macOS Sonoma 14.6.1 Photos.app does not import those LensModel and FocalLengthIn35mmFormat tags. BTW Photos.app prefers Keys and imports UserData in a much more limited manner and ignores all XMP. Somehow tagsFromFile does not copy Keys:CreationDate so QuickTime:CreateDate that is +1 second is used instead. This tagsFromFile command also writes GPS to XMP which Photos.app ignores. (screen captures from Photos.app ):

Screenshot 2024-08-22 at 14.55.51 GMT+3.png
Screenshot 2024-08-22 at 14.56.01 GMT+3.png

> The tags written to the video track are associated only with the
> camera optics, so it is true they aren't related to other tracks

So maybe Apple thinks the user might change the lens during one movie shot so it writes that info at the track level?

- Matti

Phil Harvey

I'm dropping the ability to write these tags in 12.94 since it seems they weren't being written to the correct location. :(

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

wywh

Quote from: wywh on August 22, 2024, 08:24:02 AMSo maybe Apple thinks the user might change the lens during one movie shot so it writes that info at the track level?

That does not seem to be the case.

iPhone 13 Pro has Telephoto (9 mm, 77 mm equivalent) ƒ/2.8, Wide (5.7 mm, 26 mm equivalent) ƒ/1.5, and Ultra Wide (1.6 mm, 13 mm equivalent) ƒ/1.8 lenses.

My son took a movie while on-the-fly switching Wide -> Telephoto -> Wide -> Ultra Wide lenses during the same shot.

But macOS Sonoma 14.6.1 Photos.app Info reports only "Apple iPhone 13 Pro" and "Wide Camera - 26 mm ƒ1.5" lens for that movie (exiftool displays it as 27 mm equivalent).

Also exiftool v12.94 reports only one lens:

exiftool -a -G1 -s -n -ee -Keys:All '-*lens*' '-*focal*' IMG_9851.MOV
[Keys]          LocationAccuracyHorizontal      : 35.000000
[Keys]          GPSCoordinates                  : xx.xxxx xx.xxxx xx.xxx
[Keys]          Make                            : Apple
[Keys]          Model                           : iPhone 13 Pro
[Keys]          Software                        : 17.5.1
[Keys]          CreationDate                    : 2024:08:28 20:16:37+03:00
[Track1]        CameraLensModel-fin-FI          : iPhone 13 Pro back camera 5.7mm f/1.5
[Track1]        CameraLensModel                 : iPhone 13 Pro back camera 5.7mm f/1.5
[Track1]        CameraFocalLength35mmEquivalent-fin-FI: 27
[Track1]        CameraFocalLength35mmEquivalent : 27

exiftool -a -G5 -s -n -ee -Keys:All '-*lens*' '-*focal*' IMG_9851.MOV
[MOV-Movie-Meta-Keys] LocationAccuracyHorizontal: 35.000000
[MOV-Movie-Meta-Keys] GPSCoordinates            : xx.xxxx xx.xxxx xx.xxx
[MOV-Movie-Meta-Keys] Make                      : Apple
[MOV-Movie-Meta-Keys] Model                     : iPhone 13 Pro
[MOV-Movie-Meta-Keys] Software                  : 17.5.1
[MOV-Movie-Meta-Keys] CreationDate              : 2024:08:28 20:16:37+03:00
[MOV-Movie-Track-Meta-Keys] CameraLensModel-fin-FI: iPhone 13 Pro back camera 5.7mm f/1.5
[MOV-Movie-Track-Meta-Keys] CameraLensModel     : iPhone 13 Pro back camera 5.7mm f/1.5
[MOV-Movie-Track-Meta-Keys] CameraFocalLength35mmEquivalent-fin-FI: 27
[MOV-Movie-Track-Meta-Keys] CameraFocalLength35mmEquivalent: 27

I guess it is not possible to copy or write that lens info at the track level:

exiftool -m -overwrite_original -api LargeFileSupport=1 '-Track1:CameraLensModel=iPhone 13 Pro back camera 5.7mm f/1.5' test.mov
Warning: Tag 'Track1:CameraLensModel' is not defined
Nothing to do.

A suboptimal workaround might be to write lens info to Keys in re-encoded movies although Photos.app does not read it. And as you said, unlike v12.93, v12.94 no longer supports that and it might be a good choice:

exiftool -m -P -overwrite_original -Keys:LensModel='iPhone 13 Pro back camera 5.7mm f/1.5' -Keys:FocalLengthIn35mmFormat=27 test.mov
Warning: Sorry, Keys:LensModel doesn't exist or isn't writable
Warning: Sorry, Keys:FocalLengthIn35mmFormat doesn't exist or isn't writable
Nothing to do.

- Matti

Phil Harvey

Hi Matti,

The Track metadata is not timed, so lens changes can't be accommodated by this metadata.

And yes, ExifTool currently only creates top-level metadata.  Adding the ability to create Track-level metadata would be possible, but I worry that things are already confusing enough for users due to the 3 possible top-level locations for video metadata.  This would multiply it by the number of tracks, and also put the onus on the user to determine which of the tracks to write (to do this properly, ExifTool should probably be modified to use track names such as AudioTrack/VideoTrack... instead of Track1/Track2... but this would introduce a level of backward incompatibility).

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

wywh

Quote from: wywh on August 30, 2024, 06:58:05 AMA suboptimal workaround might be to write lens info to Keys in re-encoded movies although Photos.app does not read it.

One workaround to save lens info in re-encoded movies is to copy it to XMP although none of my apps display it. A simple ffmpeg re-wrap as an example:

ffmpeg -i IMG_9851.MOV -c copy output.mov

exiftool -m -overwrite_original -api QuickTimeUTC=1 -api LargeFileSupport=1 -tagsFromFile IMG_9851.MOV -All:All '-XMP-exifEX:LensModel<CameraLensModel' '-XMP-exifEX:LensInfo<CameraFocalLength35mmEquivalent' '-FileCreateDate<QuickTime:CreateDate' '-FileModifyDate<QuickTime:CreateDate' output.mov

exiftool -a -G1 -s -n -api QuickTimeUTC=1 -FileCreateDate -FileModifyDate -QuickTime:CreateDate -Keys:All '-*lens*' '-*focal*' .
======== ./IMG_9851.MOV
[MacOS]         FileCreateDate                  : 2024:08:28 20:16:37+03:00
[System]        FileModifyDate                  : 2024:08:28 20:16:37+03:00
[QuickTime]     CreateDate                      : 2024:08:28 20:16:37+03:00
[Keys]          CreationDate                    : 2024:08:28 20:16:37+03:00
[Keys]          GPSCoordinates                  : 29.9792 31.1342 138.5
[Keys]          LocationAccuracyHorizontal      : 35.000000
[Keys]          Make                            : Apple
[Keys]          Model                           : iPhone 13 Pro
[Keys]          Software                        : 17.5.1
[Track1]        CameraLensModel-fin-FI          : iPhone 13 Pro back camera 5.7mm f/1.5
[Track1]        CameraLensModel                 : iPhone 13 Pro back camera 5.7mm f/1.5
[Track1]        CameraFocalLength35mmEquivalent-fin-FI: 27
[Track1]        CameraFocalLength35mmEquivalent : 27
======== ./output.mov
[MacOS]         FileCreateDate                  : 2024:08:28 20:16:37+03:00
[System]        FileModifyDate                  : 2024:08:28 20:16:37+03:00
[QuickTime]     CreateDate                      : 2024:08:28 20:16:37+03:00
[Keys]          CreationDate                    : 2024:08:28 20:16:37+03:00
[Keys]          GPSCoordinates                  : 29.9792 31.1342 138.5
[Keys]          LocationAccuracyHorizontal      : 35.000000
[Keys]          Make                            : Apple
[Keys]          Model                           : iPhone 13 Pro
[Keys]          Software                        : 17.5.1
[Keys]          MajorBrand                      : Apple QuickTime (.MOV/QT)
[Keys]          CompatibleBrands                : qt
[Keys]          MinorVersion                    : 0.0.0
[XMP-exifEX]    LensModel                       : iPhone 13 Pro back camera 5.7mm f/1.5
[XMP-exifEX]    LensInfo                        : 27

- Matti

wright96d

+1 request for track level metadata. Just released this on github without realizing everything ran through it was missing lens info.