https://bugs.kde.org/show_bug.cgi?id=429219
Bug ID: 429219 Summary: MWG "Applied To" state (mwg-rs:AppliedToDimensions XMP tag) is not included when writing Face metadata to file Product: digikam Version: 7.1.0 Platform: Other OS: Other Status: REPORTED Severity: normal Priority: NOR Component: Metadata-Xmp Assignee: digikam-bugs-n...@kde.org Reporter: jose_oli...@hotmail.com Target Milestone: --- SUMMARY MWG mwg-rs:AppliedToDimensions XMP tag is not included when writting Face metada to file. These values are important in determining if the face regions are valid for the image. STEPS TO REPRODUCE 1. Using a photo with a face, scan for face. 2. Add name details to face region. 3. Write face metadata to image file. OBSERVED RESULT Using a metadata extraction tool such as exiftool, extract XMP. Example: exiftool <filename> -xmp -b > output.xml Face data is added within mwg-rs:Regions mwg-rs:AppliedToDimensions XMP tag with image height and width dimensions are not included. EXPECTED RESULT - Per MWG (Metadata Working Group) Guidelines for Handling Image Metadata version 2.0 page 53 - the mwg-rs:AppliedToDimensions field should contain "Width and height of the image at the time of processing when storing image region metadata." - Why is this important/useful? When an image is cropped, rotated and/or resized using an application which does not re-adjust the MWG file regions the regions risk being offset. An application can compare the recorded mwg-rs:AppliedToDimensions with the actual image dimensions to determine if the face regions are valid or not. - In the event that the AppliedToDimensions and actual image dimensions do not match, Digikam may choose to ignore/invalidate the face regions so they can be re-applied. - In the event an image is resized, cropped or rotated, Digikam should adjust the image regions accordingly and reset the AppliedToDimensions value. - Another risk is that an application which does read MWG regions may ignore the face regions added by Digikam, based on the assumption that these are invalid or do not adhere to the MWG guidelines. Refer to Page 55: “Applied To” State Since the file may be modified by actors that are either non-compliant to this guidance or choose not to participate in image region metadata, it is critical to retain information about what the state of the image was when the region was specified. A Creator MUST store the region “applied to” width and height. A Changer MUST update the “applied to” value upon a resize, crop, or physical rotation in order to ensure that the region information is still valid for the new state of the file. In the case of a crop or physical rotation, a Changer MUST also update the region coordinates so as to further ensure that the region information remains valid. A Changer SHOULD remove region information for regions that are no longer applicable (e.g. a region that was orphaned due to a crop or rotation operation). A Consumer MUST validate the current state of the image and compare this against the “applied to” state to ensure that the region information is up-to-date. The information specified in the region MUST be validated to ensure that the data is applicable to the current state of the file. In the case where the “applied to” size and actual image size differ, if the ratio is significantly different a Consumer SHOULD ignore the region. Otherwise a Consumer or Changer MAY update the region metadata as though the image were scaled to the new dimensions. SOFTWARE/OS VERSIONS Windows: 10 macOS: Linux/KDE Plasma: (available in About System) KDE Plasma Version: KDE Frameworks Version: Qt Version: ADDITIONAL INFORMATION References: https://www.exiv2.org/tags-xmp-mwg-rs.html -- You are receiving this mail because: You are watching all bug changes.