GIMP 2.10.6 out-of-range RGB values from .CR2 file

Go here and download the tar.gz file.
http://download.savannah.nongnu.org/releases/openexr/openexr-images-1.7.0.tar.gz

Unpack it and navigate to the Chromaticities folder and open the file named Rec709.exr. That file. Should it be clipped above 1.0f in Blender or Nuke?

I would encourage you to think about what the intention of the light values are in the encoded file.

If they represent colour, then as @gwgill has pointed out several times, those colours are only given meaning by attaching it to the standard observer model.

If you do that, then adjust the colour values, and some end up out of gamut, should they be clipped for manipulation?

IE: The crux of this entire question is whether RGB scaling is generating appropriate colour values in the first place. The point I’ve tried to make is that it is questionable, given the nature of chromatic adaptation, whether RGB scaling is delievering actual adapted values.

TL;DR I personally don’t believe that RGB axis scaling is delivering the values that the device would capture the illuminant as at the sensor photon level, hence a portion of that transform is invalid data.

Addendum: Sorry didn’t realize you were referencing the EXR samples. I haven’t looked at that file, so it depends on the encoding. If that is the digital Lad image, it is scene referred with highlights in Marcie’s hair extending up to an arbitrary value that I can’t remember.

Well, could you take a look and let me know whether that exr file should be clipped upon opening it with Blender or Nuke?

That’s the flower. It’s scene referred, so no clip. You’ll need a proper camera view transform to view the values appropriately as they extend up to 2.0+ in some instances.

OK, what about the file “WideColorGamut.exr” in the folder “TestImages”? That file has a lot of negative channel values. What should be done with it when opening it with Nuke or Blender?

Some pixels in this RGB image have extremely saturated colors, outside the gamut that can be displayed on a video monitor whose primaries match Rec. ITU-R BT.709. All RGB triples in the image correspond to CIE xyY triples with xy chromaticities that represent real colors.

So convert to your reference space, and clip.

My apologies, I don’t use the same terminology as you use. What do you mean by “reference space”?

The space you are going to align all of your imagery to. It has a fixed gamut if in additive RGB.

Are there criteria for choosing a reference space? In particular, can the reference space color gamut be different from the monitor color gamut?

The reason I ask, is that given the name and description of the file, I’m guessing it was produced in WideGamutRGB and converted to sRGB to make the test image. There are some negative channel values in the extreme green and blue corners, but that might be from a difference in assumed primaries for WideGamutRGB - AFAIK Adobe never published a standard for this particular color space. So I’m guessing the entire image is supposed to be in gamut wrt to WideGamutRGB.

Also, what does “it has a fixed gamut if in additive RGB” mean? What would a “not fixed” gamut look like or how would it be different from a fixed gamut color space? And what is “additive RGB” as opposed to ?? I wasn’t aware of a “not additive” RGB color space.

Why yes I did. What makes you think I didn’t? Did you see the words “given the name and description of the file”?

Why yes I did, if you mean the description file that accompanies the image file. What makes you think I didn’t read it? What meaning did you extract from the description file that seems to have escaped my notice?

Again, what makes you think I didn’t read the description file? What did you glean from the description file?

That’s nice. I don’t know what you are talking about. And I’d really like to know what it is that I said that you think indicates that I didn’t read whatever it is that you think I didn’t read. If you think someone missed an important point, the usual procedure is to quote what you think they missed and offer an interpretation. Y

Your manner of speaking isn’t very helpful. It would be better if you just explain what’s behind your enunciation that I didn’t read whatever it is that you think I didn’t read,

See, I’m asking questions that are as straightforward as I can manage, and you are giving entirely unhelpful answers consisting of repeating over and over and over again that I didn’t read something or other, to the point where I’ve totally lost track of whatever it is you think I did read - something you posted? The image description file?

Moving right along to my next question, as I don’t think I’m going to get a helpful response to why it is that @anon11264400 thinks I didn’t read whatever it is I didn’t read . . .

What if I open Rec709.exr with its >1.0 channel values, but this time open it with GIMP or darktable instead of with Blender or Nuke? What’s the appropriate thing to do next?

I read all that. I offered my assessment for what it’s worth that the image probably was intended to fit inside one or another version of the old WideGamutRGB color space. Is this what you are responding to when you say that I didn’t read your post? Or are you responding to something else that makes you think I didn’t read your post?

The reason why WideGamutRGB is relevant is because my inclination is to convert to WideGamutRGB. I don’t have any reason to choose some other reference space.

I apologize. Let’s try again. I misread you and was rude.

Try with:

Component x y Wavelength
Red 0.7347 0.2653 700 nm
Green 0.1152 0.8264 525 nm
Blue 0.1566 0.0177 450 nm
White point 0.3457 0.3585

This could be a reasonable decision. Bear in mind that if your target is smaller, that would mean some crafted gamut mapping. It might also yield funky math wonky results on saturation in your manipulations.

Yes, creating images that won’t fit into color gamut of the final display color space be it for the web or for print - edit: and then making them fit - sorry, left this part out :slight_smile: is just not fun and not easy, is actually quite demanding of creative efforts to preserve “pretty” while squeezing those colors down, as no doubt just about everyone on this forum knows very well from experience.

I don’t normally add a lot of saturation to photographs, so this “oh my goodness the colors just don’t fit” problem didn’t really hit home for me until I started working on some digital paintings, working in a color gamut that “just fits” my monitor color space but doesn’t fit well at all into sRGB. Fitting into a reasonably large gamut printer profile, that’s easy, sRGB not so much.

1 Like

As a helper, I’ve used the mind blowing useful Colab in conjunction with the absolutely incredible Colour Science library. Technically this is one line in Colour, but I included the others to show what default matrices are used. It’s specification unless you tell Colour otherwise.

That’s one of the concerns that require addressing when choosing a reference space.

If you were targetting a ten ink print with a wider gamut, it would be a consideration. Gamut mapping via absolute or relative colorimetric, versus CAM or homebrew based perceptual / saturation might work or might not, depending. There’s plenty of room out there for clever folks like @anon41087856, and the way he’s been completely cutting to the core of image processing, to include tunable interfaces for pixel pushers to engage with their work with more control considering the output. Imagine a tunable gamut mapper? That’s pretty easy with the knowledge and coding abilities of the folks around here to have in Darktable almost overnight.

This isn’t a place where typical people have no control over the tools, and instead, sometimes magic happens as @anon41087856 has shown.

1 Like

If that page you linked to allows people to compress colors, I bet a lot of people would find it very helpful. That’s taking this particular discussion waaay off-topic, I think. But if that page does show an alternative “automatic” way to get nicely compressed colors, if you started a new thread, I bet a lot of people would like to learn how to use the information. Color conversion without losing colors seems to be a big concern, and the usual “use perceptual intent to convert to the sRGB matrix profile” of course just clips because there aren’t any perceptual intent tables in the matrix version of sRGB (why didn’t the ICC give some other name to their LUT versions of sRGB???).

1 Like

Did you get those primaries from here? http://www.babelcolor.com/index_htm_files/A%20review%20of%20RGB%20color%20spaces.pdf

My WideGamutRGB ICC profile is made using Pascale’s primaries rathr than Lindbloom’s.

It’s sort of cramming a camera rendering transform into the core, operating on scene referred linear data that comes before it.

With the exception of @gwgill’s arguably best-of-breed work, Perceptual and Saturation renderings are largely secret sauce. That poses problems, as well as being extremely brittle.

With that said, Darktable or its ilk could implement a gamut mapping node rather easily that would allow for direct dialing of the gamut curves for a particular work, and letting the rendering intent remain simply absolute or relative colorimetric.

Actually, “out-of-range values” is precisely on that subject matter. :wink:

All of Colour comes with full citations.

1 Like

I followed @anon41087856 's darktable thread with a lot of interest. And you are right - “out of range” values is where this current thread started. Which brings us back around to this question:

I still think it would be nice to start a new thread on using the Colour tools to corral colors for color space conversions and even also the relevant ArgyllCMS tools - I’ve had people ask me questions about using ArgyllCMS for making image-specific gamut mappings, but I don’t have enough experience doing this sort of thing to say anything helpful.

1 Like