aboutsummaryrefslogtreecommitdiffhomepage
path: root/tests/ColorSpaceTest.cpp
diff options
context:
space:
mode:
authorGravatar msarett <msarett@google.com>2016-05-09 14:27:48 -0700
committerGravatar Commit bot <commit-bot@chromium.org>2016-05-09 14:27:49 -0700
commit2c3eca38c9f74be9d91f467540feb586a0e941ca (patch)
tree85c1634f6612b66814aa92156e14f17f626c1a77 /tests/ColorSpaceTest.cpp
parent05c987cee37ff9fcc7d42e73ec2909a55cd48e01 (diff)
Approximate common gamma tables as single values
This should improve performance of gamma conversion in software (we can use vector math instead of table look ups). Additionally this allows us to quickly and easily identify sRGB-like gammas. On gpu, identifying sRGB gamma improves performance/memory, because the hardware may support gamma conversion. This will help us identify situations where gamma conversion is not necessary. Ex: sRGB input -> sRGB display BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1950183006 Review-Url: https://codereview.chromium.org/1950183006
Diffstat (limited to 'tests/ColorSpaceTest.cpp')
-rw-r--r--tests/ColorSpaceTest.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/ColorSpaceTest.cpp b/tests/ColorSpaceTest.cpp
index 7e818caad0..17332d720d 100644
--- a/tests/ColorSpaceTest.cpp
+++ b/tests/ColorSpaceTest.cpp
@@ -74,7 +74,7 @@ DEF_TEST(ColorSpaceParsePngICCProfile, r) {
const float red[] = { 0.436066f, 0.222488f, 0.013916f };
const float green[] = { 0.385147f, 0.716873f, 0.0970764f };
const float blue[] = { 0.143066f, 0.0606079f, 0.714096f };
- const float gamma[] = { 0, 0, 0 }; // table-based gamma returns 0 from this its float-getter
+ const float gamma[] = { 2.2f, 2.2f, 2.2f };
test_space(r, colorSpace, red, green, blue, gamma);
#endif
}