diff options
Diffstat (limited to 'src/gpu/effects/Gr1DKernelEffect.h')
-rw-r--r-- | src/gpu/effects/Gr1DKernelEffect.h | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/gpu/effects/Gr1DKernelEffect.h b/src/gpu/effects/Gr1DKernelEffect.h index 0aec4b1336..4fc52b1385 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(GrProcessorDataManager* procDataManager, GrTexture* texture, Direction direction, @@ -36,6 +38,18 @@ public: , fDirection(direction) , fRadius(radius) {} + Gr1DKernelEffect(GrProcessorDataManager* procDataManager, + GrTexture* texture, + Direction direction, + int radius, + GrTextureParams::FilterMode filterMode) + : INHERITED(procDataManager, + texture, + GrCoordTransform::MakeDivByTextureWHMatrix(texture), + filterMode) + , fDirection(direction) + , fRadius(radius) {} + virtual ~Gr1DKernelEffect() {}; static int WidthFromRadius(int radius) { return 2 * radius + 1; } |