CN111915478A - Beautifying method, device and equipment based on edge-preserving blur and computer-readable storage medium - Google Patents
Beautifying method, device and equipment based on edge-preserving blur and computer-readable storage medium Download PDFInfo
- Publication number
- CN111915478A CN111915478A CN202010675071.7A CN202010675071A CN111915478A CN 111915478 A CN111915478 A CN 111915478A CN 202010675071 A CN202010675071 A CN 202010675071A CN 111915478 A CN111915478 A CN 111915478A
- Authority
- CN
- China
- Prior art keywords
- picture
- processed
- value
- edge
- blur
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
- 238000000034 method Methods 0.000 title claims abstract description 40
- 238000012545 processing Methods 0.000 claims abstract description 80
- 230000003796 beauty Effects 0.000 claims abstract description 15
- 230000000694 effects Effects 0.000 claims abstract description 13
- 238000011282 treatment Methods 0.000 claims abstract description 10
- 238000004590 computer program Methods 0.000 claims description 22
- 238000004364 calculation method Methods 0.000 claims description 12
- 230000008569 process Effects 0.000 claims description 10
- 230000002146 bilateral effect Effects 0.000 claims description 9
- 238000001914 filtration Methods 0.000 claims description 9
- 230000008859 change Effects 0.000 claims description 6
- 239000002537 cosmetic Substances 0.000 claims 2
- 230000001815 facial effect Effects 0.000 claims 2
- 230000006870 function Effects 0.000 description 5
- 238000010586 diagram Methods 0.000 description 4
- 238000004891 communication Methods 0.000 description 2
- 239000011159 matrix material Substances 0.000 description 2
- 210000000697 sensory organ Anatomy 0.000 description 2
- 230000001413 cellular effect Effects 0.000 description 1
- 238000013461 design Methods 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 210000004709 eyebrow Anatomy 0.000 description 1
- 210000004209 hair Anatomy 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 239000007787 solid Substances 0.000 description 1
- 230000002087 whitening effect Effects 0.000 description 1
Images
Classifications
-
- G06T3/04—
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/90—Determination of colour characteristics
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/10—Image acquisition modality
- G06T2207/10024—Color image
Landscapes
- Engineering & Computer Science (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- Image Processing (AREA)
Abstract
The invention discloses a beautifying method based on edge protection blurring, which comprises the following steps: acquiring a picture to be processed; performing edge protection fuzzy processing on the picture to be processed to obtain a first picture; carrying out high contrast processing on the picture to be processed and the first picture to obtain a second picture; and performing beauty treatment on the picture to be processed, the first picture and the second picture to obtain a third picture. This scheme can realize in real-time beautiful face in-process, better carries out edge protection to the edge, reaches better beautiful face effect.
Description
Technical Field
The invention relates to the technical field of image processing, in particular to a beautifying method, device and equipment based on edge preserving blur and a computer readable storage medium.
Background
The beautifying is an operation for beautifying images, and generally comprises various treatments such as skin grinding, whitening, face thinning, eye magnification, nose stereo, mouth adjustment, eyebrow adjustment and the like for beautifying human figures. A general image may include an edge portion including, in the case of a human face, a contour of five sense organs, hair, and the like, and a non-edge portion which may be other than the edge contour. At present, the buffing treatment of a plurality of beautifying schemes on the market is mostly treated by means of Gaussian blur, the Gaussian blur mainly blurs the whole body, and the detailed part cannot be well reserved, so that the beautifying effect is not satisfactory.
The invention is therefore proposed.
Disclosure of Invention
In view of this, the present invention provides a method, an apparatus, and a device for beautifying based on edge preserving blur, which can implement better edge protection on edges in a real-time beautifying process, so as to achieve a better beautifying effect.
In order to achieve the above object, the present invention provides a method for beautifying based on edge preserving blur, the method comprising:
acquiring a picture to be processed;
performing edge protection fuzzy processing on the picture to be processed to obtain a first picture;
carrying out high contrast processing on the picture to be processed and the first picture to obtain a second picture;
and performing beauty treatment on the picture to be processed, the first picture and the second picture to obtain a third picture.
Preferably, the blurring processing of the protection edge further includes bilateral filtering processing, surface blurring processing, and local mean square error processing.
Preferably, the calculation formula for performing high contrast processing on the picture to be processed and the first picture is as follows:
result=oral-blur+128;
wherein, oral is the color value of each pixel point in the picture to be processed; blur is the color value of each pixel point in the first picture; the color value range of the pixel point is 0-255.
Preferably, the performing the beauty treatment on the to-be-processed picture, the first picture and the second picture to obtain a third picture further includes:
(1) calculating the difference transparency p;
p ═ (min (oralRed, mean red-rValue) -oValue) ratavalue; wherein oralRed is a red channel color value of the picture to be processed, meanRed is a red channel color value of the first picture, rValue is a first input value, represents a correlation value of the first picture and the picture to be processed, and has a value range of 0.0-0.2; oValue is the second input value, the value range is 0.1-0.3, and ratValue is the multiple, namely the multiple for amplifying the effect change, the value range is 1.0-10.0;
(2) calculating the color mean value meanAvg of each pixel point in the second picture;
(3) calculating the transparency alpha;
alpha ═ 1.0-meanAvg/(meanAvg + theta)). p ═ blu alpha; wherein, the meanAvg is the color average value in the step (2), the theta is a fixed value, and the value range is 0.05-0.2; p is the differential transparency in step (1); blurAlpha is a user input value, namely the mixing degree, and the value range is 0.0-1.0.
(4) And performing transparency mixing processing on the picture to be processed and the first picture based on transparency alpha to obtain a third picture.
In order to achieve the above object, the present invention further provides a device for beautifying based on edge preserving blur, which is characterized in that the device comprises:
the acquisition unit is used for acquiring a picture to be processed;
the fuzzy processing unit is used for carrying out fuzzy processing of edge protection on the picture to be processed to obtain a first picture;
the high contrast processing unit is used for carrying out high contrast processing on the picture to be processed and the first picture to obtain a second picture;
and the beautifying processing unit is used for carrying out beautifying processing on the picture to be processed, the first picture and the second picture to obtain a third picture.
Preferably, the blurring processing of the protection edge further includes bilateral filtering processing, surface blurring processing, and local mean square error processing.
Preferably, the calculation formula for performing high contrast processing on the picture to be processed and the first picture is as follows:
result=oral-blur+128;
wherein, oral is the color value of each pixel point in the picture to be processed; blur is the color value of each pixel point in the first picture; the color value range of the pixel point is 0-255.
Preferably, the beauty processing unit further includes:
(1) calculating the difference transparency p;
p ═ (min (oralRed, mean red-rValue) -oValue) ratavalue; wherein oralRed is a red channel color value of the picture to be processed, meanRed is a red channel color value of the first picture, rValue is a first input value, represents a correlation value of the first picture and the picture to be processed, and has a value range of 0.0-0.2; oValue is the second input value, the value range is 0.1-0.3, and ratValue is the multiple, namely the multiple for amplifying the effect change, the value range is 1.0-10.0;
(2) calculating the color mean value meanAvg of each pixel point in the second picture;
(3) calculating the transparency alpha;
alpha ═ 1.0-meanAvg/(meanAvg + theta)). p ═ blu alpha; wherein, the meanAvg is the color average value in the step (2), the theta is a fixed value, and the value range is 0.05-0.2; p is the differential transparency in step (1); blurAlpha is a user input value, namely the mixing degree, and the value range is 0.0-1.0.
(4) And performing transparency mixing processing on the picture to be processed and the first picture based on transparency alpha to obtain a third picture.
In order to achieve the above object, the present invention further proposes an edge-preserving blur-based beautifying device, including a processor, a memory, and a computer program stored in the memory, wherein the computer program is capable of implementing the edge-preserving blur-based beautifying method according to the above embodiments when executed by the processor.
In order to achieve the above object, the present invention further provides a computer-readable storage medium, which includes a stored computer program, wherein when the computer program runs, the apparatus on which the computer-readable storage medium is executed is controlled to implement the edge-preserving blur-based beautifying method according to the above embodiment.
Has the advantages that:
according to the scheme, the picture to be processed is obtained; carrying out fuzzy processing of protecting edges on a picture to be processed to obtain a first picture; carrying out high contrast processing on the picture to be processed and the first picture to obtain a second picture; performing beauty treatment on the picture to be processed, the first picture and the second picture to obtain a third picture; the edge protection can be better carried out on the edge in the real-time beautifying process, and a better beautifying effect is achieved.
In the above scheme, the calculation formula for performing high contrast processing on the picture to be processed and the first picture is as follows: residual-blu + 128; wherein, oral is the color value of each pixel point in the picture to be processed; blur is the color value of each pixel point in the first picture; the color value range of the pixel point is 0-255; the noise can be reduced, the details such as edges and the like are kept, and the information of the image can be effectively enhanced.
According to the scheme, the fuzzy processing of the edge is protected, and the method further comprises bilateral filtering processing, surface fuzzy processing and local mean square error processing; the method can play a good role in protecting details and edges.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the drawings without creative efforts.
Fig. 1 is a flowchart illustrating a method for beautifying based on edge preserving blur according to an embodiment of the present invention.
Fig. 2 is a schematic structural diagram of a beauty device based on edge-preserving blur according to an embodiment of the present invention.
The implementation, functional features and advantages of the objects of the present invention will be further explained with reference to the accompanying drawings.
Detailed Description
The present invention will be described in further detail with reference to the accompanying drawings and examples. It is to be noted that the following examples are only illustrative of the present invention, and do not limit the scope of the present invention. Similarly, the following examples are only some but not all examples of the present invention, and all other examples obtained by those skilled in the art without any inventive work are within the scope of the present invention.
The present invention will be described in detail with reference to the following examples.
The invention provides a beautifying method based on edge protection blur, which can better protect edges in a real-time beautifying process and achieve a better beautifying effect.
Fig. 1 is a schematic flow chart of a video beautifying method based on a face recognition technology according to an embodiment of the present invention.
A beautifying method based on edge-preserving blur comprises the following steps:
and S1, acquiring the picture to be processed.
And S2, carrying out edge protection fuzzy processing on the picture to be processed to obtain a first picture.
The fuzzy processing of the protection edge further comprises bilateral filtering processing, surface fuzzy processing and local mean square error processing.
In this embodiment, the blur processing for protecting the edge is performed on the picture to be processed to obtain a blur picture, where the blur picture is the first picture. The fuzzy processing of the protection edge can be processing modes such as bilateral filtering, surface fuzzy, local mean square error and the like. The invention is not limited thereto.
For example, if surface mold processing is used, the fuzzy calculation formula of the protected edge is as follows:
wherein, wijIs the value of the convolution matrix element; i isijIs the image pixel value; i is0Is a diagram corresponding to the center of the matrix templateA pixel value; t is the blur threshold.
And S3, performing high contrast processing on the picture to be processed and the first picture to obtain a second picture.
Wherein, the calculation formula for performing high contrast processing on the picture to be processed and the first picture is as follows:
result=oral-blur+128;
wherein, oral is the color value of each pixel point in the picture to be processed; blur is the color value of each pixel point in the first picture; the color value range of the pixel point is 0-255.
The high contrast processing is to keep the place with large contrast in the original image, for example, in one face image, the place with large contrast is five sense organs, the original image is usually smoothed when face beautification is performed, but the detail information of the image is lost after the processing, so that the detail information of the image is kept on the other side through the high contrast or other high-pass filters, and then the smoothed image and the high-frequency image are subjected to light linear mixing, so that a better effect can be obtained.
In this embodiment, the to-be-processed picture and the blurred picture are calculated to obtain a high-contrast picture, which is the second picture. That is, the color value of the pixel point of the high contrast image is equal to the color value of the pixel point of the image to be processed — the color value of the pixel point of the blurred image + 128.
And S4, performing beauty treatment on the picture to be processed, the first picture and the second picture to obtain a third picture.
In this embodiment, the calculation of the beauty treatment is performed on the picture to be processed, the blurred picture and the high-contrast picture, and finally a beauty result graph is obtained. The specific calculation is as follows:
a. firstly, calculating to obtain the differential transparency p, wherein the formula is as follows:
p=(min(oralRed,meanRed-rValue)-oValue)*ratValue
wherein, oralRed is a red channel color value of the picture to be processed, meanRed is a red channel color value of the blurred picture, and rValue is an input value, which represents a correlation value between the blurred picture and the picture to be processed, and may be 0.0-0.2; oValue is an input value adjusted by a user, is also a default value, and can be between 0.1 and 0.3; the value of ratValue, which is the factor by which the change in effect is to be amplified, may be between 1.0 and 10.0.
b. And calculating the color mean value meanAvg of each pixel point in the high-contrast picture.
The color values of the red channel, the blue channel and the green channel are arranged in each pixel point, and the color values are added and divided by 3 to obtain the color mean value.
c. Calculating the transparency alpha;
alpha=(1.0–meanAvg/(meanAvg+theta))*p*blurAlpha;
wherein, the meanAvg is the color mean value in the step b; theta is a fixed value and can be between 0.05 and 0.2; p is the differential transparency in step a; blurAlpha is a user input value, namely the mixing degree, and the value is between 0.0 and 1.0.
d. Performing transparency mixing processing on the picture to be processed and the fuzzy picture based on transparency alpha to obtain a result graph; the calculation formula is as follows:
resultColor=oralColor*(1.0-alpha)+alpha*blurColor
wherein, the oralColor is the color value of each channel of the picture to be processed; blurColor is the color value of each channel of the fuzzy picture; alpha is the transparency in step c.
According to the scheme, the picture to be processed is obtained; carrying out fuzzy processing of protecting edges on a picture to be processed to obtain a first picture; carrying out high contrast processing on the picture to be processed and the first picture to obtain a second picture; performing beauty treatment on the picture to be processed, the first picture and the second picture to obtain a third picture; the edge protection can be better carried out on the edge in the real-time beautifying process, and a better beautifying effect is achieved.
In the above scheme, the calculation formula for performing high contrast processing on the picture to be processed and the first picture is as follows: residual-blu + 128; wherein, oral is the color value of each pixel point in the picture to be processed; blur is the color value of each pixel point in the first picture; the color value range of the pixel point is 0-255; the noise can be reduced, the details such as edges and the like are kept, and the information of the image can be effectively enhanced.
According to the scheme, the fuzzy processing of the edge is protected, and the method further comprises bilateral filtering processing, surface fuzzy processing and local mean square error processing; the method can play a good role in protecting details and edges.
Fig. 2 is a schematic structural diagram of a beauty device based on edge-protecting blur according to an embodiment of the present invention.
A device for beautifying based on edge-preserving blur, the device 20 comprising:
an obtaining unit 21, configured to obtain a picture to be processed;
the blurring processing unit 22 is configured to perform edge protection blurring processing on the to-be-processed picture to obtain a first picture;
a high contrast processing unit 23, configured to perform high contrast processing on the to-be-processed picture and the first picture to obtain a second picture;
and the beautifying processing unit 24 is configured to perform beautifying processing on the to-be-processed picture, the first picture and the second picture to obtain a third picture.
Optionally, the blurring processing of the protected edge further includes bilateral filtering processing, surface blurring processing, and local mean square error processing.
Optionally, the calculation formula for performing high contrast processing on the to-be-processed picture and the first picture is as follows:
result=oral-blur+128;
wherein, oral is the color value of each pixel point in the picture to be processed; blur is the color value of each pixel point in the first picture; the color value range of the pixel point is 0-255.
Optionally, the beautifying processing unit 24 further includes:
(1) calculating the difference transparency p;
p ═ (min (oralRed, mean red-rValue) -oValue) ratavalue; wherein oralRed is a red channel color value of the picture to be processed, meanRed is a red channel color value of the first picture, rValue is a first input value, represents a correlation value of the first picture and the picture to be processed, and has a value range of 0.0-0.2; oValue is the second input value, the value range is 0.1-0.3, and ratValue is the multiple, namely the multiple for amplifying the effect change, the value range is 1.0-10.0;
(2) calculating the color mean value meanAvg of each pixel point in the second picture;
(3) calculating the transparency alpha;
alpha ═ 1.0-meanAvg/(meanAvg + theta)). p ═ blu alpha; wherein, the meanAvg is the color average value in the step (2), the theta is a fixed value, and the value range is 0.05-0.2; p is the differential transparency in step (1); blurAlpha is a user input value, namely the mixing degree, and the value range is 0.0-1.0;
(4) and performing transparency mixing processing on the picture to be processed and the first picture based on transparency alpha to obtain a third picture.
Each unit module of the beauty device 20 can respectively execute the corresponding steps in the above method embodiments, so that the detailed description of each unit module is omitted here, and please refer to the description of the corresponding steps above.
The embodiment of the present invention further provides a beautifying apparatus based on edge preserving blur, which includes a processor, a memory, and a computer program stored in the memory, where the computer program is executable by the processor to implement the beautifying method based on edge preserving blur according to the foregoing embodiment.
An embodiment of the present invention further provides a computer-readable storage medium, where the computer-readable storage medium includes a stored computer program, where when the computer program runs, a device in which the computer-readable storage medium is located is controlled to execute the method for beautifying based on edge preserving blur according to the foregoing embodiment.
Illustratively, the computer program may be divided into one or more units, which are stored in the memory and executed by the processor to accomplish the present invention. The one or more units may be a series of computer program instruction segments capable of performing specific functions, which are used to describe the execution process of the computer program in the edge-preserving blur-based beautifying device.
The edge preserving blur based beautifying device can include but is not limited to a processor and a memory. It will be understood by those skilled in the art that the schematic diagram is merely an example of a color device based on edge protection fuzziness, and does not constitute a limitation of the color device based on edge protection fuzziness, and may include more or less components than those shown, or combine some components, or different components, for example, the color device based on edge protection fuzziness may further include an input-output device, a network access device, a bus, etc.
The Processor may be a Central Processing Unit (CPU), other general purpose Processor, a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), an off-the-shelf Programmable Gate Array (FPGA) or other Programmable logic device, discrete Gate or transistor logic, discrete hardware components, etc. The general purpose processor may be a microprocessor or the processor may be any conventional processor or the like, the control center of the edge preserving blur based beauty apparatus connects the various parts of the entire edge preserving blur based beauty apparatus with various interfaces and lines.
The memory may be used to store the computer programs and/or modules, and the processor may implement the various functions of the edge-preserving blur-based beautifying device by running or executing the computer programs and/or modules stored in the memory and calling the data stored in the memory. The memory may mainly include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application program required by at least one function (such as a sound playing function, an image playing function, etc.), and the like; the storage data area may store data (such as audio data, a phonebook, etc.) created according to the use of the cellular phone, and the like. In addition, the memory may include high speed random access memory, and may also include non-volatile memory, such as a hard disk, a memory, a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card), at least one magnetic disk storage device, a Flash memory device, or other volatile solid state storage device.
Wherein, the unit integrated by the beautifying device based on edge protection fuzziness can be stored in a computer readable storage medium if the unit is realized in the form of a software functional unit and sold or used as a stand-alone product. Based on such understanding, all or part of the flow of the method according to the embodiments of the present invention may also be implemented by a computer program, which may be stored in a computer-readable storage medium, and when the computer program is executed by a processor, the steps of the method embodiments may be implemented. Wherein the computer program comprises computer program code, which may be in the form of source code, object code, an executable file or some intermediate form, etc.
The computer-readable medium may include: any entity or device capable of carrying the computer program code, recording medium, usb disk, removable hard disk, magnetic disk, optical disk, computer Memory, Read-Only Memory (ROM), Random Access Memory (RAM), electrical carrier wave signals, telecommunications signals, software distribution medium, and the like. It should be noted that the computer readable medium may contain content that is subject to appropriate increase or decrease as required by legislation and patent practice in jurisdictions, for example, in some jurisdictions, computer readable media does not include electrical carrier signals and telecommunications signals as is required by legislation and patent practice.
It should be noted that the above-described device embodiments are merely illustrative, where the units described as separate parts may or may not be physically separate, and the parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the present embodiment. In addition, in the drawings of the embodiment of the apparatus provided by the present invention, the connection relationship between the modules indicates that there is a communication connection between them, and may be specifically implemented as one or more communication buses or signal lines. One of ordinary skill in the art can understand and implement it without inventive effort.
The embodiments in the above embodiments can be further combined or replaced, and the embodiments are only used for describing the preferred embodiments of the present invention, and do not limit the concept and scope of the present invention, and various changes and modifications made to the technical solution of the present invention by those skilled in the art without departing from the design idea of the present invention belong to the protection scope of the present invention.
Claims (10)
1. A method for beautifying based on edge preserving blur, the method comprising:
acquiring a picture to be processed;
performing edge protection fuzzy processing on the picture to be processed to obtain a first picture;
carrying out high contrast processing on the picture to be processed and the first picture to obtain a second picture;
and performing beauty treatment on the picture to be processed, the first picture and the second picture to obtain a third picture.
2. The method of claim 1, wherein the edge-preserving blur-based facial beautification process further comprises a bilateral filtering process, a surface blurring process and a local mean square error process.
3. The method for beautifying face based on edge preserving blur according to claim 1, wherein the calculation formula for performing high contrast processing on the picture to be processed and the first picture is as follows:
result=oral-blur+128;
wherein, oral is the color value of each pixel point in the picture to be processed; blur is the color value of each pixel point in the first picture; the color value range of the pixel point is 0-255.
4. The method of claim 1, wherein the performing a beautifying process on the to-be-processed picture, the first picture and the second picture to obtain a third picture, further comprises:
(1) calculating the difference transparency p;
p ═ (min (oralRed, mean red-rValue) -oValue) ratavalue; wherein oralRed is a red channel color value of the picture to be processed, meanRed is a red channel color value of the first picture, rValue is a first input value, represents a correlation value of the first picture and the picture to be processed, and has a value range of 0.0-0.2; oValue is the second input value, the value range is 0.1-0.3, and ratValue is the multiple, namely the multiple for amplifying the effect change, the value range is 1.0-10.0;
(2) calculating the color mean value meanAvg of each pixel point in the second picture;
(3) calculating the transparency alpha;
alpha ═ 1.0-meanAvg/(meanAvg + theta)). p ═ blu alpha; wherein, the meanAvg is the color average value in the step (2), the theta is a fixed value, and the value range is 0.05-0.2; p is the differential transparency in step (1); blurAlpha is a user input value, namely the mixing degree, and the value range is 0.0-1.0;
(4) and performing transparency mixing processing on the picture to be processed and the first picture based on transparency alpha to obtain a third picture.
5. A device for beautifying based on edge preserving blur, the device comprising:
the acquisition unit is used for acquiring a picture to be processed;
the fuzzy processing unit is used for carrying out fuzzy processing of edge protection on the picture to be processed to obtain a first picture;
the high contrast processing unit is used for carrying out high contrast processing on the picture to be processed and the first picture to obtain a second picture;
and the beautifying processing unit is used for carrying out beautifying processing on the picture to be processed, the first picture and the second picture to obtain a third picture.
6. The apparatus according to claim 5, wherein the edge-preserving blur-based facial beautification apparatus further comprises bilateral filtering, surface blurring, and local mean square error processing.
7. The edge-preserving blur-based beautifying device according to claim 5, wherein the calculation formula for performing high contrast processing on the picture to be processed and the first picture is as follows:
result=oral-blur+128;
wherein, oral is the color value of each pixel point in the picture to be processed; blur is the color value of each pixel point in the first picture; the color value range of the pixel point is 0-255.
8. The apparatus of claim 5, wherein the beautifying processing unit further comprises:
(1) calculating the difference transparency p;
p ═ (min (oralRed, mean red-rValue) -oValue) ratavalue; wherein oralRed is a red channel color value of the picture to be processed, meanRed is a red channel color value of the first picture, rValue is a first input value, represents a correlation value of the first picture and the picture to be processed, and has a value range of 0.0-0.2; oValue is the second input value, the value range is 0.1-0.3, and ratValue is the multiple, namely the multiple for amplifying the effect change, the value range is 1.0-10.0;
(2) calculating the color mean value meanAvg of each pixel point in the second picture;
(3) calculating the transparency alpha;
alpha ═ 1.0-meanAvg/(meanAvg + theta)). p ═ blu alpha; wherein, the meanAvg is the color average value in the step (2), the theta is a fixed value, and the value range is 0.05-0.2; p is the differential transparency in step (1); blurAlpha is a user input value, namely the mixing degree, and the value range is 0.0-1.0;
(4) and performing transparency mixing processing on the picture to be processed and the first picture based on transparency alpha to obtain a third picture.
9. A cosmetic device based on edge preserving blur, comprising a processor, a memory and a computer program stored in the memory, the computer program being executable by the processor to implement the method of cosmetic based on edge preserving blur according to any one of claims 1 to 4.
10. A computer-readable storage medium, comprising a stored computer program, wherein the computer program, when executed, controls an apparatus in which the computer-readable storage medium is located to perform the method for edge-preserving blur based beautifying according to any one of claims 1 to 4.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202010675071.7A CN111915478B (en) | 2020-07-14 | 2020-07-14 | Beautifying method, device and equipment based on edge protection blurring and computer readable storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202010675071.7A CN111915478B (en) | 2020-07-14 | 2020-07-14 | Beautifying method, device and equipment based on edge protection blurring and computer readable storage medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN111915478A true CN111915478A (en) | 2020-11-10 |
CN111915478B CN111915478B (en) | 2023-06-23 |
Family
ID=73281053
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202010675071.7A Active CN111915478B (en) | 2020-07-14 | 2020-07-14 | Beautifying method, device and equipment based on edge protection blurring and computer readable storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN111915478B (en) |
Citations (12)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20110299776A1 (en) * | 2010-04-05 | 2011-12-08 | Lee Kuang-Chih | Systems and methods for segmenting human hairs and faces in color images |
US20120269414A1 (en) * | 2011-04-22 | 2012-10-25 | Toshiba Medical Systems Corporation | Mri gibbs' ringing filtering with edge-protection |
CN104574285A (en) * | 2013-10-23 | 2015-04-29 | 厦门美图网科技有限公司 | Method for automatically removing image black eyes |
CN106169177A (en) * | 2016-06-27 | 2016-11-30 | 北京金山安全软件有限公司 | Image buffing method and device and electronic equipment |
CN106296576A (en) * | 2016-08-05 | 2017-01-04 | 厦门美图之家科技有限公司 | Image processing method and image processing apparatus |
CN107492079A (en) * | 2017-08-28 | 2017-12-19 | 维沃移动通信有限公司 | A kind of image mill skin method and mobile terminal |
CN107730448A (en) * | 2017-10-31 | 2018-02-23 | 北京小米移动软件有限公司 | U.S. face method and device based on image procossing |
CN108090876A (en) * | 2016-11-23 | 2018-05-29 | 北京金山云网络技术有限公司 | A kind of image processing method and device |
WO2018214769A1 (en) * | 2017-05-24 | 2018-11-29 | 阿里巴巴集团控股有限公司 | Image processing method, device and system |
CN109146823A (en) * | 2018-09-25 | 2019-01-04 | 广州华多网络科技有限公司 | Image processing method, device, equipment and the storage medium retained based on high contrast |
US20190066367A1 (en) * | 2017-08-25 | 2019-02-28 | Google Inc. | Methods for dynamic image color remapping using alpha blending |
CN110378846A (en) * | 2019-06-28 | 2019-10-25 | 北京字节跳动网络技术有限公司 | A kind of method, apparatus, medium and the electronic equipment of processing image mill skin |
-
2020
- 2020-07-14 CN CN202010675071.7A patent/CN111915478B/en active Active
Patent Citations (12)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20110299776A1 (en) * | 2010-04-05 | 2011-12-08 | Lee Kuang-Chih | Systems and methods for segmenting human hairs and faces in color images |
US20120269414A1 (en) * | 2011-04-22 | 2012-10-25 | Toshiba Medical Systems Corporation | Mri gibbs' ringing filtering with edge-protection |
CN104574285A (en) * | 2013-10-23 | 2015-04-29 | 厦门美图网科技有限公司 | Method for automatically removing image black eyes |
CN106169177A (en) * | 2016-06-27 | 2016-11-30 | 北京金山安全软件有限公司 | Image buffing method and device and electronic equipment |
CN106296576A (en) * | 2016-08-05 | 2017-01-04 | 厦门美图之家科技有限公司 | Image processing method and image processing apparatus |
CN108090876A (en) * | 2016-11-23 | 2018-05-29 | 北京金山云网络技术有限公司 | A kind of image processing method and device |
WO2018214769A1 (en) * | 2017-05-24 | 2018-11-29 | 阿里巴巴集团控股有限公司 | Image processing method, device and system |
US20190066367A1 (en) * | 2017-08-25 | 2019-02-28 | Google Inc. | Methods for dynamic image color remapping using alpha blending |
CN107492079A (en) * | 2017-08-28 | 2017-12-19 | 维沃移动通信有限公司 | A kind of image mill skin method and mobile terminal |
CN107730448A (en) * | 2017-10-31 | 2018-02-23 | 北京小米移动软件有限公司 | U.S. face method and device based on image procossing |
CN109146823A (en) * | 2018-09-25 | 2019-01-04 | 广州华多网络科技有限公司 | Image processing method, device, equipment and the storage medium retained based on high contrast |
CN110378846A (en) * | 2019-06-28 | 2019-10-25 | 北京字节跳动网络技术有限公司 | A kind of method, apparatus, medium and the electronic equipment of processing image mill skin |
Also Published As
Publication number | Publication date |
---|---|
CN111915478B (en) | 2023-06-23 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN108205804B (en) | Image processing method and device and electronic equipment | |
US9495582B2 (en) | Digital makeup | |
CN107194869B (en) | Image processing method and terminal, computer storage medium and computer equipment | |
CN112784773B (en) | Image processing method and device, storage medium and terminal | |
US20090220169A1 (en) | Image enhancement | |
CN104517265A (en) | Intelligent buffing method and intelligent buffing device | |
CN112214773B (en) | Image processing method and device based on privacy protection and electronic equipment | |
CN113808027B (en) | Human body image processing method and device, electronic equipment and storage medium | |
CN105023252A (en) | Method and system for enhancement processing of beautified image and shooting terminal | |
CN112766204A (en) | Image processing method, image processing apparatus, and computer-readable storage medium | |
WO2019047409A1 (en) | Image processing method and system, readable storage medium and mobile camera device | |
US6323855B1 (en) | Sharpening edge features in digital image providing high frequency edge enhancement | |
CN108346128B (en) | Method and device for beautifying and peeling | |
WO2017161542A1 (en) | Skin map-aided skin smoothing of images using a bilateral filter | |
CN111815729B (en) | Real-time skin beautifying method, device, equipment and computer storage medium | |
CN111915478B (en) | Beautifying method, device and equipment based on edge protection blurring and computer readable storage medium | |
CN111932442A (en) | Video beautifying method, device and equipment based on face recognition technology and computer readable storage medium | |
CN114862729A (en) | Image processing method, image processing device, computer equipment and storage medium | |
CN113256534B (en) | Image enhancement method, device and medium | |
CN115170386A (en) | Portrait image processing method, portrait image processing device, electronic equipment and storage medium | |
CN113379623B (en) | Image processing method, device, electronic equipment and storage medium | |
CN114742725A (en) | Image processing method, image processing device, electronic equipment and storage medium | |
CN114187202A (en) | Image processing method, apparatus, device, storage medium, and program product | |
CN110895789B (en) | Face beautifying method and device | |
CN111986095A (en) | Image processing method and image processing device based on edge extraction |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |