Light measuring method, device, capture apparatus and storage medium
Technical field
The present embodiments relate to optical measuring technique more particularly to a kind of light measuring method, device, capture apparatus and storages
Medium.
Background technique
The photometric system of the capture apparatus such as digital camera or mobile phone, the usually light of measurement subject reflection
Degree.The brightness measured is transferred in the processor of capture apparatus, after the calculating process of automatic exposure, determines to expose
Combination, that is, the aperture shot are combined with shutter speed, and the aperture and fast gate value then provided according to capture apparatus is taken pictures, i.e.,
The accurate photo of exposure can be shot.
The common metering mode of capture apparatus has evaluation to survey light, spot light-metering, center portion survey light and center and averagely surveys at present
Light etc., every kind of metering mode are corresponding with pre-set light metering weight table, so that the survey light initially obtained to photometric system is drawn
The brightness value of each statistical regions in face is weighted, and obtains the corresponding resulting survey light brightness of metering mode.
But since light metering weight table is the fixation parameter under corresponding metering mode, therefore there is part in surveying light picture
In the case where extremely bright or dark local extreme abnormal area, the brightness value of the abnormal area will be to the resulting light of metering mode
Brightness generates the influence that can not ignore, such as makes brightness excessive or too small, and then automatic exposure process is caused to calculate gained
Exposure combination value and actual demand value deviation it is larger, influence shooting effect.
Summary of the invention
The embodiment of the present invention provides a kind of light measuring method, device, capture apparatus and storage medium, surveys the accurate of light to improve
Property, the survey light brightness of more realistic imaging demand is obtained, to realize subsequent reasonable exposure, guarantees shooting effect.
In a first aspect, the embodiment of the invention provides a kind of light measuring methods, comprising:
Obtain the corresponding survey brightness matrix of smooth picture to be measured;
According to the survey brightness matrix and extreme brightness threshold value, determine that brightness value is located at extreme in the smooth picture to be measured
The region accounting in the extreme brightness region of brightness section, the extreme brightness section by the extreme brightness threshold value and with it is described
The corresponding brightness value of extreme brightness threshold value is most worth generation;
If the region accounting is less than default accounting threshold value, by each extreme brightness value in the survey brightness matrix
It adjusts to normal brightness section, obtains adjustment luminance matrix, the normal brightness section is by the extreme brightness threshold value or described
Extreme brightness threshold value and the brightness value are most worth generation;
According to the adjustment luminance matrix and the corresponding light metering weight table of target metering mode, the smooth picture to be measured is surveyed
Light.
Second aspect, the embodiment of the invention also provides a kind of light measurer, which includes:
It surveys brightness matrix and obtains module, for obtaining the corresponding survey brightness matrix of smooth picture to be measured;
Region accounting determining module, for determining described to be measured according to the survey brightness matrix and extreme brightness threshold value
Brightness value is located at the region accounting in the extreme brightness region in extreme brightness section in light picture, and the extreme brightness section is by described
Extreme brightness threshold value and brightness value corresponding with the extreme brightness threshold value are most worth generation;
Luminance matrix determining module is adjusted, if being less than default accounting threshold value for the region accounting, by the survey light
Each extreme brightness value in luminance matrix is adjusted to normal brightness section, obtains adjustment luminance matrix, the normal brightness area
Between generation is most worth by the extreme brightness threshold value or the extreme brightness threshold value and the brightness value;
Optical module is surveyed, is used for according to the adjustment luminance matrix and the corresponding light metering weight table of target metering mode, to institute
It states smooth picture to be measured and surveys light.
The third aspect, the embodiment of the invention also provides a kind of capture apparatus, which includes:
One or more processors;
Storage device, for storing one or more programs;
Camera, for acquiring smooth picture to be measured;
When one or more of programs are executed by one or more of processors, so that one or more of processing
Device realizes light measuring method provided by any embodiment of the invention.
Fourth aspect, the embodiment of the invention also provides a kind of computer readable storage mediums, are stored thereon with computer
Program, the computer program realize light measuring method provided by any embodiment of the invention when being executed by processor.
The embodiment of the present invention determines light to be measured by the corresponding survey brightness matrix of smooth picture to be measured and extreme brightness threshold value
The region accounting in extreme brightness region in picture, and when region accounting is less than default accounting threshold value, it will survey in brightness matrix
Extreme brightness value adjust to normal brightness section, obtain adjustment luminance matrix, and then survey according to adjustment luminance matrix and target
The corresponding light metering weight table of optical mode surveys light to smooth picture to be measured.Both it had shielded under the lesser scene of extreme brightness region accounting,
The extreme brightness value in brightness matrix is surveyed to the anomalous effects of photometry result, also ensures that extreme brightness region accounting is biggish
The invariance that brightness matrix is surveyed under scene obtains the survey of more realistic imaging demand to improve the accuracy for surveying light
Light brightness guarantees shooting effect to realize subsequent reasonable exposure.
Detailed description of the invention
Fig. 1 is the flow chart of one of the embodiment of the present invention one light measuring method;
Fig. 2 is the flow chart of one of the embodiment of the present invention two light measuring method;
Fig. 3 is the survey brightness section distribution schematic diagram in the embodiment of the present invention;
Fig. 4 is the flow chart of one of the embodiment of the present invention three light measuring method;
Fig. 5 is the survey brightness matrix schematic diagram in the embodiment of the present invention three;
Fig. 6 is the structural schematic diagram of one of the embodiment of the present invention four light measurer;
Fig. 7 is the structural schematic diagram of one of the embodiment of the present invention five equipment.
Specific embodiment
The present invention is described in further detail with reference to the accompanying drawings and examples.It is understood that this place is retouched
The specific embodiment stated is used only for explaining the present invention rather than limiting the invention.It also should be noted that in order to just
Only the parts related to the present invention are shown in description, attached drawing rather than entire infrastructure.
Embodiment one
It is lesser that light measuring method provided in this embodiment is applicable to extreme brightness region accounting in entirely survey light picture
In the case of capture apparatus survey light.This method can be executed by light measurer, which can be by the side of software and/or hardware
Formula realizes that the device can integrate in the capture apparatus using CMOS/CCD sensor, such as mobile phone, tablet computer, vehicle-mounted
Camera, foolproof camera or slr camera etc..Referring to Fig. 1, the method for the present embodiment specifically comprises the following steps:
S110, the corresponding survey brightness matrix of smooth picture to be measured is obtained.
Wherein, smooth picture to be measured refers to the picture acquired when capture apparatus surveys light by camera.Surveying brightness matrix is
Refer to that the luminance matrix for carrying out flash spotter calculation, each of which matrix element value are the system of the corresponding statistical regions of the matrix element
Count brightness value.
Specifically, smooth picture to be measured, the CMOS/CCD sensor of the capture apparatus are grabbed by the camera of capture apparatus
The reflectance lightness (brightness value) in the smooth picture to be measured is obtained, a matrix element quantity is generated and number of sensors is consistent
Original intensity matrix.Later, which is divided into multiple statistical regions.For each statistical regions, by the system
It counts all brightness values in region and carries out (weighting) averagely, the statistics brightness value of the statistical regions can be obtained, and then surveyed
Brightness matrix.
S120, foundation survey brightness matrix and extreme brightness threshold value, determine that brightness value is located at extremely bright in smooth picture to be measured
Spend the region accounting in the extreme brightness region in section.
Wherein, extreme brightness threshold value is preset brightness value, be used to distinguish a brightness value be it is excessive it is (excessively bright),
It is normal or too small (excessively dark).The extreme brightness threshold value can be the fixed numbers of equipment factory setting;It is also possible to user or tune
The numerical value for the input interface input that examination engineer is provided by capture apparatus, to meet different application demands.This is extremely bright
Spending threshold value can be one, such as characterizes the too small very dark luminance threshold of brightness value or characterize the excessive incandescent brightness of brightness value
Threshold value;The extreme brightness threshold value may be two, i.e., extreme brightness threshold value includes very dark luminance threshold and incandescent luminance threshold.
Extreme brightness section is an extreme brightness numberical range, by extreme brightness threshold value and with extreme brightness threshold value
Corresponding brightness value is most worth generation.Such as extreme brightness threshold value is very dark luminance threshold, then the extreme brightness section is just by pole
Dark luminance threshold and brightness value minimum value generate.Brightness value most value refers to the value range for surveying brightness value in brightness matrix
Boundary value, may include brightness value minimum value and brightness value maximum value.Brightness value is most worth by the figure in capture apparatus
Picture signal processor (Image Signal Processor, ISP) determines, such as can be 0 and 255.
Specifically, each brightness value in brightness matrix will be surveyed with extreme brightness threshold value comparison, determined extremely bright
Brightness value falls in the matrix element distribution in extreme brightness section in degree matrix, and matrix element distribution can determine that accordingly
Extreme brightness region in smooth picture to be measured.Later, specific gravity of the extreme brightness region in entire smooth picture to be measured is calculated, i.e.,
Region accounting.Region accounting can be based on areal calculation, such as calculate the area and smooth picture area to be measured in extreme brightness region
Ratio;It is also possible to calculate based on element number.Specifically use which kind of calculation, can be according to the image of capture apparatus at
Function is managed to determine.
Illustratively, S120 includes: to determine that brightness value is located at extremely bright in survey brightness matrix according to extreme brightness threshold value
Spend the element number in section;According to the element total number of element number and survey brightness matrix, brightness in smooth picture to be measured is determined
Value is located at the region accounting in the extreme brightness region in extreme brightness section.
Specifically, it according to each brightness value of extreme brightness threshold value and survey brightness matrix, directly counts brightness value and falls into
The element number of the matrix element in extreme brightness section.Later, the resulting element number of counting statistics and survey brightness matrix packet
The ratio of all elements number (element total number) contained is located at the pole in extreme brightness section as brightness value in smooth picture to be measured
Hold the region accounting of luminance area.The advantages of this arrangement are as follows further increasing survey ray velocity.
If S130, region accounting are less than default accounting threshold value, each extreme brightness value tune in brightness matrix will be surveyed
It is whole to normal brightness section, obtain adjustment luminance matrix.
Wherein, presetting accounting threshold value is maximum accounting of the preset extreme brightness region in entire smooth picture to be measured,
Its fixed value that can be capture apparatus factory configuration is also possible to capture apparatus and provides setting interface, for user/debugging work
The numerical value that Cheng Shi is dynamically adjusted according to actual needs.The setting purpose of the default accounting threshold value, is in order in large area accumulated snow
Or pure dark situation etc. has under the photographed scene of large scale extreme brightness, not to the survey brightness square of its resulting smooth picture to be measured
Battle array carries out brightness adjustment, to guarantee the accuracy of the resulting photometry result of the photographed scene, and then ensures such photographed scene
The accuracy of lower shooting image/video.
Normal brightness section is correspondingly arranged with extreme brightness section, and normal brightness section is by extreme brightness threshold value or extremely
Luminance threshold and brightness value are most worth generation.For example, extreme brightness threshold value only has very dark luminance threshold, then normal brightness section by
Very dark luminance threshold and brightness value maximum value generate.For another example, extreme brightness threshold value has very dark luminance threshold and incandescent luminance threshold
Value, then normal brightness section is just generated by very dark luminance threshold and incandescent luminance threshold.
Specifically, compare the resulting region accounting of S120 and default accounting threshold value.It is preset when region accounting is greater than or equal to
When accounting threshold value, illustrates that the corresponding photographed scene of smooth picture to be measured is the photographed scene with large scale extreme brightness, survey light
Extreme brightness value in luminance matrix is normal brightness value needed for surveying light, therefore does not need to carry out brightness value adjustment to it, can be straight
It connects based on survey brightness matrix, and is utilized as the corresponding survey light power of metering mode (target metering mode) of smooth picture setting to be measured
Weight table, carries out survey light to smooth picture to be measured.
When region accounting is less than default accounting threshold value, illustrate that the extreme brightness value surveyed in brightness matrix is to subsequent survey
Light has the noise brightness value of anomalous effects, then needs to carry out brightness adjustment to it.When it is implemented, will survey bright in brightness matrix
Each brightness value (extreme brightness value) that angle value belongs to extreme brightness section is adjusted according to predetermined luminance value adjustment rule to just
Normal brightness section, the brightness value that can obtain each matrix element are respectively positioned on the adjustment luminance matrix in normal brightness section.This is pre-
If brightness value adjustment rule, which can be, directly carries out brightness value setting, it is also possible to be scaled.
S140, foundation adjustment luminance matrix and the corresponding light metering weight table of target metering mode survey light to smooth picture to be measured.
Wherein, light metering weight table refers to the data for survey each weighted value composition used in light shading computation, can
To be matrix form, it is also possible to tabular form, as long as the corresponding weighted value distribution situation of target metering mode can be characterized i.e.
It can.For example, corresponding center average metering mode, then require in light metering weight table, act on and survey brightness matrix middle section
Weighted value, greater than the weighted value for acting on survey brightness matrix neighboring area.
Specifically, adjustment luminance matrix weight by element using target metering mode corresponding light metering weight table and be counted
It calculates, and calculates weighted results mean value, the corresponding survey light brightness of smooth picture to be measured can be obtained, complete the survey to smooth picture to be measured
Light.Here the metering mode specified in default configuration when target metering mode can be capture apparatus factory, is also possible to use
The survey optical mode that family/commissioning engineer is selected from multiple metering modes that capture apparatus provides by the interactive interface of capture apparatus
Formula.
The technical solution of the present embodiment is determined by the corresponding survey brightness matrix of smooth picture to be measured and extreme brightness threshold value
The region accounting in extreme brightness region in smooth picture to be measured, and when region accounting is less than default accounting threshold value, brightness will be surveyed
Extreme brightness value in matrix is adjusted to normal brightness section, obtains adjustment luminance matrix, so according to adjustment luminance matrix and
The corresponding light metering weight table of target metering mode surveys light to smooth picture to be measured.Both it is lesser extreme brightness region accounting had been shielded
Under scene, the extreme brightness value in brightness matrix is surveyed to the anomalous effects of photometry result, also ensures that extreme brightness region accounts for
The invariance that brightness matrix is surveyed under bigger scene obtains more realistic imaging to improve the accuracy for surveying light
The survey light brightness of demand guarantees shooting effect to realize subsequent reasonable exposure.
Embodiment two
The present embodiment on the basis of the above embodiment 1, to " will survey brightness matrix in each extreme brightness value tune
It is whole to normal brightness section, obtain adjustment luminance matrix " advanced optimized.Wherein or phase identical as the various embodiments described above
Details are not described herein for the explanation for the term answered.Referring to fig. 2, light measuring method provided in this embodiment includes:
S210, the corresponding survey brightness matrix of smooth picture to be measured is obtained.
S220, foundation survey brightness matrix and extreme brightness threshold value, determine that brightness value is located at extremely bright in smooth picture to be measured
Spend the region accounting in the extreme brightness region in section.
Illustratively, extreme brightness threshold value includes very dark luminance threshold and incandescent luminance threshold, and extreme brightness section includes
Very dark brightness section and incandescent brightness section;The left margin and right margin of very dark brightness section be respectively brightness value minimum value and
Very dark luminance threshold, the left margin and right margin in normal brightness section are respectively very dark luminance threshold and incandescent luminance threshold, pole
The left margin and right margin of bright brightness section are respectively incandescent luminance threshold and brightness value maximum value.
Specifically, in order to improve the scope of application of light measuring method in the embodiment of the present invention, light to be measured can be suitable for
There is the photographed scene of very dark region and/or extreme bright regions in picture, sets extreme brightness threshold value to comprising pole in the present embodiment
Dark luminance threshold and incandescent luminance threshold.At this point, extreme brightness section just includes very dark brightness section and incandescent brightness section, that
The entire value range for surveying brightness values is just divided into very dark brightness section, normal brightness section and incandescent brightness section.
Referring to Fig. 3, according to the sequence of brightness value from small to large, the division boundary parameter of each brightness section is corresponded respectively to
Brightness value minimum value 301, very dark luminance threshold 302, incandescent luminance threshold 303 and brightness value maximum value 304.So, pole
The left margin and right margin of dark brightness section 310 are respectively brightness value minimum value 301 and very dark luminance threshold 302, are just always on
The left margin and right margin for spending section 320 are respectively very dark luminance threshold 302 and incandescent luminance threshold 303, incandescent brightness section
330 left margin and right margin is respectively incandescent luminance threshold 303 and brightness value maximum value 304.
If S230, region accounting are less than default accounting threshold value, according to surveying the corresponding target brightness value of light picture, extremely bright
Threshold value and each extreme brightness value are spent, determines the corresponding adjustment brightness value of each extreme brightness value.
Wherein, target brightness value refers to that the brightness of smooth picture to be measured it is expected the brightness values being adjusted to, and is to survey light
The brightness values reached it is expected later with automatic exposure operation.
Illustratively, environment light when target brightness value is by survey light determines, and target brightness value is located at normal brightness section
It is interior.When it is implemented, can determine one according to the value relationship between the environment light measured when testing and expectation brightness values
Mapping relations between environment light and expectation brightness values, and the environment light that measures of according to practical application when and above-mentioned mapping relations
Determine target brightness value;Also environment light can be set and it is expected the look-up table between brightness values, according to different photographed scenes
The average value of lower environment light its corresponding expectation brightness values is arranged, and is determined according to actual photographed scene corresponding
Environment light further determines target brightness value according to above-mentioned look-up table.Referring to Fig. 3, target brightness value 305 is generally in normally
In brightness section 320.
Specifically, brightness values when being final desired shooting due to target brightness value, therefore the adjustment mesh of extreme brightness value
Mark is so that each extreme brightness value is close to target brightness value.Meanwhile the boundary value in normal brightness section is pole
Luminance threshold is held, therefore extreme brightness value is adjusted to normal brightness section, is adjusted extreme brightness value to extreme luminance threshold
Between value and target brightness value.
To sum up, each extreme brightness value can be adjusted according to target brightness value and extreme brightness threshold value.For example,
It can be according to numeric distribution ratio of the extreme brightness value where it in numerical intervals (extreme brightness section), in extreme brightness threshold
Determine a brightness value as extreme brightness value adjustment brightness value adjusted between value and target brightness value;It for another example, can be with
According to the data distribution between the data distribution in extreme brightness section and extreme brightness threshold value and target brightness value, setting one
Number value comparison table directly searches corresponding adjustment brightness value of each extreme brightness value etc. according to the numerical comparatives table.
S240, each extreme brightness value surveyed in brightness matrix is replaced with into adjustment brightness corresponding with extreme brightness
Value obtains adjustment luminance matrix.
Specifically, each corresponding pole in brightness matrix is surveyed with each adjustment brightness value substitution after brightness adjustment
Brightness value is held, adjustment luminance matrix can be obtained.
S250, foundation adjustment luminance matrix and the corresponding light metering weight table of target metering mode survey light to smooth picture to be measured.
The technical solution of the present embodiment, by according to surveying the corresponding target brightness value of light picture, extreme brightness threshold value and every
A extreme brightness value determines the corresponding adjustment brightness value of each extreme brightness value;It is each extremely bright in brightness matrix by surveying
Angle value replaces with adjustment brightness value corresponding with extreme brightness, obtains adjustment luminance matrix.So that surveying each in brightness matrix
The adjustment of extreme brightness value is more accurate, rather than is simply to set a fixed adjustment brightness value, not only guarantees to survey brightness
All brightness values both participate in flash spotter calculation in matrix, and make each extreme brightness value to be more nearly target brightness value
It adjusts brightness value and participates in flash spotter calculation, to further improve the accuracy for surveying light.
Embodiment three
The present embodiment is on the basis of above-described embodiment two, to " according to surveying the corresponding target brightness value of light picture, extremely bright
Threshold value and each extreme brightness value are spent, determines the corresponding adjustment brightness value of each extreme brightness value " it is advanced optimized.Its
In the explanation of term identical or corresponding with the various embodiments described above details are not described herein.Referring to fig. 4, survey light provided in this embodiment
Method includes:
S310, the corresponding survey brightness matrix of smooth picture to be measured is obtained.
S320, foundation survey brightness matrix and extreme brightness threshold value, determine that brightness value is located at extremely bright in smooth picture to be measured
Spend the region accounting in the extreme brightness region in section.
Illustratively, when brightness value minimum value is 0 and brightness value maximum value is 255, very dark luminance threshold is 30,
Incandescent luminance threshold is 220.In this way, can determine very dark brightness section be [0,30), normal brightness section be [30,220], with
And incandescent brightness section be (220,255].
If S330, region accounting are less than default accounting threshold value, and if extreme brightness value be located at very dark brightness section, foundation
Target brightness value, very dark luminance threshold, brightness value minimum value and each extreme brightness value determine that each extreme brightness value is corresponding
Adjustment brightness value.
Specifically, referring to Fig. 3, if extreme brightness value 306 is fallen in very dark brightness section 310, it is directed to any one
Extreme brightness value determines the first brightness adjustment according to the extreme brightness value, brightness value minimum value and very dark luminance threshold first
Ratio;Secondly corresponding according to target brightness value, very dark luminance threshold and the first brightness adjustment ratio-dependent extreme brightness value
Adjust brightness value.When it is implemented, determining the corresponding adjustment brightness value of extreme brightness value of brightness to be adjusted according to following formula:
Wherein, result_lum indicates that adjustment brightness value, target_lum indicate target brightness value;Low_thr indicates pole
Dark luminance threshold, cur_lum indicate the extreme brightness value of brightness to be adjusted, and min_lum indicates brightness value minimum value.Why
Not directly using minuend as adjustment brightness value, be because minuend institute value may possibly still be present deviate target brightness value compared with
Big situation, the relatively large deviation caused by still can not weakening extreme brightness value well in this way in flash spotter calculation, therefore this hair
The calculated result of brightness value in bright embodiment with target brightness value and after being scaled is adjustment brightness value.
If S340, region accounting are less than default accounting threshold value, and if extreme brightness value be located at incandescent brightness section, foundation
Target brightness value, incandescent luminance threshold, brightness value maximum value and each extreme brightness value determine that each extreme brightness value is corresponding
Adjustment brightness value.
Specifically, referring to Fig. 3, if extreme brightness value 306 ' is fallen in incandescent brightness section 330, it is directed to any one
Extreme brightness value determines the second brightness adjustment according to brightness value maximum value, the extreme brightness value and incandescent luminance threshold first
Ratio;Secondly corresponding according to target brightness value, incandescent luminance threshold and the second brightness adjustment ratio-dependent extreme brightness value
Adjust brightness value.When it is implemented, determining the corresponding adjustment brightness value of extreme brightness value of brightness to be adjusted according to following formula:
Wherein, hight_thr indicates that incandescent luminance threshold, max_lum indicate brightness value maximum value.
S350, each extreme brightness value surveyed in brightness matrix is replaced with into adjustment brightness corresponding with extreme brightness
Value obtains adjustment luminance matrix.
S360, foundation adjustment luminance matrix and the corresponding light metering weight table of target metering mode survey light to smooth picture to be measured.
For example, it is assumed that each weighted value is 1 in light metering weight table, and brightness value minimum value is 0, and brightness value is most
Big value is 255, and very dark luminance threshold is 30, and incandescent luminance threshold is 220, and presetting accounting threshold value is 30% and object brightness
Value is 60.
Referring to Fig. 5, there are 12*12 brightness values in the survey brightness matrix, and wherein brightness value 255 is greater than incandescent luminance threshold
Value 220, therefore there are incandescent luminance areas in the survey brightness matrix, and extreme brightness value 255 is entirely surveying brightness matrix
In region accounting are as follows: (12*3)/(12*12) * 100%=25% < 30%, and all extreme brightness values all fall within incandescent brightness
Region.
Initial photometric brightness so for being adjusted without brightness value are as follows: (255*12*3+50*12*9)/(12*12)
=101.25.
If need to first carry out extreme brightness value adjustment according to light measuring method provided by the embodiment of the present invention.So according to
Formula (2), adjustment brightness value result_lum=60+ (220-60) * (255- after each adjustment of extreme brightness value 255
255)/(255-220)=60.Later, the incandescent brightness value 255 in the substitution survey brightness matrix of brightness value 60 will be adjusted, obtained
Adjust luminance matrix.Finally, calculating target surveys light brightness: (60*12*3+50*12*9)/(12*12)=52.5.
Automatic exposure module (AE) is mainly to lead to according to light brightness is surveyed with the difference of target brightness value (target_lum)
Adjustment exposure value is crossed to come so that picture brightness reaches our target brightness value.By taking previous example as an example: the scene capture main body
Brightness is 50, and edge extreme brightness value is 255.Initial photometric brightness without brightness value adjustment is 101.25, therefore is
System can reduce picture brightness by reducing the light exposure of sensor sensor, so that final overall picture brightness can be reduced to
60, the brightness value 50 of shooting main part in this way can be down to lower brightness value, and the expectation with us is not inconsistent.By brightness value tune
It is 52.5 that whole target, which surveys light brightness, and the brightness value with shooting main body is closer to, and system will increase sensor exposure at this time
Amount, so that final overall picture brightness is increased to 60, can obtain to improve picture brightness and meet desired shooting picture.
The technical solution of the present embodiment, if being located at very dark brightness section by extreme brightness value, according to target brightness value,
Very dark luminance threshold, brightness value minimum value and each extreme brightness value determine the corresponding adjustment brightness of each extreme brightness value
Value;If extreme brightness value is located at incandescent brightness section, according to target brightness value, incandescent luminance threshold, brightness value maximum value
With each extreme brightness value, the corresponding adjustment brightness value of each extreme brightness value is determined.It is bright that more accurate adjustment can be obtained
Angle value further increases the accuracy for surveying light.
It is the embodiment of light measurer provided in an embodiment of the present invention, the survey light side of the device and the various embodiments described above below
It is owned by France in the same inventive concept, the detail content of not detailed description in the embodiment of light measurer can refer to above-mentioned survey
The embodiment of light method.
Example IV
The present embodiment provides a kind of light measurers, and referring to Fig. 6, which is specifically included:
It surveys brightness matrix and obtains module 610, for obtaining the corresponding survey brightness matrix of smooth picture to be measured;
Region accounting determining module 620, for determining smooth picture to be measured according to brightness matrix and extreme brightness threshold value is surveyed
Middle brightness value is located at the region accounting in the extreme brightness region in extreme brightness section, extreme brightness section by extreme brightness threshold value with
And brightness value corresponding with extreme brightness threshold value is most worth generation;
Luminance matrix determining module 630 is adjusted, if being less than default accounting threshold value for region accounting, brightness square will be surveyed
Each extreme brightness value in battle array is adjusted to normal brightness section, obtains adjustment luminance matrix, normal brightness section is by extremely bright
Degree threshold value or extreme brightness threshold value and brightness value are most worth generation;
Optical module 640 is surveyed, for foundation adjustment luminance matrix and the corresponding light metering weight table of target metering mode, to be measured
Light picture surveys light.
Optionally, region accounting determining module 620 is specifically used for:
According to extreme brightness threshold value, determines and survey the element number that brightness value in brightness matrix is located at extreme brightness section;
According to the element total number of element number and survey brightness matrix, determine that brightness value is located at extreme in smooth picture to be measured
The region accounting in the extreme brightness region of brightness section.
Optionally, adjustment luminance matrix determining module 630 includes:
Adjustment brightness value determines submodule, for according to survey the corresponding target brightness value of light picture, extreme brightness threshold value and
Each extreme brightness value determines the corresponding adjustment brightness value of each extreme brightness value.
Adjustment luminance matrix determines submodule, for replacing with and pole each extreme brightness value surveyed in brightness matrix
The corresponding adjustment brightness value of brightness is held, adjustment luminance matrix is obtained.
Wherein, environment light when target brightness value is by survey light determines, and target brightness value is located in normal brightness section.
Wherein, extreme brightness threshold value includes very dark luminance threshold and incandescent luminance threshold, and extreme brightness section includes very dark
Brightness section and incandescent brightness section;
The left margin and right margin of very dark brightness section are respectively brightness value minimum value and very dark luminance threshold, are just always on
The left margin and right margin for spending section are respectively very dark luminance threshold and incandescent luminance threshold, the left margin of incandescent brightness section and
Right margin is respectively incandescent luminance threshold and brightness value maximum value.
Further, adjustment brightness value determines that submodule is specifically used for:
If extreme brightness value is located at very dark brightness section, most according to target brightness value, very dark luminance threshold, brightness value
Small value and each extreme brightness value, determine the corresponding adjustment brightness value of each extreme brightness value;
If extreme brightness value is located at incandescent brightness section, most according to target brightness value, incandescent luminance threshold, brightness value
Big value and each extreme brightness value, determine the corresponding adjustment brightness value of each extreme brightness value.
Optionally, when brightness value minimum value is 0 and brightness value maximum value is 255, very dark luminance threshold is 30, pole
Bright luminance threshold is 220.
Four a kind of light measurer through the embodiment of the present invention improves the accuracy for surveying light, more suits reality to obtain
Border images the survey light brightness of demand, to realize subsequent reasonable exposure, guarantees shooting effect.
Light measuring method provided by any embodiment of the invention can be performed in light measurer provided by the embodiment of the present invention, tool
The standby corresponding functional module of execution method and beneficial effect.
Light measurer provided by the embodiment of the present invention can integrate in image-signal processor ISP, be schemed by changing
Reach hard-wired purpose as the related circuit design in signal processor ISP.
It is worth noting that, included each unit and module are only according to function in the embodiment of above-mentioned light measurer
Energy logic is divided, but is not limited to the above division, as long as corresponding functions can be realized;In addition, each function
The specific name of energy unit is also only for convenience of distinguishing each other, the protection scope being not intended to restrict the invention.
Embodiment five
Referring to Fig. 7, a kind of capture apparatus is present embodiments provided comprising: one or more processors 720;Storage dress
710 are set, for storing one or more programs;Camera 760, for acquiring smooth picture to be measured;When one or more program quilts
One or more processors 720 execute, so that one or more processors 720, which are realized, surveys light side provided by the embodiment of the present invention
Method, comprising:
Obtain the corresponding survey brightness matrix of smooth picture to be measured;
According to brightness matrix and extreme brightness threshold value is surveyed, determine that brightness value is located at extreme brightness section in smooth picture to be measured
Extreme brightness region region accounting, extreme brightness section is by extreme brightness threshold value and corresponding with extreme brightness threshold value bright
Degree value is most worth generation;
If region accounting is less than default accounting threshold value, each extreme brightness value surveyed in brightness matrix is adjusted to just
Normal brightness section obtains adjustment luminance matrix, and normal brightness section is taken by extreme brightness threshold value or extreme brightness threshold value and brightness
Value most value generates;
According to adjustment luminance matrix and the corresponding light metering weight table of target metering mode, light is surveyed to smooth picture to be measured.
Certainly, it will be understood by those skilled in the art that processor 720 can also realize that any embodiment of that present invention is provided
Light measuring method technical solution.
The capture apparatus that Fig. 7 is shown is only an example, should not function and use scope band to the embodiment of the present invention
Carry out any restrictions.As shown in fig. 7, the capture apparatus includes processor 720, storage device 710, camera 760, input unit
730 and output device 740;The quantity of processor 720 can be one or more in capture apparatus, with a processor in Fig. 7
For 720;Processor 720, storage device 710, camera 760, input unit 730 and output device 740 in capture apparatus
It can be connected by bus or other modes, in Fig. 7 for being connected by bus 750.
Storage device 710 is used as a kind of computer readable storage medium, and it is executable to can be used for storing software program, computer
Program and module, if the corresponding program instruction/module of the light measuring method in the embodiment of the present invention is (for example, in light measurer
It surveys brightness matrix to obtain module, region accounting determining module, adjustment luminance matrix determining module and survey optical module).
Storage device 710 can mainly include storing program area and storage data area, wherein storing program area can store operation
Application program needed for system, at least one function;Storage data area, which can be stored, uses created data etc. according to terminal.
In addition, storage device 710 may include high-speed random access memory, it can also include nonvolatile memory, for example, at least
One disk memory, flush memory device or other non-volatile solid state memory parts.In some instances, storage device 710
It can further comprise the memory remotely located relative to processor 720, these remote memories can be by being connected to the network extremely
Capture apparatus.The example of above-mentioned network includes but is not limited to internet, intranet, local area network, mobile radio communication and its group
It closes.
Input unit 730 can be used for receiving the number or character information of input, and generates and set with the user of capture apparatus
It sets and the related key signals of function control inputs.Output device 740 may include that display screen etc. shows equipment.
Embodiment six
The present embodiment provides a kind of storage mediums comprising computer executable instructions, and computer executable instructions are by counting
For executing a kind of light measuring method when calculation machine processor executes, this method comprises:
Obtain the corresponding survey brightness matrix of smooth picture to be measured;
According to brightness matrix and extreme brightness threshold value is surveyed, determine that brightness value is located at extreme brightness section in smooth picture to be measured
Extreme brightness region region accounting, extreme brightness section is by extreme brightness threshold value and corresponding with extreme brightness threshold value bright
Degree value is most worth generation;
If region accounting is less than default accounting threshold value, each extreme brightness value surveyed in brightness matrix is adjusted to just
Normal brightness section obtains adjustment luminance matrix, and normal brightness section is taken by extreme brightness threshold value or extreme brightness threshold value and brightness
Value most value generates;
According to adjustment luminance matrix and the corresponding light metering weight table of target metering mode, light is surveyed to smooth picture to be measured.
Certainly, a kind of storage medium comprising computer executable instructions, computer provided by the embodiment of the present invention
Executable instruction is not limited to method operation as above, can also be performed in light measuring method provided by any embodiment of the invention
Relevant operation.
By the description above with respect to embodiment, it is apparent to those skilled in the art that, the present invention
It can be realized by software and required common hardware, naturally it is also possible to which by hardware realization, but in many cases, the former is more
Good embodiment.Based on this understanding, technical solution of the present invention substantially in other words contributes to the prior art
Part can be embodied in the form of software products, which can store in computer readable storage medium
In, floppy disk, read-only memory (Read-Only Memory, ROM), random access memory (Random such as computer
Access Memory, RAM), flash memory (FLASH), hard disk or CD etc., including some instructions use so that a capture apparatus
Execute light measuring method provided by each embodiment of the present invention.
Note that the above is only a better embodiment of the present invention and the applied technical principle.It will be appreciated by those skilled in the art that
The invention is not limited to the specific embodiments described herein, be able to carry out for a person skilled in the art it is various it is apparent variation,
It readjusts and substitutes without departing from protection scope of the present invention.Therefore, although being carried out by above embodiments to the present invention
It is described in further detail, but the present invention is not limited to the above embodiments only, without departing from the inventive concept, also
It may include more other equivalent embodiments, and the scope of the invention is determined by the scope of the appended claims.