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

Unified Diff: skia/ext/convolver_SSE2.cc

Issue 14929006: [MIPS] Added MIPS DSPr2 optimization for BGRAConvolve2D routine (Closed)
Patch Set: Added "has_alpha" to all implementations Created 7 years, 7 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 | « skia/ext/convolver_SSE2.h ('k') | skia/ext/convolver_mips_dspr2.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: skia/ext/convolver_SSE2.cc
diff --git a/skia/ext/convolver_SSE2.cc b/skia/ext/convolver_SSE2.cc
index a823edcb519291d89ed79c448efa98f9569bb788..9a9c9b70e56e2ac91abaa2e0156b7af02cf4fb9b 100644
--- a/skia/ext/convolver_SSE2.cc
+++ b/skia/ext/convolver_SSE2.cc
@@ -14,6 +14,7 @@ namespace skia {
// Convolves horizontally along a single row. The row data is given in
// |src_data| and continues for the num_values() of the filter.
+template<bool has_alpha>
Stephen White 2013/05/13 14:08:43 If this function is going to ignore has_alpha anyw
Teodora Novkovic 2013/05/13 16:23:06 Done.
void ConvolveHorizontally_SSE2(const unsigned char* src_data,
const ConvolutionFilter1D& filter,
unsigned char* out_row) {
@@ -453,4 +454,18 @@ void ConvolveVertically_SSE2(const ConvolutionFilter1D::Fixed* filter_values,
}
}
+void ConvolveHorizontally_SSE2(const unsigned char* src_data,
+ const ConvolutionFilter1D& filter,
+ unsigned char* out_row,
+ bool has_alpha) {
+ if (has_alpha) {
+ ConvolveHorizontally_SSE2<true>(src_data,
+ filter,
+ out_row);
+ } else {
+ ConvolveHorizontally_SSE2<false>(src_data,
+ filter,
+ out_row);
+ }
+}
} // namespace skia
« no previous file with comments | « skia/ext/convolver_SSE2.h ('k') | skia/ext/convolver_mips_dspr2.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698