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

Unified Diff: src/opts/opts_check_SSE2.cpp

Issue 52603004: Implement SSE2-based implementations of the morphology filters (dilate & (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Tweak Created 7 years, 2 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/SkMorphology_opts_none.cpp ('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 8f0bdac8fd88b647bb88b3c1fca6f640526914b1..b40ca9d4b846d3dbdd185f195ecf7f5dd5f31b0e 100644
--- a/src/opts/opts_check_SSE2.cpp
+++ b/src/opts/opts_check_SSE2.cpp
@@ -14,6 +14,8 @@
#include "SkBlitRow_opts_SSE2.h"
#include "SkUtils_opts_SSE2.h"
#include "SkUtils.h"
+#include "SkMorphology_opts.h"
+#include "SkMorphology_opts_SSE2.h"
#include "SkRTConf.h"
@@ -248,6 +250,24 @@ SkMemset32Proc SkMemset32GetPlatformProc() {
}
}
+SkMorphologyProc SkMorphologyGetPlatformProc(SkMorphologyProcType type) {
+ if (!cachedHasSSE2()) {
+ return NULL;
+ }
+ switch (type) {
+ case kDilateX_SkMorphologyProcType:
+ return SkDilateX_SSE2;
+ case kDilateY_SkMorphologyProcType:
+ return SkDilateY_SSE2;
+ case kErodeX_SkMorphologyProcType:
+ return SkErodeX_SSE2;
+ case kErodeY_SkMorphologyProcType:
+ return SkErodeY_SSE2;
+ default:
+ return NULL;
+ }
+}
+
SkBlitRow::ColorRectProc PlatformColorRectProcFactory(); // suppress warning
SkBlitRow::ColorRectProc PlatformColorRectProcFactory() {
« no previous file with comments | « src/opts/SkMorphology_opts_none.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698