In a CIE-referenced RGB color space, luminance is the weighted sum of linearized representations of the three color planes. The weights depend on the color space.
I'm not worried about a histogram's accuracy, the code to collect the buckets is quite trivial. I'm more worried about the source data used to calculate it.
Okay, a little illustration. Here's a screenshot of an image developed to just past demosaic, still in the linear energy relationship of the raw file:
Pretty easy to follow, the processing toolchain is in the top-left pane, and the result of the checked tool is what is displayed and histogrammed. This histogram is a "linear-linear' depiction (sorry, Iliah...) , and at this point it's distribution is equivalent to the original raw data. Of particular note, the magenta blob in about the middle of the image are blown pixels (the white balance skew made them magenta), but note there's no spike or other indication of that clipping at the right hand side of the histogram.
Now, here's a screenshot of the developed image with the last tool checked:
This is set up to show the histogram you'd see of the JPEG image; to do this, I had to change out my display profile to a linear one and add the 2.2 gamma normally applied by my display profile to the end of the toolchain. Looks more like a "normal" histogram, no? Notice, still no "pile-up" at the top end,
What I want in the viewfinder is for that magenta area to blink. Then, I can say, 'oh, headlight, I can let that go a bit", and increase my exposure a bit. I mean, I had a bit of room to do just that, 1/750sec with ISO gain of 560, do not remember why I had that setting.
I'm not familiar with 'rawproc' Glenn, so I'm guessing that you are a victim of auto-scaling. In this case there is so much dark area that the headlamp's area contribution is pushed down to nothing or almost nothing.
I remain interested in "accuracy" as it relates to histograms generally. The task itself is simple enough, so all histograms should be 100% accurate ... and, therefore, no one camera should be more accurate or less accurate than another in the histogram dept.
rawproc is my hack raw processor. I wrote it specifically to expose each and every operation required to turn a raw file into a rendition, no hidden operations like "auto-scale".
I like this image for such a demonstration. Cloudy morning, not a lot of light to fill shadows. And that danged headlight. Essentially, a low-contrast image with a high-intensity in-scene illuminant. Where, oh where, do you put the exposure?
Sorry, I was talking about the histogram Y-axis itself, not operations on the data.
Exposure 101 is very clear on that issue with regard to highlights in a scene and I'm sure you know what it says but, just in case ...
... say you have the perfect spotmeter and the engine is frozen in time ... you, not the camera, should decide - engine (say metered at 13EV) or lamp (say mewtered at 18EV)?
I would go for the engine and set my exposure to 13EV, say f/5.6 and 1/250 secs, see the table row for 13EV in en.wikipedia.org/wiki/Exposure_value
The lamp would blow for sure but it would be easily selected and fixed in post.
Thanks, and you're looking at the not-best rendition. Just looked at the raw histogram, all of the image except for the headlight is at or below 10%, "underexposed" by any account. It requires a fairly aggressive tone curve to put everything in a good place:
Taken in 2015, just learning to shoot raw, a lot of learning ahead to figure out what to care about. Still futzing with it; currently trying out the Z 6 highlight-weighted matrix metering with a +1EV exposure compensation. I think I'd rather shoot manual with freaking raw blinkies... 😆
my sony a74 the train light would have flashed with an overexposed camera setting with blinkies set to 109+1 which is the equivalent accuracy of a raw file histogram.
No, it was shown and explained to you by multiple people in your other thread why your blinkies set to 109+1 is not the equivalent accuracy of a raw histogram.