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

Unified Diff: dm/DMSrcSink.cpp

Issue 2049813002: Modify QCMS test to match use by Chrome (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 6 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: dm/DMSrcSink.cpp
diff --git a/dm/DMSrcSink.cpp b/dm/DMSrcSink.cpp
index 9927c30428b51a8442e62e9498e3bd4bd28dbac1..0490e6f09e76af4991eec21f951086153b1d815b 100644
--- a/dm/DMSrcSink.cpp
+++ b/dm/DMSrcSink.cpp
@@ -921,6 +921,10 @@ Error ColorCodecSrc::draw(SkCanvas* canvas) const {
SkAutoTCallVProc<qcms_profile, qcms_profile_release>
dstSpace(qcms_profile_from_memory(dstData->data(), dstData->size()));
SkASSERT(dstSpace);
+
+ // Optimizes conversion by precomputing the inverse transformation to dst. Also
+ // causes QCMS to use a completely different codepath. This is how Chrome uses QCMS.
+ qcms_profile_precache_output_transform(dstSpace);
SkAutoTCallVProc<qcms_transform, qcms_transform_release>
transform (qcms_transform_create(srcSpace, QCMS_DATA_RGBA_8, dstSpace,
QCMS_DATA_RGBA_8, QCMS_INTENT_PERCEPTUAL));
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698