CN105049704A - Shooting method and equipment - Google Patents

Shooting method and equipment Download PDF

Info

Publication number
CN105049704A
CN105049704A CN201510338491.5A CN201510338491A CN105049704A CN 105049704 A CN105049704 A CN 105049704A CN 201510338491 A CN201510338491 A CN 201510338491A CN 105049704 A CN105049704 A CN 105049704A
Authority
CN
China
Prior art keywords
image
taking pictures
main body
position information
longitudinal position
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201510338491.5A
Other languages
Chinese (zh)
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.)
Hisense Mobile Communications Technology Co Ltd
Original Assignee
Hisense Mobile Communications Technology Co 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 Hisense Mobile Communications Technology Co Ltd filed Critical Hisense Mobile Communications Technology Co Ltd
Priority to CN201510338491.5A priority Critical patent/CN105049704A/en
Publication of CN105049704A publication Critical patent/CN105049704A/en
Pending legal-status Critical Current

Links

Abstract

The invention relates to the technical field of digital images, and specifically relates to a shooting method and equipment. The problem of poor shooting effect in dim light can be solved. The method includes: after a shooting instruction is received, shooting is performed in a selected area, and a first image and a second image are obtained by respectively employing super-long exposure and turning on a flash light; a shooting main body in the second image is determined; according to vertical position information of the shooting main body in the second image, the same images of the first image and the shooting main body in the second image are determined; and the determined image in the first image is replaced by the shooting main body in the second image, and a target image is obtained. According to the technical scheme, the vertical position information of the shooting main body in the second image is determined via at least two cameras, the image in the first image whose vertical position information is the same with the vertical position information of the shooting main body in the second image is precisely replaced by the shooting main body in the second image, and the shooting effect is improved and enhanced.

Description

A kind of method and apparatus of taking pictures
Technical field
The present invention relates to Digital image technology field, particularly a kind of method and apparatus of taking pictures.
Background technology
At present, the photographing devices such as existing smart mobile phone, panel computer have the function of photoflash lamp and overlength exposure, for taking pictures to when night scene or dark.
Such as, under half-light, use the photographing device such as smart mobile phone or panel computer to take pictures, when adopting overlength exposure to take pictures, the brightness of subject is improved by prolonging exposure time, for preventing overexposure, do not open photoflash lamp and carry out light filling, because the whole scene of taking pictures is all by natural daylight, the image definition taken like this and colourity poor; Another kind of mode adopts photoflash lamp to take pictures, and the range of exposures like this due to photoflash lamp is limited, and the shutter of photographing device regulates with the brightness in the range of exposures of photoflash lamp, therefore take a picture in background be as dark as a stack of black cats.
For improving the effect of taking pictures when night scene or dark, photographing device by having the dual camera particularly camera that two optical systems are identical in prior art is taken pictures under half-light environment, double photosensitive owing to can obtain when taking pictures, therefore compared with the image taken with the photographing device with a camera, improve in the brightness of image, but due to by means of only natural daylight, the definition of the image therefore obtained is poor, so the effect of taking pictures does not significantly improve.
In sum, the effect using photographing device to take pictures under half-light in prior art is poor.
Summary of the invention
The invention provides a kind of method and apparatus of taking pictures, in order to solve the poor problem of the effect that uses photographing device to take pictures under half-light in prior art.
Embodiments provide a kind of method of taking pictures, comprising:
Receive photographing instruction, taken pictures in selected region, adopt overlength exposure and unlatching photoflash lamp to obtain the first image and the second image respectively;
The main body of taking pictures in described second image is determined from the thing of taking pictures of described second image;
According to the longitudinal position information of main body of taking pictures in described second image, determine the identical image with main body of taking pictures in described second image in described first image;
Image in described first image determined is replaced with the main body of taking pictures in described second image, obtain target image;
Wherein, the longitudinal position information of main body of taking pictures in described second image is obtained by least two cameras.
Owing to obtaining the first image respectively by the exposure of employing overlength in embodiments of the present invention, the second image is obtained with unlatching photoflash lamp, and can determine by least two cameras the longitudinal position information of main body in the second image of taking pictures, accurately realize image identical with main body longitudinal position information of taking pictures in the second image in the first image, replace with the main body of taking pictures in the second image, and because the background in region selected in the first image is comparatively clear, the main body of taking pictures in region selected in the second image is comparatively clear, thus the effect that makes to take pictures is improved and improves, solve and use at present photographing device to take pictures the poor problem of effect.
Optionally, after determining the main body of taking pictures in described second image, to determine in described first image, with before the identical image of main body of taking pictures in described second image, also to comprise:
The longitudinal position information of main body of determining to take pictures in described second image is different from the longitudinal position information of other things of taking pictures in described second image.
Optionally, after main body of taking pictures described in determining, also comprise:
If described in the take pictures longitudinal position information of main body identical with at least one other thing longitudinal position information in described second image of taking pictures in described second image, by in described first image with the longitudinal position information of main body of taking pictures in described second image, image that horizontal direction positional information is all identical with vertical direction positional information, replace with the main body of taking pictures in described second image, obtain target image.
Due to when when at least one, other thing longitudinal position information in the second image of taking pictures are identical with the longitudinal position information of main body in the second image of taking pictures, by other things of taking pictures that the horizontal position information of main body in the second image of determining to take pictures is identical with the longitudinal position information of main body in the second image of taking pictures with vertical position data separation, thus ensure that the accuracy that main body of taking pictures is replaced.
Optionally, determine the main body of taking pictures in described second image, specifically comprise:
According to the brightness value of each pixel in described second image, determine the main body of taking pictures in described second image.
Because the embodiment of the present invention according to the brightness value of each pixel, can determine main body of taking pictures from the thing of taking pictures of the second image, make take pictures main body and other Iamge Segmentation in the second image, thus accurately can obtain the main body of taking pictures of the second image.
Optionally, according to the brightness value of each pixel in described second image, determine the main body of taking pictures in described second image, specifically comprise:
Determine the brightness value of each pixel in described second image;
Determine that the brightness value of pixel in described second image is greater than the pixel of the brightness value of presetted pixel;
According to the pixel determined, from the thing of taking pictures of described second image, determine the main body of taking pictures in described second image.
Optionally, according to the brightness value of each pixel in described second image, determine the main body of taking pictures in described second image, specifically comprise:
Described second image is divided into multiple subregion, and according to the brightness value of pixel each in described subregion, determines the brightness value of described subregion;
Determine that brightness value exceedes the subregion of setting threshold;
All brightness values are exceeded the image in the subregion of setting threshold, as the main body of taking pictures in described second image.
Optionally, determine the main body of taking pictures in described second image, specifically comprise:
According to the longitudinal position information of thing of taking pictures in photoflash lamp illuminated area, determine the main body of taking pictures in described second image.
Because the embodiment of the present invention according to the longitudinal position information of thing of taking pictures in photoflash lamp illuminated area, can determine the main body of taking pictures in the second image, simplify the step of main body of determining to take pictures, improve the speed generating target image.
Optionally, according to the longitudinal position information of thing of taking pictures in photoflash lamp illuminated area, determine the main body of taking pictures in described second image, specifically comprise:
By thing of taking pictures identical with the longitudinal position information of thing of taking pictures in described photoflash lamp illuminated area in described second image, as the main body of taking pictures in described second image;
Wherein, the longitudinal position information of thing of taking pictures in described photoflash lamp illuminated area is determined by least two cameras.
Embodiments provide a kind of equipment of taking pictures, comprising:
Image photographic module, for receiving photographing instruction, takes pictures to selected region, adopts overlength exposure respectively and open photoflash lamp to obtain the first image and the second image;
Main body determination module, for determining the main body of taking pictures in described second image in the thing of taking pictures from described second image;
Images match module, for the longitudinal position information according to main body of taking pictures in described second image, determines the identical image with main body of taking pictures in described second image in described first image;
Computer image genration module, for the image in described first image determined being replaced with the main body of taking pictures in described second image, obtains target image;
Wherein, the longitudinal position information of main body of taking pictures in described second image is obtained by least two cameras.
Optionally, described images match module, also for
After the longitudinal position information of main body of determining to take pictures in described second image is different from the longitudinal position information of other things of taking pictures in described second image, determine the identical image with main body of taking pictures in described second image in described first image.
Optionally, described images match module, also for
If described in the take pictures longitudinal position information of main body identical with at least one other thing longitudinal position information in described second image of taking pictures in described second image, by in described first image with the longitudinal position information of main body of taking pictures in described second image, image that horizontal direction positional information is all identical with vertical direction positional information, replace with the main body of taking pictures in described second image, obtain target image.
Optionally, described main body determination module, specifically for:
According to the brightness value of each pixel in described second image, determine the main body of taking pictures in described second image.
Optionally, described main body determination module, specifically for: the brightness value determining each pixel in described second image;
Determine that the brightness value of pixel in described second image is greater than the pixel of the brightness value of presetted pixel;
According to the pixel determined, from the thing of taking pictures of described second image, determine the main body of taking pictures in described second image.
Optionally, described main body determination module, specifically for:
Described second image is divided into multiple subregion, and according to the brightness value of pixel each in described subregion, determines the brightness value of described subregion;
Determine that brightness value exceedes the subregion of setting threshold;
All brightness values are exceeded the image in the subregion of setting threshold, as the main body of taking pictures in described second image.
Optionally, described main body determination module, specifically for:
According to the longitudinal position information of thing of taking pictures in photoflash lamp illuminated area, determine the main body of taking pictures in described second image.
Optionally, described main body determination module, specifically for:
By thing of taking pictures identical with the longitudinal position information of thing of taking pictures in described photoflash lamp illuminated area in described second image, as the main body of taking pictures in described second image;
Wherein, the longitudinal position information of thing of taking pictures in described photoflash lamp illuminated area is determined by least two cameras.
Accompanying drawing explanation
Fig. 1 is the schematic flow sheet of the method that the embodiment of the present invention is taken pictures;
Fig. 2 is the Method And Principle schematic diagram that the embodiment of the present invention is taken pictures;
Fig. 3 is the photographing device schematic diagram that the embodiment of the present invention has two cameras;
Fig. 4 is the Method And Principle schematic diagram that the embodiment of the present invention is taken pictures;
Fig. 5 (a) embodiment of the present invention longitudinal position information measuring principle schematic diagram;
The Method And Principle schematic diagram that Fig. 5 (b) embodiment of the present invention is taken pictures;
The Method And Principle schematic diagram that Fig. 6 embodiment of the present invention is taken pictures;
Fig. 7 is the schematic flow sheet of the method that the embodiment of the present invention is taken pictures;
Fig. 8 is the schematic flow sheet of the method that the embodiment of the present invention is taken pictures;
Fig. 9 is the schematic diagram of the equipment that the embodiment of the present invention is taken pictures.
Embodiment
The embodiment of the present invention receives photographing instruction, takes pictures to selected region, adopts overlength exposure respectively and open photoflash lamp to obtain the first image and the second image; The main body of taking pictures in the second image is determined from the thing of taking pictures of the second image; According to the longitudinal position information of main body of taking pictures in the second image, determine the identical image with main body of taking pictures in the second image in the first image; Image in the first image determined is replaced with the main body of taking pictures in the second image, obtain target image; Wherein, the longitudinal position information of main body of taking pictures in the second image is obtained by least two cameras.This technical scheme is owing to obtaining the first image respectively by the exposure of employing overlength in embodiments of the present invention, the second image is obtained with unlatching photoflash lamp, and can determine by least two cameras the longitudinal position information of main body in the second image of taking pictures, accurately realize image identical with main body longitudinal position information of taking pictures in the second image in the first image, replace with the main body of taking pictures in the second image, and because the background in region selected in the first image is comparatively clear, the main body of taking pictures in region selected in the second image is comparatively clear, thus the effect that makes to take pictures is improved and improves, solve and use at present photographing device to take pictures the poor problem of effect.
Below in conjunction with Figure of description, the embodiment of the present invention is described in further detail.
As shown in Figure 1, the method that the embodiment of the present invention is taken pictures, comprising:
Step 100, receives photographing instruction, takes pictures to selected region, adopts overlength exposure respectively and open photoflash lamp to obtain the first image and the second image;
Step 101, determines the main body of taking pictures in the second image from the thing of taking pictures of the second image;
Step 102, according to the longitudinal position information of main body of taking pictures in the second image, determines the identical image with main body of taking pictures in the second image in the first image;
Step 103, replaces with the main body of taking pictures in the second image, obtains target image by the image in the first image determined.
Wherein, the longitudinal position information of main body of taking pictures in the second image is obtained by least two cameras.
Smart mobile phone, panel computer, iPad etc. that the method for taking pictures in the embodiment of the present invention can be applied to dual camera have the photographing device of overlength exposure function and photoflash lamp.
It should be noted that, in step 100, taken pictures in selected region, respectively adopt overlength exposure and open photoflash lamp obtain the first image and the second image, comprise two kinds of situations: a kind of situation is, first adopt overlength exposure to take pictures to selected region, obtain the first image, then close overlength exposure to open photoflash lamp again and take pictures to selected region, obtain the second image; Another kind of situation is, first open photoflash lamp to take pictures to selected region, obtain the second image, adopt overlength to expose again to take pictures to selected region, obtain the first image, that is: photographing device first adopts overlength to expose to take pictures to selected region or first opening photoflash lamp takes pictures to selected region, without inevitable sequencing, as long as obtain the first image and the second image.
Wherein, selected region is need according to user the region selected, the first image adopting overlength exposure to take pictures to obtain and open photoflash lamp and to take pictures the second image obtained, and is and takes pictures the image obtained to this selected region.
Specifically, user, by adjusting position or the angle of photographing device, comes the region that selected user needs to take pictures.By pre-setting the time of overlength exposure, within the time pre-setting overlength exposure, overlength exposure is adopted to take pictures, obtain the first image, after reaching the time pre-setting overlength exposure, closedown overlength exposes, wherein, the time pre-setting overlength exposure is longer, better light can be realized and paint effect, but owing to exposing the background in acquisition first image by overlength in the embodiment of the present invention, wherein, background is as shown in Figure 2 shown in 201 in the first image 1, when realizing, the time of establishing overlength to expose can be pre-set in photographing device, such as the time of user's input is 20 minutes, the background of the target image obtained is unintelligible, do not reach the demand of user for image definition, adjustment that can be suitable again pre-sets the time of overlength exposure.
Wherein, the time pre-setting overlength exposure carries out setting according to the needs of actual conditions.
The higher image of quality can be taken by the method in the embodiment of the present invention under half-light for making user, before smart mobile phone is taken pictures to selected region, a kind of method using technical solution of the present invention to carry out taking pictures that triggers is: user arranges corresponding exposal model according to the needs of actual conditions, such as: if current light is comparatively dark, exposal model is set as the pattern that half-light is taken pictures by user.
Wherein, the method for taking pictures that the half-light pattern of taking pictures is corresponding is embodiment of the present invention method as shown in Figure 1.
In addition, optionally, after receiving photographing command, determine that current intensity of illumination of taking pictures is less than the intensity of illumination preset, exposal model is set to the pattern that half-light is taken pictures by photographing device automatically, adopt overlength exposure to take pictures to selected region, obtain the first image, then perform step 101, step 102 and step 103 successively.
The intensity of illumination preset in the embodiment of the present invention sets according to actual conditions.
Such as: the intensity of illumination preset is 15, then mobile communication terminal (as smart mobile phone) is 14 monitoring current intensity of illumination of taking pictures, and is less than the intensity of illumination preset, then smart mobile phone determination current environment is half-light environment.If smart mobile phone, when monitoring current intensity of illumination and being 20, is greater than the intensity of illumination preset, then smart mobile phone determines that current environment is high light.
In embodiments of the present invention, optionally, photographing device adopts overlength exposure, by at least one camera, taken pictures in territory, selected frontal region, obtain the first image, after overlength exposure reaches Preset Time, closedown overlength exposes, open photoflash lamp, to by least one camera, taken pictures in selected region, obtain the second image.
Such as, this photographing device is the smart mobile phone of dual camera, if two of this smart mobile phone are made a video recording, first is main camera, one is auxiliary camera, then respectively by main camera, taken pictures in selected region, obtain the first image and the second image, for Fig. 3, photographing device 300 comprises camera 301 and camera 302, wherein, camera 301 is main camera, camera 302 is auxiliary camera, then photographing device 300 utilizes camera 301 to take pictures, namely photographing device 300 is after receiving photographing instruction, adopt overlength to expose by camera 301 to take pictures to selected region, obtain the first image, after overlength exposure reaches Preset Time, closedown overlength exposes, open photoflash lamp, by camera 301, taken pictures in selected region, obtain the second image, camera 302 carries out the measurement of longitudinal position information for auxiliary camera 301.
In addition, when photographing device is the photographing device of dual camera, and during two cameras camera that to be optical system identical, taken pictures by these two cameras, for Fig. 3, when supposing that two cameras 301 and 302 of photographing device 300 are identical two cameras of optical system, photographing device 300 is after receiving photographing instruction, adopt overlength to expose by camera 301 and camera 302 to take pictures to selected region, obtain the first image, after overlength exposure reaches Preset Time, closedown overlength exposes, open photoflash lamp, by camera 301 and camera 302, taken pictures in selected region, obtain the second image.
Take pictures owing to opening photoflash lamp in the ban, then when adopting overlength exposure to take pictures, its process of taking pictures is similar to the above, does not repeat them here.
Specifically, longitudinal position information is obtained by least two camera measurements, be specifically described for the photographing device of dual camera, as shown in Figure 4, distance between camera 400 and camera 401 is d1, distance between a pixel 402 to photographing device of taking pictures on thing is d2, angle between camera 400 and a pixel 402 of taking pictures on thing is θ, angle between camera 401 and pixel 402 is α, pass through d1, θ, α calculates d2, d2 is the distance that the pixel 402 of taking pictures on thing arrives photographing device, pixel all on thing of taking pictures then forms the longitudinal position information of thing of taking pictures to the distance of photographing device.In selected region, the longitudinal position information of all things of taking pictures forms depth of field map.
Wherein, the longitudinal position information of thing of taking pictures in selected region can in the pre-test of step 100, also can measure after step 100 or step 101 or step 102, as long as in the pre-test of step 103, and step 100, step 101, there is no inevitable sequencing between step 102.
For determining the main body of taking pictures in the second image more accurately, optionally, according to the longitudinal position information of thing of taking pictures in photoflash lamp illuminated area, determine the main body of taking pictures in described second image.
Specifically, by thing of taking pictures identical with the longitudinal position information of thing of taking pictures in described photoflash lamp illuminated area in described second image, as the main body of taking pictures in described second image;
Wherein, the longitudinal position information of thing of taking pictures in described photoflash lamp illuminated area is determined by least two cameras.
Be specifically described for Fig. 2, the first image 1 obtained is exposed by overlength, the second image 2 is obtained by opening photoflash lamp, suppose that the region that photoflash lamp illuminates is 202, by the longitudinal position information of the thing of taking pictures of at least two camera determination photoflash lamp illuminated area, suppose that the longitudinal position information of the thing of taking pictures of photoflash lamp illuminated area is 1.5 meters, then the thing of taking pictures being 1.5 meters by longitudinal position information in the second image 2 is defined as main body of taking pictures.As shown in Figure 2, the longitudinal position information of the thing of taking pictures in 202 regions is 1.5 meters, then the thing of taking pictures in 202 regions is defined as main body of taking pictures.
It should be noted that, in embodiments of the present invention, longitudinal position information is take pictures thing to the distance between photographing device in selected region.The measurement of the second longitudinal position information can before taking pictures to selected region, or in the process of taking pictures to selected region, also can be both after taking pictures to selected region.
It should be noted that the main body of taking pictures in the second image is the main body of taking pictures in the first image, is also simultaneously the main body of taking pictures in selected region.
As shown in Figure 2,202 regions in the second image 2 are replaced in 200 regions in the first image 1, obtains target image 3, namely target image 3 is made up of 202 regions and 201 regions.
Because in the first image 1, the brightness value of 201 area pixel is greater than the brightness value of the pixel in 203 regions in the second image 2, in second image 2, the brightness value of 202 area pixel is greater than the brightness value in 200 regions in the first image 1, and the effect of the image of the target image 3 therefore obtained is better.
Optionally, after step 101 determines the main body of taking pictures in described second image, the longitudinal position information of main body of determining to take pictures in described second image is different from the longitudinal position information of other things of taking pictures in described second image, then perform step 102, determine the identical image with main body of taking pictures in described second image in described first image
Be specifically described for Fig. 5 (a), if the longitudinal position information of main body 502 of taking pictures in the second image 501 is as different in the longitudinal position information of thing 503 in the second image 501 of taking pictures from other things of taking pictures in the second image 501, photographing device is by image 502 identical with the longitudinal position information of main body 502 of taking pictures in the second image 501 in the first image 500, replace with the main body 502 of taking pictures in the second image 501, obtain target image 504.
If described in the take pictures longitudinal position information of main body identical with at least one other thing longitudinal position information in described second image of taking pictures in described second image, optionally, after main body of taking pictures described in determining, by in described first image with the longitudinal position information of main body of taking pictures in described second image, image that horizontal direction positional information is all identical with vertical direction positional information, replace with the main body of taking pictures in described second image, obtain target image.
Be specifically described for Fig. 5 (b), because main body 502 of taking pictures in the second image 501 is identical with the longitudinal position information of thing 505 of taking pictures, then photographing device to be determined to take pictures the horizontal direction positional information of main body 502 and vertical direction positional information according to the second image 501, pass through longitudinal position information, horizontal direction positional information and vertical direction positional information determine the position of main body in the second image 501 of taking pictures, because main body 502 of taking pictures is identical with the position in the second image 501 in the first image 500, then the main body 502 of taking pictures in the first image 500 is replaced with the main body of taking pictures in the second image 501, obtain target image 504.
It should be noted that, due to thing not necessarily plane of taking pictures, main body 502 of taking pictures as shown in Fig. 5 (b) is for automobile, it not plane, each pixel of therefore taking pictures in main body is incomplete same to the distance of photographing device, and the longitudinal position information of main body of wherein taking pictures is the distance of all pixels to photographing device, and wherein this distance may be a value, also may be a scope, or multiple value.
In addition, after obtaining target image, the embodiment of the present invention can also be preserved and be shown this target image.
Specifically, after obtaining target image, photographing device shows this target image, as the target image 3 in Fig. 2, and this target image 3 is preserved in a device, or in RAM (random access memory) card.
For determining the main body of taking pictures in the second image more accurately, optionally, according to the brightness value of each pixel in described second image, the main body of taking pictures in described second image is determined.
Specifically, a kind of optional implementation is: the brightness value of each pixel in fixed described second image;
Determine that the brightness value of pixel in described second image is greater than the pixel of the brightness value of presetted pixel;
According to the pixel determined, from the thing of taking pictures of described second image, determine the main body of taking pictures in described second image.
Wherein, the brightness value of presetted pixel be the image of photoflash lamp illuminated portion in differentiation second image pixel and not by the critical value of the pixel of the image of photoflash lamp illuminated portion, set according to actual conditions.
Such as, the brightness value of presetted pixel is 20, then as shown in Figure 2, in the second image 2, the pixel brightness value in 202 regions is greater than 20, and the brightness value of the pixel in 203 regions is less than 20, and therefore 202 regions are the main body of taking pictures in the second image.
Calculate for simplifying, a kind of optional implementation is: described second image is divided into multiple subregion, and according to the brightness value of pixel each in described subregion, determines the brightness value of described subregion;
Determine that brightness value exceedes the subregion of setting threshold;
All brightness values are exceeded the image in the subregion of setting threshold, as the main body of taking pictures in described second image.
Such as: when the size of image is [W, H], wherein W is the width of image, and H is the height of image, image is divided into m*m sub regions, and m value is larger, and the effect of the target image of generation is better, but corresponding amount of calculation increases, therefore under normal circumstances, preferably, m gets 16 or 32.
Be specifically described for Fig. 6, the first image 01 obtained is exposed by overlength, the second image 02 is obtained by opening photoflash lamp, and target image 03, second image 02 is divided into 64 sub regions, i.e. m=8, the brightness value of every sub regions is obtained by the mean value of the brightness value calculating all pixels in every sub regions, such as, the brightness value of subregion a is 18, be greater than the threshold value 15 of setting, count in the second image 02 all subregion a ~ p being greater than the threshold value of setting, the image be then made up of subregion a ~ p is the main body of taking pictures in the second image.
Wherein, the threshold value of setting sets according to actual conditions, and the threshold value value of general setting is 15.
When the second image is divided into other multiple subregions, mode and the said method of its generation target image are similar, do not repeat them here.
Owing to only needing in the method to judge whether the region divided is greater than the threshold value of setting, and judge whether the brightness value of each pixel is greater than compared with the brightness value of default pixel, simplifies the workload of calculating, improves efficiency.
It should be noted that, in the embodiment of the present invention, be not limited by the main body of taking pictures that pixel intensity is determined in the second image, the method for other main bodys that can be used in determining taking pictures in the second image.
In order to being introduced the method that the embodiment of the present invention is taken pictures clearly, when photographing device determines that current photo environment is half-light automatically, generate the detailed process of target image as shown in Figure 7.
As shown in Figure 7, the method that the embodiment of the present invention is taken pictures, comprising:
Step 700, after receiving photographing instruction, determines that current intensity of illumination of taking pictures is less than the intensity of illumination preset.
Step 701, adopts overlength exposure to take pictures to selected region, obtains the first image.
Step 702, after overlength exposure reaches Preset Time, closes overlength exposure, opens automatic exposure, and opens photoflash lamp and take pictures to selected region, obtains the second image.
Step 703, by thing of taking pictures identical with the longitudinal position information of thing of taking pictures in photoflash lamp illuminated area in the second image, as the main body of taking pictures in the second image, wherein, the longitudinal position information of thing of taking pictures in photoflash lamp illuminated area is determined by least two cameras.
Step 704, according to the longitudinal position information of main body of taking pictures in described second image, determines the identical image with main body of taking pictures in described second image in described first image.
Step 705, the image in the first image determined is replaced with the main body of taking pictures in described second image, and obtain target image, this flow process terminates.
When the exposal model of the half-light that photographing device is arranged according to actual conditions by user, generate the detailed process of target image as shown in Figure 8.Such as, current light is more weak, and the effect of taking pictures of common shooting style is poor, and the exposal model of photographing device is directly set to the exposal model of half-light by user.
As shown in Figure 8, the method for taking pictures of the embodiment of the present invention, comprising:
Step 800, after receiving photographing instruction, adopts overlength exposure to take pictures to selected region, obtains the first image.
Step 801, after overlength exposure reaches Preset Time, closes overlength exposure, opens automatic exposure, and open photoflash lamp, take pictures, obtain the second image to selected region.
Step 802, according to the brightness value of each pixel in described second image, determines the main body of taking pictures in described second image.
Step 803, whether the longitudinal position information of main body of judging to take pictures in the second image is identical with other thing longitudinal position information in the second image of taking pictures in the second image, if, then perform step 804, otherwise perform step 805, wherein, the longitudinal position information of main body of taking pictures is determined by least two cameras.
Step 804, by in the first image with the longitudinal position information of main body of taking pictures in the second image, image that horizontal direction positional information is all identical with vertical direction positional information, replace with the main body of taking pictures in the second image, obtain target image, then perform step 806.
Step 805, by image identical with the longitudinal position information of main body of taking pictures in the second image in the first image, replaces with the main body of taking pictures in the second image, obtains target image.
Step 806, preserve and show this target image, this flow process terminates.
Based on same inventive concept, a kind of equipment of taking pictures is additionally provided in the embodiment of the present invention, because the method that the photographing device of Fig. 9 is corresponding is the method that the embodiment of the present invention is taken pictures, therefore the enforcement of embodiment of the present invention equipment see the enforcement of method, can repeat part and repeats no more.
As shown in Figure 9, the equipment that the embodiment of the present invention is taken pictures, comprising:
Image photographic module 900, for receiving photographing instruction, takes pictures to selected region, adopts overlength exposure respectively and open photoflash lamp to obtain the first image and the second image;
Main body determination module 901, for determining the main body of taking pictures in the second image from the thing of taking pictures of the second image;
Images match module 902, for the longitudinal position information according to main body of taking pictures in the second image, determines the identical image with main body of taking pictures in the second image in the first image;
Computer image genration module 903, for the image in the determine first image being replaced with the main body of taking pictures in the second image, obtains target image;
Wherein, the longitudinal position information of main body of taking pictures in the second image is obtained by least two cameras.
Optionally, images match module 902, also for
After the longitudinal position information of main body of determining to take pictures in the second image is different from the longitudinal position information of other things of taking pictures in the second image, determine the identical image with main body of taking pictures in the second image in the first image.
Optionally, images match module 902, also for
If take pictures, the longitudinal position information of main body is identical with at least one other thing longitudinal position information in the second image of taking pictures in the second image, by in the first image with the longitudinal position information of main body of taking pictures in the second image, image that horizontal direction positional information is all identical with vertical direction positional information, replace with the main body of taking pictures in the second image, obtain target image.
Optionally, main body determination module 901, specifically for:
According to the brightness value of pixel each in the second image, determine the main body of taking pictures in the second image.
Optionally, main body determination module 901, specifically for:
Determine the brightness value of each pixel in the second image;
Determine that the brightness value of pixel in the second image is greater than the pixel of the brightness value of presetted pixel;
According to the pixel determined, from the thing of taking pictures of the second image, determine the main body of taking pictures in the second image.
Optionally, main body determination module 901, specifically for:
Second image is divided into multiple subregion, and according to the brightness value of pixel each in subregion, determines the brightness value of subregion;
Determine that brightness value exceedes the subregion of setting threshold;
All brightness values are exceeded the image in the subregion of setting threshold, as the main body of taking pictures in the second image.
Optionally, main body determination module 901, specifically for:
According to the longitudinal position information of thing of taking pictures in photoflash lamp illuminated area, determine the main body of taking pictures in the second image.
Optionally, main body determination module 901, specifically for:
By thing of taking pictures identical with the longitudinal position information of thing of taking pictures in photoflash lamp illuminated area in the second image, as the main body of taking pictures in the second image;
Wherein, the longitudinal position information of thing of taking pictures in photoflash lamp illuminated area is determined by least two cameras.
It can be seen from the above: the embodiment of the present invention receives photographing instruction, takes pictures to selected region, adopts overlength exposure respectively and open photoflash lamp to obtain the first image and the second image; The main body of taking pictures in the second image is determined from the thing of taking pictures of the second image; According to the longitudinal position information of main body of taking pictures in the second image, determine the identical image with main body of taking pictures in the second image in the first image; Image in the first image determined is replaced with the main body of taking pictures in the second image, obtain target image; Wherein, the longitudinal position information of main body of taking pictures in the second image is obtained by least two cameras.This technical scheme is owing to obtaining the first image respectively by the exposure of employing overlength in embodiments of the present invention, the second image is obtained with unlatching photoflash lamp, and can determine by least two cameras the longitudinal position information of main body in the second image of taking pictures, accurately realize image identical with main body longitudinal position information of taking pictures in the second image in the first image, replace with the main body of taking pictures in the second image, and because the background in region selected in the first image is comparatively clear, the main body of taking pictures in region selected in the second image is comparatively clear, thus the effect that makes to take pictures is improved and improves, solve and use at present photographing device to take pictures the poor problem of effect.
Those skilled in the art should understand, embodiments of the invention can be provided as method, system or computer program.Therefore, the present invention can adopt the form of complete hardware embodiment, the completely embodiment of application software embodiment or connected applications software and hardware aspect.And the present invention can adopt in one or more form wherein including the upper computer program implemented of computer-usable storage medium (including but not limited to magnetic disc store, CD-ROM, optical memory etc.) of computer usable program code.
The present invention describes with reference to according to the flow chart of the method for the embodiment of the present invention, equipment (system) and computer program and/or block diagram.Should understand can by the combination of the flow process in each flow process in computer program instructions realization flow figure and/or block diagram and/or square frame and flow chart and/or block diagram and/or square frame.These computer program instructions can being provided to the processor of all-purpose computer, special-purpose computer, Embedded Processor or other programmable data processing device to produce a machine, making the instruction performed by the processor of computer or other programmable data processing device produce device for realizing the function of specifying in flow chart flow process or multiple flow process and/or block diagram square frame or multiple square frame.
These computer program instructions also can be stored in can in the computer-readable memory that works in a specific way of vectoring computer or other programmable data processing device, the instruction making to be stored in this computer-readable memory produces the manufacture comprising command device, and this command device realizes the function of specifying in flow chart flow process or multiple flow process and/or block diagram square frame or multiple square frame.
These computer program instructions also can be loaded in computer or other programmable data processing device, make on computer or other programmable devices, to perform sequence of operations step to produce computer implemented process, thus the instruction performed on computer or other programmable devices is provided for the step realizing the function of specifying in flow chart flow process or multiple flow process and/or block diagram square frame or multiple square frame.
Although describe the preferred embodiments of the present invention, those skilled in the art once obtain the basic creative concept of cicada, then can make other change and amendment to these embodiments.So claims are intended to be interpreted as comprising preferred embodiment and falling into all changes and the amendment of the scope of the invention.
Obviously, those skilled in the art can carry out various change and modification to the present invention and not depart from the spirit and scope of the present invention.Like this, if these amendments of the present invention and modification belong within the scope of the claims in the present invention and equivalent technologies thereof, then the present invention is also intended to comprise these change and modification.

Claims (16)

1. a method of taking pictures, is characterized in that, the method comprises:
Receive photographing instruction, taken pictures in selected region, adopt overlength exposure and unlatching photoflash lamp to obtain the first image and the second image respectively;
The main body of taking pictures in described second image is determined from the thing of taking pictures of described second image;
According to the longitudinal position information of main body of taking pictures in described second image, determine the identical image with main body of taking pictures in described second image in described first image;
Image in described first image determined is replaced with the main body of taking pictures in described second image, obtain target image;
Wherein, the longitudinal position information of main body of taking pictures in described second image is obtained by least two cameras.
2. the method for claim 1, is characterized in that, after determining the main body of taking pictures in described second image, to determine in described first image, with before the identical image of main body of taking pictures in described second image, also to comprise:
The longitudinal position information of main body of determining to take pictures in described second image is different from the longitudinal position information of other things of taking pictures in described second image.
3. method as claimed in claim 2, is characterized in that, after main body of taking pictures, also comprise described in determining:
If described in the take pictures longitudinal position information of main body identical with at least one other thing longitudinal position information in described second image of taking pictures in described second image, by in described first image with the longitudinal position information of main body of taking pictures in described second image, image that horizontal direction positional information is all identical with vertical direction positional information, replace with the main body of taking pictures in described second image, obtain target image.
4. method as claimed in claim 2, is characterized in that, determine the main body of taking pictures in described second image, specifically comprise:
According to the brightness value of each pixel in described second image, determine the main body of taking pictures in described second image.
5. method as claimed in claim 4, is characterized in that, according to the brightness value of each pixel in described second image, determine the main body of taking pictures in described second image, specifically comprise:
Determine the brightness value of each pixel in described second image;
Determine that the brightness value of pixel in described second image is greater than the pixel of the brightness value of presetted pixel;
According to the pixel determined, from the thing of taking pictures of described second image, determine the main body of taking pictures in described second image.
6. method as claimed in claim 4, is characterized in that, according to the brightness value of each pixel in described second image, determine the main body of taking pictures in described second image, specifically comprise:
Described second image is divided into multiple subregion, and according to the brightness value of pixel each in described subregion, determines the brightness value of described subregion;
Determine that brightness value exceedes the subregion of setting threshold;
All brightness values are exceeded the image in the subregion of setting threshold, as the main body of taking pictures in described second image.
7. the method for claim 1, is characterized in that, determines the main body of taking pictures in described second image, specifically comprises:
According to the longitudinal position information of thing of taking pictures in photoflash lamp illuminated area, determine the main body of taking pictures in described second image.
8. method as claimed in claim 7, is characterized in that, according to the longitudinal position information of thing of taking pictures in photoflash lamp illuminated area, determine the main body of taking pictures in described second image, specifically comprise:
By thing of taking pictures identical with the longitudinal position information of thing of taking pictures in described photoflash lamp illuminated area in described second image, as the main body of taking pictures in described second image;
Wherein, the longitudinal position information of thing of taking pictures in described photoflash lamp illuminated area is determined by least two cameras.
9. an equipment of taking pictures, is characterized in that, this equipment comprises:
Image photographic module, for receiving photographing instruction, takes pictures to selected region, adopts overlength exposure respectively and open photoflash lamp to obtain the first image and the second image;
Main body determination module, for determining the main body of taking pictures in described second image in the thing of taking pictures from described second image;
Images match module, for the longitudinal position information according to main body of taking pictures in described second image, determines the identical image with main body of taking pictures in described second image in described first image;
Computer image genration module, for the image in described first image determined being replaced with the main body of taking pictures in described second image, obtains target image;
Wherein, the longitudinal position information of main body of taking pictures in described second image is obtained by least two cameras.
10. equipment as claimed in claim 9, is characterized in that, described images match module, also for:
After the longitudinal position information of main body of determining to take pictures in described second image is different from the longitudinal position information of other things of taking pictures in described second image, determine the identical image with main body of taking pictures in described second image in described first image.
11. equipment as claimed in claim 10, is characterized in that, described images match module, also for:
If described in the take pictures longitudinal position information of main body identical with at least one other thing longitudinal position information in described second image of taking pictures in described second image, by in described first image with the longitudinal position information of main body of taking pictures in described second image, image that horizontal direction positional information is all identical with vertical direction positional information, replace with the main body of taking pictures in described second image, obtain target image.
12. equipment as claimed in claim 10, is characterized in that, described main body determination module, specifically for:
According to the brightness value of each pixel in described second image, determine the main body of taking pictures in described second image.
13. equipment as claimed in claim 12, is characterized in that, described main body determination module, specifically for:
Determine the brightness value of each pixel in described second image;
Determine that the brightness value of pixel in described second image is greater than the pixel of the brightness value of presetted pixel;
According to the pixel determined, from the thing of taking pictures of described second image, determine the main body of taking pictures in described second image.
14. equipment as claimed in claim 12, is characterized in that, described main body determination module, specifically for:
Described second image is divided into multiple subregion, and according to the brightness value of pixel each in described subregion, determines the brightness value of described subregion;
Determine that brightness value exceedes the subregion of setting threshold;
All brightness values are exceeded the image in the subregion of setting threshold, as the main body of taking pictures in described second image.
15. equipment as claimed in claim 9, is characterized in that, described main body determination module, specifically for:
According to the longitudinal position information of thing of taking pictures in photoflash lamp illuminated area, determine the main body of taking pictures in described second image.
16. equipment as claimed in claim 15, is characterized in that, described main body determination module, specifically for:
By thing of taking pictures identical with the longitudinal position information of thing of taking pictures in described photoflash lamp illuminated area in described second image, as the main body of taking pictures in described second image;
Wherein, the longitudinal position information of thing of taking pictures in described photoflash lamp illuminated area is determined by least two cameras.
CN201510338491.5A 2015-06-17 2015-06-17 Shooting method and equipment Pending CN105049704A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510338491.5A CN105049704A (en) 2015-06-17 2015-06-17 Shooting method and equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510338491.5A CN105049704A (en) 2015-06-17 2015-06-17 Shooting method and equipment

Publications (1)

Publication Number Publication Date
CN105049704A true CN105049704A (en) 2015-11-11

Family

ID=54455870

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510338491.5A Pending CN105049704A (en) 2015-06-17 2015-06-17 Shooting method and equipment

Country Status (1)

Country Link
CN (1) CN105049704A (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108234880A (en) * 2018-02-02 2018-06-29 成都西纬科技有限公司 A kind of image enchancing method and device
CN108881730A (en) * 2018-08-06 2018-11-23 成都西纬科技有限公司 Image interfusion method, device, electronic equipment and computer readable storage medium
CN109993711A (en) * 2019-03-25 2019-07-09 维沃移动通信有限公司 A kind of image processing method and terminal device
CN110677584A (en) * 2019-09-30 2020-01-10 联想(北京)有限公司 Processing method and electronic equipment

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2000308068A (en) * 1999-04-16 2000-11-02 Olympus Optical Co Ltd Image pickup device
CN1645914A (en) * 2004-01-23 2005-07-27 索尼株式会社 Image processing method, image processing apparatus, and computer program used therewith
CN102469265A (en) * 2010-11-18 2012-05-23 卡西欧计算机株式会社 Image capturing apparatus and image capturing method
CN103871051A (en) * 2014-02-19 2014-06-18 小米科技有限责任公司 Image processing method, device and electronic equipment
CN103905730A (en) * 2014-03-24 2014-07-02 深圳市中兴移动通信有限公司 Shooting method of mobile terminal and mobile terminal
CN104113702A (en) * 2014-07-25 2014-10-22 北京智谷睿拓技术服务有限公司 Flash control method and device and image collection method and device
CN104333710A (en) * 2014-11-28 2015-02-04 广东欧珀移动通信有限公司 Camera exposure method, camera exposure device and camera exposure equipment
CN104333748A (en) * 2014-11-28 2015-02-04 广东欧珀移动通信有限公司 Method, device and terminal for obtaining image main object

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2000308068A (en) * 1999-04-16 2000-11-02 Olympus Optical Co Ltd Image pickup device
CN1645914A (en) * 2004-01-23 2005-07-27 索尼株式会社 Image processing method, image processing apparatus, and computer program used therewith
CN102469265A (en) * 2010-11-18 2012-05-23 卡西欧计算机株式会社 Image capturing apparatus and image capturing method
CN103871051A (en) * 2014-02-19 2014-06-18 小米科技有限责任公司 Image processing method, device and electronic equipment
CN103905730A (en) * 2014-03-24 2014-07-02 深圳市中兴移动通信有限公司 Shooting method of mobile terminal and mobile terminal
CN104113702A (en) * 2014-07-25 2014-10-22 北京智谷睿拓技术服务有限公司 Flash control method and device and image collection method and device
CN104333710A (en) * 2014-11-28 2015-02-04 广东欧珀移动通信有限公司 Camera exposure method, camera exposure device and camera exposure equipment
CN104333748A (en) * 2014-11-28 2015-02-04 广东欧珀移动通信有限公司 Method, device and terminal for obtaining image main object

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108234880A (en) * 2018-02-02 2018-06-29 成都西纬科技有限公司 A kind of image enchancing method and device
CN108234880B (en) * 2018-02-02 2020-11-24 成都西纬科技有限公司 Image enhancement method and device
CN108881730A (en) * 2018-08-06 2018-11-23 成都西纬科技有限公司 Image interfusion method, device, electronic equipment and computer readable storage medium
CN109993711A (en) * 2019-03-25 2019-07-09 维沃移动通信有限公司 A kind of image processing method and terminal device
CN110677584A (en) * 2019-09-30 2020-01-10 联想(北京)有限公司 Processing method and electronic equipment

Similar Documents

Publication Publication Date Title
USRE48595E1 (en) Method and system for determining optimal exposure of structured light based 3D camera
CN101690243B (en) Image pickup device and image pickup method
EP3248374B1 (en) Method and apparatus for multiple technology depth map acquisition and fusion
CN105208281B (en) A kind of night scene image pickup method and device
CN103763477B (en) A kind of dual camera claps back focusing imaging device and method
CN102084642B (en) Electron camera, image processing device, and image processing method
CN109218627B (en) Image processing method, image processing device, electronic equipment and storage medium
KR20200041382A (en) Dual camera-based imaging method, mobile terminal and storage medium
CN110213494B (en) Photographing method and device, electronic equipment and computer readable storage medium
CN103780840A (en) High-quality imaging double camera shooting and imaging device and method thereof
CN108337446B (en) High dynamic range image acquisition method, device and equipment based on double cameras
CN106851122A (en) The scaling method and device of the auto exposure parameter based on dual camera system
CN104333710A (en) Camera exposure method, camera exposure device and camera exposure equipment
CN104052933A (en) Method for determining dynamic range mode, and image obtaining apparatus
CN101877765A (en) Image translation device and control image translation device method of operating
CN102057665A (en) Electron camera, image processing device, and image processing method
CN105049704A (en) Shooting method and equipment
CN104092955A (en) Flash control method and device, as well as image acquisition method and equipment
CN104092956A (en) Flash control method, flash control device and image acquisition equipment
CN107846556A (en) imaging method, device, mobile terminal and storage medium
KR930701761A (en) The process of determining the extra system speed and automatically optimizing the exposure parameters of the picture.
CN103634528A (en) Backlight compensation method, apparatus and terminal
CN106331505A (en) Shooting method and device
CN105049703A (en) Shooting method for mobile communication terminal and mobile communication terminal
CN104092954A (en) Flash control method and control device and image collection method and collection device

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication

Application publication date: 20151111

RJ01 Rejection of invention patent application after publication