Method and device for realizing Gaussian blur
A technology of Gaussian blur and implementation method, applied in the field of image processing, can solve the problem of unacceptable efficiency, and achieve the effect of reducing the amount of calculation and improving the processing speed
- Summary
- Abstract
- Description
- Claims
- Application Information
AI Technical Summary
Problems solved by technology
Method used
Image
Examples
Embodiment 1
[0039] Such as figure 1 As shown, a Gaussian blur implementation method includes the following steps:
[0040] (1) Determine the convolution kernel width K according to the image processing width width input by the user, specifically:
[0041] First, determine the convolution kernel radius R according to R=ceil(3*width);
[0042] Then, the convolution kernel width K is determined according to K=2*R+1.
[0043] (2) Determine the specific value of the convolution kernel according to the convolution kernel width K and the Gaussian function.
[0044] (3) Perform two one-dimensional Gaussian convolutions on the image to be processed according to the determined convolution kernel to obtain the target image. The steps are specifically:
[0045] First, perform horizontal one-dimensional Gaussian convolution on each row of the image to be processed from the horizontal direction;
[0046] Then, perform vertical one-dimensional Gaussian convolution on the result of the above-mention...
Embodiment 2
[0056] The difference between this embodiment 2 and embodiment 1 is that, on the basis of embodiment 1, this embodiment 2 fully considers when performing horizontal one-dimensional Gaussian convolution, in order to solve the problem of pixel values in the neighborhood adjacent to the boundary pixel problem, and the introduction of a large number of conditional branch statements, thus affecting the computational efficiency of the problem. Because, when performing horizontal one-dimensional Gaussian convolution, it is calculated by multiplying and summing the pixel value in each pixel neighborhood (that is, the neighborhood with a width of K) and the one-dimensional Gaussian convolution kernel, However, for some pixels that are closer to the image boundary, the pixels in the neighborhood have exceeded the starting position or the ending position of the line. Usually, it is necessary to use the method of boundary pixel extension to simulate these pixels, that is, if it is less t...
Embodiment 3
[0060] The difference between this embodiment 3 and embodiment 1 is that, on the basis of embodiment 1, this embodiment 3 fully considers that after performing horizontal one-dimensional Gaussian convolution, a larger buffer is required for data storage, so as to Causes the problem of lower CPU cache utilization. Because in the implementation method of Gaussian blur introduced in Example 1, since the horizontal one-dimensional Gaussian convolution is performed on the image first, and then the vertical one-dimensional Gaussian convolution is performed, it is usually necessary to allocate a buffer as large as the original image area to store the result of horizontal one-dimensional Gaussian convolution, and then use the image in this buffer (that is: the result of horizontal one-dimensional Gaussian convolution) as input to perform vertical one-dimensional Gaussian convolution, and put the result into the target image. Therefore, when the image size is relatively large, it is ne...
PUM
Abstract
Description
Claims
Application Information
- R&D Engineer
- R&D Manager
- IP Professional
- Industry Leading Data Capabilities
- Powerful AI technology
- Patent DNA Extraction
Browse by: Latest US Patents, China's latest patents, Technical Efficacy Thesaurus, Application Domain, Technology Topic, Popular Technical Reports.
© 2024 PatSnap. All rights reserved.Legal|Privacy policy|Modern Slavery Act Transparency Statement|Sitemap|About US| Contact US: help@patsnap.com