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

Unified Diff: src/opts/opts_check_SSE2.cpp

Issue 138163013: SSE2 implementation of S32A_D565_Opaque (Closed) Base URL: https://skia.googlesource.com/skia.git@SkSrcOver32To16SSE
Patch Set: fix nits Created 6 years, 10 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/SkColor_opts_SSE2.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/opts/opts_check_SSE2.cpp
diff --git a/src/opts/opts_check_SSE2.cpp b/src/opts/opts_check_SSE2.cpp
index aaf6b2ef824dfab2e7b26f261862b7f97614a145..9ecb905c5f181678f8dc28367c7a81d6566094aa 100644
--- a/src/opts/opts_check_SSE2.cpp
+++ b/src/opts/opts_check_SSE2.cpp
@@ -165,6 +165,17 @@ void SkBitmapProcState::platformProcs() {
}
}
+static SkBlitRow::Proc platform_16_procs[] = {
+ NULL, // S32_D565_Opaque
+ NULL, // S32_D565_Blend
+ S32A_D565_Opaque_SSE2, // S32A_D565_Opaque
+ NULL, // S32A_D565_Blend
+ NULL, // S32_D565_Opaque_Dither
+ NULL, // S32_D565_Blend_Dither
+ NULL, // S32A_D565_Opaque_Dither
+ NULL, // S32A_D565_Blend_Dither
+};
+
static SkBlitRow::Proc32 platform_32_procs[] = {
NULL, // S32_Opaque,
S32_Blend_BlitRow32_SSE2, // S32_Blend,
@@ -173,7 +184,11 @@ static SkBlitRow::Proc32 platform_32_procs[] = {
};
SkBlitRow::Proc SkBlitRow::PlatformProcs565(unsigned flags) {
- return NULL;
+ if (cachedHasSSE2()) {
+ return platform_16_procs[flags];
+ } else {
+ return NULL;
+ }
}
SkBlitRow::ColorProc SkBlitRow::PlatformColorProc() {
« no previous file with comments | « src/opts/SkColor_opts_SSE2.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698