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

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 5 years, 6 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') | src/gpu/effects/GrConvolutionEffect.cpp » ('J')
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 a195b7606c4a32fdc1c4f71695522deb423a4be3..3fd1d64bdbf0497e56398c9562b59c8236e3deb8 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)
+ : GrSingleTextureEffect(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') | src/gpu/effects/GrConvolutionEffect.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698