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

Unified Diff: src/gpu/effects/Gr1DKernelEffect.h

Issue 1216623003: Bilinear optimization for 1D convolution. Base URL: https://chromium.googlesource.com/skia.git@master
Patch Set: Created 4 years, 9 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 | src/gpu/effects/GrConvolutionEffect.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/effects/Gr1DKernelEffect.h
diff --git a/src/gpu/effects/Gr1DKernelEffect.h b/src/gpu/effects/Gr1DKernelEffect.h
index 519d6dbeb5663c653583b567fdab387a9a4f81f6..2d4aa230fefee66d32cbf61bba44d9e4c7a0dfa8 100644
--- a/src/gpu/effects/Gr1DKernelEffect.h
+++ b/src/gpu/effects/Gr1DKernelEffect.h
@@ -28,6 +28,8 @@ public:
kY_Direction,
};
+ // Constructor using default nearest-neighbor sampling for the input texture
+ // filter mode.
Gr1DKernelEffect(GrTexture* texture,
Direction direction,
int radius)
@@ -35,6 +37,16 @@ public:
, fDirection(direction)
, fRadius(radius) {}
+ Gr1DKernelEffect(GrTexture* texture,
+ Direction direction,
+ int radius,
+ GrTextureParams::FilterMode filterMode)
+ : INHERITED(texture,
+ GrCoordTransform::MakeDivByTextureWHMatrix(texture),
+ filterMode)
+ , fDirection(direction)
+ , fRadius(radius) {}
+
virtual ~Gr1DKernelEffect() {};
static int WidthFromRadius(int radius) { return 2 * radius + 1; }
« no previous file with comments | « no previous file | src/gpu/effects/GrConvolutionEffect.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698