From e28a6b55dfbcd510d86cca39a167d179b81e4f4c Mon Sep 17 00:00:00 2001 From: Mike Klein Date: Wed, 25 Jul 2018 13:05:17 -0400 Subject: add explicit accessor for sRGB singleton colorspaces SkColorSpace::MakeSRGB().get() is scary, and causes more ref/unref pairs than strictly necessary for these singletons. This time the implementation is still in SkColorSpace.cpp, so these should really work as singletons. Change-Id: I40f2942c8dcde3040663a04c4f5330aca90868ae Reviewed-on: https://skia-review.googlesource.com/143305 Auto-Submit: Mike Klein Commit-Queue: Brian Osman Reviewed-by: Brian Osman --- tests/ColorSpaceTest.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'tests/ColorSpaceTest.cpp') diff --git a/tests/ColorSpaceTest.cpp b/tests/ColorSpaceTest.cpp index c8d6a06e66..2e2687c591 100644 --- a/tests/ColorSpaceTest.cpp +++ b/tests/ColorSpaceTest.cpp @@ -80,7 +80,7 @@ static constexpr float g_sRGB_G[]{ 0.3853f, 0.7170f, 0.0971f }; static constexpr float g_sRGB_B[]{ 0.1430f, 0.0606f, 0.7139f }; DEF_TEST(ColorSpace_sRGB, r) { - test_space(r, SkColorSpace::MakeSRGB().get(), + test_space(r, sk_srgb_singleton(), g_sRGB_R, g_sRGB_G, g_sRGB_B, kSRGB_SkGammaNamed); } -- cgit v1.2.3