From 08c5ec71303aa58d6f081914f3e868fa5cce9f4c Mon Sep 17 00:00:00 2001 From: Robert Phillips Date: Mon, 30 Jan 2017 12:26:47 -0500 Subject: Make blur utils take GrTextureProxies - take 2 This is a re-land of https://skia-review.googlesource.com/c/7738/ (Make blur utils take GrTextureProxies) with a fix for the Nexus7 Change-Id: I5821a26b1e986daa11d960ae826a1207512cd2a0 Reviewed-on: https://skia-review.googlesource.com/7746 Commit-Queue: Robert Phillips Reviewed-by: Robert Phillips --- src/gpu/effects/GrGaussianConvolutionFragmentProcessor.h | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'src/gpu/effects/GrGaussianConvolutionFragmentProcessor.h') diff --git a/src/gpu/effects/GrGaussianConvolutionFragmentProcessor.h b/src/gpu/effects/GrGaussianConvolutionFragmentProcessor.h index b4f5cb7921..0bb9c5e1df 100644 --- a/src/gpu/effects/GrGaussianConvolutionFragmentProcessor.h +++ b/src/gpu/effects/GrGaussianConvolutionFragmentProcessor.h @@ -24,7 +24,7 @@ public: int halfWidth, float gaussianSigma, bool useBounds, - float* bounds) { + int* bounds) { return sk_sp(new GrGaussianConvolutionFragmentProcessor( tex, dir, halfWidth, gaussianSigma, useBounds, bounds)); } @@ -35,7 +35,7 @@ public: int halfWidth, float gaussianSigma, bool useBounds, - float* bounds) { + int* bounds) { return sk_sp(new GrGaussianConvolutionFragmentProcessor( context, std::move(proxy), dir, halfWidth, gaussianSigma, useBounds, bounds)); } @@ -44,7 +44,7 @@ public: const float* kernel() const { return fKernel; } - const float* bounds() const { return fBounds; } + const int* bounds() const { return fBounds; } bool useBounds() const { return fUseBounds; } const char* name() const override { return "GaussianConvolution"; } @@ -61,11 +61,11 @@ public: private: /// Convolve with a Gaussian kernel GrGaussianConvolutionFragmentProcessor(GrTexture*, Direction, int halfWidth, - float gaussianSigma, bool useBounds, float bounds[2]); + float gaussianSigma, bool useBounds, int bounds[2]); GrGaussianConvolutionFragmentProcessor(GrContext*, sk_sp, Direction, int halfWidth, float gaussianSigma, bool useBounds, - float bounds[2]); + int bounds[2]); GrGLSLFragmentProcessor* onCreateGLSLInstance() const override; @@ -85,7 +85,7 @@ private: // some of the logic from SkGpuBlurUtils into this class related to radius/sigma calculations. float fKernel[kMaxKernelWidth]; bool fUseBounds; - float fBounds[2]; + int fBounds[2]; typedef Gr1DKernelEffect INHERITED; }; -- cgit v1.2.3