-
-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Color eq 2 #283
base: master
Are you sure you want to change the base?
Color eq 2 #283
Conversation
libify the gamut LUT and gamut mapping methods
One that works, now.
|
Thank you ! We need to remove all |
|
||
// fetch the corresponding y values | ||
const float y_prev = gamut_lut[xi]; | ||
const float y_next = gamut_lut[xii]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @aurelienpierre , i stumbled across this while looking for colorbalancergb issues both with opencl and cpu code. As we later do a simple lin approx i think we can/should avoid the division by (x_next - x_prev) and simply do
// fetch the corresponding y values
const float y_prev = gamut_lut[xi];
// return y_prev if we are on the same integer LUT element or do linear interpolation
return y_prev + ((xi != xii) ? (x_test - x_prev) * (gamut_lut[xii] - y_prev) : 0.0f);
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it's not a linear interpolation if you don't do
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Isn't dx here either 1 or zero due to floor/ceil above?
Removed my comments... |
Guided filter still produces NaN (then black squares) in high ISO pictures. Can't figure out why, mitigation is to raise the black point.