Summary of the invention
Embodiments of the invention provide a kind of method and apparatus of Lookup protocol screening-mode, have realized the Lookup protocol of screening-mode, have improved shooting effect.
For achieving the above object, embodiments of the invention adopt following technical scheme:
On the one hand, the invention provides a kind of method of Lookup protocol screening-mode, comprising:
Open people's face measuring ability of capture apparatus, and obtain the graphical information in everyone face zone of sign in the preview interface of described capture apparatus, described graphical information is used for identifying the regional extent that everyone face occupies;
Calculate the first ratio value of maximum face region area and described preview interface area in the described preview interface according to the physical size of described graphical information, described preview interface;
When described the first ratio value during more than or equal to first threshold, the screening-mode of described capture apparatus is set to the character motif pattern, and described first threshold is the percentage that described capture apparatus individual human face region area in the photo of taking character motif occupies the photo gross area;
When described the first ratio value during less than described first threshold, the screening-mode of described capture apparatus is set to non-character motif pattern.
In the possible implementation of the first of first aspect, when described graphical information is rectangle frame information, when described rectangle frame information comprised rectangle frame wide and high, described physical size according to described graphical information, described preview interface calculated that the first ratio value of maximum face area and described preview interface area is specially in the described preview interface:
According to R
Face=Max (X
Face1* Y
Face1, X
Face2* Y
Face2..., X
Facen* Y
Facen)/(X
Pic* Y
Pic) calculate the first ratio value of maximum face area and described preview interface area in the described preview interface, wherein R
FaceBe the first ratio value of maximum face area in the described preview interface and described preview interface area, (X
Face1, Y
Face1), (X
Face2, Y
Face2) ..., (X
Facen, Y
Facen) be respectively rectangle frame wide and high of in described preview interface, get access to n sign different people face, (X
Pic, Y
Pic) be the wide and high of described preview interface.
In conjunction with the possible implementation of the first of first aspect or first aspect, in the possible implementation of the second, after the screening-mode of described capture apparatus was set to the character motif pattern, described method also comprised:
Calculate the current distance of maximum face is corresponding in the described preview interface the person of being taken and described capture apparatus according to described the first ratio value, default predetermined distance, preset ratio value, described default predetermined distance is for when whole people's face of the person of being taken included in photo, the minimum distance of the described person of being taken and described capture apparatus, when described preset ratio value is described default predetermined distance for the distance as described capture apparatus and the person of being taken, the person's of being taken maximum face region area and the ratio value of described preview interface area;
Whether judge described current distance greater than default safe distance, described default safe distance for the intensity of illumination when the photoflash lamp of described capture apparatus be human eye bear maximum safe intensity of illumination the time, described capture apparatus and the person's of being taken safe distance;
In the time that described current distance is not more than described default safe distance, the operating state of the photoflash lamp of described capture apparatus is set to close.
In conjunction with the possible implementation of the second of first aspect, in the third possible implementation, the described current distance of calculating maximum face is corresponding in the described preview interface the person of being taken and described capture apparatus according to described the first ratio value, default predetermined distance, preset ratio value is specially:
According to
Calculate maximum face is corresponding in the described preview interface the person of being taken and the current distance of described capture apparatus, wherein D
CurrentBe maximum face is corresponding in the described preview interface the person of the being taken current distance with described capture apparatus, R
MaxBe described preset ratio value, R
FaceBe described the first ratio value, D
NearestBe described default predetermined distance.
In conjunction with the possible implementation of the second of first aspect, in the 4th kind of possible implementation, described method also comprises:
When described current distance greater than described default safe distance the time, the operating state of described photoflash lamp is set according to the parameter request of the character motif pattern of described capture apparatus.
Second aspect the invention provides a kind of device of Lookup protocol screening-mode, comprising:
Acquiring unit is used for opening people's face measuring ability of capture apparatus, and obtains the graphical information in everyone face zone of sign in the preview interface of described capture apparatus, and described graphical information is used for identifying the regional extent that everyone face occupies;
The first processing unit is for the first ratio value that calculates described preview interface maximum face region area and described preview interface area according to the physical size of described graphical information, described preview interface;
Setting unit, be used for when described the first ratio value during more than or equal to first threshold, the screening-mode of described capture apparatus is set to the character motif pattern, and described first threshold is the percentage that described capture apparatus individual human face region area in the photo of taking character motif occupies the photo gross area;
Described setting unit also is used for when described the first ratio value during less than described first threshold, and the screening-mode of described capture apparatus is set to non-character motif pattern.
In the possible implementation of the first of second aspect, when described graphical information is rectangle frame information, when described rectangle frame information comprises rectangle frame wide and high,
Described the first processing unit, concrete being used for according to R
Face=Max (X
Face1* Y
Face1, X
Face2* Y
Face2..., X
Facen* Y
Facen)/(X
Pic* Y
Pic) calculate the first ratio value of maximum face area and described preview interface area in the described preview interface, wherein R
FaceBe the first ratio value of maximum face area in the described preview interface and described preview interface area, (X
Face1, Y
Face1), (X
Face2, Y
Face2) ..., (X
Facen, Y
Facen) be respectively rectangle frame wide and high of in described preview interface, get access to n sign different people face, (X
Pic, Y
Pic) be the wide and high of described preview interface.
In conjunction with the possible implementation of the first of second aspect or second aspect, in the possible implementation of the second, described device also comprises:
The second processing unit, be used for calculating according to described the first ratio value, default predetermined distance, preset ratio value the current distance of the person of being taken corresponding to described preview interface maximum face and described capture apparatus, described default predetermined distance is for when whole people's face of the person of being taken included in photo, the minimum distance of the described person of being taken and described capture apparatus, when described preset ratio value is described default predetermined distance for the distance as described capture apparatus and the person of being taken, the person's of being taken maximum face region area and the ratio value of described preview interface area;
The 3rd processing unit, be used for judging that whether described current distance is greater than default safe distance, described default safe distance for the intensity of illumination when the photoflash lamp of described capture apparatus be human eye bear maximum safe intensity of illumination the time, described capture apparatus and the person's of being taken safe distance;
Described setting unit also is used in the time that described current distance is not more than described default safe distance, and the operating state of the photoflash lamp of described capture apparatus is set to close.
In conjunction with the possible implementation of the second of second aspect, in the third possible implementation, described the second processing unit specifically is used for basis
Calculate maximum face is corresponding in the described preview interface the person of being taken and the current distance of described capture apparatus, wherein D
CurrentBe maximum face is corresponding in the described preview interface the person of the being taken current distance with described capture apparatus, R
MaxBe described preset ratio value, R
FaceBe described the first ratio value, D
NearestBe described default predetermined distance.
In conjunction with the possible implementation of the second of second aspect, in the 4th kind of possible implementation, described setting unit, also be used for when described current distance greater than described default safe distance the time, the operating state of described photoflash lamp is set according to the parameter request of the character motif pattern of described capture apparatus.
The method and apparatus of a kind of Lookup protocol screening-mode that the embodiment of the invention provides, open people's face measuring ability of capture apparatus, and obtain the graphical information in everyone face zone of sign in the preview interface of described capture apparatus, then according to described graphical information, the physical size of described preview interface calculates the first ratio value of maximum face region area and described preview interface area in the described preview interface, when described the first ratio value during more than or equal to first threshold, the screening-mode of described capture apparatus is set to the character motif pattern, when described the first ratio value during less than described first threshold, the screening-mode of described capture apparatus is set to non-character motif pattern.
The embodiment of the invention has solved in the prior art because most of users are unfamiliar with which kind of screening-mode that needs to use mobile phone under which kind of scene, make shooting photo effect out undesirable, the problem of making troubles for user's use, realize the Lookup protocol of screening-mode, improved shooting effect.
Embodiment
Below in conjunction with the accompanying drawing in the embodiment of the invention, the technical scheme in the embodiment of the invention is clearly and completely described, obviously, described embodiment only is the present invention's part embodiment, rather than whole embodiment.Based on the embodiment among the present invention, those of ordinary skills belong to the scope of protection of the invention not making the every other embodiment that obtains under the creative work prerequisite.
The capture apparatus that the embodiment of the invention relates to can be the camera in the smart mobile phone, also can be the digital camera that has carried operating system, does not do in the present invention restriction.As shown in Figure 1, the embodiment of the invention provides a kind of method of Lookup protocol screening-mode, takes as example to utilize the camera in the smart mobile phone, and described method specifically comprises the steps:
101, open people's face measuring ability of capture apparatus, and obtain the graphical information in everyone face zone of sign in the preview interface of described capture apparatus, described graphical information is used for identifying the regional extent that everyone face occupies.
When the user opens camera in the described smart mobile phone, when taking, people's face measuring ability of camera is opened automatically, the image in the preview interface of described mobile telephone display is carried out people's face detect.
Human face detection tech is the feature according to people's face, and with the recognition of face that appears at preview interface out, and then mark out.In the prior art, human face detection tech is comparative maturity, for example, based on people's face detection of template matches, based on people's face detection of face shaping, based on people's face detection of neural net, based on people's face detection of feature, people's face detection of skin color based etc., do not limit in embodiments of the present invention and use which kind of human face detection tech, as long as the human face region in the preview interface can be identified out.In existing human face detection tech, usually utilize figure that human face region is identified out, such as rectangle frame, ellipse, circle, square etc.
In the preview interface of mobile telephone display, obtain the graphical information of each human face region of sign, there are several human face regions that several graphical informations are just arranged, the figure that wherein identifies human face region can be identical, also can be different, as long as the regional extent that everyone face can be occupied identifies out.
In addition, before the graphical information of obtaining the sign human face region, do not limit described camera and whether focus successfully.Because may exist the user when using camera to take; do not focus and successfully just take; therefore in order to guarantee to protect to greatest extent the person's of being taken eyes; whether whether obtaining the graphical information that identifies human face region and not relying on focusing in this step be successful, detect successful but depend on people's face.
102, calculate the first ratio value of maximum face region area and described preview interface area in the described preview interface according to the physical size of described graphical information, described preview interface.
According to the graphical information that gets access to, obtain the area of each human face region, wherein the ratio of the area of the preview interface of maximum face region area and described mobile telephone display is described the first ratio value.
103, when described the first ratio value during more than or equal to first threshold, the screening-mode of described capture apparatus is set to the character motif pattern, and described first threshold is the percentage that described capture apparatus individual human face region area in the photo of taking character motif occupies the photo gross area.
Wherein, described first threshold be by camera when taking the photo of character motif, individual human face region area in the photo occupies the percentage of the photo gross area, and the statistical value through repeatedly calculating, camera in the different smart mobile phones, corresponding different first thresholds, for example, in the VIVA mobile phone, described first threshold is 0.07.
104, when described the first ratio value during less than described first threshold, the screening-mode of described capture apparatus is set to non-character motif pattern.
Because the person of being taken is far away with the distance of described camera, the area ratio that the person's of being taken human face region area occupies in described preview interface is less, therefore at described the first ratio value during less than described first threshold, the ratio value of explanation maximum face region area and described preview interface area in described preview interface, ration statistics value less than described camera individual human face region area and photo area in taking the photo of character motif, so the distance of the described people face corresponding with described the first ratio value and camera greater than camera corresponding to described first threshold when taking the photo of character motif, the ultimate range of personage and described camera, think then that the user will take the personage this moment, the screening-mode of so described capture apparatus is set to non-character motif pattern, the landscape matic mould for example, then take according to the Common Parameters of the landscape matic mould, for example, the large depth of field, slow shutter etc.
The method of a kind of Lookup protocol screening-mode that the embodiment of the invention provides, open people's face measuring ability of capture apparatus, and obtain the graphical information in everyone face zone of sign in the preview interface of described capture apparatus, then according to described graphical information, the physical size of described preview interface calculates the first ratio value of maximum face region area and described preview interface area in the described preview interface, when described the first ratio value during more than or equal to first threshold, the screening-mode of described capture apparatus is set to the character motif pattern, when described the first ratio value during less than described first threshold, the screening-mode of described capture apparatus is set to non-character motif pattern.The embodiment of the invention has solved in the prior art because most of users are unfamiliar with which kind of screening-mode that needs to use mobile phone under which kind of scene, make shooting photo effect out undesirable, the problem of making troubles for user's use, realize the Lookup protocol of screening-mode, improved shooting effect.
In a kind of implementation of the embodiment of the invention, a kind of method of Lookup protocol screening-mode is provided, as shown in Figure 2, to take as example to utilize the camera in the smart mobile phone, described method specifically comprises the steps:
201, open people's face measuring ability of capture apparatus, and obtain the graphical information in everyone face zone of sign in the preview interface of described capture apparatus, described graphical information is used for identifying the regional extent that everyone face occupies.
When the user opens camera in the described smart mobile phone, when taking, people's face measuring ability of camera is opened automatically, the image in the preview interface of described mobile telephone display is carried out people's face detect.
Human face detection tech is the feature according to people's face, and with the recognition of face that appears at preview interface out, and then mark out.In the prior art, human face detection tech is comparative maturity, for example, based on people's face detection of template matches, based on people's face detection of face shaping, based on people's face detection of neural net, based on people's face detection of feature, people's face detection of skin color based etc., do not limit in embodiments of the present invention and use which kind of human face detection tech, as long as the human face region in the preview interface can be identified out.In existing human face detection tech, usually utilize figure that human face region is identified out, such as rectangle frame, ellipse, circle, square etc.
In the preview interface of mobile telephone display, obtain the graphical information of each human face region of sign, there are several human face regions that several graphical informations are just arranged, the figure that wherein identifies human face region can be identical, also can be different, as long as the regional extent that everyone face can be occupied identifies out.
In addition, before the graphical information of obtaining the sign human face region, do not limit described camera and whether focus successfully.Because may exist the user when using camera to take; do not focus and successfully just take; therefore in order to guarantee to protect to greatest extent the person's of being taken eyes; whether whether obtaining the graphical information that identifies human face region and not relying on focusing in this step be successful, detect successful but depend on people's face.
202, calculate the first ratio value of maximum face region area and described preview interface area in the described preview interface according to the physical size of described graphical information, described preview interface.
According to the graphical information that gets access to, obtain the area of each human face region, wherein the ratio of the area of the preview interface of maximum face region area and described mobile telephone display is described the first ratio value.
When the human face region that uses rectangle frame to described preview interface identifies, the rectangle frame information that gets access to comprises the wide and high of rectangle frame, in addition, obtain in advance preview interface wide and high of described camera, then calculate the first ratio value of maximum face area and described preview interface area in the described preview interface according to formula (1).
R
face=Max(X
face1*Y
face1,X
face2*Y
face2,...,X
facen*Y
facen)/(X
pic*Y
pic) (1)
Wherein, R
FaceBe the first ratio value of maximum face area in the described preview interface and described preview interface area, (X
Face1, Y
Face1), (X
Face2, Y
Face2) ..., (X
Facen, Y
Facen) be respectively rectangle frame wide and high of in described preview interface, get access to n sign different people face, (X
Pic, Y
Pic) be the wide and high of described preview interface.
In addition, when only identifying people's face in the described preview interface, then above-mentioned formula (1) is converted to the first ratio value that formula (2) calculates maximum face area and described preview interface area in the described preview interface.
R
face=(X
face*Y
face)/(X
pic*Y
pic) (2)
Wherein, R
FaceThe first ratio value of and described preview interface area long-pending for people's face in the described preview interface, (X
Face, Y
Face) wide and high for the rectangle frame of people's face of getting access in the described preview interface, (X
Pic, Y
Pic) be the wide and high of described preview interface.
203, whether judge described the first ratio value less than first threshold, described first threshold is the percentage that described capture apparatus individual human face region area in the photo of taking character motif occupies the photo gross area.
Described first threshold be by camera when taking the photo of character motif, individual human face region area in the photo occupies the percentage of the photo gross area, and the statistical value through repeatedly calculating, camera in the different smart mobile phones, corresponding different first thresholds, for example, in the VIVA mobile phone, described first threshold is 0.07.
204, when described the first ratio value during more than or equal to described first threshold, the screening-mode of described capture apparatus is set to the character motif pattern, and described first threshold is the percentage that described capture apparatus individual human face region area in the photo of taking character motif occupies the photo gross area.
Wherein, described first threshold be by camera when taking the photo of character motif, individual human face region area in the photo occupies the percentage of the photo gross area, and the statistical value through repeatedly calculating, camera in the different smart mobile phones, corresponding different first thresholds, for example, in the VIVA mobile phone, described first threshold is 0.07.
When described the first ratio value during more than or equal to first threshold, illustrate take this moment be the photo of character motif, by computing camera and the person's of being taken current distance, and then judge whether the photoflash lamp of camera can damage the person's of being taken eyes.
205, calculate the current distance of maximum face is corresponding in the described preview interface the person of being taken and described capture apparatus according to described the first ratio value, default predetermined distance, preset ratio value, described default predetermined distance is for when whole people's face of the person of being taken included in photo, the minimum distance of the described person of being taken and described capture apparatus, when described preset ratio value is described default predetermined distance for the distance as described capture apparatus and the person of being taken, the person's of being taken maximum face region area and the ratio value of described preview interface area.
When the camera in the VIVA mobile phone when taking the photo of character motif, camera is 15cm with the person's of being taken distance, the people's face that is taken can be included fully in photo, if the person of being taken is closer again for distance, the people's face that is taken can not intactly be presented in the preview interface, thereby can not people's face be detected by human face detection tech.So 15cm that will this moment is designated as default predetermined distance, i.e. the minimum distance of the described camera person of being taken and described capture apparatus in taking the photo of character motif.And when camera and the person's of being taken distance is 15cm, the statistical value of the first ratio value that obtains is 0.35, then the first ratio value of this moment is the preset ratio value, namely when camera and the person's of being taken distance is described default predetermined distance, the person's of being taken maximum face region area and the ratio value of described preview interface area.
Calculate the current distance of maximum face is corresponding in the described preview interface the person of being taken and described capture apparatus according to formula (3).
D wherein
CurrentBe maximum face is corresponding in the described preview interface the person of the being taken current distance with described capture apparatus, R
MaxBe described preset ratio value, R
FaceBe described the first ratio value, D
NearestBe described default predetermined distance.
Wherein, because the person of being taken is far away with the distance of described camera, the area ratio that the person's of being taken human face region area occupies in described preview interface is less, and area ratio is directly proportional with square distance.Be R
MaxWith (D
Nearest)
2Proportional, R
FaceWith (D
Current)
2Proportional.
206, whether judge described current distance greater than default safe distance, described default safe distance for the intensity of illumination when the photoflash lamp of described capture apparatus be human eye bear maximum safe intensity of illumination the time, described capture apparatus and the person's of being taken safe distance.
In existing research, the maximum intensity of illumination that human eye can bear is 106cd/m
2In order better to protect the person's of being taken eyes, the safe intensity of illumination that we can set that human eye can bear is 80cd/m
2Wherein, owing to the model of photoflash lamp in the camera and the difference of intensity, the person of being taken is 80cd/m in the intensity of illumination of the photoflash lamp that bears different cameral
2The time, all have different from the distance of camera.For example, can utilize the intensity of illumination tester to test out, be 80cd/m when the intensity of illumination tester receives the intensity of illumination that the photoflash lamp of camera sends
2The time, obtain the distance of described intensity of illumination tester and camera, and described distance is set to default safe distance, for example, in the VIVA mobile phone, default safe distance is 5 meters.
In step 206, whether judge the described current distance obtain greater than described default safe distance, the person's of being taken eyes are damaged avoiding.
207, in the time that described current distance is not more than described default safe distance, the operating state of the photoflash lamp of described capture apparatus is set to close.
When described current distance less than or equal to described default safe distance the time, if illustrate when the photoflash lamp of camera this moment is in opening, use described camera that the person of being taken is taken, can the person's of being taken eyes be damaged.Therefore, when the screening-mode of described camera is set to the character motif pattern, the positive closing photoflash lamp, wherein other parameters of character motif pattern can utilize the Common Parameters that uses in the prior art to arrange, for example white balance, tone, burst mode, the shallow depth of field, the isoparametric setting of large aperture.If light is very dark, can suitably improve the sensitization susceptibility of camera, specifically arranged voluntarily by the user.
208, when described current distance greater than described default safe distance the time, the operating state of described photoflash lamp is set according to the parameter request of the character motif pattern of described capture apparatus.
By step 204 as can be known, what took this moment is the photo of character motif, and described current distance is greater than described default safe distance, then the photoflash lamp of described camera can not damage the person's of being taken eyes, therefore the operating state of described photoflash lamp is set according to the parameter request of described character motif pattern, not limiting described photoflash lamp is to open or close, by the parameter request decision of described character motif pattern.
209, when described the first ratio value during less than first threshold, the screening-mode of described capture apparatus is set to non-character motif pattern.
Because the person of being taken is far away with the distance of described camera, the area ratio that the person's of being taken human face region area occupies in described preview interface is less, therefore at described the first ratio value during less than described first threshold, the ratio value of explanation maximum face region area and described preview interface area in described preview interface, ration statistics value less than described camera individual human face region area and photo area in taking the photo of character motif, so the distance of the described people face corresponding with described the first ratio value and camera greater than camera corresponding to described first threshold when taking the photo of character motif, the ultimate range of personage and described camera, think then that the user will take the personage this moment, the screening-mode of so described capture apparatus is set to non-character motif pattern, the landscape matic mould for example, then take according to the Common Parameters of the landscape matic mould, for example, the large depth of field, slow shutter etc.
Pass through the embodiment of the invention, reduced the user when using capture apparatus, the physiology injury of bringing for the person of being taken, improved simultaneously the user when arranging for the parameter of being unfamiliar with capture apparatus, the quality of taking pictures, and can the Lookup protocol screening-mode, be convenient to the user and obtain better shooting effect.
Embodiment 2
The embodiment of the invention provides a kind of device of Lookup protocol screening-mode, and as shown in Figure 3, described device 30 comprises acquiring unit 31, the first processing unit 32 and setting unit 33.
Wherein, acquiring unit 31 is used for opening people's face measuring ability of capture apparatus, and obtains the graphical information in everyone face zone of sign in the preview interface of described capture apparatus, and described graphical information is used for identifying the regional extent that everyone face occupies;
The first processing unit 32 is for the first ratio value that calculates described preview interface maximum face region area and described preview interface area according to the physical size of described graphical information, described preview interface;
Setting unit 33, be used for when described the first ratio value during more than or equal to first threshold, the screening-mode of described capture apparatus is set to the character motif pattern, and described first threshold is the percentage that described capture apparatus individual human face region area in the photo of taking character motif occupies the photo gross area;
Described setting unit 33 also is used for when described the first ratio value during less than described first threshold, and the screening-mode of described capture apparatus is set to non-character motif pattern.
The device of a kind of Lookup protocol screening-mode that the embodiment of the invention provides, open people's face measuring ability of capture apparatus, and obtain the graphical information in everyone face zone of sign in the preview interface of described capture apparatus, then according to described graphical information, the physical size of described preview interface calculates the first ratio value of maximum face region area and described preview interface area in the described preview interface, when described the first ratio value during more than or equal to first threshold, the screening-mode of described capture apparatus is set to the character motif pattern, when described the first ratio value during less than described first threshold, the screening-mode of described capture apparatus is set to non-character motif pattern.The embodiment of the invention has solved in the prior art because most of users are unfamiliar with which kind of screening-mode that needs to use mobile phone under which kind of scene, make shooting photo effect out undesirable, the problem of making troubles for user's use, realize the Lookup protocol of screening-mode, improved shooting effect.
Optionally, when described graphical information is rectangle frame information, when described rectangle frame information comprises rectangle frame wide and high, described the first processing unit, concrete being used for according to R
Face=Max (X
Face1* Y
Face1, X
Face2* Y
Face2..., X
Facen* Y
Facen)/(X
Pic* Y
Pic) calculate the first ratio value of maximum face area and described preview interface area in the described preview interface, wherein R
FaceBe the first ratio value of maximum face area in the described preview interface and described preview interface area, (X
Face1, Y
Face1), (X
Face2, Y
Face2) ..., (X
Facen, Y
Facen) be respectively rectangle frame wide and high of in described preview interface, get access to n sign different people face, (X
Pic, Y
Pic) be the wide and high of described preview interface.
Optionally, as shown in Figure 4, described device 30 also comprises:
The second processing unit 34, be used for calculating according to described the first ratio value, default predetermined distance, preset ratio value the current distance of the person of being taken corresponding to described preview interface maximum face and described capture apparatus, described default predetermined distance is for when whole people's face of the person of being taken included in photo, the minimum distance of the described person of being taken and described capture apparatus, when described preset ratio value is described default predetermined distance for the distance as described capture apparatus and the person of being taken, the person's of being taken maximum face region area and the ratio value of described preview interface area;
The 3rd processing unit 35, be used for judging that whether described current distance is greater than default safe distance, described default safe distance for the intensity of illumination when the photoflash lamp of described capture apparatus be human eye bear maximum safe intensity of illumination the time, described capture apparatus and the person's of being taken safe distance;
Described setting unit 33 also is used in the time that described current distance is not more than described default safe distance, and the operating state of the photoflash lamp of described capture apparatus is set to close.
Optionally, described the second processing unit specifically is used for basis
Calculate maximum face is corresponding in the described preview interface the person of being taken and the current distance of described capture apparatus, wherein D
CurrentBe maximum face is corresponding in the described preview interface the person of the being taken current distance with described capture apparatus, R
MaxBe described preset ratio value, R
FaceBe described the first ratio value, D
NearestBe described default predetermined distance.
Optionally, described setting unit also is used for when described the first ratio value during less than first threshold, and the screening-mode of described capture apparatus is set to non-character motif pattern.
Optionally, described setting unit also is used for when described current distance greater than described default safe distance the time, and the operating state of described photoflash lamp is set according to the parameter request of the character motif pattern of described capture apparatus.
The operating process of described device 30 is referring to the processing procedure of the method for above-mentioned Lookup protocol screening-mode.
Embodiment 3
The embodiment of the invention provides a kind of device of Lookup protocol screening-mode, and as shown in Figure 5, described device 50 comprises memory 51 and processor 52.
Wherein, memory 51 is used for storage instruction and parameter preset;
Processor 52 is used for the instruction of execute store 51, the concrete execution:
Open people's face measuring ability of capture apparatus, and obtain the graphical information in everyone face zone of sign in the preview interface of described capture apparatus, described graphical information is used for identifying the regional extent that everyone face occupies;
Calculate the first ratio value of maximum face region area and described preview interface area in the described preview interface according to the physical size of described graphical information, described preview interface;
When described the first ratio value during more than or equal to first threshold, the screening-mode of described capture apparatus is set to the character motif pattern, and described first threshold is the percentage that described capture apparatus individual human face region area in the photo of taking character motif occupies the photo gross area;
When described the first ratio value during less than described first threshold, the screening-mode of described capture apparatus is set to non-character motif pattern.
The device of a kind of Lookup protocol screening-mode that the embodiment of the invention provides, open people's face measuring ability of capture apparatus, and obtain the graphical information in everyone face zone of sign in the preview interface of described capture apparatus, then according to described graphical information, the physical size of described preview interface calculates the first ratio value of maximum face region area and described preview interface area in the described preview interface, when described the first ratio value during more than or equal to first threshold, the screening-mode of described capture apparatus is set to the character motif pattern, when described the first ratio value during less than described first threshold, the screening-mode of described capture apparatus is set to non-character motif pattern.The embodiment of the invention has solved in the prior art because most of users are unfamiliar with which kind of screening-mode that needs to use mobile phone under which kind of scene, make shooting photo effect out undesirable, the problem of making troubles for user's use, realize the Lookup protocol of screening-mode, improved shooting effect.
Optionally, described processor 52 also is used for carrying out:
When described graphical information is rectangle frame information, when described rectangle frame information comprised rectangle frame wide and high, described physical size according to described graphical information, described preview interface calculated that the first ratio value of maximum face area and described preview interface area is specially in the described preview interface:
According to R
Face=Max (X
Face1* Y
Face1, X
Face2* Y
Face2..., X
Facen* Y
Facen)/(X
Pic* Y
Pic) calculate the first ratio value of maximum face area and described preview interface area in the described preview interface, wherein R
FaceBe the first ratio value of maximum face area in the described preview interface and described preview interface area, (X
Face1, Y
Face1), (X
Face2, Y
Face2) ..., (X
Facen, Y
Facen) be respectively rectangle frame wide and high of in described preview interface, get access to n sign different people face, (X
Pic, Y
Pic) be the wide and high of described preview interface.
Optionally, described processor 52 also is used for carrying out:
Calculate the current distance of maximum face is corresponding in the described preview interface the person of being taken and described capture apparatus according to described the first ratio value, default predetermined distance, preset ratio value, described default predetermined distance is for when whole people's face of the person of being taken included in photo, the minimum distance of the described person of being taken and described capture apparatus, when described preset ratio value is described default predetermined distance for the distance as described capture apparatus and the person of being taken, the person's of being taken maximum face region area and the ratio value of described preview interface area;
Whether judge described current distance greater than default safe distance, described default safe distance for the intensity of illumination when the photoflash lamp of described capture apparatus be human eye bear maximum safe intensity of illumination the time, described capture apparatus and the person's of being taken safe distance;
In the time that described current distance is not more than described default safe distance, the operating state of the photoflash lamp of described capture apparatus is set to close.
Optionally, described processor 52 also is used for carrying out:
The current distance of calculating maximum face is corresponding in the described preview interface the person of being taken and described capture apparatus according to described the first ratio value, default predetermined distance, preset ratio value is specially:
According to
Calculate maximum face is corresponding in the described preview interface the person of being taken and the current distance of described capture apparatus, wherein D
CurrentBe maximum face is corresponding in the described preview interface the person of the being taken current distance with described capture apparatus, R
MaxBe described preset ratio value, R
FaceBe described the first ratio value, D
NearestBe described default predetermined distance.
When described the first ratio value during less than first threshold, the screening-mode of described capture apparatus is set to non-character motif pattern.
Optionally, described processor 52 also is used for carrying out:
When described current distance greater than described default safe distance the time, the operating state of described photoflash lamp is set according to the parameter request of the character motif pattern of described capture apparatus.
The operating process of described device 50 is referring to the processing procedure of the method for above-mentioned Lookup protocol screening-mode.
Through the above description of the embodiments, the those skilled in the art can be well understood to the present invention and can realize by the mode that software adds essential common hardware, can certainly pass through hardware, but the former is better execution mode in a lot of situation.Based on such understanding, the part that technical scheme of the present invention contributes to prior art in essence in other words can embody with the form of software product, this computer software product is stored in the storage medium that can read, floppy disk such as computer, hard disk or CD etc., comprise some instructions with so that computer equipment (can be personal computer, server, the perhaps network equipment etc.) carry out the described method of each embodiment of the present invention.
The above; be the specific embodiment of the present invention only, but protection scope of the present invention is not limited to this, anyly is familiar with those skilled in the art in the technical scope that the present invention discloses; can expect easily changing or replacing, all should be encompassed within protection scope of the present invention.Therefore, protection scope of the present invention should be as the criterion with the protection range of described claim.