CN104994281A - Method for correcting face distortion and terminal - Google Patents

Method for correcting face distortion and terminal Download PDF

Info

Publication number
CN104994281A
CN104994281A CN201510378947.0A CN201510378947A CN104994281A CN 104994281 A CN104994281 A CN 104994281A CN 201510378947 A CN201510378947 A CN 201510378947A CN 104994281 A CN104994281 A CN 104994281A
Authority
CN
China
Prior art keywords
face
distortion
terminal
distortion correction
distorted region
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
Application number
CN201510378947.0A
Other languages
Chinese (zh)
Other versions
CN104994281B (en
Inventor
曾元清
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guangdong Oppo Mobile Telecommunications Corp Ltd
Original Assignee
Guangdong Oppo Mobile Telecommunications Corp Ltd
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Guangdong Oppo Mobile Telecommunications Corp Ltd filed Critical Guangdong Oppo Mobile Telecommunications Corp Ltd
Priority to CN201510378947.0A priority Critical patent/CN104994281B/en
Publication of CN104994281A publication Critical patent/CN104994281A/en
Application granted granted Critical
Publication of CN104994281B publication Critical patent/CN104994281B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Image Processing (AREA)
  • Studio Devices (AREA)

Abstract

The embodiment of the invention discloses a method for correcting face distortion and a terminal. The method comprises: a step of detecting human faces in a view finding image taken by a camera of the terminal; a step of judging whether a distortion area in which distortion coefficients are greater than a preset threshold exists in M human faces when it is detected that the M human faces exist in the view finding image, wherein M is an integer greater than or equal to 1; and if so, the distortion area is subjected to the distortion correction. According to the embodiment of the invention, the human face in the view finding image taken by the camera is detected, and the detected human face is subjected to the distortion correction, thereby reducing the distortion degree of the distorted human face in a wide-angle camera.

Description

A kind of method of face distortion correction and terminal
Technical field
The embodiment of the present invention relates to technical field of electronic equipment, refers more particularly to a kind of method and terminal of face distortion correction.
Background technology
Along with developing rapidly of information technology, the integrated attainable function of terminal gets more and more, as taken pictures, surfing the Net, play, do shopping etc., but terminal is not omnipotent, in prior art, terminal can realize taking pictures, but in process of taking pictures, the scope of taking pictures also exists certain constraint.
Under normal circumstances, can expect adopting wide-angle camera to take pictures, but the image that wide-angle camera is taken out is exceeding the generation distortion of the region outside certain angle scope, the generation of this distortion is because the characteristic of wide-angle camera self causes, especially carry out distortion correction to the face of wide-angle camera shooting separately for thinking, prior art still not yet solves.
Summary of the invention
Embodiments provide a kind of method and terminal of face distortion correction, carry out distortion correction to the face of finding a view in picture to wide-angle camera, thus, reduce the distortion degree of this face.
Embodiment of the present invention first aspect discloses a kind of method of face distortion correction, comprises step:
Face datection is carried out to the picture of finding a view that the camera of terminal photographs;
There is M face if find a view described in detecting in picture, judge whether to exist in a described M face distorted region that distortion factor is greater than predetermined threshold value, wherein, M be more than or equal to 1 integer;
If so, distortion correction is carried out to described distorted region.
Correspondingly, embodiment of the present invention second aspect discloses a kind of terminal, comprising:
Detecting unit, carries out Face datection for the picture of finding a view photographed the camera of terminal;
Judging unit, if there is M face in picture of finding a view described in detecting for described detecting unit, judges whether to exist in a described M face distorted region that distortion factor is greater than predetermined threshold value, wherein, M be more than or equal to 1 integer;
Correcting unit, for judging to exist in a described M face distorted region that distortion factor is greater than predetermined threshold value at described judging unit, carries out distortion correction to described distorted region.
What the camera of the embodiment of the present invention to terminal photographed find a view, and picture carries out Face datection; There is M face if find a view described in detecting in picture, judge whether to exist in a described M face distorted region that distortion factor is greater than predetermined threshold value, wherein, M be more than or equal to 1 integer; If so, distortion correction is carried out to described distorted region.Adopt the embodiment of the present invention can to detect the face of finding a view in picture that camera photographs, and distortion correction is carried out to the face detected, thus, the distortion degree of the face that distorts in reduction wide-angle camera.
Accompanying drawing explanation
In order to be illustrated more clearly in the technical scheme in the embodiment of the present invention, be briefly described to the accompanying drawing used required in embodiment, description below, apparently, accompanying drawing in the following describes is only some embodiments of the embodiment of the present invention, for those of ordinary skill in the art, under the prerequisite not paying creative work, other accompanying drawing can also be obtained according to these accompanying drawings.
The schematic flow sheet of the first embodiment of the method for a kind of face distortion correction that Fig. 1 provides for the embodiment of the present invention;
The schematic flow sheet of the second embodiment of the method for a kind of face distortion correction that Fig. 2 provides for the embodiment of the present invention;
The schematic flow sheet of the 3rd embodiment of the method for a kind of face distortion correction that Fig. 3 provides for the embodiment of the present invention;
The structural representation of the first embodiment of a kind of terminal that Fig. 4 a provides for the embodiment of the present invention;
The another structural representation of the first embodiment of a kind of terminal that Fig. 4 b provides for the embodiment of the present invention;
The another structural representation of the first embodiment of a kind of terminal that Fig. 4 c provides for the embodiment of the present invention;
The another structural representation of the first embodiment of a kind of terminal that Fig. 4 d provides for the embodiment of the present invention;
The another structural representation of the first embodiment of a kind of terminal that Fig. 4 e provides for the embodiment of the present invention;
The structural representation of the second embodiment of a kind of terminal that Fig. 5 provides for the embodiment of the present invention.
Embodiment
Below in conjunction with the accompanying drawing in the embodiment of the present invention, be clearly and completely described the technical scheme in the embodiment of the present invention, obviously, described embodiment is only embodiment of the present invention part embodiment, instead of whole embodiments.Based on the embodiment in the embodiment of the present invention, those of ordinary skill in the art are not making the every other embodiment obtained under creative work prerequisite, all belong to the scope of embodiment of the present invention protection.
In realization, in the embodiment of the present invention, terminal can include but not limited to: notebook computer, mobile phone, panel computer, intelligent wearable device etc.The system of terminal refers to the operating system of equipment, can include but not limited to: android system, Saipan system, Windows system, IOS (Mobile operating system of Apple's exploitation), XP system, windows 8 system etc.It should be noted that, Android terminal refers to the terminal of android system, and Saipan terminal refers to the terminal of Saipan system, etc.Above-mentioned terminal is only citing, and non exhaustive, including but not limited to above-mentioned terminal.
In specific implementation, the camera described in the embodiment of the present invention is wide-angle camera, and its scope is greater than the photo angle of existing common camera.In the embodiment of the present invention, problem to be solved only carries out distortion correction to the distorted region of the face in picture of finding a view that wide-angle camera photographs, and other distorted regions do not process.
Embodiment of the present invention composition graphs 1 to Fig. 5 is described the method for a kind of face distortion correction that the embodiment of the present invention provides and terminal.
Refer to Fig. 1, Fig. 1 is the schematic flow sheet of the first embodiment of the method for a kind of face distortion correction that the embodiment of the present invention provides.The method of the face distortion correction described in the present embodiment, comprises step:
S101, Face datection is carried out to the picture of finding a view that the camera of terminal photographs.
Wherein, terminal can carry out Face datection to the picture of finding a view that the camera of this terminal is taken.Face datection can according to the face mask of people, face feature (as nose, eyes, face, eyebrow etc.), and current human face detection tech is comparatively ripe.
As a kind of possible execution mode, before terminal can carry out Face datection at the picture of finding a view photographed the camera of terminal, determine the pre-photo angle scope of the camera of this terminal, user is when the camera starting terminal, can according to the angular range of the scenery adjustment shooting wanting to take pictures, pre-photo angle scope is exactly that user determines according to the size in region shared by scenery in scene.Terminal first can obtain the touch instruction of the photo angle scope that user selects, according to the pre-photo angle scope of the camera of this instruction determination terminal.Such as, if the scenery scope in scene is smaller, then pre-photo angle scope can be adjusted to the camera lens scope of common camera, and in this case, the photo obtained of taking pictures distorts very little, can think undistorted; If the scenery scope in scene is comparatively large, exceeded the camera lens scope of common camera, the image of pre-photo angle scope carries out distortion correction possibly.
As a kind of possible execution mode, the camera of terminal can be front-facing camera or the post-positioned pick-up head of terminal; Or the camera of terminal can be terminal wirelessly or the camera that controls of wired mode.
There is M face if find a view described in S102 detects in picture, judge whether to exist in a described M face distorted region that distortion factor is greater than predetermined threshold value, wherein, M be more than or equal to 1 integer.
Wherein, if terminal detects the situation that there is M face in picture of finding a view, can judge whether to exist in this M face the distortion factor that distortion factor is greater than predetermined threshold value.Occupy certain area due in the picture of finding a view that face photographs at camera, thus, face is at diverse location, and the distortion factor on this position is different.It should be noted that, under normal circumstances, due to the characteristic of wide-angle camera self, thus, the distortion of wide-angle camera exists always, and wide-angle camera has symmetry characteristic under normal circumstances, with the center of wide-angle camera to both sides, distortion factor presents symmetrical, and distortion factor occurred in the prior art, does not do too much description at this.Distortion factor represents the distortion degree of the image that wide-angle camera is taken, the distortion factor of wide-angle camera is larger, illustrate that distortion is larger, and the distortion factor of wide-angle camera within the specific limits, namely distortion factor is less than the situation of a certain predetermined threshold value, then can think that distortion factor is less than region corresponding to a certain predetermined threshold value is orthoscopic zone, and the photo angle scope of its correspondence may be defined as undistorted photo angle scope.
As a kind of possible execution mode, terminal can determine the corresponding angle scope being less than or equal to the picture of finding a view that camera corresponding to above-mentioned predetermined threshold value photographs; And judge the region that whether exists in M face outside described corresponding angle scope.
S103, if so, distortion correction is carried out to described distorted region.
Wherein, if terminal detects in M face the distortion factor that there is distortion factor and be greater than predetermined threshold value, then distortion correction is carried out to this distorted region.Further, human face region is divided into distortion factor according to the large I of distortion factor and is less than or equal to the distorted region that the region of predetermined threshold value and distortion factor be greater than predetermined threshold value, distortion correction can be carried out to the region that distortion factor is greater than predetermined threshold value, and the distorted region being less than or equal to predetermined threshold value is remained unchanged.
As a kind of possible execution mode, suppose that distorted region comprises distorted region i, terminal can obtain the distortion correction coefficient of user for this distorted region i; According to described distortion correction coefficient, distortion correction is carried out to described distorted region i.That is, user can, to arbitrary face distorted region, adopt same distortion correction coefficient to correct.
What the camera of the embodiment of the present invention to terminal photographed find a view, and picture carries out Face datection; There is M face if find a view described in detecting in picture, judge whether to exist in a described M face distorted region that distortion factor is greater than predetermined threshold value, wherein, M be more than or equal to 1 integer; If so, distortion correction is carried out to described distorted region.Adopt the embodiment of the present invention can to detect the face of finding a view in picture that camera photographs, and distortion correction is carried out to the face detected, thus, the distortion degree of the face that distorts in reduction wide-angle camera.
Refer to Fig. 2, Fig. 2 is the schematic flow sheet of the second embodiment of the method for a kind of face distortion correction that the embodiment of the present invention provides.The method of the face distortion correction described in the present embodiment, comprises step:
S201, Face datection is carried out to the picture of finding a view that the camera of terminal photographs.
Wherein, terminal can carry out Face datection to the picture of finding a view that the camera of this terminal is taken.Face datection can according to the face mask of people, face feature (as nose, eyes, face, eyebrow etc.), and current human face detection tech is comparatively ripe.
There is M face if find a view described in S202 detects in picture, judge whether to exist in a described M face distorted region that distortion factor is greater than predetermined threshold value, wherein, M be more than or equal to 1 integer.
Wherein, if terminal detects the situation that there is M face in picture of finding a view, can judge whether to exist in this M face the distortion factor that distortion factor is greater than predetermined threshold value.Occupy certain area due in the picture of finding a view that face photographs at camera, thus, face is at diverse location, and the distortion factor on this position is different.
S203, if so, distortion correction is carried out to described distorted region.
Wherein, if terminal detects in M face the distortion factor that there is distortion factor and be greater than predetermined threshold value, then distortion correction is carried out to this distorted region.Further, human face region is divided into distortion factor according to the large I of distortion factor and is less than or equal to the distorted region that the region of predetermined threshold value and distortion factor be greater than predetermined threshold value, distortion correction can be carried out to the region that distortion factor is greater than predetermined threshold value, and the distorted region being less than or equal to predetermined threshold value is remained unchanged.
S204, determine the size of the human face region after distortion correction.
Wherein, terminal can determine the size of the human face region after distortion correction, terminal can carry out contour detecting to the face after distortion correction, to determine the size of human face region, or terminal can determine the size of human face region according to the position of the human face region size before non-distortion correction and the corresponding pixel value obtained after carrying out a series of algorithm calculating to human face region.
S205, determine the first position of centre of gravity of described distorted region according to the size of the human face region after described distortion correction and calculate the second position of centre of gravity of correcting area corresponding to described distorted region, described first position of centre of gravity and described second position of centre of gravity are overlapped, what the camera using the position of centre of gravity after overlapping as center, described correcting area being fused to described terminal photographed finds a view in picture.
Wherein, terminal is determined the first position of centre of gravity of distorted region according to the size of the human face region after distortion correction and is calculated the second position of centre of gravity of correcting area corresponding to distorted region, first position of centre of gravity and described second position of centre of gravity are overlapped, what the camera using the position of centre of gravity after overlapping as center, correcting area being fused to terminal photographed finds a view in picture.Thus the human face region after correction is mounted in original distorted position better.
What the camera of the embodiment of the present invention to terminal photographed find a view, and picture carries out Face datection; There is M face if find a view described in detecting in picture, judge whether to exist in a described M face distorted region that distortion factor is greater than predetermined threshold value, wherein, M be more than or equal to 1 integer; If so, distortion correction is carried out to described distorted region; Determine the size of the human face region after distortion correction; Determine the position of centre of gravity of correcting area corresponding to the position of centre of gravity of described distorted region and described distorted region, both overlapped, what as center, described correcting area to be fused to that the camera of described terminal photographs by the position of centre of gravity after coincidence finds a view in picture.Adopt the embodiment of the present invention can to detect the face of finding a view in picture that camera photographs, and distortion correction is carried out to the face detected, thus, reduce to distort in wide-angle camera the distortion degree of face, meanwhile, the face after distortion correction can be placed on the position of the face before non-distortion correction.
Refer to Fig. 3, Fig. 3 is the schematic flow sheet of the 3rd embodiment of the method for a kind of face distortion correction that the embodiment of the present invention provides.The method of the face distortion correction described in the present embodiment, comprises step:
S301, Face datection is carried out to the picture of finding a view that the camera of terminal photographs.
Wherein, terminal can carry out Face datection to the picture of finding a view that the camera of this terminal is taken.Face datection can according to the face mask of people, face feature (as nose, eyes, face, eyebrow etc.), and current human face detection tech is comparatively ripe.
There is M face if find a view described in S302 detects in picture, judge whether to exist in a described M face distorted region that distortion factor is greater than predetermined threshold value, wherein, M be more than or equal to 1 integer.
Wherein, if terminal detects the situation that there is M face in picture of finding a view, can judge whether to exist in this M face the distortion factor that distortion factor is greater than predetermined threshold value.Occupy certain area due in the picture of finding a view that face photographs at camera, thus, face is at diverse location, and the distortion factor on this position is different.
The distortion threshold value of S303, if so, acquisition user input.
Wherein, if terminal detects in M face the distortion factor that there is distortion factor and be greater than predetermined threshold value, the distortion threshold value of user's input can be obtained, this threshold value adjusts for user, terminal can adjust the human face region being greater than this threshold value, and does not process the human face region being less than or equal to this threshold value.
S304, determine that in described distorted region, distortion factor is greater than the target area of described distortion threshold value.
Wherein, terminal determines that in distorted region, distortion factor is greater than the target area of this distortion threshold value, and in the distorted region namely in human face region, distortion factor is greater than distortion threshold coefficient pixel and can forms target area.
S305, distortion correction is carried out to described target area.
Wherein, terminal only can carry out distortion correction to target area, thus, the fault image of some entertaining can be produced, because the different fault image that different distortion factor is corresponding.
What the camera of the embodiment of the present invention to terminal photographed find a view, and picture carries out Face datection; There is M face if find a view described in detecting in picture, judge whether to exist in a described M face distorted region that distortion factor is greater than predetermined threshold value, wherein, M be more than or equal to 1 integer; If so, the distortion threshold value of user's input is obtained; Determine that in described distorted region, distortion factor is greater than the target area of described distortion threshold value; Distortion correction is carried out to described target area.So, for the distortion threshold value of user's input, distortion correction can be carried out to the distorted region in face, thus the distortion degree of the face that distorts in reduction wide-angle camera, has interest simultaneously.
Refer to Fig. 4 a, Fig. 4 a is the schematic flow sheet of the first embodiment of a kind of terminal that the embodiment of the present invention provides.The method of the terminal described in the present embodiment, comprises step:
Detecting unit 401, carries out Face datection for the picture of finding a view photographed the camera of terminal.
Wherein, detecting unit 401 can carry out Face datection to the picture of finding a view that the camera of this terminal is taken.Face datection can according to the face mask of people, face feature (as nose, eyes, face, eyebrow etc.), and current human face detection tech is comparatively ripe.
As a kind of possible execution mode, terminal described by the embodiment of the present invention also can comprise determining unit (not marking in figure), it is for before can carrying out Face datection at the picture of finding a view photographed the camera of terminal, determine the pre-photo angle scope of the camera of this terminal, user is when the camera starting terminal, can according to the angular range of the scenery adjustment shooting wanting to take pictures, pre-photo angle scope is exactly that user determines according to the size in region shared by scenery in scene.Terminal first can obtain the touch instruction of the photo angle scope that user selects, according to the pre-photo angle scope of the camera of this instruction determination terminal.Such as, if the scenery scope in scene is smaller, then pre-photo angle scope can be adjusted to the camera lens scope of common camera, and in this case, the photo obtained of taking pictures distorts very little, can think undistorted; If the scenery scope in scene is comparatively large, exceeded the camera lens scope of common camera, the image of pre-photo angle scope carries out distortion correction possibly.
As a kind of possible execution mode, the camera of terminal can be front-facing camera or the post-positioned pick-up head of terminal; Or the camera of terminal can be terminal wirelessly or the camera that controls of wired mode.
Judging unit 402, if there is M face in picture of finding a view described in detecting for described detecting unit 401, judges whether to exist in a described M face distorted region that distortion factor is greater than predetermined threshold value, wherein, M be more than or equal to 1 integer.
Wherein, if detecting unit 401 detects the situation that there is M face in picture of finding a view, judging unit 402 can judge whether to exist in this M face the distortion factor that distortion factor is greater than predetermined threshold value.Occupy certain area due in the picture of finding a view that face photographs at camera, thus, face is at diverse location, and the distortion factor on this position is different.It should be noted that, under normal circumstances, due to the characteristic of wide-angle camera self, thus, the distortion of wide-angle camera exists always, and wide-angle camera has symmetry characteristic under normal circumstances, with the center of wide-angle camera to both sides, distortion factor presents symmetrical, and distortion factor occurred in the prior art, does not do too much description at this.Distortion factor represents the distortion degree of the image that wide-angle camera is taken, the distortion factor of wide-angle camera is larger, illustrate that distortion is larger, and the distortion factor of wide-angle camera within the specific limits, namely distortion factor is less than the situation of a certain predetermined threshold value, then can think that distortion factor is less than region corresponding to a certain predetermined threshold value is orthoscopic zone, and the photo angle scope of its correspondence may be defined as undistorted photo angle scope.
As a kind of possible execution mode, as shown in Figure 4 b, the judging unit 402 of the terminal in Fig. 4 a described by the embodiment of the present invention also can comprise: the first determining unit 4021 and judgment sub-unit 4022, specific as follows:
First determining unit 4021, for determining the corresponding angle scope being less than or equal to the picture of finding a view that described camera corresponding to described predetermined threshold value photographs;
Judgment sub-unit 4022, for judging whether to exist in a described M face region outside corresponding angle scope that described determining unit determines.
Correcting unit 403, for judging to exist in a described M face distorted region that distortion factor is greater than predetermined threshold value at described judging unit 402, carries out distortion correction to described distorted region.
Wherein, if judging unit 402 judges to exist in M face the distorted region that distortion factor is greater than predetermined threshold value, correcting unit 403 carries out distortion correction to this distorted region.Further, human face region is divided into distortion factor according to the large I of distortion factor and is less than or equal to the distorted region that the region of predetermined threshold value and distortion factor be greater than predetermined threshold value, distortion correction can be carried out to the region that distortion factor is greater than predetermined threshold value, and the distorted region being less than or equal to predetermined threshold value is remained unchanged.
As a kind of possible execution mode, as illustrated in fig. 4 c, the correcting unit 403 of the terminal in Fig. 4 a described by the embodiment of the present invention also can comprise: the first acquiring unit 4031 and the first syndrome unit 4032, specific as follows:
First acquiring unit 4031, for obtaining the distortion correction coefficient of user for described distorted region i.
First syndrome unit 4032, for carrying out distortion correction according to described distortion correction coefficient to described distorted region i.
In specific implementation, suppose that distorted region comprises distorted region i, the first acquiring unit 4031 can obtain the distortion correction coefficient of user for this distorted region i; First syndrome unit 4032 carries out distortion correction according to described distortion correction coefficient to described distorted region i.That is, user can, to arbitrary face distorted region, adopt same distortion correction coefficient to correct.
As a kind of possible execution mode, as shown in figure 4d, the correcting unit 403 of the terminal in Fig. 4 a described by the embodiment of the present invention can comprise: second acquisition unit 4041, the 3rd determining unit 4042 and the second syndrome unit 4043, specific as follows:
Second acquisition unit 4041, for obtaining the distortion threshold value of user's input.
Wherein, if detecting unit 402 detects in M face the distortion factor that there is distortion factor and be greater than predetermined threshold value, second acquisition unit 4041 can obtain the distortion threshold value of user's input, this threshold value adjusts for user, terminal can adjust the human face region being greater than this threshold value, and does not process the human face region being less than or equal to this threshold value.
3rd determining unit 4042, for determining that in described distorted region, distortion factor is greater than the target area of the distortion threshold value that described second acquisition unit 4041 gets.
Wherein, the 3rd determining unit 4042 can determine that in distorted region, distortion factor is greater than the target area of this distortion threshold value, and in the distorted region namely in human face region, distortion factor is greater than distortion threshold coefficient pixel and can forms target area.
Second syndrome unit 4043, carries out distortion correction to the target area that described 3rd determining unit 4042 is determined.
Wherein, the second syndrome unit 4043 only can carry out distortion correction to target area, thus, the fault image of some entertaining can be produced, because the different fault image that different distortion factor is corresponding.
As a kind of possible execution mode, as shown in fig 4e, the terminal in Fig. 4 a described by the embodiment of the present invention also can comprise: the second determining unit 404 and integrated unit 405, specific as follows:
Second determining unit 404, for determining the size of the human face region after described correcting unit distortion correction;
Integrated unit 405, for determining the first position of centre of gravity of described distorted region according to the size of the human face region after described distortion correction and calculating the second position of centre of gravity of correcting area corresponding to described distorted region, described first position of centre of gravity and described second position of centre of gravity are overlapped, what the camera using the position of centre of gravity after overlapping as center, described correcting area being fused to described terminal photographed finds a view in picture.
Terminal described by the embodiment of the present invention carries out Face datection by the picture of finding a view photographed the camera of terminal; There is M face if find a view described in detecting in picture, judge whether to exist in a described M face distorted region that distortion factor is greater than predetermined threshold value, wherein, M be more than or equal to 1 integer; If so, distortion correction is carried out to described distorted region.Adopt the embodiment of the present invention can to detect the face of finding a view in picture that camera photographs, and distortion correction is carried out to the face detected, thus, the distortion degree of the face that distorts in reduction wide-angle camera.
Refer to Fig. 5, the structural representation of the second embodiment of a kind of terminal that Fig. 5 provides for the embodiment of the present invention.Terminal described in the present embodiment comprises: at least one input equipment 1000; At least one output equipment 2000; At least one processor 3000, such as CPU; With memory 4000, above-mentioned input equipment 1000, output equipment 2000, processor 3000 are connected by bus 5000 with memory 4000.
Wherein, above-mentioned input equipment 1000 can be contact panel, common PC, liquid crystal display screen, touch screen, push button etc.
Above-mentioned memory 4000 can be high-speed RAM memory, also can be non-labile memory (non-volatile memory), such as magnetic disc store.Above-mentioned memory 4000 is for storing batch processing code, and above-mentioned input equipment 1000, output equipment 2000 and processor 3000, for calling the program code stored in memory 4000, perform and operate as follows:
Above-mentioned processor 3000, for:
Face datection is carried out to the picture of finding a view that the camera of terminal photographs;
There is M face if find a view described in detecting in picture, judge whether to exist in a described M face distorted region that distortion factor is greater than predetermined threshold value, wherein, M be more than or equal to 1 integer;
If so, distortion correction is carried out to described distorted region.
As a kind of possible implementation, above-mentioned processor 3000 judges whether to exist in a described M face distorted region that distortion factor is greater than predetermined threshold value, is specially:
Determine the corresponding angle scope being less than or equal to the picture of finding a view that described camera corresponding to described predetermined threshold value photographs;
Judge the region whether existed in a described M face outside described corresponding angle scope.
As a kind of possible implementation, after above-mentioned processor 3000 carries out distortion correction to described distorted region, also specifically for:
Determine the size of the human face region after distortion correction;
Determine the first position of centre of gravity of described distorted region according to the size of the human face region after described distortion correction and calculate the second position of centre of gravity of correcting area corresponding to described distorted region, described first position of centre of gravity and described second position of centre of gravity are overlapped, what the camera using the position of centre of gravity after overlapping as center, described correcting area being fused to described terminal photographed finds a view in picture.
As a kind of possible implementation, described distorted region comprises distorted region i, and above-mentioned processor 3000 carries out distortion correction to described distorted region, is specially:
Obtain the distortion correction coefficient of user for described distorted region i;
According to described distortion correction coefficient, distortion correction is carried out to described distorted region i.
As a kind of possible implementation, above-mentioned processor 3000 carries out distortion correction to described distorted region, is specially:
Obtain the distortion threshold value of user's input;
Determine that in described distorted region, distortion factor is greater than the target area of described distortion threshold value;
Distortion correction is carried out to described target area.
Terminal described by the embodiment of the present invention carries out Face datection by the picture of finding a view photographed the camera of terminal; There is M face if find a view described in detecting in picture, judge whether to exist in a described M face distorted region that distortion factor is greater than predetermined threshold value, wherein, M be more than or equal to 1 integer; If so, distortion correction is carried out to described distorted region.Adopt the embodiment of the present invention can to detect the face of finding a view in picture that camera photographs, and distortion correction is carried out to the face detected, thus, the distortion degree of the face that distorts in reduction wide-angle camera.
The embodiment of the present invention also provides a kind of computer-readable storage medium, and wherein, this computer-readable storage medium can have program stored therein, and comprises the part or all of step of any one signal processing method recorded in said method embodiment when this program performs.
In the above-described embodiments, the description of each embodiment is all emphasized particularly on different fields, in certain embodiment, there is no the part described in detail, can see the associated description of other embodiments.
It should be noted that, for aforesaid each embodiment of the method, in order to simple description, therefore it is all expressed as a series of combination of actions, but those skilled in the art should know, the present invention is not by the restriction of described sequence of movement, because according to the present invention, some step may can adopt other orders or carry out simultaneously.Secondly, those skilled in the art also should know, the embodiment described in specification all belongs to preferred embodiment, and involved action and module might not be that the present invention is necessary.
In several embodiments that the application provides, should be understood that, disclosed device, the mode by other realizes.Such as, device embodiment described above is only schematic, the division of such as said units, be only a kind of logic function to divide, actual can have other dividing mode when realizing, such as multiple unit or assembly can in conjunction with or another system can be integrated into, or some features can be ignored, or do not perform.Another point, shown or discussed coupling each other or direct-coupling or communication connection can be by some interfaces, and the indirect coupling of device or unit or communication connection can be electrical or other form.
The above-mentioned unit illustrated as separating component or can may not be and physically separates, and the parts as unit display can be or may not be physical location, namely can be positioned at a place, or also can be distributed in multiple network element.Some or all of unit wherein can be selected according to the actual needs to realize the object of the present embodiment scheme.
In addition, each functional unit in various embodiments of the present invention can be integrated in a processing unit, also can be that the independent physics of unit exists, also can two or more unit in a unit integrated.Above-mentioned integrated unit both can adopt the form of hardware to realize, and the form of SFU software functional unit also can be adopted to realize.
If above-mentioned integrated unit using the form of SFU software functional unit realize and as independently production marketing or use time, can be stored in a computer read/write memory medium.Based on such understanding, the part that technical scheme of the present invention contributes to prior art in essence in other words or all or part of of this technical scheme can embody with the form of software product, this computer software product is stored in a storage medium, comprise all or part of step of some instructions in order to make a computer equipment (can be personal computer, server or the network equipment etc., can be specifically the processor in computer equipment) perform each embodiment said method of the present invention.Wherein, and aforesaid storage medium can comprise: USB flash disk, portable hard drive, magnetic disc, CD, read-only memory are (English: Read-Only Memory, abbreviation: ROM) or random access memory (English: Random Access Memory, abbreviation: RAM) etc. various can be program code stored medium.
The above, above embodiment only in order to technical scheme of the present invention to be described, is not intended to limit; Although with reference to previous embodiment to invention has been detailed description, those of ordinary skill in the art is to be understood that: it still can be modified to the technical scheme described in foregoing embodiments, or carries out equivalent replacement to wherein portion of techniques feature; And these amendments or replacement, do not make the essence of appropriate technical solution depart from the spirit and scope of various embodiments of the present invention technical scheme.

Claims (10)

1. a method for face distortion correction, is characterized in that, comprising:
Face datection is carried out to the picture of finding a view that the camera of terminal photographs;
There is M face if find a view described in detecting in picture, judge whether to exist in a described M face distorted region that distortion factor is greater than predetermined threshold value, wherein, M be more than or equal to 1 integer;
If so, distortion correction is carried out to described distorted region.
2. the method for claim 1, is characterized in that, the described distorted region judging whether to exist in a described M face distortion factor and be greater than predetermined threshold value, comprising:
Determine the corresponding angle scope being less than or equal to the picture of finding a view that described camera corresponding to described predetermined threshold value photographs;
Judge the region whether existed in a described M face outside described corresponding angle scope.
3. the method as described in any one of claim 1 or 2, is characterized in that, described distortion correction is carried out to described distorted region after, described method comprises:
Determine the size of the human face region after distortion correction;
Determine the first position of centre of gravity of described distorted region according to the size of the human face region after described distortion correction and calculate the second position of centre of gravity of correcting area corresponding to described distorted region, described first position of centre of gravity and described second position of centre of gravity are overlapped, what the camera using the position of centre of gravity after overlapping as center, described correcting area being fused to described terminal photographed finds a view in picture.
4. the method as described in any one of claim 1 or 2, it is characterized in that, described distorted region comprises distorted region i, describedly carries out distortion correction to described distorted region, comprising:
Obtain the distortion correction coefficient of user for described distorted region i;
According to described distortion correction coefficient, distortion correction is carried out to described distorted region i.
5. the method as described in any one of claim 1 or 2, is characterized in that, describedly carries out distortion correction to described distorted region, comprising:
Obtain the distortion threshold value of user's input;
Determine that in described distorted region, distortion factor is greater than the target area of described distortion threshold value;
Distortion correction is carried out to described target area.
6. a terminal, is characterized in that, comprising:
Detecting unit, carries out Face datection for the picture of finding a view photographed the camera of terminal;
Judging unit, if there is M face in picture of finding a view described in detecting for described detecting unit, judges whether to exist in a described M face distorted region that distortion factor is greater than predetermined threshold value, wherein, M be more than or equal to 1 integer;
Correcting unit, for judging to exist in a described M face distorted region that distortion factor is greater than predetermined threshold value at described judging unit, carries out distortion correction to described distorted region.
7. terminal as claimed in claim 6, it is characterized in that, described judging unit comprises:
First determining unit, for determining the corresponding angle scope being less than or equal to the picture of finding a view that described camera corresponding to described predetermined threshold value photographs;
Judgment sub-unit, for judging whether to exist in a described M face region outside corresponding angle scope that described determining unit determines.
8. the terminal as described in any one of claim 6 or 7, it is characterized in that, described terminal also comprises:
Second determining unit, for determining the size of the human face region after described correcting unit distortion correction;
Integrated unit, for determining the first position of centre of gravity of described distorted region according to the size of the human face region after described distortion correction and calculating the second position of centre of gravity of correcting area corresponding to described distorted region, described first position of centre of gravity and described second position of centre of gravity are overlapped, what the camera using the position of centre of gravity after overlapping as center, described correcting area being fused to described terminal photographed finds a view in picture.
9. the terminal as described in any one of claim 6 or 7, it is characterized in that, described distorted region comprises distorted region i, and described correcting unit comprises:
First acquiring unit, for obtaining the distortion correction coefficient of user for described distorted region i;
First syndrome unit, for carrying out distortion correction according to described distortion correction coefficient to described distorted region i.
10. the terminal as described in any one of claim 6 or 7, it is characterized in that, described correcting unit comprises:
Second acquisition unit, for obtaining the distortion threshold value of user's input;
3rd determining unit, for determining that in described distorted region, distortion factor is greater than the target area of the distortion threshold value that described second acquisition unit gets;
Second syndrome unit, carries out distortion correction to the target area that described 3rd determining unit is determined.
CN201510378947.0A 2015-06-30 2015-06-30 A kind of method and terminal of face distortion correction Active CN104994281B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510378947.0A CN104994281B (en) 2015-06-30 2015-06-30 A kind of method and terminal of face distortion correction

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510378947.0A CN104994281B (en) 2015-06-30 2015-06-30 A kind of method and terminal of face distortion correction

Publications (2)

Publication Number Publication Date
CN104994281A true CN104994281A (en) 2015-10-21
CN104994281B CN104994281B (en) 2017-09-19

Family

ID=54306031

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510378947.0A Active CN104994281B (en) 2015-06-30 2015-06-30 A kind of method and terminal of face distortion correction

Country Status (1)

Country Link
CN (1) CN104994281B (en)

Cited By (18)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105554403A (en) * 2016-02-29 2016-05-04 广东欧珀移动通信有限公司 Control method, control device and electronic device
CN105611161A (en) * 2015-12-24 2016-05-25 广东欧珀移动通信有限公司 Photographing control method, photographing control device and photographing system
CN107018316A (en) * 2015-12-22 2017-08-04 卡西欧计算机株式会社 Image processing apparatus, image processing method and program
CN108803011A (en) * 2018-03-15 2018-11-13 成都理想境界科技有限公司 A kind of image correction method and optical fiber scanning imaging device
CN108932698A (en) * 2017-11-17 2018-12-04 北京猎户星空科技有限公司 Bearing calibration, device, electronic equipment and the storage medium of pattern distortion
CN110008806A (en) * 2017-12-27 2019-07-12 本田技研工业株式会社 Storage medium, learning processing method, learning device and object identification device
US10440307B2 (en) 2015-12-22 2019-10-08 Casio Computer Co., Ltd. Image processing device, image processing method and medium
CN110660034A (en) * 2019-10-08 2020-01-07 北京迈格威科技有限公司 Image correction method and device and electronic equipment
CN110751602A (en) * 2019-09-20 2020-02-04 北京迈格威科技有限公司 Conformal distortion correction method and device based on face detection
CN110971827A (en) * 2019-12-09 2020-04-07 Oppo广东移动通信有限公司 Portrait mode shooting method and device, terminal equipment and storage medium
CN111028169A (en) * 2019-12-09 2020-04-17 Oppo广东移动通信有限公司 Image correction method, device, terminal equipment and storage medium
CN111080545A (en) * 2019-12-09 2020-04-28 Oppo广东移动通信有限公司 Face distortion correction method and device, terminal equipment and storage medium
WO2020082827A1 (en) * 2018-10-24 2020-04-30 中兴通讯股份有限公司 Photographing method, device, terminal, and computer storage medium
CN111105367A (en) * 2019-12-09 2020-05-05 Oppo广东移动通信有限公司 Face distortion correction method and device, electronic equipment and storage medium
CN111144182A (en) * 2018-11-06 2020-05-12 天地融科技股份有限公司 Method and system for detecting face risk in video
CN111401223A (en) * 2020-03-13 2020-07-10 北京新氧科技有限公司 Face shape comparison method, device and equipment
WO2021022057A1 (en) * 2019-08-01 2021-02-04 Plantronics, Inc. Videoconferencing with adaptive lens distortion-correction and image deformation-reduction
EP4068151A4 (en) * 2019-12-09 2023-04-12 Guangdong Oppo Mobile Telecommunications Corp., Ltd. Linear processing method and apparatus in face image, terminal device, and storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2007119712A1 (en) * 2006-04-13 2007-10-25 Opt Corporation Camera apparatus, and image processing apparatus and image processing method
CN103247031A (en) * 2013-04-19 2013-08-14 华为技术有限公司 Method, terminal and system for correcting aberrant image
CN103283214A (en) * 2011-01-06 2013-09-04 松下电器产业株式会社 Camera, distortion correction device and distortion correction method
CN104469137A (en) * 2013-09-20 2015-03-25 卡西欧计算机株式会社 Image Processing Apparatus and Image Processing Method

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2007119712A1 (en) * 2006-04-13 2007-10-25 Opt Corporation Camera apparatus, and image processing apparatus and image processing method
CN103283214A (en) * 2011-01-06 2013-09-04 松下电器产业株式会社 Camera, distortion correction device and distortion correction method
CN103247031A (en) * 2013-04-19 2013-08-14 华为技术有限公司 Method, terminal and system for correcting aberrant image
CN104469137A (en) * 2013-09-20 2015-03-25 卡西欧计算机株式会社 Image Processing Apparatus and Image Processing Method

Cited By (29)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107018316B (en) * 2015-12-22 2021-02-05 卡西欧计算机株式会社 Image processing apparatus, image processing method, and storage medium
CN107018316A (en) * 2015-12-22 2017-08-04 卡西欧计算机株式会社 Image processing apparatus, image processing method and program
US10440307B2 (en) 2015-12-22 2019-10-08 Casio Computer Co., Ltd. Image processing device, image processing method and medium
CN105611161A (en) * 2015-12-24 2016-05-25 广东欧珀移动通信有限公司 Photographing control method, photographing control device and photographing system
CN105611161B (en) * 2015-12-24 2019-03-12 Oppo广东移动通信有限公司 Camera control method, photographing control device and camera system
CN105554403B (en) * 2016-02-29 2018-12-04 广东欧珀移动通信有限公司 Control method, control device and electronic device
CN105554403A (en) * 2016-02-29 2016-05-04 广东欧珀移动通信有限公司 Control method, control device and electronic device
CN108932698B (en) * 2017-11-17 2021-07-23 北京猎户星空科技有限公司 Image distortion correction method, device, electronic equipment and storage medium
CN108932698A (en) * 2017-11-17 2018-12-04 北京猎户星空科技有限公司 Bearing calibration, device, electronic equipment and the storage medium of pattern distortion
CN110008806A (en) * 2017-12-27 2019-07-12 本田技研工业株式会社 Storage medium, learning processing method, learning device and object identification device
CN110008806B (en) * 2017-12-27 2022-11-08 本田技研工业株式会社 Information processing device, learning processing method, learning device, and object recognition device
CN108803011A (en) * 2018-03-15 2018-11-13 成都理想境界科技有限公司 A kind of image correction method and optical fiber scanning imaging device
WO2020082827A1 (en) * 2018-10-24 2020-04-30 中兴通讯股份有限公司 Photographing method, device, terminal, and computer storage medium
CN111144182A (en) * 2018-11-06 2020-05-12 天地融科技股份有限公司 Method and system for detecting face risk in video
CN111144182B (en) * 2018-11-06 2023-04-07 天地融科技股份有限公司 Method and system for detecting face risk in video
WO2021022057A1 (en) * 2019-08-01 2021-02-04 Plantronics, Inc. Videoconferencing with adaptive lens distortion-correction and image deformation-reduction
CN110751602A (en) * 2019-09-20 2020-02-04 北京迈格威科技有限公司 Conformal distortion correction method and device based on face detection
CN110751602B (en) * 2019-09-20 2022-09-30 北京迈格威科技有限公司 Conformal distortion correction method and device based on face detection
CN110660034A (en) * 2019-10-08 2020-01-07 北京迈格威科技有限公司 Image correction method and device and electronic equipment
CN111105367A (en) * 2019-12-09 2020-05-05 Oppo广东移动通信有限公司 Face distortion correction method and device, electronic equipment and storage medium
WO2021114990A1 (en) * 2019-12-09 2021-06-17 Oppo广东移动通信有限公司 Method and apparatus for correcting face distortion, electronic device, and storage medium
CN111080545A (en) * 2019-12-09 2020-04-28 Oppo广东移动通信有限公司 Face distortion correction method and device, terminal equipment and storage medium
CN111028169A (en) * 2019-12-09 2020-04-17 Oppo广东移动通信有限公司 Image correction method, device, terminal equipment and storage medium
CN110971827A (en) * 2019-12-09 2020-04-07 Oppo广东移动通信有限公司 Portrait mode shooting method and device, terminal equipment and storage medium
EP4068151A4 (en) * 2019-12-09 2023-04-12 Guangdong Oppo Mobile Telecommunications Corp., Ltd. Linear processing method and apparatus in face image, terminal device, and storage medium
CN111028169B (en) * 2019-12-09 2024-02-06 Oppo广东移动通信有限公司 Image correction method, device, terminal equipment and storage medium
CN111080545B (en) * 2019-12-09 2024-03-12 Oppo广东移动通信有限公司 Face distortion correction method, device, terminal equipment and storage medium
CN111401223A (en) * 2020-03-13 2020-07-10 北京新氧科技有限公司 Face shape comparison method, device and equipment
CN111401223B (en) * 2020-03-13 2023-09-19 北京新氧科技有限公司 Face shape comparison method, device and equipment

Also Published As

Publication number Publication date
CN104994281B (en) 2017-09-19

Similar Documents

Publication Publication Date Title
CN104994281A (en) Method for correcting face distortion and terminal
CN109644229B (en) Method for controlling camera and electronic device thereof
CN108289161B (en) Electronic device and image capturing method thereof
CN105282430B (en) Electronic device using composition information of photograph and photographing method using the same
KR101916355B1 (en) Photographing method of dual-lens device, and dual-lens device
US9959601B2 (en) Distortion rectification method and terminal
KR20180106076A (en) Method for providing different indicator for image based on photographing mode and electronic device thereof
CN106249508B (en) Atomatic focusing method and system, filming apparatus
TW201918772A (en) Apparatus and method of five dimensional (5D) video stabilization with camera and gyroscope fusion
JP6924901B2 (en) Photography method and electronic equipment
KR20160016068A (en) Method for generating image and electronic device thereof
CN105141826A (en) Distortion correction method and terminal
WO2017093883A1 (en) Method and apparatus for providing a view window within a virtual reality scene
EP2911088B1 (en) Method and apparatus for displaying biometric information
CN109040524B (en) Artifact eliminating method and device, storage medium and terminal
CN108134903B (en) Shooting method and related product
CN112954212B (en) Video generation method, device and equipment
EP3480646A1 (en) Method for adjusting angle of shooting module element and head-mounted display device
CN104994286B (en) The method and terminal of a kind of distortion correction
KR20170057680A (en) Electronic device and method for displaying content thereof
CN112351271A (en) Camera shielding detection method and device, storage medium and electronic equipment
EP2933997B1 (en) Electronic device with zoom lens
JP6686319B2 (en) Image projection device and image display system
US10943562B2 (en) Display control apparatus and display control method
KR102666977B1 (en) Electronic device and method for photographing image thereof

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
CP01 Change in the name or title of a patent holder
CP01 Change in the name or title of a patent holder

Address after: Changan town in Guangdong province Dongguan 523860 usha Beach Road No. 18

Patentee after: GUANGDONG OPPO MOBILE TELECOMMUNICATIONS CORP., Ltd.

Address before: Changan town in Guangdong province Dongguan 523860 usha Beach Road No. 18

Patentee before: GUANGDONG OPPO MOBILE TELECOMMUNICATIONS CORP., Ltd.