I've added the RAW EV histogram to all the XIMR builds (downloadable from the google drive link).
There's a new menu option to enable it and set options.
'Show RAW EV Histogram' - enable and set where it is displayed (ALT mode, Play mode or both).
'Under exposure threshold' - raw values that are less than camera black level + this value are considered clipped black.
'Over exposure threshold' - raw values that are greater than camera white level - this value are considered clipped white.
'Save EV histogram log' - append calculated histogram to A/raw_ev_histo.csv.
'Sensor sampling area:'
' Width %' - percentage of the sensor width to sample for calculating histogram.
' Height %' - percentage of the sensor height to sample for calculating histogram.
' X Step' - Number of pixels to skip in each row when sampling (set to 2 to sample every pixel which will be slow).
' Y Step' - Number of pixels to skip in each column when sampling (set to 2 to sample every pixel which will be slow).
The sampling area is centered in the sensor active area. Some camera have severe barrel distortion at the wide end so setting the sample area to 100 may throw off the under exposure calculation because of the corner vignetting.
A sample histogram is attached. Each red, green or blue column is 1/3 EV, and the grey vertical lines are 1 EV apart.
The count of under exposed values is drawn in white over the top of the leftmost red/green/blue bar. Over exposed count is over the rightmost red/green/blue bar.
The thinner white line at the left is the percentage of under exposed values relative to the total # of pixels with a value <= 20.
The thinner white line at the right is the percentage of over exposed values relative to the total number of pixels in the rightmost 1/3 EV bucket.