Image uploads - color profiles dropped

I think this is a bug, though maybe it is a feature to make the file size smaller?

I work in the photo industry, in our forum sometimes people post images for others to try to troubleshoot printing issues. The image uploaded could be in a color space other than sRGB like Adobe 98 or ProPhoto RGB.

If I post an image to our Discourse forum that is Adobe 98, when I download that image the profile has been stripped and now it is untagged which is really bad as there is no way to know what the original color space was.

Is this intended? is there a way to not remove the color profile?

1 like

By default, image metadata is removed from uploads. However, there’s a site setting for this.

If you’d like the metadata to be preserved, search for strip_image_metadata in the settings and you should see this:

Capture7

Disabling this setting means the metadata will not be stripped from future image uploads.

7 likes

Strip image metadata doesn’t mean the color profile should be ignored.

An image that loses its color gamut information is rendered as a different image. And this feature supports a very limited number of image formats.

For example, AVIF does not lose any image metadata, however, the resulting thumbnail is not color managed.

Refer to the image below. Please wait patiently for Discourse to load the preview image, then click to expand the original image. Note the color difference between the two.

2 likes

You’re right! I checked this and the original has more intens reds, yellows, greens etc. I don’t have an answer for you but just confirming that I see what you see.

Interesting if this has always been an issue in Discourse. Is it just with avif files (a format I don’t use much myself) or are you able to see this with other more common formats?

Dit fenomeen is een voorbeeld van het verlies van afbeeldingsmetadata. Dit verlies is niet beperkt tot AVIF; metadata wordt verwijderd voor alle afbeeldingsformaten die door Discourse worden ondersteund. AVIF is gekozen omdat de miniaturen ervan afbeeldingsmetadata hebben verwijderd, terwijl originele afbeeldingen niet worden verwerkt.

Dit komt eigenlijk door twee bugs:

  1. Discourse beweert metadata voor alle afbeeldingen te verwijderen, maar deed dat in werkelijkheid niet.

  2. Het verwijderen van metadata verwijdert zelfs kleurbereiksinformatie, wat de kleurinformatie van de afbeelding in gevaar brengt.