/external/libvpx/libvpx/vpx_dsp/ |
H A D | postproc.h | 18 // Fills a noise buffer with gaussian noise strength determined by sigma. 19 int vpx_setup_noise(double sigma, int8_t *noise, int size);
|
H A D | add_noise.c | 41 static double gaussian(double sigma, double mu, double x) { argument 42 return 1 / (sigma * sqrt(2.0 * 3.14159265)) * 43 (exp(-(x - mu) * (x - mu) / (2 * sigma * sigma))); 46 int vpx_setup_noise(double sigma, int8_t *noise, int size) { argument 52 const int a_i = (int)(0.5 + 256 * gaussian(sigma, 0, i));
|
/external/skia/src/core/ |
H A D | SkGaussFilter.cpp | 45 static int calculate_bessel_factors(double sigma, double *gauss) { argument 46 auto var = sigma * sigma; 51 // BesselI_0 for 0 <= sigma < 2. 58 // Use a variable number of loops. When sigma is small, this only requires 3-4 loops, but 59 // when sigma is near 2, it could require 10 loops. The same holds for BesselI_1. 67 // BesselI_1 for 0 <= sigma < 2. 90 // The maximum spread for sigma == 2 is guass[4], but in order to know to stop guass[5] 107 static int calculate_gauss_factors(double sigma, double* gauss) { argument 108 SkASSERT(0 <= sigma 140 SkGaussFilter(double sigma, Type type) argument [all...] |
H A D | SkMaskCache.h | 26 static SkCachedData* FindAndRef(SkScalar sigma, SkBlurStyle style, SkBlurQuality quality, 29 static SkCachedData* FindAndRef(SkScalar sigma, SkBlurStyle style, SkBlurQuality quality, 36 static void Add(SkScalar sigma, SkBlurStyle style, SkBlurQuality quality, 39 static void Add(SkScalar sigma, SkBlurStyle style, SkBlurQuality quality,
|
/external/skqp/src/core/ |
H A D | SkGaussFilter.cpp | 45 static int calculate_bessel_factors(double sigma, double *gauss) { argument 46 auto var = sigma * sigma; 51 // BesselI_0 for 0 <= sigma < 2. 58 // Use a variable number of loops. When sigma is small, this only requires 3-4 loops, but 59 // when sigma is near 2, it could require 10 loops. The same holds for BesselI_1. 67 // BesselI_1 for 0 <= sigma < 2. 90 // The maximum spread for sigma == 2 is guass[4], but in order to know to stop guass[5] 107 static int calculate_gauss_factors(double sigma, double* gauss) { argument 108 SkASSERT(0 <= sigma 140 SkGaussFilter(double sigma, Type type) argument [all...] |
H A D | SkMaskCache.h | 26 static SkCachedData* FindAndRef(SkScalar sigma, SkBlurStyle style, SkBlurQuality quality, 29 static SkCachedData* FindAndRef(SkScalar sigma, SkBlurStyle style, SkBlurQuality quality, 36 static void Add(SkScalar sigma, SkBlurStyle style, SkBlurQuality quality, 39 static void Add(SkScalar sigma, SkBlurStyle style, SkBlurQuality quality,
|
/external/skia/tests/ |
H A D | SkGaussFilterTest.cpp | 32 double sigma; SkGaussFilter::Type type; std::vector<double> golden; 33 std::tie(sigma, type, golden) = test; 34 SkGaussFilter filter{sigma, type}; 51 // 0.788675 - most common mask sigma. 58 // 1.07735 - second most common mask sigma. 74 auto check = [&](double sigma, SkGaussFilter::Type type) { 75 SkGaussFilter filter{sigma, type}; 88 for (double sigma = 0.0; sigma < 2.0; sigma [all...] |
/external/skqp/tests/ |
H A D | SkGaussFilterTest.cpp | 32 double sigma; SkGaussFilter::Type type; std::vector<double> golden; 33 std::tie(sigma, type, golden) = test; 34 SkGaussFilter filter{sigma, type}; 51 // 0.788675 - most common mask sigma. 58 // 1.07735 - second most common mask sigma. 74 auto check = [&](double sigma, SkGaussFilter::Type type) { 75 SkGaussFilter filter{sigma, type}; 88 for (double sigma = 0.0; sigma < 2.0; sigma [all...] |
/external/skia/src/effects/ |
H A D | SkBlurMask.h | 18 static bool SK_WARN_UNUSED_RESULT BlurRect(SkScalar sigma, SkMask *dst, const SkRect &src, 22 static bool SK_WARN_UNUSED_RESULT BlurRRect(SkScalar sigma, SkMask *dst, const SkRRect &src, 27 // forceQuality will prevent BoxBlur from falling back to the low quality approach when sigma 39 SkScalar sigma, SkBlurStyle style, SkBlurQuality, 45 static bool SK_WARN_UNUSED_RESULT BlurGroundTruth(SkScalar sigma, SkMask* dst, 49 // If radius > 0, return the corresponding sigma, else return 0 51 // If sigma > 0.5, return the corresponding radius, else return 0 52 static SkScalar SK_API ConvertSigmaToRadius(SkScalar sigma); 67 @param size Should be 6*sigma bytes 68 @param sigma Th [all...] |
H A D | GrCircleBlurFragmentProcessor.fp | 25 const SkRect& circle, float sigma); 38 static float make_unnormalized_half_kernel(float* halfKernel, int halfKernelSize, float sigma) { 39 const float invSigma = 1.f / sigma; 53 // Create a Gaussian half-kernel (right side) and a summed area table given a sigma and number 56 int halfKernelSize, float sigma) { 58 const float tot = 2.f * make_unnormalized_half_kernel(halfKernel, halfKernelSize, sigma); 130 static uint8_t* create_circle_profile(float sigma, float circleR, int profileTextureWidth) { 135 int halfKernelSize = SkScalarCeilToInt(6.0f*sigma); 146 make_half_kernel_and_summed_table(halfKernel, summedKernel, halfKernelSize, sigma); 163 float sigma [all...] |
/external/skqp/src/effects/ |
H A D | SkBlurMask.h | 18 static bool SK_WARN_UNUSED_RESULT BlurRect(SkScalar sigma, SkMask *dst, const SkRect &src, 22 static bool SK_WARN_UNUSED_RESULT BlurRRect(SkScalar sigma, SkMask *dst, const SkRRect &src, 27 // forceQuality will prevent BoxBlur from falling back to the low quality approach when sigma 39 SkScalar sigma, SkBlurStyle style, SkBlurQuality, 45 static bool SK_WARN_UNUSED_RESULT BlurGroundTruth(SkScalar sigma, SkMask* dst, 49 // If radius > 0, return the corresponding sigma, else return 0 51 // If sigma > 0.5, return the corresponding radius, else return 0 52 static SkScalar SK_API ConvertSigmaToRadius(SkScalar sigma); 67 must free the memory. The amount of memory allocated will be exactly 6*sigma bytes. 68 @param sigma Th [all...] |
H A D | GrCircleBlurFragmentProcessor.fp | 25 const SkRect& circle, float sigma); 38 static float make_unnormalized_half_kernel(float* halfKernel, int halfKernelSize, float sigma) { 39 const float invSigma = 1.f / sigma; 53 // Create a Gaussian half-kernel (right side) and a summed area table given a sigma and number 56 int halfKernelSize, float sigma) { 58 const float tot = 2.f * make_unnormalized_half_kernel(halfKernel, halfKernelSize, sigma); 130 static uint8_t* create_circle_profile(float sigma, float circleR, int profileTextureWidth) { 135 int halfKernelSize = SkScalarCeilToInt(6.0f*sigma); 146 make_half_kernel_and_summed_table(halfKernel, summedKernel, halfKernelSize, sigma); 163 float sigma [all...] |
/external/skia/include/c/ |
H A D | sk_maskfilter.h | 41 @param sigma Standard deviation of the Gaussian blur to apply. Must be > 0. 43 sk_maskfilter_t* sk_maskfilter_new_blur(sk_blurstyle_t, float sigma);
|
/external/skia/include/effects/ |
H A D | SkBlurDrawLooper.h | 19 sk_sp<SkDrawLooper> SK_API Make(SkColor color, SkScalar sigma, SkScalar dx, SkScalar dy);
|
H A D | SkBlurMaskFilter.h | 22 * If radius > 0, return the corresponding sigma, else return 0. Use this to convert from the 23 * (legacy) idea of specify the blur "radius" to the standard notion of specifying its sigma. 39 * @param sigma Standard deviation of the Gaussian blur to apply. Must be > 0. 46 static sk_sp<SkMaskFilter> Make(SkBlurStyle style, SkScalar sigma, 49 static sk_sp<SkMaskFilter> Make(SkBlurStyle style, SkScalar sigma, argument 51 return Make(style, sigma, SkRect::MakeEmpty(), flags); 80 SkScalar sigma, SkScalar xformedSigma,
|
/external/skqp/include/c/ |
H A D | sk_maskfilter.h | 41 @param sigma Standard deviation of the Gaussian blur to apply. Must be > 0. 43 sk_maskfilter_t* sk_maskfilter_new_blur(sk_blurstyle_t, float sigma);
|
/external/skqp/include/effects/ |
H A D | SkBlurDrawLooper.h | 19 sk_sp<SkDrawLooper> SK_API Make(SkColor color, SkScalar sigma, SkScalar dx, SkScalar dy);
|
/external/tensorflow/tensorflow/contrib/specs/python/ |
H A D | params_ops.py | 82 def Nt(mu, sigma, limit=3.0): 84 return min(max(random.gauss(mu, sigma), mu-limit*sigma), mu+limit*sigma)
|
/external/skia/gm/ |
H A D | blurtextsmallradii.cpp | 17 for (auto sigma : sigmas) { 20 paint.setMaskFilter(SkBlurMaskFilter::Make(kNormal_SkBlurStyle, sigma));
|
H A D | blurimagevmask.cpp | 31 for (auto sigma:sigmas) { 36 sprintf(out, "Sigma: %g", sigma); 42 SkBlurMaskFilter::Make(kNormal_SkBlurStyle, sigma, 49 imageBlurPaint.setImageFilter(SkBlurImageFilter::Make(sigma, sigma, nullptr));
|
/external/skqp/gm/ |
H A D | blurtextsmallradii.cpp | 17 for (auto sigma : sigmas) { 20 paint.setMaskFilter(SkBlurMaskFilter::Make(kNormal_SkBlurStyle, sigma));
|
H A D | blurimagevmask.cpp | 31 for (auto sigma:sigmas) { 36 sprintf(out, "Sigma: %g", sigma); 42 SkBlurMaskFilter::Make(kNormal_SkBlurStyle, sigma, 49 imageBlurPaint.setImageFilter(SkBlurImageFilter::Make(sigma, sigma, nullptr));
|
/external/skia/src/gpu/effects/ |
H A D | GrRectBlurEffect.h | 23 float sigma) { 24 unsigned int profileSize = SkScalarCeilToInt(6 * sigma); 42 SkBlurMask::ComputeBlurProfile(bitmap.getAddr8(0, 0), profileSize, sigma); 64 float sigma() const { return fSigma; } function in class:GrRectBlurEffect 67 const SkRect& rect, float sigma) { 68 int doubleProfileSize = SkScalarCeilToInt(12 * sigma); 71 // if the blur sigma is too large so the gaussian overlaps the whole 76 sk_sp<GrTextureProxy> blurProfile(CreateBlurProfileTexture(proxyProvider, sigma)); 82 rect, sigma, std::move(blurProfile), 90 GrRectBlurEffect(SkRect rect, float sigma, sk_s argument 22 CreateBlurProfileTexture(GrProxyProvider* proxyProvider, float sigma) argument 66 Make(GrProxyProvider* proxyProvider, const SkRect& rect, float sigma) argument [all...] |
/external/skqp/src/gpu/effects/ |
H A D | GrRectBlurEffect.h | 23 float sigma) { 24 unsigned int profileSize = SkScalarCeilToInt(6 * sigma); 41 std::unique_ptr<uint8_t[]> profile(SkBlurMask::ComputeBlurProfile(sigma)); 56 float sigma() const { return fSigma; } function in class:GrRectBlurEffect 59 const SkRect& rect, float sigma) { 60 int doubleProfileSize = SkScalarCeilToInt(12 * sigma); 63 // if the blur sigma is too large so the gaussian overlaps the whole 68 sk_sp<GrTextureProxy> blurProfile(CreateBlurProfileTexture(proxyProvider, sigma)); 74 rect, sigma, std::move(blurProfile), 82 GrRectBlurEffect(SkRect rect, float sigma, sk_s argument 22 CreateBlurProfileTexture(GrProxyProvider* proxyProvider, float sigma) argument 58 Make(GrProxyProvider* proxyProvider, const SkRect& rect, float sigma) argument [all...] |
/external/libxcam/modules/ocl/ |
H A D | cl_gauss_handler.h | 39 const SmartPtr<CLContext> &context, uint32_t radius, float sigma); 41 bool set_gaussian(uint32_t radius, float sigma); 62 bool set_gaussian_table(int size, float sigma); 72 float sigma = XCAM_GAUSS_DEFAULT_SIGMA);
|