-
Notifications
You must be signed in to change notification settings - Fork 31
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
fix primaries used for display p3 gamut #331
Conversation
80bad93
to
9f25e09
Compare
9f25e09
to
dd56e5c
Compare
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.
LGTM. Thank you!
94ada70
to
c44bd39
Compare
- luminance function of p3 gamut is using weights of dci p3 instead of display p3. this is corrected. accordingly the gamut conversions involving display p3 are updated. - increased precision of some constants used in csc Test: ./ultrahdr_unit_test Change-Id: Iec77b3d24adb7ad887a8f53d805eecc0c0160f28
c44bd39
to
ee9e793
Compare
return {{{1.34369f * e.r + -0.28223f * e.g + -0.06135f * e.b, | ||
-0.06533f * e.r + 1.07580f * e.g + -0.01051f * e.b, | ||
0.00283f * e.r + -0.01957f * e.g + 1.01679f * e.b}}}; | ||
return {{{1.343578f * e.r + -0.282179f * e.g + -0.061399f * e.b, |
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.
Could you double check if this matrix is correct?
I use
[2.4934969119,−0.9313836179,−0.4027107845; −0.8294889696,1.7626640603,0.0236246858; 0.0358458302,−0.0761723893,0.9568845240;]
x [0.636958,0.144617,0.168881; 0.262700,0.677998,0.059302; 0.000000,0.028073,1.060985;]
and got this: (maybe I am wrong)
[ 1.33736487 -0.33736476 -7.08830856e-07 ] [ 0.02128283 0.97871719 -1.14552781e-07 ] [ 0.00418868 0.03418871 0.99581128 ]
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.
the matrix multiplication seems to be wrong. The individual matrices are same as the ones i am using.
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.
OK I re-did the math with gemini and this time the result matches with yours. My previous result with chatGPT was wrong. Sorry for the confusion.
return {{{1.34369f * e.r + -0.28223f * e.g + -0.06135f * e.b, | ||
-0.06533f * e.r + 1.07580f * e.g + -0.01051f * e.b, | ||
0.00283f * e.r + -0.01957f * e.g + 1.01679f * e.b}}}; | ||
return {{{1.343578f * e.r + -0.282179f * e.g + -0.061399f * e.b, |
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.
OK I re-did the math with gemini and this time the result matches with yours. My previous result with chatGPT was wrong. Sorry for the confusion.
Test: ./ultrahdr_unit_test