Image shooting method and device and camera shooting equipment

The initial exposure parameters and ISP parameters are determined through the status of the filter switching device and the infrared fill light, and the target parameters are adjusted based on the ambient light information of the first image, which solves the problem of inaccurate exposure parameters in the existing technology and improves the image quality. and device drawing speed.

CN118632129APending Publication Date: 2024-09-10TP-LINK
View PDF 0 Cites 2 Cited by

Patent Information

Application Number
CN202410718167.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-06-04
Publication Date
2024-09-10

AI Technical Summary

Technical Problem

In the existing technology, the ambient light information cannot be accurately determined based on the RGB information of the image, resulting in inaccurate exposure parameters and affecting image quality and device image output speed.

Method used

The initial exposure parameters and ISP parameters are determined through the status of the filter switching device and the infrared fill light, and the first image is captured to obtain more accurate ambient light information, and then the target exposure parameters and ISP parameters are adjusted.

Benefits of technology

It improves the accuracy of exposure parameters and ISP parameters, shortens the time to adjust exposure parameters and ISP parameters, and improves image quality and device rendering speed.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118632129A
    Figure CN118632129A
Patent Text Reader

Abstract

The invention provides an image shooting method and device and camera shooting equipment. The image shooting method comprises the following steps: determining an initial exposure parameter and an initial ISP parameter according to the state of an optical filter switching device and the state of an infrared light supplement lamp; shooting a first image according to the initial exposure parameter and the initial ISP parameter; determining first ambient light information according to the first image; determining a target exposure parameter and a target ISP parameter according to the first ambient light information; and shooting a target image according to the target exposure parameter and the target ISP parameter. The first ambient light information is determined according to the first image and reflects information of more dimensions of the ambient light, so that the matching degree of the target exposure parameter and the target ISP parameter with the current environment is improved. The initial exposure parameter and the initial ISP parameter are determined according to the state of the optical filter switching device and the state of the infrared light supplement lamp, so that the convergence speed can be improved when the exposure parameter and the ISP parameter are adjusted, the target exposure parameter and the target ISP parameter are rapidly determined, and the image output speed is further improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of image processing, and in particular to image capturing methods, devices and camera equipment. Background Art

[0002] In some image capture scenarios (such as video door locks), high requirements are placed on the quality of the captured images. In the prior art, an image can be captured first, and the exposure parameters can be determined based on the RGB information of the image. However, accurate ambient light information cannot be obtained based on the RGB information of the image, which results in inaccurate exposure parameters, resulting in incorrect exposure parameters or underexposure of the captured image. If the exposure parameters are further adjusted, the optimal value of the exposure parameters may converge slowly due to an incorrect selection of the initial value of the exposure parameters, thereby affecting the image output speed of the device. Summary of the invention

[0003] In view of this, the embodiments of the present application provide an image capturing method, an apparatus, and a camera device, which can obtain accurate exposure parameters and ISP parameters while improving the image output speed.

[0004] A first aspect of an embodiment of the present application provides an image capturing method, comprising:

[0005] Determine the initial exposure parameter and the initial ISP parameter according to the state of the filter switching device and the state of the infrared fill light;

[0006] Capturing a first image according to the initial exposure parameters and the initial ISP parameters;

[0007] determining first ambient light information according to the first image;

[0008] Determine a target exposure parameter and a target ISP parameter according to the first ambient light information;

[0009] A target image is captured according to the target exposure parameters and the target ISP parameters.

[0010] In one embodiment, determining the initial exposure parameter and the initial ISP parameter according to the state of the filter switching device and the state of the infrared fill light includes:

[0011] Determine an initial exposure parameter according to the state of the filter switching device, the state of the infrared fill light, and a first exposure parameter mapping relationship, wherein the first exposure parameter mapping relationship represents a correspondence between the state of the filter switching device, the state of the infrared fill light, and the exposure parameter;

[0012] The initial ISP parameters are determined according to the state of the filter switching device, the state of the infrared fill light and the first ISP parameter mapping relationship, wherein the first ISP parameter mapping relationship represents the correspondence between the state of the filter switching device, the state of the infrared fill light and the ISP parameters.

[0013] In one embodiment, the method further comprises:

[0014] The state of the filter switching device and the state of the infrared fill light are determined according to initial ambient light information, and the initial ambient light information is detected by a sensor.

[0015] In one embodiment, determining the initial exposure parameter and the initial ISP parameter according to the state of the filter switching device and the state of the infrared fill light includes:

[0016] Upon receiving a power-on instruction of the first chip, the state of the filter switching device, and the state of the infrared fill light, initial exposure parameters and initial ISP parameters are determined according to the state of the filter switching device and the state of the infrared fill light; the first chip is used to switch from a low power consumption state to a normal working state when an image shooting instruction is detected, and to start the sensor to obtain the initial ambient light information sent by the sensor, and to indicate the filter switching device and the switching state of the infrared fill light according to the initial ambient light information.

[0017] In one embodiment, the first ambient light information includes ambient light brightness and ambient light color temperature; and determining a target exposure parameter and a target ISP parameter according to the first ambient light information includes:

[0018] Determining the target exposure parameter according to the ambient light brightness and a second exposure parameter mapping relationship, wherein the second exposure parameter mapping relationship represents a corresponding relationship between the ambient light brightness and the exposure parameter;

[0019] The target ISP parameters are determined according to the ambient light color temperature and a second ISP parameter mapping relationship, wherein the second ISP parameter mapping relationship represents a corresponding relationship between the ambient light color temperature and the ISP parameters.

[0020] In one embodiment, determining first ambient light information according to the first image includes:

[0021] The ambient light brightness is determined according to the brightness of the first image and an exposure value when the first image is captured.

[0022] In one embodiment, determining first ambient light information according to the first image includes:

[0023] According to the RGB values ​​of the first pixels in the first image, projecting the first pixels into a plurality of white areas, wherein each white area corresponds to a color temperature;

[0024] The color temperature of the ambient light is determined according to the number of first pixel points corresponding to each white area in the plurality of white areas.

[0025] In one embodiment, determining the target exposure parameter according to the ambient light brightness and the second exposure parameter mapping relationship includes:

[0026] A first exposure parameter is determined according to the ambient light brightness and the second exposure parameter mapping relationship, and exposure compensation is performed on the first exposure parameter according to a preset expected value to obtain the target exposure parameter.

[0027] A second aspect of an embodiment of the present application provides an image capturing device, including:

[0028] A first determination module, used to determine initial exposure parameters and initial ISP parameters according to the state of the filter switching device and the state of the infrared fill light;

[0029] A first shooting module, configured to shoot a first image according to the initial exposure parameters and the initial ISP parameters;

[0030] A second determining module, configured to determine first ambient light information according to the first image;

[0031] A third determination module, configured to determine a target exposure parameter and a target ISP parameter according to the first ambient light information;

[0032] The second shooting module is used to shoot a target image according to the target exposure parameter and the target ISP parameter.

[0033] A third aspect of an embodiment of the present application provides a camera device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, the image capture method as described in the first aspect above is implemented.

[0034] A fourth aspect of an embodiment of the present application provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the image capturing method as described in the first aspect above is implemented.

[0035] A fifth aspect of the embodiments of the present application provides a computer program product. When the computer program product is run on a camera device, the camera device executes the image capturing method described in any one of the first aspects.

[0036] Compared with the prior art, the embodiments of the present application have the following beneficial effects: the initial exposure parameters and initial ISP parameters are first determined according to the state of the filter switching device and the state of the infrared fill light, so that the approximate range of the exposure parameters and ISP parameters can be determined. Afterwards, the first image is captured according to the initial exposure parameters and initial ISP parameters, the first ambient light information is determined according to the first image, and the target exposure parameters and target ISP parameters are determined according to the first ambient light information. Since the first ambient light information is determined according to the first image, it can reflect more dimensional information of the ambient light, improve the matching degree of the obtained target exposure parameters and target ISP parameters with the current environment, and thus improve the quality of the obtained target image. At the same time, since the initial exposure parameters and initial ISP parameters are determined according to the state of the filter switching device and the state of the infrared fill light, they have a high accuracy. On this basis, the exposure parameters and ISP parameters are further adjusted, which can improve the convergence speed when adjusting the exposure parameters and ISP parameters, quickly determine the target exposure parameters and target ISP parameters, and thus improve the image output speed. BRIEF DESCRIPTION OF THE DRAWINGS

[0037] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the embodiments or the description of the prior art are briefly introduced below.

[0038] Figure 1 It is a schematic diagram of the implementation process of the image capturing method provided by an embodiment of the present application;

[0039] Figure 2 is a schematic diagram of a camera device provided by an embodiment of the present application;

[0040] Figure 3 This is a schematic diagram of white area distribution provided by an embodiment of the present application;

[0041] Figure 4 is a schematic diagram of a first pixel point projected onto a white area provided by an embodiment of the present application;

[0042] Figure 5 is a flow chart of a photographing method provided by an embodiment of the present application;

[0043] Figure 6 is a schematic diagram of an image capturing device provided by an embodiment of the present application;

[0044] Figure 7 It is a schematic diagram of the structure of the camera device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0045] In the following description, specific details such as specific system structures, technologies, etc. are provided for the purpose of illustration rather than limitation, so as to provide a thorough understanding of the embodiments of the present application. However, it should be clear to those skilled in the art that the present application may also be implemented in other embodiments without these specific details. In other cases, detailed descriptions of well-known systems, devices, circuits, and methods are omitted to prevent unnecessary details from obstructing the description of the present application.

[0046] It should be understood that when used in this specification and the appended claims, the term "comprising" indicates the presence of described features, integers, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, integers, steps, operations, elements, components and / or groups thereof.

[0047] It should also be understood that the terms used in this application specification are only for the purpose of describing specific embodiments and are not intended to limit the application. As used in this application specification and the appended claims, unless the context clearly indicates otherwise, the singular forms "a", "an" and "the" are intended to include plural forms.

[0048] It should be further understood that the term “and / or” used in the specification and appended claims refers to any combination and all possible combinations of one or more of the associated listed items, and includes these combinations.

[0049] As used in this specification and the appended claims, the term "if" may be interpreted as "when" or "upon" or "in response to determining" or "in response to detecting," depending on the context. Similarly, the phrases "if it is determined" or "if [described condition or event] is detected" may be interpreted as meaning "upon determination" or "in response to determining" or "upon detection of [described condition or event]" or "in response to detecting [described condition or event]," depending on the context.

[0050] In addition, in the description of the present application, the terms "first", "second", etc. are only used to distinguish the description and cannot be understood as indicating or implying relative importance.

[0051] The imaging principle of a camera (such as a camera, etc.) is as follows: after light passes through the lens and enters the camera, it is focused on the photosensitive element by the lens, and the photosensitive element converts the light signal into an electrical signal. The electrical signal is converted into a digital signal after passing through the digital-to-analog conversion circuit. After that, the image processor processes the digital signal, stores the processed digital signal, and obtains an image file.

[0052] The photosensitive element may be a charge-coupled device (CCD) or a complementary metal oxide semiconductor (CMOS).

[0053] In different scenes, the light intensity varies greatly. The human eye can adjust the light sensitivity by adjusting the size of the pupil, so that it can sense the appropriate brightness. However, the photosensitive element does not have the ability to adjust adaptively, so it needs to have the ability of automatic exposure. Automatic exposure means that the photosensitive element adjusts the exposure parameters such as lens aperture, exposure time, gain, etc. according to the ambient light information.

[0054] The image processor processes the digital signal corresponding to the image file, which means that the image processor adjusts the image's white balance, noise reduction filter parameters, gamma correction and other ISP parameters according to the ambient light information.

[0055] Among them, the white balance of the image is closely related to the color temperature of the ambient light. Specifically, since the human visual system has the characteristic of color constancy, it will not be affected by the color of the light source. In real life, whether it is sunny, cloudy, indoor incandescent lamps, or LED lamps, the white objects we see are always white. This is the result of visual correction by the human visual system. That is, the human brain has a certain prior knowledge of the color of objects, can recognize objects and correct this color difference. However, the photosensitive element does not have the characteristic of color constancy, and the color of the image obtained is easily affected by the ambient light. For example, under incandescent lighting, the photo will be yellowish, under outdoor sunny conditions, the photo will be blue, and under candlelight, the color will be reddish. Therefore, it is necessary to adjust the white balance of the image to more accurately restore the true color of the subject.

[0056] In order to obtain high-quality images, the camera equipment needs more accurate exposure parameters and ISP parameters, and then needs to obtain accurate and comprehensive ambient light information. At the same time, in some image capture scenarios, in order to improve the response speed of the system, it is necessary to capture images quickly.

[0057] To this end, the present application provides an image capture method, which first determines the initial exposure parameters and initial ISP parameters according to the state of the filter switching device and the state of the infrared fill light, so that the approximate range of the exposure parameters and ISP parameters can be determined. Afterwards, the first image is captured according to the initial exposure parameters and the initial ISP parameters, the first ambient light information is determined according to the first image, and the target exposure parameters and target ISP parameters are determined according to the first ambient light information. Since the first ambient light information is determined according to the first image, it can reflect more dimensional information of the ambient light, improve the accuracy of the obtained target exposure parameters and target ISP parameters, and thus improve the image quality. At the same time, since the initial exposure parameters and the initial ISP parameters are determined according to the state of the filter switching device and the state of the infrared fill light, the accuracy is relatively high. On this basis, the target exposure parameters and target ISP parameters are obtained, which can improve the convergence speed when adjusting the exposure parameters and ISP parameters, quickly determine the target exposure parameters and target ISP parameters, and thus improve the image output speed.

[0058] The image capturing method provided by the present application is described in detail below.

[0059] The image capturing method provided in the embodiment of the present application is executed on a camera device, which can be applied to a video door lock system, a monitoring system, and the like.

[0060] Please see attached Figure 1 , an image capturing method provided by an embodiment of the present application includes:

[0061] S101: Determine initial exposure parameters and initial ISP parameters according to the state of the filter switching device and the state of the infrared fill light.

[0062] In one embodiment, if Figure 2 As shown, the camera device includes a sensor 21, a first chip 22, a second chip 23, a camera 24, a filter switching device 25 and an infrared fill light 26. The image capture method provided in the embodiment of the present application is executed on the second chip 23. When the camera device is in a dormant state, the first chip 22 is in a low power consumption mode, and the second chip 23 is in a power-off dormant state. When the first chip 22 detects an image capture instruction (for example, a human activity, a face recognition instruction or an unlocking instruction), it switches from a low power consumption state to a normal working state, and obtains the states of the filter switching device 25 and the infrared fill light 26, and sends the states of the filter switching device and the infrared fill light to the second chip, and the second chip determines the initial exposure parameters and the initial ISP parameters according to the states of the filter switching device and the infrared fill light.

[0063] The sensor 21 is used to obtain initial ambient light information. In one embodiment, after the first chip 22 switches from a low power consumption state to a normal working state, the sensor 21 is started to obtain the initial ambient light information sent by the sensor 21, and the filter switching device and the switching state of the infrared fill light are indicated according to the initial ambient light information. Afterwards, the first chip 22 sends a power-on instruction, the state of the filter switching device, and the switching state of the infrared fill light to the second chip 23. When the second chip 23 receives the power-on instruction, the state of the filter switching device, and the switching state of the infrared fill light from the first chip, it starts the camera 24, and determines the initial exposure parameters and the initial ISP parameters according to the state of the filter switching device and the switching state of the infrared fill light. By setting the two chips, the power consumption of the camera device can be reduced while the camera device is started quickly, thereby increasing the service life of the camera. At the same time, using only one sensor to collect the initial ambient light information can reduce the hardware cost and power consumption of the camera device.

[0064] The filter switching device 25 includes a plurality of filters, and the first chip 21 is used to switch the filter of the filter switching device 25 to a filter corresponding to the initial ambient light information. For example, the filter switching device 25 includes a white filter and a red filter. If it is determined that it is daytime according to the ambient light intensity, the filter switching device 25 is instructed to switch the filter to a red filter. If it is determined that it is nighttime according to the ambient light intensity, the filter switching device 25 is instructed to switch the filter to a white filter.

[0065] The first chip is used to determine whether to turn on the infrared fill light 26 according to the initial ambient light information. For example, when the camera device determines that it is night time according to the ambient light intensity, it turns on the infrared fill light so that the user will not feel glare and the intensity of the reflected light of the photographed object can be increased, thereby improving the brightness of the picture.

[0066] The wavelength range of light that the human eye can recognize is between 320nm-760nm. The human eye cannot see light exceeding 320nm-760nm. However, the photosensitive element can sense light of most wavelengths. Due to the involvement of multiple wavelengths of light, there is a certain deviation between the color of the image restored by the camera equipment and the color seen by the human eye. Therefore, switching to a red filter during the day and turning off the infrared fill light can restore the true color; switching to a white filter at night and turning on the infrared fill light can increase the amount of light entering and improve the clarity of the picture.

[0067] In one embodiment, the sensor 21 is an analog-to-digital converter (ADC) photosensitive sensor for detecting the ambient light intensity. Correspondingly, the initial ambient light information includes the ambient light intensity, and the first chip is used to indicate the filter switching device and the infrared fill light switching state according to the ambient light intensity.

[0068] In another embodiment, the sensor may also include a photosensitive sensor and a color temperature sensor, which are respectively used to detect the ambient light intensity and the ambient light color temperature. Correspondingly, the initial ambient light information includes the ambient light intensity and the ambient light color temperature, and the first chip is used to indicate the filter switching device and the infrared fill light switching state according to the ambient light intensity and the ambient light color temperature.

[0069] In one embodiment, a first exposure parameter mapping relationship and a first ISP parameter mapping relationship are pre-stored in the camera device. The first exposure parameter mapping relationship represents the correspondence between the state of the filter switching device, the state of the infrared fill light and the exposure parameters, and the first ISP parameter mapping relationship represents the correspondence between the state of the filter switching device, the state of the infrared fill light and the ISP parameters. After obtaining the state of the filter switching device and the state of the infrared fill light, the camera device determines the initial exposure parameters according to the state of the filter switching device, the state of the infrared fill light and the first exposure parameter mapping relationship, and determines the initial ISP parameters according to the state of the filter switching device, the state of the infrared fill light and the first ISP parameter mapping relationship. Among them, the initial exposure parameters include the initial values ​​of parameters such as lens aperture, exposure time, and exposure gain, and the initial ISP parameters include the initial values ​​of parameters such as image white balance, noise reduction filter parameters, and gamma correction.

[0070] In one embodiment, the first exposure parameter mapping relationship includes multiple groups of exposure parameters, and the state of the filter switching device and / or the state of the infrared fill light corresponding to each group of exposure parameters are different. For example, the states of the filter switching device and the states of the infrared fill light corresponding to the multiple groups of exposure parameters are: white filter, turn on the infrared fill light, red filter, turn on the infrared fill light, white filter, turn off the infrared fill light, red filter, turn off the infrared fill light. The first chip determines the corresponding exposure parameter according to the state of the filter switching device and the state of the infrared fill light, and the exposure parameter is the initial exposure parameter.

[0071] The first ISP parameter mapping relationship includes multiple groups of ISP parameters, and each group of ISP parameters corresponds to a different state of the filter switching device and / or a different state of the infrared fill light. For example, the states of the filter switching device and the infrared fill light corresponding to the multiple groups of ISP parameters are: white filter, turn on the infrared fill light, red filter, turn on the infrared fill light, white filter, turn off the infrared fill light, red filter, turn off the infrared fill light. The first chip determines the corresponding ISP parameters according to the state of the filter switching device and the state of the infrared fill light, and the ISP parameters are the initial ISP parameters.

[0072] S102: Capture a first image according to the initial exposure parameters and the initial ISP parameters.

[0073] Specifically, the camera device uses the initial exposure parameters to perform exposure, obtains a digital signal corresponding to the image file, and then uses the initial ISP parameters to process the digital signal to obtain a first image. The first image may be one image, or may include multiple first sub-images.

[0074] S103: Determine first ambient light information according to the first image.

[0075] Specifically, since the initial exposure parameters and the initial ISP parameters are determined according to the initial ambient light information detected by the sensor, they cannot fully adapt to the actual ambient light of the current scene. By analyzing the brightness of the first image and the color of each pixel, the first ambient light information when the first image is taken is obtained, and the first ambient light information can more accurately reflect the ambient light information of the current shooting scene.

[0076] In one embodiment, the first ambient light information includes ambient light brightness and ambient light color temperature. After obtaining the first image, the camera device determines the ambient light brightness and the ambient light color temperature according to the first image.

[0077] Specifically, the camera device converts the first image into a YUV format to obtain the Y value of each pixel of the first image. The YUV format is a color encoding method that uses three components, Y, U, and V, to represent color. Y represents brightness, that is, grayscale value, and U and V represent chromaticity. Afterwards, the camera device can average the Y values ​​of each pixel to obtain the brightness of the first image, or weighted average the Y values ​​of each pixel to obtain the brightness of the first image.

[0078] For any image, the brightness of the image = the brightness of the ambient light * the exposure value. Therefore, the camera device can obtain the brightness of the ambient light according to the brightness of the first image and the exposure value when the first image is taken. Among them, the exposure value can be determined according to the exposure parameters (i.e., the initial exposure parameters) when the first image is taken, or the light metering module of the camera device can be called to calculate the exposure value. Exemplarily, the light metering module can calculate the exposure value by means of center-weighted average light metering, center-part light metering, spot light metering, etc.

[0079] In one embodiment, if the first image includes multiple first sub-images, the camera device can calculate the corresponding sub-ambient light brightness according to the brightness of each first sub-image, and then average the multiple sub-ambient light brightnesses to obtain the final ambient light brightness.

[0080] Photograph the whiteboard under light sources of different color temperatures in advance to obtain reference images corresponding to different color temperatures. For any reference image, that is, the first reference image, the first color temperature is corresponding. Calculate the RGB value of each pixel of the first reference image. The RGB value represents the color value of the three color channels of red, green, and blue. Afterwards, determine the white area in the first reference image based on the RGB value of each pixel, and then determine the R / G and B / G of each pixel in the white area based on the RGB value of the pixel in the white area. According to the R / G and B / G of each pixel in the white area, determine the position of the white area in the R / G-B / G coordinate system, and the position of the white area is the white area of ​​the first reference image, and the white area of ​​the first reference image is the white area corresponding to the first color temperature.

[0081] For all reference images, the above method is used to draw the corresponding white area on the R / G-B / G coordinate system, and then multiple white areas corresponding to multiple color temperatures can be obtained. Figure 3 As shown, in the R / G-B / G coordinate system, the horizontal axis represents R / G, the vertical axis represents B / G, and the 10 white areas drawn are white area 0, white area 1, white area 2, white area 3, white area 4, white area 5, white area 6, white area 7, white area 8 and white area 9, and each white area corresponds to a color temperature.

[0082] After acquiring the first image, the camera device calculates the RGB values ​​of multiple first pixels in the first image. The first pixels may be all pixels of the first image or some pixels of the first image. For example, the first image is divided into N (e.g., 128*90) regions, and the regions of the odd columns are removed. For any pixel in the even columns, if any of the RGB values ​​is not within the range of 4 to 224, the pixel is removed. The remaining pixels are taken as the first pixels.

[0083] For each first pixel, R / G and B / G are calculated according to the RGB value. Based on the R / G and B / G of each first pixel, multiple first pixel points are projected into multiple white areas. That is, for any first pixel, the position of the first pixel in the R / G-B / G coordinate system is determined according to R / G and B / G, and then the white area where the first pixel is located is determined according to the position of each white area. For multiple first pixel points, the above method is used to determine the white area where each pixel is located. Afterwards, the number of first pixel points corresponding to each white area in the multiple white areas is counted, and the color temperature of the ambient light is determined according to the number of first pixel points corresponding to each white area. In one embodiment, the color temperature corresponding to the white area with the largest number of first pixel points is used as the color temperature of the ambient light.

[0084] For example, Figure 4 As shown, multiple first pixel points are projected into 10 white areas. The 10 white areas are white areas with serial numbers 0 to 9, and the color temperatures corresponding to the white areas with serial numbers 0 to 9 are 20000K, 15000K, 10000K, 5000K, 4000K, 3000K, 2300K, 2000K, and 1700K, respectively. Among the white areas, the number of first pixel points corresponding to the white area with serial number 4 is 4399, and the number of first pixel points is the largest, so the color temperature 5000K corresponding to the white area with serial number 4 is used as the ambient light color temperature.

[0085] In one embodiment, if the first image includes multiple first sub-images, the camera device can determine the corresponding sub-ambient light color temperature according to each first sub-image, and then average the multiple sub-ambient light color temperatures to obtain the final ambient light color temperature.

[0086] S104: Determine a target exposure parameter and a target ISP parameter according to the first ambient light information.

[0087] Among them, the target exposure parameters include the target values ​​of parameters such as lens aperture, exposure time, and exposure gain; the target ISP parameters include the target values ​​of parameters such as image white balance, noise reduction filter parameters, and gamma correction.

[0088] In one embodiment, the first ambient light information includes ambient light brightness and ambient light color temperature. The camera device pre-stores a second exposure parameter mapping relationship and a second ISP parameter mapping relationship, the second exposure parameter mapping relationship represents the correspondence between ambient light brightness and exposure parameters, and the second ISP parameter mapping relationship represents the correspondence between ambient light color temperature and ISP parameters. For example, the second exposure parameter mapping relationship includes multiple ambient light brightness ranges, each ambient light brightness range corresponds to a set of exposure parameters, and the second ISP parameter mapping relationship includes multiple ambient light color temperature ranges, each ambient light color temperature range corresponds to a set of ISP parameters.

[0089] After determining the ambient light brightness and the ambient light color temperature, the camera device determines the range of the ambient light brightness and the range of the ambient light color temperature. After that, the exposure parameter corresponding to the ambient light brightness range in the second exposure parameter mapping relationship is determined as the target exposure parameter, and the ISP parameter corresponding to the ambient light color temperature range in the second ISP parameter mapping relationship is determined as the target ISP parameter. By presetting the second exposure parameter mapping relationship and the second ISP parameter mapping relationship, the target exposure parameter and the target ISP parameter can be quickly determined according to the first ambient light information.

[0090] In one embodiment, the camera device uses the exposure parameter determined according to the ambient light brightness and the second exposure parameter mapping relationship as the first exposure parameter, and then performs exposure compensation on the first exposure parameter according to a preset expected value to obtain a target exposure parameter. The expected value is the average value of the Y values ​​of each pixel of the image, that is, the brightness value of the image.

[0091] In one embodiment, after obtaining the first exposure parameter, the camera device uses the first exposure parameter to shoot a second image, adjusts the first exposure parameter so that the average value of the Y value of each pixel in the second image is the expected value, and the adjusted first exposure parameter is the target exposure parameter. In another embodiment, the second image includes multiple second sub-images, and after obtaining the first exposure parameter, the camera device uses the first exposure parameter to shoot the second sub-image 1, adjusts the first exposure parameter according to the difference between the average value of the Y value of the second sub-image 1 and the expected value, shoots the second sub-image 2 with the adjusted first exposure parameter, and continues to adjust the first exposure parameter according to the difference between the average value of the Y value of the second sub-image 2 and the expected value, and so on, after adjusting the first exposure parameter multiple times, the target exposure parameter is obtained.

[0092] In another embodiment, the camera device may also determine the target exposure parameter according to the ambient light brightness and the ambient light color temperature, and determine the target ISP parameter according to the ambient light brightness and the ambient light color temperature.

[0093] S105: Capture a target image according to the target exposure parameters and the target ISP parameters.

[0094] Specifically, the camera device uses the target exposure parameters to perform exposure to obtain a digital signal corresponding to the image file, and then uses the target ISP parameters to process the digital signal to obtain the target image.

[0095] In one embodiment, the camera device uses the target ISP parameters to process the digital signal to obtain a first image, and then determines the gains Rgain and Bgain of the first image based on the RGB values ​​of the pixels in the multiple first images and a preset weighting algorithm, and then corrects the RGB values ​​of the pixels in the first image based on the gains of the first image to perform white balance correction on the first image to obtain the target image.

[0096] In one embodiment, after obtaining the target image, the camera device outputs the target image, for example, by displaying the target image on a display interface of the camera device.

[0097] In the above embodiment, the initial exposure parameters and the initial ISP parameters are determined according to the state of the filter switching device and the state of the infrared fill light, the first image is captured according to the initial exposure parameters and the initial ISP parameters, the first ambient light information is determined according to the first image, and the target exposure parameters and the target ISP parameters are determined according to the first ambient light information, so that the exposure parameters and the ISP parameters that better match the actual shooting scene can be obtained. Since the target exposure parameters and the target ISP parameters are further adjusted on the basis of the initial exposure parameters and the initial ISP parameters, the speed of determining the target exposure parameters and the target ISP parameters can be increased, thereby accelerating the efficiency of image output.

[0098] The process of the shooting method provided in an embodiment of the present application is as follows: Figure 5 As shown. The first chip receives the ambient light intensity detected by the sensor, and determines whether the current scene is daytime or nighttime according to the ambient light intensity. If the current scene is daytime, the first chip instructs the filter switching device to switch to a red filter. If the current scene is nighttime, the first chip instructs the filter switching device to switch to a white filter, and turns on the infrared fill light. Afterwards, the first chip sends the state of the filter switching device and the state of the infrared fill light to the second chip, and the second chip determines the initial exposure parameters and the initial ISP parameters according to the state of the filter switching device and the state of the infrared fill light, and captures the first image according to the initial exposure parameters and the initial ISP parameters, and the first image includes multiple first sub-images. After obtaining the first image, the second chip determines the first ambient light information according to the first image, determines the target exposure parameters and the target ISP parameters according to the first ambient light information, captures the target image according to the determined target exposure parameters and the target ISP parameters, and outputs the target image.

[0099] In the above embodiment, when the camera device switches from a dormant state to a normal working state, the initial exposure parameters and initial ISP parameters are determined according to the state of the filter switching device and the state of the infrared fill light, so that the exposure parameters and ISP parameters can be quickly determined, and the convergence speed of the image output effect parameters at the initial system startup is improved. In addition, the sensor only runs at the initial system startup and no longer runs thereafter, thereby reducing the power consumption of the camera device. The camera device determines the first ambient light information based on the first image, and on the basis of the initial exposure parameters and initial ISP parameters, according to the first ambient light information target exposure parameters and target ISP parameters, the exposure parameters and ISP parameters adapted to the actual scene can be quickly determined, thereby improving the image output efficiency.

[0100] It should be understood that the size of the serial numbers of the steps in the above embodiments does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present application.

[0101] Corresponding to the image capturing method described in the above embodiment, Figure 6 A structural block diagram of an image capturing device provided in an embodiment of the present application is shown. For ease of explanation, only the parts related to the embodiment of the present application are shown.

[0102] like Figure 6 As shown, the image capturing device includes the following modules.

[0103] A first determination module 61, configured to determine initial exposure parameters and initial ISP parameters according to initial ambient light information, wherein the initial ambient light information is detected by a sensor;

[0104] A first shooting module 62, configured to shoot a first image according to the initial exposure parameters and the initial ISP parameters;

[0105] A second determining module 63, configured to determine first ambient light information according to the first image;

[0106] A third determination module 64, configured to determine a target exposure parameter and a target ISP parameter according to the first ambient light information;

[0107] The second shooting module 65 is used to shoot a target image according to the target exposure parameter and the target ISP parameter.

[0108] In one embodiment, the first determining module 61 is specifically configured to:

[0109] Determine an initial exposure parameter according to the state of the filter switching device, the state of the infrared fill light, and a first exposure parameter mapping relationship, wherein the first exposure parameter mapping relationship represents a correspondence between the state of the filter switching device, the state of the infrared fill light, and the exposure parameter;

[0110] The initial ISP parameters are determined according to the state of the filter switching device, the state of the infrared fill light and the first ISP parameter mapping relationship, wherein the first ISP parameter mapping relationship represents the correspondence between the state of the filter switching device, the state of the infrared fill light and the ISP parameters.

[0111] In one embodiment, the state of the filter switching device and the state of the infrared fill light are determined according to initial ambient light information, and the initial ambient light information is detected by a sensor.

[0112] In one embodiment, the first determining module 61 is specifically configured to:

[0113] Upon receiving a power-on instruction of the first chip, the state of the filter switching device, and the state of the infrared fill light, initial exposure parameters and initial ISP parameters are determined according to the state of the filter switching device and the state of the infrared fill light; the first chip is used to switch from a low power consumption state to a normal working state when an image shooting instruction is detected, and to start the sensor to obtain the initial ambient light information sent by the sensor, and to indicate the filter switching device and the switching state of the infrared fill light according to the initial ambient light information.

[0114] In one embodiment, the first ambient light information includes ambient light brightness and ambient light color temperature; the third determination module 64 is specifically configured to:

[0115] Determining the target exposure parameter according to the ambient light brightness and a second exposure parameter mapping relationship, wherein the second exposure parameter mapping relationship represents a corresponding relationship between the ambient light brightness and the exposure parameter;

[0116] The target ISP parameters are determined according to the ambient light color temperature and a second ISP parameter mapping relationship, wherein the second ISP parameter mapping relationship represents a corresponding relationship between the ambient light color temperature and the ISP parameters.

[0117] In one embodiment, the second determining module 63 is specifically configured to:

[0118] The ambient light brightness is determined according to the brightness of the first image and an exposure value when the first image is captured.

[0119] In one embodiment, the second determining module 63 is specifically configured to:

[0120] According to the RGB values ​​of the first pixels in the first image, projecting the first pixels into a plurality of white areas, wherein each white area corresponds to a color temperature;

[0121] The color temperature of the ambient light is determined according to the number of first pixel points corresponding to each white area in the plurality of white areas.

[0122] In one embodiment, the third determination module 64 is specifically configured to:

[0123] A first exposure parameter is determined according to the ambient light brightness and the second exposure parameter mapping relationship, and exposure compensation is performed on the first exposure parameter according to a preset expected value to obtain the target exposure parameter.

[0124] It should be noted that the information interaction, execution process, etc. between the above-mentioned devices / units are based on the same concept as the method embodiment of the present application. Their specific functions and technical effects can be found in the method embodiment part and will not be repeated here.

[0125] Figure 7 It is a schematic diagram of the structure of the camera device provided in an embodiment of the present application.

[0126] like Figure 7 As shown, the camera device of this embodiment includes: a processor 71, a memory 72, and a computer program 73 stored in the memory 72 and executable on the processor 71. When the processor 71 executes the computer program 73, the steps in the above-mentioned image capturing method embodiment are implemented, for example Figure 1 Alternatively, when the processor 71 executes the computer program 73, the functions of each module / unit in the above-mentioned device embodiments are realized, for example Figure 6 The functions of the first determining module 61 to the second shooting module 65 are shown.

[0127] Exemplarily, the computer program 73 may be divided into one or more modules / units, which are stored in the memory 72 and executed by the processor 71 to complete the present application. The one or more modules / units may be a series of computer program instruction segments capable of completing specific functions, which are used to describe the execution process of the computer program 73 in the camera device.

[0128] Those skilled in the art will understand that Figure 7 It is only an example of a camera device and does not constitute a limitation of the camera device. It may include more or fewer components than shown in the figure, or a combination of certain components, or different components. For example, the camera device may also include input and output devices, network access devices, buses, etc.

[0129] The processor 71 may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or any conventional processor, etc.

[0130] The memory 72 may be an internal storage unit of the camera device, such as a hard disk or memory of the camera device. The memory 72 may also be an external storage device of the camera device, such as a plug-in hard disk, a smart memory card (Smart Media Card, SMC), a secure digital (Secure Digital, SD) card, a flash card (Flash Card), etc. equipped on the camera device. Further, the memory 72 may also include both an internal storage unit of the camera device and an external storage device. The memory 72 is used to store the computer program and other programs and data required by the camera device. The memory 72 may also be used to temporarily store data that has been output or is to be output.

[0131] The technicians in the relevant field can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example for illustration. In practical applications, the above-mentioned function allocation can be completed by different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above. The functional units and modules in the embodiment can be integrated in a processing unit, or each unit can exist physically separately, or two or more units can be integrated in one unit. The above-mentioned integrated unit can be implemented in the form of hardware or in the form of software functional units. In addition, the specific names of the functional units and modules are only for the convenience of distinguishing each other, and are not used to limit the scope of protection of this application. The specific working process of the units and modules in the above-mentioned system can refer to the corresponding process in the aforementioned method embodiment, which will not be repeated here.

[0132] In the above embodiments, the description of each embodiment has its own emphasis. For parts that are not described or recorded in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.

[0133] In the embodiments provided in the present application, it should be understood that the disclosed devices / camera equipment and methods can be implemented in other ways. For example, the device / camera equipment embodiments described above are merely schematic. For example, the division of the modules or units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.

[0134] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0135] If the integrated module / unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the present application implements all or part of the processes in the above-mentioned embodiment method, and can also be completed by instructing the relevant hardware through a computer program. The computer program can be stored in a computer-readable storage medium, and the computer program can implement the steps of the above-mentioned various method embodiments when executed by the processor. Among them, the computer program includes computer program code, and the computer program code can be in source code form, object code form, executable file or some intermediate form. The computer-readable medium may include: any entity or device capable of carrying the computer program code, recording medium, U disk, mobile hard disk, disk, optical disk, computer memory, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), electrical carrier signal, telecommunication signal and software distribution medium, etc.

[0136] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.

[0137] The embodiments described above are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, a person skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features may be replaced by equivalents. Such modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present application, and should all be included in the protection scope of the present application.

Claims

1. An image capturing method, It is characterized in that include: Determine the initial exposure parameter and the initial ISP parameter according to the state of the filter switching device and the state of the infrared fill light; Capturing a first image according to the initial exposure parameters and the initial ISP parameters; determining first ambient light information according to the first image; Determine a target exposure parameter and a target ISP parameter according to the first ambient light information; A target image is captured according to the target exposure parameters and the target ISP parameters.

2. The method according to claim 1, It is characterized in that The determining of the initial exposure parameters and the initial ISP parameters according to the state of the filter switching device and the state of the infrared fill light comprises: Determine an initial exposure parameter according to the state of the filter switching device, the state of the infrared fill light, and a first exposure parameter mapping relationship, wherein the first exposure parameter mapping relationship represents a correspondence between the state of the filter switching device, the state of the infrared fill light, and the exposure parameter; The initial ISP parameters are determined according to the state of the filter switching device, the state of the infrared fill light and the first ISP parameter mapping relationship, wherein the first ISP parameter mapping relationship represents the correspondence between the state of the filter switching device, the state of the infrared fill light and the ISP parameters.

3. The method according to claim 1, It is characterized in that The method further comprises: The state of the filter switching device and the state of the infrared fill light are determined according to initial ambient light information, and the initial ambient light information is detected by a sensor.

4. The method according to claim 3, It is characterized in that The determining of the initial exposure parameters and the initial ISP parameters according to the state of the filter switching device and the state of the infrared fill light comprises: Upon receiving a power-on instruction of the first chip, the state of the filter switching device, and the state of the infrared fill light, initial exposure parameters and initial ISP parameters are determined according to the state of the filter switching device and the state of the infrared fill light; the first chip is used to switch from a low power consumption state to a normal working state when an image shooting instruction is detected, and to start the sensor to obtain the initial ambient light information sent by the sensor, and to indicate the filter switching device and the switching state of the infrared fill light according to the initial ambient light information.

5. The method according to claim 1, It is characterized in that The first ambient light information includes ambient light brightness and ambient light color temperature; and determining a target exposure parameter and a target ISP parameter according to the first ambient light information includes: Determining the target exposure parameter according to the ambient light brightness and a second exposure parameter mapping relationship, wherein the second exposure parameter mapping relationship represents a corresponding relationship between the ambient light brightness and the exposure parameter; The target ISP parameters are determined according to the ambient light color temperature and a second ISP parameter mapping relationship, wherein the second ISP parameter mapping relationship represents a corresponding relationship between the ambient light color temperature and the ISP parameters.

6. The method according to claim 5, It is characterized in that The determining first ambient light information according to the first image includes: The ambient light brightness is determined according to the brightness of the first image and an exposure value when the first image is captured.

7. The method according to claim 5, It is characterized in that The determining first ambient light information according to the first image includes: According to the RGB values ​​of the first pixels in the first image, projecting the first pixels into a plurality of white areas, wherein each white area corresponds to a color temperature; The color temperature of the ambient light is determined according to the number of first pixel points corresponding to each white area in the plurality of white areas.

8. The method according to claim 5, It is characterized in that The determining the target exposure parameter according to the ambient light brightness and the second exposure parameter mapping relationship includes: A first exposure parameter is determined according to the ambient light brightness and the second exposure parameter mapping relationship, and exposure compensation is performed on the first exposure parameter according to a preset expected value to obtain the target exposure parameter.

9. An image capturing device, It is characterized in that include: A first determination module, used to determine initial exposure parameters and initial ISP parameters according to the state of the filter switching device and the state of the infrared fill light; A first shooting module, configured to shoot a first image according to the initial exposure parameters and the initial ISP parameters; A second determining module, configured to determine first ambient light information according to the first image; A third determination module, configured to determine a target exposure parameter and a target ISP parameter according to the first ambient light information; The second shooting module is used to shoot a target image according to the target exposure parameter and the target ISP parameter.

10. A camera device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, It is characterized in that When the processor executes the computer program, the method according to any one of claims 1 to 9 is implemented.

Citation Information

Cited By

  • Exposure control method and device for MCU (Microprogrammed Control Unit) visual module

    CN119676573A

  • Camera exposure convergence method, camera and storage medium

    CN121603793A