diff options
| author | Carl Hetherington <cth@carlh.net> | 2025-12-14 23:15:02 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2025-12-14 23:17:58 +0100 |
| commit | fd218a6052525bbad23566e9a3be8aada401e576 (patch) | |
| tree | 2daf40d9b7bc1184a8d271362639ea0cf32fc362 | |
| parent | 3ae04a65509028d35ee18f693b223c76b1c43d2a (diff) | |
Add P3 D65 colour space.
This is the same as P3 DCI except with a D65 white point (~6500K).
(0.3127, 0.3290)
| -rw-r--r-- | src/colour_conversion.cc | 18 | ||||
| -rw-r--r-- | src/colour_conversion.h | 2 |
2 files changed, 20 insertions, 0 deletions
diff --git a/src/colour_conversion.cc b/src/colour_conversion.cc index bf44f1f4..33176d11 100644 --- a/src/colour_conversion.cc +++ b/src/colour_conversion.cc @@ -118,6 +118,24 @@ ColourConversion::p3_dci_to_xyz() return *c; } + +ColourConversion const & +ColourConversion::p3_d65_to_xyz() +{ + static auto c = new ColourConversion( + make_shared<GammaTransferFunction>(2.6), + YUVToRGB::REC709, + Chromaticity(0.68, 0.32), + Chromaticity(0.265, 0.69), + Chromaticity(0.15, 0.06), + Chromaticity(0.3127, 0.3290), + optional<Chromaticity>(), + make_shared<GammaTransferFunction>(2.6) + ); + return *c; +} + + ColourConversion const & ColourConversion::rec1886_to_xyz() { diff --git a/src/colour_conversion.h b/src/colour_conversion.h index 85d83e21..73c94cb1 100644 --- a/src/colour_conversion.h +++ b/src/colour_conversion.h @@ -165,6 +165,8 @@ public: static ColourConversion const & rec709_to_xyz(); /** P3 DCI (~6300K "theater" white point) */ static ColourConversion const & p3_dci_to_xyz(); + /** P3 with D65 white point */ + static ColourConversion const & p3_d65_to_xyz(); static ColourConversion const & rec1886_to_xyz(); static ColourConversion const & rec2020_to_xyz(); static ColourConversion const & s_gamut3_to_xyz(); |
