Lines Matching defs:kernel
28 static void fill_in_2D_gaussian_kernel(float* kernel, int width, int height,
52 // is dropped here, since we renormalize the kernel below.
53 kernel[y * width + x] = xyTerm;
57 // Normalize the kernel
60 kernel[i] *= scale;
82 // and the appropriate kernel already computed, but there's value in keeping the shader simpler.
132 float kernel[GrMatrixConvolutionEffect::kMaxUniformSize];
133 fill_in_2D_gaussian_kernel(kernel, size.width(), size.height(), sigmaX, sigmaY);
135 size, kernel, 1.0f, 0.0f, kernelOffset, wm, true,
197 // 'mid' is the area where we can ignore the mode because the kernel does not reach to the
211 // Inset for sub-rect of 'srcBounds' where the x-dir kernel doesn't reach the edges, clipped
507 // single color value repeated at each column/row. Applying the normalized kernel to that
553 // launch a single non separable kernel vs two launches.
843 void Compute1DGaussianKernel(float* kernel, float sigma, int radius) {
848 std::fill_n(kernel, 1, 0.f);
849 kernel[0] = 1.f;
862 // is dropped here, since we renormalize the kernel below.
863 kernel[i] = sk_float_exp(-term * term * sigmaDenom);
864 sum += kernel[i];
866 // Normalize the kernel
869 kernel[i] *= scale;
873 void Compute1DLinearGaussianKernel(float* kernel, float* offset, float sigma, int radius) {
885 // Create a temporary standard kernel.
895 // Compute1DGaussianKernel produces a full 2N + 1 kernel. Since the kernel can be mirrored,
908 get_new_weight(&kernel[halfradius], &offset[halfradius],
910 kernel[low_index] = kernel[halfradius];
917 kernel[halfradius] = temp_kernel[index];
924 get_new_weight(&kernel[i], &offset[i], temp_kernel[index], temp_kernel[index + 1]);
928 kernel[low_index] = kernel[i];