Meta Data Corruption

Reported bugs that have been closed and/or resolved

Moderators: XnTriq, xnview, Dreamer

Post Reply
brb
Posts: 5
Joined: Fri Feb 05, 2021 2:52 am

Meta Data Corruption

Post by brb »

Subject: 0.98.1: Cropping corrupts meta data under Windows 10

XnView: MP 0.98.1 - 64 bit
OS: Windows 10 64 bit

Cropping a picture corrupts the meta data on a jpg. It becomes necessary to run EXIF against the image to correct it and allow edits to the meta data.

To reproduce:
1. Crop a jpg and save it.
2. Right click jpg and select Properties.
3. Go to Details tab and add a comment.
4. Try to save the change (click OK or Apply). You will get an error box.

Running EXIF with the following parameters fixes the jpg file.

"D:\Software and Drivers\Tools\exiftool" -all= -tagsfromfile @ -all:all -unsafe -icc_profile xxx.jpg
User avatar
xnview
Author of XnView
Posts: 34717
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: Meta Data Corruption

Post by xnview »

could you send me a sample file, and the exact step to reproduce?
Pierre.
brb
Posts: 5
Joined: Fri Feb 05, 2021 2:52 am

Re: Meta Data Corruption

Post by brb »

I've attached an original and cropped image. You can change the comment (xxx) in the original image, but not in the cropped image.

Properties> Details> Comments

Rotating and saving an image also produces the problem.
Attachments
Cropped file
Cropped file
Original file
Original file
User avatar
xnview
Author of XnView
Posts: 34717
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: Meta Data Corruption

Post by xnview »

i can't reproduce, could you pot screenshot of steps? which settings>Formats>Write>JPEG do you have?
Pierre.
brb
Posts: 5
Joined: Fri Feb 05, 2021 2:52 am

Re: Meta Data Corruption

Post by brb »

The steps are in the original post. Crop the picture, save it, then try to add a comment via the Properties dialog.

All settings in XNviewMP are at default. I do not use any custom settings.
User avatar
michel038
Posts: 654
Joined: Tue Sep 27, 2016 8:18 am
Location: France
Contact:

Re: Meta Data Corruption

Post by michel038 »

1
- I cropped my own jpg, saved it.
- return to browser mode, right clic, properties (= Windows properties) details, select "comment", enter a comment, apply, ok,
Windows has entered an exif comment without error.
Same result if my jpg has some xmp metadata

2
I downloaded your cropped picture, right click, found a "xxx" comment, edit, apply : I get a Windows error box : 0x80070057
I had to use "Tools, Metadata, Clean, XMP"
When xmp metadata are deleted, I can modify Windows comment
In this cropped file, XMP: HDRP Maker note seems deleted or not read in Exiftool tab, and in XMP tab neither.

3
I downloaded your original picture, cropped it : I get the same error. I need to delete xmp metadata to make Windows be able to manage details.
It seems that XnViewMP does not handle some of the xmp metadata created by HDR software . :bugconfirmed:


4
If ExifTool builds a sidecar, I get this error : (I think ExifTool has found the bug !)

Code: Select all

 "XMP format error <no closing tag for x:xmpmeta>
but a right sidecar file is built

Code: Select all

<?xpacket begin='' id='W5M0MpCehiHzreSzNTczkc9d'?>

<x:xmpmeta xmlns:x="adobe:ns:meta/" x:xmptk="Adobe XMP Core 5.1.0-jc003">
	<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
<rdf:Description rdf:about="" xmlns:xmpNote="http://ns.adobe.com/xmp/note/" xmpNote:HasExtendedXMP="5249587BDE60EC68A062A1B6FFED4020"/>
	</rdf:RDF>
</x:xmpmeta>
 <?xpacket end='w'?><?xpacket end='w'?>
brb
Posts: 5
Joined: Fri Feb 05, 2021 2:52 am

Re: Meta Data Corruption

Post by brb »

Yes, you've recreated the error. Thanks for the tip regarding using Tools> Metadata to fix it within XnView.

Any kind of modification to the original jpg seems to induce the error. In addition to cropping an image, I've also encountered it when rotating the image.

I find that once I use the Tools> Metadata option to repair the error, I no longer run into problems when modifying the image (crop, rotate), and then go in and change the comment.

I've seen the problem with pictures taken on Google Pixel 2 and Pixel 4 smartphones. Is it possible the phones are not writing the metadata correctly?
User avatar
xnview
Author of XnView
Posts: 34717
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: Meta Data Corruption

Post by xnview »

:bugconfirmed: Thanks to your detailed description I can reproduce the problem.
The JPEG file uses Extended XMP data
Pierre.
User avatar
xnview
Author of XnView
Posts: 34717
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: Meta Data Corruption

Post by xnview »

This problem is supposed to be fixed in XnView MP 0.98.2. Please check and confirm the bug fix here.
Pierre.
brb
Posts: 5
Joined: Fri Feb 05, 2021 2:52 am

Re: Meta Data Corruption

Post by brb »

0.98.2 fixes the problem.

Thanks!
Post Reply