From 51ca2249ff7a812ac9e1b7eae59f768d8500dcac Mon Sep 17 00:00:00 2001 From: cxl Date: Sun, 24 Mar 2019 08:46:24 +0000 Subject: [PATCH] Core: DarkTheme(Color) changed to boost blue/red git-svn-id: svn://ultimatepp.org/upp/trunk@12885 f0d560ea-af0d-0410-9eb7-867de7ffcac7 --- uppsrc/Core/Color.cpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/uppsrc/Core/Color.cpp b/uppsrc/Core/Color.cpp index 6959600c4..b9fa29d41 100644 --- a/uppsrc/Core/Color.cpp +++ b/uppsrc/Core/Color.cpp @@ -228,10 +228,12 @@ Color DarkTheme(Color color) v[0] = color.GetR(); v[1] = color.GetG(); v[2] = color.GetB(); - - static double c[3] = { 0.21, 0.72, 0.07 }; - double m0 = 0.21 * v[0] + 0.72 * v[1] + 0.07 * v[2]; +// this represent physiological perception of brightness of R,G,B. Sum = 1 +// static double c[3] = { 0.21, 0.72, 0.07 }; // physiologically correct values + static double c[3] = { 0.3, 0.5, 0.2 }; // with this set, blues and reds are more pronounced + + double m0 = c[0] * v[0] + c[1] * v[1] + c[2] * v[2]; double m = 256 - m0; int i0 = 0;