Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(656)

Unified Diff: tests/ColorSpaceXformTest.cpp

Issue 2174493002: Add color space xform support to SkJpegCodec (includes F16!) (Closed) Base URL: https://skia.googlesource.com/skia.git@drop
Patch Set: Fix MSAN suppression Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/opts/SkOpts_sse41.cpp ('k') | tools/viewer/ImageSlide.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/ColorSpaceXformTest.cpp
diff --git a/tests/ColorSpaceXformTest.cpp b/tests/ColorSpaceXformTest.cpp
index 23b08ce8aecc9a2a30808422d5f4bf5ab817146b..1e75ee68534cbb6acff1daae791a7f6eb295732d 100644
--- a/tests/ColorSpaceXformTest.cpp
+++ b/tests/ColorSpaceXformTest.cpp
@@ -37,19 +37,19 @@ static void test_identity_xform(skiatest::Reporter* r, const sk_sp<SkGammas>& ga
// Create and perform an identity xform.
std::unique_ptr<SkColorSpaceXform> xform = ColorSpaceXformTest::CreateIdentityXform(gammas);
- xform->applyTo8888(dstPixels, srcPixels, width);
+ xform->applyToRGBA(dstPixels, srcPixels, width);
// Since the src->dst matrix is the identity, and the gamma curves match,
// the pixels should be unchanged.
for (int i = 0; i < width; i++) {
REPORTER_ASSERT(r, almost_equal(((srcPixels[i] >> 0) & 0xFF),
- SkGetPackedR32(dstPixels[i])));
+ ((dstPixels[i] >> 0) & 0xFF)));
REPORTER_ASSERT(r, almost_equal(((srcPixels[i] >> 8) & 0xFF),
- SkGetPackedG32(dstPixels[i])));
+ ((dstPixels[i] >> 8) & 0xFF)));
REPORTER_ASSERT(r, almost_equal(((srcPixels[i] >> 16) & 0xFF),
- SkGetPackedB32(dstPixels[i])));
+ ((dstPixels[i] >> 16) & 0xFF)));
REPORTER_ASSERT(r, almost_equal(((srcPixels[i] >> 24) & 0xFF),
- SkGetPackedA32(dstPixels[i])));
+ ((dstPixels[i] >> 24) & 0xFF)));
}
}
« no previous file with comments | « src/opts/SkOpts_sse41.cpp ('k') | tools/viewer/ImageSlide.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698