CN107292939A - A kind of wrinkle generation method and electronic equipment - Google Patents
A kind of wrinkle generation method and electronic equipment Download PDFInfo
- Publication number
- CN107292939A CN107292939A CN201610212559.XA CN201610212559A CN107292939A CN 107292939 A CN107292939 A CN 107292939A CN 201610212559 A CN201610212559 A CN 201610212559A CN 107292939 A CN107292939 A CN 107292939A
- Authority
- CN
- China
- Prior art keywords
- wrinkle
- pixel value
- image
- parameter
- average
- 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.)
- Pending
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T11/00—2D [Two Dimensional] image generation
- G06T11/20—Drawing from basic elements, e.g. lines or circles
- G06T11/203—Drawing of straight lines or curves
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T15/00—3D [Three Dimensional] image rendering
- G06T15/50—Lighting effects
- G06T15/503—Blending, e.g. for anti-aliasing
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V40/00—Recognition of biometric, human-related or animal-related patterns in image or video data
- G06V40/10—Human or animal bodies, e.g. vehicle occupants or pedestrians; Body parts, e.g. hands
- G06V40/16—Human faces, e.g. facial parts, sketches or expressions
- G06V40/168—Feature extraction; Face representation
- G06V40/171—Local features and components; Facial parts ; Occluding parts, e.g. glasses; Geometrical relationships
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2200/00—Indexing scheme for image data processing or generation, in general
- G06T2200/04—Indexing scheme for image data processing or generation, in general involving 3D image data
Landscapes
- Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- Health & Medical Sciences (AREA)
- Oral & Maxillofacial Surgery (AREA)
- General Health & Medical Sciences (AREA)
- Computer Graphics (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Human Computer Interaction (AREA)
- Multimedia (AREA)
- Image Processing (AREA)
Abstract
The invention discloses a kind of wrinkle generation method and electronic equipment, belong to image processing field.Methods described includes:Wrinkle parameter is obtained, the wrinkle parameter is used to describe corresponding wrinkle;According to the wrinkle parameter, the wrinkle and target image are fitted.The present invention improves the effect that wrinkle is generated on target image, the amount of calculation of reduction wrinkle generation improves the efficiency of wrinkle generation, and real-time is higher by the way that according to the wrinkle parameter, the wrinkle and target image are fitted.
Description
Technical field
The present invention relates to image processing field, more particularly to a kind of wrinkle generation method and electronic equipment.
Background technology
Wrinkle is the important component of human body face, in the neck such as recognition of face, virtual reality, human face cartoon
Domain extensive use.In computer realm, due to the category such as wrinkle number, position, shape and gray scale form
Property unstructured and uncertainty, simultaneously because the structure of wrinkle is more fine, in extraction process, hold
Easily influenceed by factors such as the visual field, illumination, shooting angle so that the simulation of wrinkle is more difficult, so existing
There is great significance providing a kind of method of efficient generation wrinkle.
In the prior art, someone divides level to produce fine wrinkles using Voronoi (Thiessen polygon) figure
And user-defined Cubic kolmogorov's differential system produces large-scale wrinkle, but the calculating of this method is more multiple
It is miscellaneous so that relatively low using computational efficiency during this method;Someone is carried out by the wrinkle shape to face database
Statistical analysis, to draw the general shape of wrinkle, the method for carrying out moulding to wrinkle grid using curve, but
Or be the method generation of this driving grid wrinkle it is more coarse, and amount of calculation is excessive, poor real;
Wrinkle is generated by the method based on texture mapping at present, calculating speed is very fast in this way, and in real time
Property it is high, but the wrinkle of generation easily produces distortion phenomenon, such as the abnormal display of profile or due to not having
Have the texture sampling for considering parallax and producing incorrect etc..
The content of the invention
In order to improve the effect of generation wrinkle, the amount of calculation of reduction wrinkle generation improves the efficiency of wrinkle generation,
The embodiments of the invention provide a kind of wrinkle generation method and electronic equipment.The technical scheme is as follows:
There is provided a kind of wrinkle generation method for first aspect, it is characterised in that methods described includes:
Wrinkle parameter is obtained, the wrinkle parameter is used to describe corresponding wrinkle;
According to the wrinkle parameter, the wrinkle and target image are fitted.
With reference in a first aspect, in the first possible implementation, the acquisition wrinkle parameter includes:
The image and multiple images for including wrinkle not comprising wrinkle of identical face are obtained under same light photograph;
The image not comprising wrinkle is compared with multiple described images comprising wrinkle;
According to the result of the comparison, the wrinkle parameter is obtained.
With reference to the first possible implementation of first aspect, in second of possible implementation, institute
State by the image not comprising wrinkle with it is described multiple comprising wrinkle images be compared including:
The pixel value of the pixel value of the image not comprising wrinkle and multiple images comprising wrinkle is entered
Row subtracts each other, and obtains the difference of multigroup pixel value after subtracting each other.
With reference to the first possible implementation of first aspect, in the third possible implementation, institute
Stating the image not comprising wrinkle being compared with multiple described images comprising wrinkle also includes:
The pixel value of the pixel value of the image not comprising wrinkle and multiple images comprising wrinkle is entered
Row is divided by, and obtains the ratio of multigroup pixel value after being divided by.
With reference to second of first aspect or the third possible implementation, the 4th kind of possible realization side
Described according to the result of the comparison in formula, obtaining wrinkle parameter includes:
Calculate the average of the average of the difference of multigroup pixel value or the ratio of multigroup pixel value;
According to the average of calculating, wrinkle parameter is obtained.
With reference to the 4th kind of possible implementation of first aspect, in the 5th kind of possible implementation, institute
Stating the average of the average for the difference for calculating multigroup pixel value or the ratio of multigroup pixel value includes:
According to weight coefficient, the ratio of difference or multigroup pixel value to multigroup pixel value is added
Weight average, obtains the average or multigroup pixel value of the difference of multigroup pixel value after weighted average
The average of ratio.
With reference to the 5th kind of possible implementation of first aspect, in the 6th kind of possible implementation, institute
Stating method also includes:
According to the human face characteristic point of the human face characteristic point of the image comprising wrinkle, and the target image, calculate
The weight coefficient.
With reference to the 5th kind of possible implementation of first aspect, in the 7th kind of possible implementation, institute
State according to the wrinkle parameter, by the wrinkle and target image be fitted including:
The average of the difference of multigroup pixel value is added with the pixel value of the target image;Or
The average of the ratio of multigroup pixel value is multiplied by the pixel value of the target image.
Second aspect is there is provided a kind of electronic equipment, and the equipment includes:
Wrinkle parameter module is obtained, for obtaining wrinkle parameter, the wrinkle parameter is used to describe corresponding wrinkle
Line;
Fitting module, for according to the wrinkle parameter, the wrinkle and target image to be fitted.
With reference to second aspect, in the first possible implementation, the acquisition wrinkle parameter module includes:
Obtain image submodule, for obtained under being shone in same light the image not comprising wrinkle of identical face with
Multiple include the image of wrinkle;
Comparison sub-module, for the image not comprising wrinkle to be entered with multiple described images comprising wrinkle
Row compares;
Wrinkle parameter sub-module is obtained, for according to the result of the comparison, obtaining the wrinkle parameter.
With reference to the first possible implementation of second aspect, in second of possible implementation, institute
State comparison sub-module specifically for:
The pixel value of the pixel value of the image not comprising wrinkle and multiple images comprising wrinkle is entered
Row subtracts each other, and obtains the difference of multigroup pixel value after subtracting each other.
With reference to the first possible implementation of second aspect, in the third possible implementation, institute
State comparison sub-module also particularly useful for:
The pixel value of the pixel value of the image not comprising wrinkle and multiple images comprising wrinkle is entered
Row is divided by, and obtains the ratio of multigroup pixel value after being divided by.
With reference to second of second aspect or the third possible implementation, the 4th kind of possible realization side
In formula, the acquisition wrinkle parameter sub-module enclosed mass:
Equal value cell is calculated, average or multigroup pixel value for the difference that calculates multigroup pixel value
Ratio average;
Wrinkle parameters unit is obtained, for the average according to calculating, wrinkle parameter is obtained.
With reference to the 4th kind of possible implementation of second aspect, in the 5th kind of possible implementation, institute
State the equal value cell of calculating specifically for:
According to weight coefficient, the ratio of difference or multigroup pixel value to multigroup pixel value is added
Weight average, obtains the average or multigroup pixel value of the difference of multigroup pixel value after weighted average
The average of ratio.
With reference to the 5th kind of possible implementation of second aspect, in the 6th kind of possible implementation, institute
Stating acquisition wrinkle parameter module also includes:
Weight coefficient module is calculated, for the human face characteristic point according to the image comprising wrinkle, and the target
The human face characteristic point of image, calculates the weight coefficient.
With reference to the 5th kind of possible implementation of second aspect, in the 7th kind of possible implementation, institute
State fitting module specifically for:
The average of the difference of multigroup pixel value is added with the pixel value of the target image;Or
The average of the ratio of multigroup pixel value is multiplied by the pixel value of the target image.
The third aspect is there is provided a kind of electronic equipment, and the electronic equipment includes display screen, camera, deposited
Reservoir and the processor being connected with the display screen, the camera, the memory, wherein, it is described
Memory is used to store batch processing code, and the processor calls the program code that the memory is stored
For performing following operation:
Wrinkle parameter is obtained, the wrinkle parameter is used to describe corresponding wrinkle;
According to the wrinkle parameter, the wrinkle and target image are fitted.
With reference to the third aspect, in the first possible implementation, the processor calls the memory
The program code stored is used to perform following operation:
The image and multiple images for including wrinkle not comprising wrinkle of identical face are obtained under same light photograph;
The image not comprising wrinkle is compared with multiple described images comprising wrinkle;
According to the result of the comparison, the wrinkle parameter is obtained.
With reference to the first possible implementation of the third aspect, in second of possible implementation, institute
State processor and call the program code that the memory is stored for performing following operation:
The pixel value of the pixel value of the image not comprising wrinkle and multiple images comprising wrinkle is entered
Row subtracts each other, and obtains the difference of multigroup pixel value after subtracting each other.
With reference to the first possible implementation of the third aspect, in the third possible implementation, institute
State processor and call the program code that the memory is stored for performing following operation:
The pixel value of the pixel value of the image not comprising wrinkle and multiple images comprising wrinkle is entered
Row is divided by, and obtains the ratio of multigroup pixel value after being divided by.
With reference to second of the third aspect or the third possible implementation, the 4th kind of possible realization side
In formula, the program code that the processor calls the memory to be stored is used to perform following operation:
Calculate the average of the average of the difference of multigroup pixel value or the ratio of multigroup pixel value;
According to the average of calculating, wrinkle parameter is obtained.
With reference to the 4th kind of possible implementation of the third aspect, in the 5th kind of possible implementation, institute
State processor and call the program code that the memory is stored for performing following operation:
According to weight coefficient, the ratio of difference or multigroup pixel value to multigroup pixel value is added
Weight average, obtains the average or multigroup pixel value of the difference of multigroup pixel value after weighted average
The average of ratio.
With reference to the 5th kind of possible implementation of the third aspect, in the 6th kind of possible implementation, institute
State processor and call the program code that the memory is stored for performing following operation:
According to the human face characteristic point of the human face characteristic point of the image comprising wrinkle, and the target image, calculate
The weight coefficient.
With reference to the 5th kind of possible implementation of the third aspect, in the 7th kind of possible implementation, institute
State processor and call the program code that the memory is stored for performing following operation:
The average of the difference of multigroup pixel value is added with the pixel value of the target image;Or
The average of the ratio of multigroup pixel value is multiplied by the pixel value of the target image.
The embodiment of the present invention improves a kind of wrinkle generation method and electronic equipment.Methods described includes:Obtain
Wrinkle parameter, the wrinkle parameter is used to describe corresponding wrinkle;According to the wrinkle parameter, by the wrinkle
Line is fitted with target image.The present invention is by according to the wrinkle parameter, by the wrinkle and target figure
As being fitted, the effect that wrinkle is generated on target image is improved, the amount of calculation of wrinkle generation is reduced,
The efficiency of wrinkle generation is improved, and real-time is higher.
Brief description of the drawings
Technical scheme in order to illustrate the embodiments of the present invention more clearly, institute in being described below to embodiment
The accompanying drawing needed to use is briefly described, it should be apparent that, drawings in the following description are only the present invention
Some embodiments, for those of ordinary skill in the art, on the premise of not paying creative work,
Other accompanying drawings can also be obtained according to these accompanying drawings.
Fig. 1 is a kind of wrinkle generation method flow chart provided in an embodiment of the present invention;
Fig. 2 is a kind of wrinkle generation method flow chart provided in an embodiment of the present invention;
Fig. 3 is electronic devices structure schematic diagram provided in an embodiment of the present invention;
Fig. 4 is electronic devices structure schematic diagram provided in an embodiment of the present invention.
Embodiment
To make the object, technical solutions and advantages of the present invention clearer, below in conjunction with the embodiment of the present invention
In accompanying drawing, the technical scheme in the embodiment of the present invention is clearly and completely described, it is clear that retouched
The embodiment stated is only a part of embodiment of the invention, rather than whole embodiments.Based in the present invention
Embodiment, those of ordinary skill in the art obtained under the premise of creative work is not made it is all its
His embodiment, belongs to the scope of protection of the invention.
Embodiment one
The embodiments of the invention provide a kind of wrinkle generation method, shown in reference picture 1, methods described includes:
101st, wrinkle parameter is obtained.
Wherein, the wrinkle parameter is used to describe corresponding wrinkle.
Specifically, obtaining the process of wrinkle parameter can include:
The image and multiple images for including wrinkle not comprising wrinkle of identical face are obtained under same light photograph;
The image not comprising wrinkle is compared with multiple described images comprising wrinkle;
According to the result of the comparison, the wrinkle parameter is obtained.
Wherein it is possible to be accomplished by the following way by the image not comprising wrinkle with it is described multiple comprising wrinkle
The process that the image of line is compared:
The pixel value of the pixel value of the image not comprising wrinkle and multiple images comprising wrinkle is entered
Row subtracts each other, and obtains the difference of multigroup pixel value after subtracting each other.
Can also be accomplished by the following way by the image not comprising wrinkle with it is described multiple comprising wrinkle
The process that image is compared:
The pixel value of the pixel value of the image not comprising wrinkle and multiple images comprising wrinkle is entered
Row is divided by, and obtains the ratio of multigroup pixel value after being divided by.
Wherein, according to the result of the comparison, obtaining the process of wrinkle parameter can include:
Calculate the average of the average of the difference of multigroup pixel value or the ratio of multigroup pixel value;
According to the average of calculating, wrinkle parameter is obtained.
Specifically, the average or the ratio of multigroup pixel value of the difference for calculating multigroup pixel value
The process of average can include:
According to weight coefficient, the ratio of difference or multigroup pixel value to multigroup pixel value is added
Weight average, obtains the average or multigroup pixel value of the difference of multigroup pixel value after weighted average
The average of ratio.
Optionally, method also includes:
According to the human face characteristic point of the human face characteristic point of the image comprising wrinkle, and the target image, calculate
The weight coefficient.
102nd, according to the wrinkle parameter, the wrinkle and target image are fitted.
The average of the difference of multigroup pixel value is added with the pixel value of the target image;Or
The average of the ratio of multigroup pixel value is multiplied by the pixel value of the target image.
The embodiments of the invention provide a kind of wrinkle generation method, by according to the wrinkle parameter, by described in
Wrinkle is fitted with target image, improves the effect that wrinkle is generated on target image, reduction wrinkle life
Into amount of calculation, improve the efficiency of wrinkle generation, and real-time is higher.
Embodiment two
The embodiments of the invention provide a kind of wrinkle generation method, shown in reference picture 2, methods described includes:
201st, the image and multiple figures for including wrinkle not comprising wrinkle of identical face are obtained under same light photograph
Picture.
Specifically, acquisition can be the image being acquired by the camera of electronic equipment or obtain
The stored image taken, the embodiment of the present invention is not limited to specific acquisition modes.
Wherein, the image not comprising wrinkle can include direct picture when disposition is expressed one's feelings in face, multiple bags
Image containing wrinkle can include direct picture face when doing different expressions;The direct picture can include
Positive plane picture and positive 3-D view.
Same light can also pass through light source according to that can be determined by the output parameter of the light sensitive component of electronic equipment
Intensity determine, can also determine by other means, the embodiment of the present invention is not limited to this.
Because images that the image not comprising wrinkle for obtaining identical face includes wrinkle with multiple are in illumination phase
Obtain simultaneously, so influence of the illumination to the wrinkle parameter of acquisition is avoided, so as to improve the wrinkle of acquisition
The accuracy of parameter.
202nd, the image not comprising wrinkle is compared with multiple described images comprising wrinkle.
The process can be accomplished by the following way:
The pixel value of the pixel value of the image not comprising wrinkle and multiple images comprising wrinkle is entered
Row subtracts each other, and obtains the difference of multigroup pixel value after subtracting each other.
If specifically, described image is gray level image, by each pixel of the image not comprising wrinkle
The pixel of the pixel value of point respectively with each pixel of the correspondence position of multiple images comprising wrinkle
Value is subtracted each other, and obtains the difference of multigroup pixel value after subtracting each other;If described image is RGB (three primary colors, Red
Red, Green is green, and Blue is blue) image, then by each pixel of the image not comprising wrinkle
Each pixel of R values, G values and B values respectively with the correspondence position of multiple images comprising wrinkle
R values, G values and B values subtracted each other, obtain subtract each other after multigroup R values, G values, the difference of B values;
If described image is RGB image, the RGB image can also be converted to and be handled after gray level image.
The process can also be realized by the following method:
The pixel value of the pixel value of the image not comprising wrinkle and multiple images comprising wrinkle is entered
Row is divided by, and obtains the ratio of multigroup pixel value after being divided by.
If specifically, described image is gray level image, by each pixel of the image not comprising wrinkle
The pixel of the pixel value of point respectively with each pixel of the correspondence position of multiple images comprising wrinkle
Value is divided by, and obtains multigroup ratio after being divided by;If described image is that (three primary colors, Red is red, Green by RGB
Green, Blue is blue) image, then by the R values of each pixel of the image not comprising wrinkle, G values
And the B values R values of each pixel respectively with the correspondence position of multiple images comprising wrinkle, G
Value and B values are divided by, and obtain multigroup R values after being divided by, G values, the ratio of B values;If described image
For RGB image, the RGB image can also be converted to and be handled after gray level image.
Wherein, method also includes:
The scope of the ratio is set.
Specifically, the ratio range can be more than or equal to the first default ratio, it is default less than or equal to second
Ratio;If the ratio calculated is more than the described second default ratio, the ratio of the calculating is set to described
Second default ratio, if the ratio calculated is less than the described first default ratio, the ratio of the calculating is set
It is set to the described first default ratio.Exemplary, the ratio range can be [0.5,2], if the ratio calculated
Value is more than 2, then the ratio is set into 2, if the ratio calculated is less than 0.5, the ratio is set into 0.5.
It should be noted that for when pixel value is zero carry out ratio calculated, to the pixel value, addition is pre- at random
If pixel value, the presetted pixel value can be the random less pixel value of numerical value.
Because the image not comprising wrinkle comes from identical face with multiple described images comprising wrinkle, and
Illumination is identical, it is ensured that the acquisition condition phase for the images that the image for not including wrinkle includes wrinkle with multiple
Together, so that after the image not comprising wrinkle and the image comprising wrinkle are subtracted each other or be divided by, what is obtained is more
The difference or ratio of group pixel value are the parameter of multigroup wrinkle, and by the process, operation is succinct, and keeps away
Influence of the illumination condition to the wrinkle parameter of acquisition is exempted from.
203rd, according to the result of the comparison, the wrinkle parameter is obtained.
Wherein, the wrinkle parameter is used to describe corresponding wrinkle.
Specifically, the process can include:
The average of a, the average of the difference of calculating multigroup pixel value or multigroup pixel value ratio.
Specifically, calculating the process of the average of the difference of multigroup pixel value can include:
If described image is RGB image, by the difference of the R values, G values and B values of same pixel point position
Value is separately summed, then respectively divided by image comprising wrinkle number, be R values, the G of the pixel position
The average of the difference of value and B values, mean value computation is carried out to each pixel;If described image is gray scale
Multigroup difference of same pixel point position, then be added by image, then divided by image comprising wrinkle
Number, is the average of the difference of the pixel position, mean value computation is carried out to each pixel.
Calculating the process of the average of the ratio of multigroup pixel value can include:
If described image is RGB image, respectively by multiple R values, G values and the B of same pixel point position
The ratio of value is added respectively, then respectively divided by image comprising wrinkle number, be pixel position
The average for the ratio put, mean value computation is carried out to each pixel;If described image is gray level image,
Multiple ratios of same pixel point position are added, then divided by image comprising wrinkle number, be
The average of the ratio of the pixel position, mean value computation is carried out to each pixel.
Calculate the process of the average of the difference of multigroup pixel value or the average of the ratio of multigroup pixel value
It can also include:
According to weight coefficient, the ratio of difference or multigroup pixel value to multigroup pixel value is added
Weight average, obtains the average or multigroup pixel value of the difference of multigroup pixel value after weighted average
The average of ratio.
Specifically, being calculated by below equation:
A=∑s wiAi
Wherein, AiRepresent i-th of difference or ratio, wiRepresent i-th of difference or the corresponding weight system of ratio
Number.
Wherein, weight coefficient can calculate acquisition in the following manner:
According to the human face characteristic point of the human face characteristic point of the image comprising wrinkle, and the target image, calculate
The weight coefficient.
Specifically, being calculated by below equation:
Y=∑s wixi
Wherein, xiFor the human face characteristic point of i-th image comprising wrinkle, wiRepresent i-th image correspondence
Weight coefficient, Y be target image human face characteristic point.
B, the average according to calculating, obtain wrinkle parameter.
Specifically, according to the average of calculating, obtaining the pixel value or ratio for describing corresponding wrinkle.
It should be noted that step 201 to step 202 is to realize the process for obtaining wrinkle parameter, except upper
State outside mode, can also realize the process by other means, the embodiment of the present invention to specific mode not
It is limited.
204th, according to the wrinkle parameter, the wrinkle and target image are fitted.
Specifically, the process can be accomplished by the following way:
The average of the difference of multigroup pixel value is added with the pixel value of the target image.
According to the average of the difference of multigroup pixel value, by the picture of the average of each pixel
The pixel value of element value each pixel corresponding with the target image is added.
The process can also be accomplished by the following way:
The average of the ratio of multigroup pixel value is multiplied by the pixel value of the target image.
According to the average of the ratio of multigroup pixel value, the ratio of each pixel is multiplied by institute
State the pixel value of corresponding each pixel of target image.
It should be noted that be not that each step 204 that performs will perform step 201 to step 203 before,
The wrinkle parameter that wrinkle parameter in step 204 can also be the storage obtained is performed, the embodiment of the present invention is to this
It is not limited.
If when performing step 204, the wrinkle parameter of acquisition is the wrinkle parameter of storage, then step 204 it
Before, method can include:
Obtain and store wrinkle parameter.
Specifically, the process for obtaining wrinkle parameter is identical with described in step 201 to step 203, herein not
It is repeated here again.
Wherein, in addition to obtaining and storing wrinkle parameter, in addition to obtain and store and retouched by wrinkle parameter
The size parameter for the wrinkle image stated, includes the numerical value of length and width, resolution ratio etc.;Also include obtaining the wrinkle
Intensity of illumination during line parameter;Also the information of face corresponding with the wrinkle image that wrinkle parameter is described is included,
The information of the face includes the sample type of the face, and multiple characteristic points for describing the face are joined
Number etc..
In addition to this it is possible to obtain and store the related other information of the wrinkle parameter, the present invention is implemented
Example is not limited to this.
It is worth noting that, when obtaining the wrinkle parameter of storage, obtaining identical with the illumination condition of target image
Wrinkle parameter.
Because the wrinkle parameter of storage can be obtained, so as to further increase the efficiency of wrinkle generation, improve
Generation wrinkle it is ageing, meanwhile, because wrinkle parameter calculation procedure has been completed, so as to be fitted
Cheng Wuxu is carrying out the calculating of wrinkle parameter, need to be only fitted by parameter with target image, so as to enter one
Step reduces the amount of calculation of wrinkle generation, improves the efficiency of wrinkle generation, reduces to electronic equipment processing
The occupancy of resource, is improved ageing;Meanwhile, because the illumination condition of the wrinkle parameter obtained and target figure
The illumination of picture is identical, so that the influence that illumination is generated to wrinkle is avoided, so as to further increase in target
The effect of wrinkle is generated on image, Consumer's Experience is improved.
Optionally, obtaining and storing wrinkle information can be realized by setting up wrinkle parameter database.
The embodiment of the present invention is not limited to the process for specifically setting up wrinkle parameter database.
Optionally, before the step 204, mode also includes:
Adjust the size of the target image or wrinkle image.
Specifically, the wrinkle image is described by the wrinkle parameter.
The size of the target image is adjusted to identical with the size of the wrinkle image;Or by the wrinkle
The size of image is adjusted to identical with the size of the target image.
It can also pass through and adjust by adjusting the size of target image described in resolution adjustment or wrinkle image
Whole length and wide numerical value adjust the size of the target image or wrinkle image, can also institute by other means
The size of target image or wrinkle image is stated, the embodiment of the present invention is not limited to this.
The embodiments of the invention provide a kind of wrinkle generation method, by according to the wrinkle parameter, by described in
Wrinkle is fitted with target image, improves the effect that wrinkle is generated on target image, reduction wrinkle life
Into amount of calculation, improve the efficiency of wrinkle generation, and real-time is higher;Meanwhile, because obtaining identical face
Image not comprising wrinkle with multiple images comprising wrinkle obtained when illumination is identical, so avoiding
Influence of the illumination to the wrinkle parameter of acquisition, so as to improve the accuracy of the wrinkle parameter of acquisition.
Embodiment three
The embodiments of the invention provide a kind of electronic equipment 3, shown in reference picture 3, the equipment includes:
Wrinkle parameter module 31 is obtained, for obtaining wrinkle parameter, the wrinkle parameter is used to describe corresponding
Wrinkle;
Fitting module 32, for according to the wrinkle parameter, the wrinkle and target image to be fitted.
Optionally, the acquisition wrinkle parameter module 31 includes:
Obtain image submodule 311, the image not comprising wrinkle for obtaining identical face under being shone in same light
The image of wrinkle is included with multiple;
Comparison sub-module 312, for by the image not comprising wrinkle with it is described multiple include the image of wrinkle
It is compared;
Wrinkle parameter sub-module 313 is obtained, for according to the result of the comparison, obtaining the wrinkle parameter.
Optionally, the comparison sub-module 312 specifically for:
The pixel value of the pixel value of the image not comprising wrinkle and multiple images comprising wrinkle is entered
Row subtracts each other, and obtains the difference of multigroup pixel value after subtracting each other.
Optionally, the comparison sub-module 312 also particularly useful for:
The pixel value of the pixel value of the image not comprising wrinkle and multiple images comprising wrinkle is entered
Row is divided by, and obtains the ratio of multigroup pixel value after being divided by.
Optionally, the enclosed mass of acquisition wrinkle parameter sub-module 313:
Equal value cell 3131 is calculated, average or multigroup picture for the difference that calculates multigroup pixel value
The average of the ratio of element value;
Wrinkle parameters unit 3132 is obtained, for the average according to calculating, wrinkle parameter is obtained.
Optionally, it is described calculate equal value cell 3131 specifically for:
According to weight coefficient, the ratio of difference or multigroup pixel value to multigroup pixel value is added
Weight average, obtains the average or multigroup pixel value of the difference of multigroup pixel value after weighted average
The average of ratio.
Optionally, the acquisition wrinkle parameter module 31 also includes:
Weight coefficient module 314 is calculated, for the human face characteristic point according to the image comprising wrinkle, and the mesh
The human face characteristic point of logo image, calculates the weight coefficient.
Optionally, the fitting module 32 specifically for:
The average of the difference of multigroup pixel value is added with the pixel value of the target image;Or
The average of the ratio of multigroup pixel value is multiplied by the pixel value of the target image.
The embodiments of the invention provide a kind of electronic equipment, the electronic equipment by according to the wrinkle parameter,
The wrinkle and target image are fitted, the effect that wrinkle is generated on target image, reduction is improved
The amount of calculation of wrinkle generation, improves the efficiency of wrinkle generation, and real-time is higher;Meanwhile, because obtaining phase
It is obtained when illumination is identical with image of the face not comprising wrinkle with multiple images comprising wrinkle, so
Influence of the illumination to the wrinkle parameter of acquisition is avoided, so as to improve the accuracy of the wrinkle parameter of acquisition.
Example IV
The embodiments of the invention provide a kind of electronic equipment 4, the electronic equipment includes display screen 41, shooting
First 42, memory 43 and it is connected with the display screen 41, the camera 42, the memory 43
Processor 44, wherein, the memory 43 is used to store batch processing code, and the processor 44 is called
The program code that the memory 43 is stored is used to perform following operation:
Wrinkle parameter is obtained, the wrinkle parameter is used to describe corresponding wrinkle;
According to the wrinkle parameter, the wrinkle and target image are fitted.
Optionally, the processor 44 call the program code that the memory 43 stored be used to performing with
Lower operation:
The image and multiple images for including wrinkle not comprising wrinkle of identical face are obtained under same light photograph;
The image not comprising wrinkle is compared with multiple described images comprising wrinkle;
According to the result of the comparison, the wrinkle parameter is obtained.
Optionally, the processor 44 call the program code that the memory 43 stored be used to performing with
Lower operation:
The pixel value of the pixel value of the image not comprising wrinkle and multiple images comprising wrinkle is entered
Row subtracts each other, and obtains the difference of multigroup pixel value after subtracting each other.
Optionally, the processor 44 call the program code that the memory 43 stored be used to performing with
Lower operation:
The pixel value of the pixel value of the image not comprising wrinkle and multiple images comprising wrinkle is entered
Row is divided by, and obtains the ratio of multigroup pixel value after being divided by.
Optionally, the processor 44 call the program code that the memory 43 stored be used to performing with
Lower operation:
Calculate the average of the average of the difference of multigroup pixel value or the ratio of multigroup pixel value;
According to the average of calculating, wrinkle parameter is obtained.
Optionally, the processor 44 call the program code that the memory 43 stored be used to performing with
Lower operation:
According to weight coefficient, the ratio of difference or multigroup pixel value to multigroup pixel value is added
Weight average, obtains the average or multigroup pixel value of the difference of multigroup pixel value after weighted average
The average of ratio.
Optionally, the processor 44 call the program code that the memory 43 stored be used to performing with
Lower operation:
According to the human face characteristic point of the human face characteristic point of the image comprising wrinkle, and the target image, calculate
The weight coefficient.
Optionally, the processor 44 call the program code that the memory 43 stored be used to performing with
Lower operation:
The average of the difference of multigroup pixel value is added with the pixel value of the target image;Or
The average of the ratio of multigroup pixel value is multiplied by the pixel value of the target image.
The embodiments of the invention provide a kind of electronic equipment, the electronic equipment by according to the wrinkle parameter,
The wrinkle and target image are fitted, the effect that wrinkle is generated on target image, reduction is improved
The amount of calculation of wrinkle generation, improves the efficiency of wrinkle generation, and real-time is higher;Meanwhile, because obtaining phase
It is obtained when illumination is identical with image of the face not comprising wrinkle with multiple images comprising wrinkle, so
Influence of the illumination to the wrinkle parameter of acquisition is avoided, so as to improve the accuracy of the wrinkle parameter of acquisition.
Above-mentioned all optional technical schemes, can form the alternative embodiment of the present invention using any combination,
This is no longer repeated one by one.
It should be noted that:Above-described embodiment provide electronic equipment implement wrinkle generation method when, only with
The division progress of above-mentioned each functional module, can be as needed and by above-mentioned work(for example, in practical application
It can distribute and be completed by different functional modules, i.e., the internal structure of equipment is divided into different functional modules,
To complete all or part of function described above.In addition, electronic equipment and wrinkle that above-described embodiment is provided
Line generation method embodiment belongs to same design, and it implements process and refers to embodiment of the method, here no longer
Repeat.
One of ordinary skill in the art will appreciate that realizing all or part of step of above-described embodiment can pass through
Hardware is completed, and the hardware of correlation can also be instructed to complete by program, described program can be stored in
In a kind of computer-readable recording medium, storage medium mentioned above can be read-only storage, disk or
CD etc..
Presently preferred embodiments of the present invention is the foregoing is only, is not intended to limit the invention, it is all the present invention's
Within spirit and principle, any modification, equivalent substitution and improvements made etc. should be included in the present invention's
Within protection domain.
Claims (10)
1. a kind of wrinkle generation method, it is characterised in that methods described includes:
Wrinkle parameter is obtained, the wrinkle parameter is used to describe corresponding wrinkle;
According to the wrinkle parameter, the wrinkle and target image are fitted.
2. according to the method described in claim 1, it is characterised in that the acquisition wrinkle parameter includes:
The image and multiple images for including wrinkle not comprising wrinkle of identical face are obtained under same light photograph;
The image not comprising wrinkle is compared with multiple described images comprising wrinkle;
According to the result of the comparison, the wrinkle parameter is obtained.
3. method according to claim 2, it is characterised in that described by the figure not comprising wrinkle
As with it is described multiple comprising wrinkle images be compared including:
The pixel value of the pixel value of the image not comprising wrinkle and multiple images comprising wrinkle is entered
Row subtracts each other, and obtains the difference of multigroup pixel value after subtracting each other.
4. method according to claim 2, it is characterised in that described by the figure not comprising wrinkle
Also include as being compared with multiple described images comprising wrinkle:
The pixel value of the pixel value of the image not comprising wrinkle and multiple images comprising wrinkle is entered
Row is divided by, and obtains the ratio of multigroup pixel value after being divided by.
5. the method according to claim 3 or 4, it is characterised in that the knot according to the comparison
Really, obtaining wrinkle parameter includes:
Calculate the average of the average of the difference of multigroup pixel value or the ratio of multigroup pixel value;
According to the average of calculating, wrinkle parameter is obtained.
6. method according to claim 5, it is characterised in that calculating multigroup pixel value
The average of the ratio of the average of difference or multigroup pixel value includes:
According to weight coefficient, the ratio of difference or multigroup pixel value to multigroup pixel value is added
Weight average, obtains the average or multigroup pixel value of the difference of multigroup pixel value after weighted average
The average of ratio.
7. method according to claim 6, it is characterised in that methods described also includes:
According to the human face characteristic point of the human face characteristic point of the image comprising wrinkle, and the target image, calculate
The weight coefficient.
8. method according to claim 6, it is characterised in that described according to the wrinkle parameter, will
The wrinkle and target image be fitted including:
The average of the difference of multigroup pixel value is added with the pixel value of the target image;Or
The average of the ratio of multigroup pixel value is multiplied by the pixel value of the target image.
9. a kind of electronic equipment, it is characterised in that the equipment includes:
Wrinkle parameter module is obtained, for obtaining wrinkle parameter, the wrinkle parameter is used to describe corresponding wrinkle
Line;
Fitting module, for according to the wrinkle parameter, the wrinkle and target image to be fitted.
10. equipment according to claim 9, it is characterised in that the acquisition wrinkle parameter module bag
Include:
Obtain image submodule, for obtained under being shone in same light the image not comprising wrinkle of identical face with
Multiple include the image of wrinkle;
Comparison sub-module, for the image not comprising wrinkle to be entered with multiple described images comprising wrinkle
Row compares;
Wrinkle parameter sub-module is obtained, for according to the result of the comparison, obtaining the wrinkle parameter.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610212559.XA CN107292939A (en) | 2016-04-07 | 2016-04-07 | A kind of wrinkle generation method and electronic equipment |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610212559.XA CN107292939A (en) | 2016-04-07 | 2016-04-07 | A kind of wrinkle generation method and electronic equipment |
Publications (1)
Publication Number | Publication Date |
---|---|
CN107292939A true CN107292939A (en) | 2017-10-24 |
Family
ID=60092918
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201610212559.XA Pending CN107292939A (en) | 2016-04-07 | 2016-04-07 | A kind of wrinkle generation method and electronic equipment |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN107292939A (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN112562026A (en) * | 2020-10-22 | 2021-03-26 | 百果园技术(新加坡)有限公司 | Wrinkle special effect rendering method and device, electronic equipment and storage medium |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1870049A (en) * | 2006-06-15 | 2006-11-29 | 西安交通大学 | Human face countenance synthesis method based on dense characteristic corresponding and morphology |
CN101556699A (en) * | 2008-11-07 | 2009-10-14 | 浙江大学 | Face-based facial aging image synthesis method |
-
2016
- 2016-04-07 CN CN201610212559.XA patent/CN107292939A/en active Pending
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1870049A (en) * | 2006-06-15 | 2006-11-29 | 西安交通大学 | Human face countenance synthesis method based on dense characteristic corresponding and morphology |
CN101556699A (en) * | 2008-11-07 | 2009-10-14 | 浙江大学 | Face-based facial aging image synthesis method |
Non-Patent Citations (2)
Title |
---|
ZICHENG LIU等: "Expressive expression mapping with ratio images", 《SIGGRAPH》 * |
朱文辉: "基于FAP的细微表情合成", 《中国优秀硕士学位论文全文数据库信息科技辑》 * |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN112562026A (en) * | 2020-10-22 | 2021-03-26 | 百果园技术(新加坡)有限公司 | Wrinkle special effect rendering method and device, electronic equipment and storage medium |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN107578390A (en) | A kind of method and device that image white balance correction is carried out using neutral net | |
CN103002225B (en) | Multiple exposure high dynamic range image capture | |
CN107945125A (en) | It is a kind of to merge spectrum estimation method and the fuzzy image processing method of convolutional neural networks | |
CN105118027B (en) | A kind of defogging method of image | |
Wang et al. | Variational single nighttime image haze removal with a gray haze-line prior | |
CN103325120A (en) | Rapid self-adaption binocular vision stereo matching method capable of supporting weight | |
Nayak et al. | A modified triangle box-counting with precision in error fit | |
CN107610093B (en) | Full-reference image quality evaluation method based on similarity feature fusion | |
CN108109201A (en) | The three-dimensional rebuilding method and system of complex colors surface object | |
CN107507144A (en) | Processing method, device and the image processing apparatus of colour of skin enhancing | |
US9892542B2 (en) | Creating bump and normal maps from images with multi-scale control | |
CN108682039A (en) | A kind of binocular stereo vision measurement method | |
CN114862725B (en) | Method and device for realizing motion perception fuzzy special effect based on optical flow method | |
CN111724317A (en) | Method for constructing Raw domain video denoising supervision data set | |
CN106412441A (en) | Video anti-shake control method and terminal | |
CN108242063A (en) | A kind of light field image depth estimation method accelerated based on GPU | |
CN108195312A (en) | Color body three-dimensional rebuilding method and system based on changeable weight | |
CN107993189A (en) | A kind of picture tone dynamic regulating method and device based on local block | |
CN107767356A (en) | A kind of image processing method and device | |
CN107832359A (en) | A kind of picture retrieval method and system | |
CN114004754A (en) | Scene depth completion system and method based on deep learning | |
CN107451595A (en) | Infrared image salient region detection method based on hybrid algorithm | |
CN116229205A (en) | Lipstick product surface defect data augmentation method based on small sample characteristic migration | |
CN107292939A (en) | A kind of wrinkle generation method and electronic equipment | |
KR101513931B1 (en) | Auto-correction method of composition and image apparatus with the same technique |
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 | ||
WD01 | Invention patent application deemed withdrawn after publication |
Application publication date: 20171024 |
|
WD01 | Invention patent application deemed withdrawn after publication |