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

Unified Diff: src/core/SkMipMap.cpp

Issue 2159993003: Improve naive SkColorXform to half floats (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Prettier code 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/core/SkHalf.h ('k') | src/core/SkNx.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkMipMap.cpp
diff --git a/src/core/SkMipMap.cpp b/src/core/SkMipMap.cpp
index 4811c9e07394f9f6cb478da50014ca49d36b53c5..cb9cc85a9874834390ec419b0023298a2302583b 100644
--- a/src/core/SkMipMap.cpp
+++ b/src/core/SkMipMap.cpp
@@ -88,7 +88,9 @@ struct ColorTypeFilter_F16 {
return SkHalfToFloat_finite(x);
}
static uint64_t Compact(const Sk4f& x) {
- return SkFloatToHalf_finite(x);
+ uint64_t r;
+ SkFloatToHalf_finite(x).store(&r);
+ return r;
}
};
« no previous file with comments | « src/core/SkHalf.h ('k') | src/core/SkNx.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698