ExifTool Forum

General => Other Discussion => Topic started by: West Swan on October 21, 2021, 03:09:43 AM

Title: Windows Photo Viewer doesn't open jpg files with Android ICC Profile
Post by: West Swan on October 21, 2021, 03:09:43 AM
Hello,

I'm not 100% sure I'm correct here.

My Dad is a keen photographer for many years.  He isn't that good with computers though.

I wouldn't have a clue about photography but can work my way around a computer quite easily.

Having said that in order to work on this problem I had to use a GUI for ExifTool.  Thank you to Bogdan Hrastnik for making one.

Ok the issue is that when Dad emails photo's to himself from his Oppo CPH1969 F11 Pro Windows Photo Viewer will not open them. 

Other photo viewers will but Dad loves the simplicity of Windows Photo Viewer and hates all the others.

Doing a bit of research (please correct me if I'm wrong) I found that the problem is that Windows Photo Viewer doesn't understand the ICC Profile in the jpg file.

I've managed to find a way to get Windows Photo Viewer to open the jpg for him by using ExifTool and the GUI to remove the ICC Profile. 

Whola, it works perfectly.  Windows Photo Viewer will now open the photo and Dad is happy with the colours etc.

Buuuuttttt I don't want to have to do this for every photo he takes for the next decade   :D

Would there be a way of getting Windows Photo Viewer to open these jpg files without removing the ICC Profile?


Happy to provide any further information required.


Regards,

Paul
Title: Re: Windows Photo Viewer doesn't open jpg files with Android ICC Profile
Post by: West Swan on October 21, 2021, 08:08:33 AM
I thought it might be useful to attach one of the photos that Windows Photo Viewer can't open.
Title: Re: Windows Photo Viewer doesn't open jpg files with Android ICC Profile
Post by: StarGeek on October 21, 2021, 01:31:34 PM
The only thing I could suggest is remove the profile and adding it back in.  See if re-writing it will make it work.

exiftool -ColorSpaceTags= -TagsFromFile @ -ColorSpaceTags file.jpg

If that doesn't work, you'll have look elsewhere for a solution.
Title: Re: Windows Photo Viewer doesn't open jpg files with Android ICC Profile
Post by: West Swan on October 21, 2021, 09:58:32 PM
Hi StarGeek,

I appreciate that.  Thank you.

Unfortunately that wouldn't be feasible as, even if I could work out how to do it, it would mean I had to "fix" any photos he took by logging in remotely.

I think I may have found a workaround.

I can open those jpg files in Microsoft Paint.  From there I save the jpg as a 24bit bmp image which Windows Photo Viewer can open.

That increases the size of the image (in megabytes) quite significantly so if Dad wants he can open the bmp in Microsoft Paint and save it to a jpg image again.   

I just tested all that and it works and Dad is happy to do it.  He said of course I can save the bloody photo twice. The quality of the image doesn't seem to be affected (at least to his and my eyes).

I'm guessing that saving the jpg as a 24bit bmp removes the ICC profile which means Windows Photo Viewer can open it?

Of course he could just use a different photo viewer but that isn't going to happen anytime this century   :)

I've attached the resultant file after converting jpg ->  bmp  ->  jpg.


Regards,

Paul

Title: Re: Windows Photo Viewer doesn't open jpg files with Android ICC Profile
Post by: StarGeek on October 22, 2021, 12:56:58 AM
Quote from: West Swan on October 21, 2021, 09:58:32 PM
Unfortunately that wouldn't be feasible as, even if I could work out how to do it, it would mean I had to "fix" any photos he took by logging in remotely.

Place exiftool on the Desktop.  Rename it as
exiftool (-overwrite_Original -ColorSpaceTags= -TagsFromFile @ -ColorSpaceTags).exe
He can now drag his images onto  the exiftool icon and it will re-write the ICC profiles.  Still unsure if that would work.  I removed the default viewer long ago so I can't test it.

Or rename it as
exiftool (-overwrite_Original -ColorSpaceTags=).exe
And he can drag/drop to remove the profiles. 

QuoteI think I may have found a workaround.

That's a lot of extra work when you could use exiftool as above to fix the images without damaging them.

Here's a comparison of your original and the converted file.  The red is where the image has been changed from the original.  The differences can be visually similar, but they will grow exponentially each time you re-save the file as jpeg.  This image was created using the imagemagick command of magick compare Original.jpg converted.jpg x.png
(https://i.imgur.com/BbbwSTO.png)
Title: Re: Windows Photo Viewer doesn't open jpg files with Android ICC Profile
Post by: West Swan on October 22, 2021, 04:59:12 AM
Wow that is easy isn't it  :)

The first one   exiftool (-overwrite_Original -ColorSpaceTags= -TagsFromFile @ -ColorSpaceTags).exe   didn't work.

But the second option exiftool (-overwrite_Original -ColorSpaceTags=).exe  works a treat.

Thank you very much.

Dad said to say he owes you a beer.

Cheers,

Paul