Focus control method, device, image sensor, electronic device and computer-readable storage medium
By combining pixel arrays and filter arrays in the image sensors, and adjusting the phase information output mode according to the light intensity, the problem of low accuracy in different lights is solved, and a higher focus control accuracy is achieved.
Patent Information
- Application Number
- CN202111383861.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-11-22
- Publication Date
- 2025-01-17
- Estimated Expiration
- 2041-11-22
AI Technical Summary
The traditional phase detection autofocus method has low accuracy in phase difference calculated by RGB pixel arrays at different light intensities, resulting in a significant reduction in the accuracy of focus.
An image sensor, including a pixel array and a filter array, determines the phase information output mode according to the light intensity of the current shooting scene, outputs an appropriate phase array, and calculates the phase difference of the pixel array through the phase array for focusing control. The image sensor includes color and full-color filters, which can adjust the output of phase information at different light intensities and improve the accuracy of phase information.
The accuracy of focus control is improved at different light intensities, and the signal-to-noise ratio is enhanced and the focus quality is improved by adjusting the phase information output mode.
Smart Images

Figure CN113891006B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of image processing technology, and in particular to a focus control method, device, image sensor, electronic device and computer-readable storage medium. Background Art
[0002] With the development of electronic devices, more and more users use electronic devices to capture images. In order to ensure the clarity of the captured images, it is usually necessary to focus the camera module of the electronic device, that is, to adjust the distance between the lens and the image sensor so that the image of the subject is on the focal plane. Traditional focusing methods include phase detection auto focus (English: phase detection auto focus; abbreviated: PDAF).
[0003] Traditional phase detection autofocus mainly calculates the phase difference based on the RGB pixel array, and then controls the motor based on the phase difference. The motor then drives the lens to move to the appropriate position for focusing so that the subject is imaged on the focal plane.
[0004] However, since the sensitivity of the RGB pixel array is different under different light intensities, the accuracy of the phase difference calculated by the RGB pixel array is low under certain light intensities, which in turn greatly reduces the accuracy of focusing. Summary of the invention
[0005] Embodiments of the present application provide a focus control method, device, electronic device, image sensor, and computer-readable storage medium, which can improve the accuracy of focus.
[0006] In one aspect, an image sensor is provided, the image sensor comprising a pixel array and a filter array, the filter array comprising a minimum repeating unit, the minimum repeating unit comprising a plurality of filter groups, the filter groups comprising a color filter and a panchromatic filter; the color filter has a narrower spectral response than the panchromatic filter, the color filter and the panchromatic filter both comprising 9 sub-filters arranged in an array;
[0007] Among them, the pixel array includes multiple full-color pixel groups and multiple color pixel groups, each of the full-color pixel groups corresponds to the full-color filter, and each of the color pixel groups corresponds to the color filter; the full-color pixel group and the color pixel group each include 9 pixels, the pixels of the pixel array are arranged corresponding to the sub-filters of the filter array, and each pixel includes at least two sub-pixels arranged in an array, and each sub-pixel corresponds to a photosensitive element.
[0008] On the other hand, a focus control method is provided, which is applied to the image sensor as described above, and the method comprises:
[0009] According to the light intensity of the current shooting scene, determine a phase information output mode adapted to the light intensity of the current shooting scene; wherein in different phase information output modes, the size of the output phase array is different;
[0010] According to the phase information output mode, output a phase array corresponding to the pixel array; wherein the phase array includes phase information corresponding to a target pixel in the pixel array;
[0011] The phase difference of the pixel array is calculated based on the phase array, and focus control is performed according to the phase difference.
[0012] On the other hand, a focus control device is provided, which is applied to the image sensor as described above, and the device comprises:
[0013] A phase information output mode determination module, used to determine a phase information output mode adapted to the light intensity of the current shooting scene according to the light intensity of the current shooting scene; wherein, in different phase information output modes, the size of the output phase array is different;
[0014] A phase array output module, configured to output a phase array corresponding to the pixel array according to the phase information output mode; wherein the phase array includes phase information corresponding to a target pixel in the pixel array;
[0015] A focus control module is used to calculate the phase difference of the pixel array based on the phase array, and perform focus control according to the phase difference.
[0016] On the other hand, an electronic device is provided, including a memory and a processor, wherein a computer program is stored in the memory, and when the computer program is executed by the processor, the processor executes the steps of the focus control method as described above.
[0017] On the other hand, a computer-readable storage medium is provided, on which a computer program is stored, and when the computer program is executed by a processor, the steps of the method described above are implemented.
[0018] On the other hand, a computer program product is provided, comprising a computer program / instruction, wherein the computer program / instruction implements the steps of the focus control method as described above when executed by a processor.
[0019] The above-mentioned focus control method, device, image sensor, electronic device and computer-readable storage medium determine the phase information output mode adapted to the light intensity of the current shooting scene according to the light intensity of the current shooting scene; wherein, in different phase information output modes, the size of the output phase array is different. According to the phase information output mode, a phase array corresponding to the pixel array is output; wherein the phase array includes the phase information corresponding to the target pixel in the pixel array. The phase difference of the pixel array is calculated based on the phase array, and focus control is performed according to the phase difference.
[0020] Under different light intensities of the current shooting scene, the accuracy of the original phase information that can be collected is different. Therefore, according to the light intensity of the current shooting scene, different phase information output modes can be used for the same pixel array, and phase arrays of different sizes can be output based on the original phase information. Since the signal-to-noise ratio of phase arrays of different sizes is different, the accuracy of the phase information output under different light intensities can be improved, thereby improving the accuracy of focus control. BRIEF DESCRIPTION OF THE DRAWINGS
[0021] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0022] Figure 1 is a schematic diagram of the structure of an electronic device in one embodiment;
[0023] Figure 2 This is a schematic diagram of the principle of phase detection autofocus;
[0024] Figure 3 A schematic diagram of arranging phase detection pixels in pairs among pixels included in an image sensor;
[0025] Figure 4 is an exploded schematic diagram of an image sensor in one embodiment;
[0026] Figure 5 is a connection diagram of a pixel array and a readout circuit in one embodiment;
[0027] Figure 6 A schematic diagram of the arrangement of the minimum repeating unit in one embodiment;
[0028] Figure 7 A schematic diagram of the arrangement of the minimum repeating unit in another embodiment;
[0029] Figure 8 is a flow chart of a focus control method in one embodiment;
[0030] Fig. 9 It is a flowchart of a method for determining a phase information output mode adapted to the light intensity of a current shooting scene according to a target light intensity range in one embodiment;
[0031] Fig.10 A flowchart of a method for generating a full-size phased array in one embodiment;
[0032] Fig.11 A schematic diagram of generating a full-size phase array in one embodiment;
[0033] Fig.12 A flowchart of a method for generating a first-size phase array in one embodiment;
[0034] Fig.13 A schematic diagram of generating a phase array of a first size in another embodiment;
[0035] Fig.14 A flowchart of a method for generating a second-size phase array in one embodiment;
[0036] Fig.15 A schematic diagram of generating a second-size phase array in one embodiment;
[0037] Fig.16 A schematic diagram of generating a phase array of a third size in one embodiment;
[0038] Fig.17 is a structural block diagram of a focus control device in one embodiment;
[0039] Fig.18 for Fig.17 The structural block diagram of the phase array output module;
[0040] Fig.19 FIG. 1 is a schematic diagram of the internal structure of an electronic device in an embodiment. DETAILED DESCRIPTION
[0041] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0042] It is understood that the terms "first", "second", "third", etc. used in this application may be used herein to describe various elements, but these elements are not limited by these terms. These terms are only used to distinguish a first element from another element. For example, without departing from the scope of this application, a first size may be referred to as a second size, and similarly, a second size may be referred to as a first size. Both the first size and the second size are sizes, but they are not the same size. The first preset threshold may be referred to as the second preset threshold, and similarly, the second preset threshold may be referred to as the first preset threshold. Both the first preset threshold and the second preset threshold are preset thresholds, but they are not the same preset threshold.
[0043] Figure 1 FIG. 1 is a schematic diagram of an application environment of a focus control method in an embodiment. Figure 1 As shown, the application environment includes an electronic device 100. The electronic device 100 includes an image sensor, and the image sensor includes a pixel array. The electronic device determines a phase information output mode adapted to the light intensity of the current shooting scene according to the light intensity of the current shooting scene; wherein, in different phase information output modes, the size of the output phase array is different; according to the phase information output mode, a phase array corresponding to the pixel array is output; wherein the phase array includes phase information corresponding to the pixel array; the phase difference of the pixel array is calculated based on the phase array, and focus control is performed according to the phase difference. The electronic device can be any terminal device with image processing function, such as a mobile phone, a tablet computer, a PDA (Personal Digital Assistant), a wearable device (smart bracelet, smart watch, smart glasses, smart gloves, smart socks, smart belt, etc.), a VR (virtual reality) device, a smart home, an unmanned vehicle, etc.
[0044] Among them, the electronic device 100 includes a camera 20, a processor 30 and a housing 40. The camera 20 and the processor 30 are both arranged in the housing 40. The housing 40 can also be used to install functional modules such as a power supply device and a communication device of the terminal 100, so that the housing 40 provides dustproof, drop-proof, waterproof and other protections for the functional modules. The camera 20 can be a front camera, a rear camera, a side camera, an under-screen camera, etc., which is not limited here. The camera 20 includes a lens and an image sensor 21. When the camera 20 takes an image, light passes through the lens and reaches the image sensor 21. The image sensor 21 is used to convert the light signal irradiated on the image sensor 21 into an electrical signal.
[0045] Figure 2 Schematic diagram of the principle of phase detection auto focus (PDAF). Figure 2As shown, M1 is the position of the image sensor when the imaging device is in a focused state, wherein the focused state refers to a state of successful focusing. When the image sensor is at position M1, the imaging light g reflected from the object W to the lens Lens in different directions converges on the image sensor, that is, the imaging light g reflected from the object W to the lens Lens in different directions forms an image at the same position on the image sensor, and at this time, the image sensor forms a clear image.
[0046] M2 and M3 are possible positions of the image sensor when the imaging device is not in focus, such as Figure 2 As shown in FIG. 1 , when the image sensor is located at position M2 or position M3, the imaging light g reflected from the object W to the lens Lens in different directions will form images at different positions. Figure 2 When the image sensor is located at position M2, the imaging light g reflected from the object W to the lens Lens in different directions forms images at positions A and B respectively. When the image sensor is located at position M3, the imaging light g reflected from the object W to the lens Lens in different directions forms images at positions C and D respectively. At this time, the image sensor image is not clear.
[0047] In PDAF technology, the positional differences of the images formed by the imaging light rays entering the lens from different directions in the image sensor can be obtained, for example, Figure 2 As shown, the difference between position A and position B can be obtained, or the difference between position C and position D can be obtained; after obtaining the difference in position of the image formed in the image sensor by the imaging light entering the lens from different directions, the defocus distance can be obtained according to the difference and the geometric relationship between the lens and the image sensor in the camera. The so-called defocus distance refers to the distance between the current position of the image sensor and the position where the image sensor should be in the focused state; the imaging device can focus according to the obtained defocus distance.
[0048] It can be seen that when the focus is achieved, the calculated PD value is 0. Conversely, the larger the calculated value, the farther away from the focus point, and the smaller the value, the closer to the focus point. When using PDAF for focusing, the defocus distance can be obtained by calculating the PD value and then calibrating the corresponding relationship between the PD value and the defocus distance. Then, the lens is controlled to move to the focus point according to the defocus distance to achieve focus.
[0049] In the related art, some phase detection pixels may be arranged in pairs among the pixels included in the image sensor, such as Figure 3As shown, the image sensor may be provided with phase detection pixel pairs (hereinafter referred to as pixel pairs) A, pixel pairs B and pixel pairs C. In each pixel pair, one phase detection pixel performs left shielding (English: Left Shield) and the other phase detection pixel performs right shielding (English: Right Shield).
[0050] For a phase detection pixel point that is blocked on the left side, only the right side of the imaging light beam directed to the phase detection pixel point can form an image on the photosensitive part (that is, the unblocked part) of the phase detection pixel point. For a phase detection pixel point that is blocked on the right side, only the left side of the imaging light beam directed to the phase detection pixel point can form an image on the photosensitive part (that is, the unblocked part) of the phase detection pixel point. In this way, the imaging light beam can be divided into two parts, the left and the right, and the phase difference can be obtained by comparing the images formed by the left and the right imaging light beams.
[0051] In one embodiment, it is further described that the image sensor includes a pixel array and a filter array, the filter array includes a minimum repeating unit, the minimum repeating unit includes a plurality of filter groups, the filter groups include color filters and panchromatic filters, in the filter groups, the color filters are arranged in a first diagonal direction, the panchromatic filters are arranged in a second diagonal direction, and the first diagonal direction is different from the second diagonal direction; the color filter has a narrower spectral response than the panchromatic filter, and the color filter and the panchromatic filter both include 9 sub-filters arranged in an array;
[0052] Among them, the pixel array includes multiple full-color pixel groups and multiple color pixel groups, each full-color pixel group corresponds to a full-color filter, and each color pixel group corresponds to a color filter; the full-color pixel group and the color pixel group each include 9 pixels, the pixels of the pixel array are arranged corresponding to the sub-filters of the filter array, and each pixel includes at least two sub-pixels arranged in an array, and each sub-pixel corresponds to a photosensitive element.
[0053] like Figure 4 As shown, the image sensor 21 includes a microlens array 22 , a filter array 23 , and a pixel array 24 .
[0054] The microlens array 22 includes a plurality of microlenses 221. The microlenses 221, the sub-filters in the filter array 23, and the pixels in the pixel array 24 are arranged in a one-to-one correspondence. The microlenses 221 are used to gather the incident light. The gathered light passes through the corresponding sub-filter and is then projected onto the pixel and received by the corresponding pixel. The pixel then converts the received light into an electrical signal.
[0055] The filter array 23 includes a plurality of minimal repeating units 231. The minimal repeating unit 231 may include a plurality of filter groups 232. Each filter group 232 includes a panchromatic filter 233 and a color filter 234, and the color filter 234 has a narrower spectral response than the panchromatic filter 233. Each panchromatic filter 233 includes nine sub-filters 2331, and each color filter 234 includes nine sub-filters 2341. Different filter groups also include different color filters 234.
[0056] The colors corresponding to the wavelength band of the light transmitted by the color filter 234 of the filter group 232 in the minimum repeating unit 231 include color a, color b and / or color c. The colors corresponding to the wavelength band of the light transmitted by the color filter 234 of the filter group 232 include color a, color b and color c, or color a, color b or color c, or color a and color b, or color b and color c, or color a and color c. Among them, color a is red, color b is green, and color c is blue, or for example, color a is magenta, color b is cyan, and color c is yellow, etc., which is not limited here.
[0057] In one embodiment, the width of the wavelength band of the light transmitted by the color filter 234 is smaller than the width of the wavelength band of the light transmitted by the full-color filter 233. For example, the wavelength band of the light transmitted by the color filter 234 may correspond to the wavelength band of red light, the wavelength band of green light, or the wavelength band of blue light, and the wavelength band of the light transmitted by the full-color filter 233 is the wavelength band of all visible light. In other words, the color filter 234 only allows light of a specific color to be transmitted, while the full-color filter 233 can pass light of all colors. Of course, the wavelength band of the light transmitted by the color filter 234 may also correspond to the wavelength band of other colored light, such as magenta light, purple light, cyan light, yellow light, etc., which is not limited here.
[0058] In one embodiment, the ratio of the number of color filters 234 to the number of full-color filters 233 in the filter group 232 can be 1:3, 1:1 or 3:1. For example, if the ratio of the number of color filters 234 to the number of full-color filters 233 is 1:3, then the number of color filters 234 is 1, and the number of full-color filters 233 is 3. At this time, the number of full-color filters 233 is large. Compared with the traditional case of only color filters, more phase information can be obtained through the full-color filters 233 in dim light, so the focusing quality is better; or, if the ratio of the number of color filters 234 to the number of full-color filters 233 is 1:1, then the number of color filters 234 is 1, and the number of full-color filters 233 is 3. The number of color filters 234 is 2, and the number of full-color filters 233 is 2. At this time, better color performance can be obtained, and more phase information can be obtained through the full-color filter 233 in dim light, so the focus quality is also better; or, the ratio of the number of color filters 234 to the number of full-color filters 233 is 3:1, then the number of color filters 234 is 3, and the number of full-color filters 233 is 1. At this time, better color performance can be obtained, and similarly, the focus quality in dim light can also be improved.
[0059] The pixel array 24 includes a plurality of pixels, and the pixels of the pixel array 24 are arranged corresponding to the sub-filters of the filter array 23. The pixel array 24 is configured to receive light passing through the filter array 23 to generate an electrical signal.
[0060] The pixel array 24 is configured to receive the light passing through the filter array 23 to generate an electrical signal, which means that the pixel array 24 is used to perform photoelectric conversion on the light of a given set of scenes of the photographed object passing through the filter array 23 to generate an electrical signal. The light of a given set of scenes of the photographed object is used to generate image data. For example, if the photographed object is a building, the given set of scenes of the photographed object refers to the scene where the building is located, and the scene may also contain other objects.
[0061] In one embodiment, the pixel array 24 may be an RGBW pixel array, including a plurality of minimum repeating units 241, the minimum repeating unit 241 including a plurality of pixel groups 242, the plurality of pixel groups 242 including a panchromatic pixel group 243 and a color pixel group 244. Each panchromatic pixel group 243 includes 9 panchromatic pixels 2431, and each color pixel group 244 includes 9 color pixels 2441. Each panchromatic pixel 2431 corresponds to a sub-filter 2331 in the panchromatic filter 233, and the panchromatic pixel 2431 receives light passing through the corresponding sub-filter 2331 to generate an electrical signal. Each color pixel 2441 corresponds to a sub-filter 2341 of the color filter 234, and the color pixel 2441 receives light passing through the corresponding sub-filter 2341 to generate an electrical signal. Each pixel includes at least two sub-pixels arranged in an array, and each sub-pixel corresponds to a photosensitive element. That is, each full-color pixel 2431 includes at least two sub-pixels 2431a and 2431b arranged in an array, and each sub-pixel corresponds to a photosensitive element; each color pixel 2441 includes at least two sub-pixels 2441a and 2441b arranged in an array, and each sub-pixel corresponds to a photosensitive element. Here, each full-color pixel 2431 includes at least two sub-pixels arranged in an array, which may specifically include two sub-pixels arranged in an array, or four sub-pixels arranged in an array, and this application does not limit this.
[0062] The image sensor 21 in this embodiment includes a filter array 23 and a pixel array 24. The filter array 23 includes a minimum repeating unit 231. The minimum repeating unit 231 includes multiple filter groups 232. The filter groups include a panchromatic filter 233 and a color filter 234. The color filter 234 has a narrower spectral response than the panchromatic filter 233, so that more light can be obtained during shooting, thereby eliminating the need to adjust shooting parameters. The focus quality in dark light is improved without affecting the stability of shooting. When focusing in dark light, both stability and quality can be taken into account, and the stability and quality of focusing in dark light are both high. Furthermore, each full-color filter 233 includes 9 sub-filters 2331, each color filter 234 includes 9 sub-filters 2341, the pixel array 24 includes multiple full-color pixels 2431 and multiple color pixels 2441, each full-color pixel 2431 corresponds to a sub-filter 2331 of the full-color filter 233, and each color pixel 2441 corresponds to a sub-filter 2341 of the color filter 234, the full-color pixels 2431 and the color pixels 2441 are used to receive light passing through the corresponding sub-filters to generate electrical signals, and when focusing in dim light, the phase information of the pixels corresponding to the 9 sub-filters can be combined and output to obtain phase information with a higher signal-to-noise ratio, and in scenes with sufficient light, the phase information of the pixels corresponding to each sub-filter can be output separately to obtain phase information with higher resolution and signal-to-noise ratio, so that it can adapt to different application scenarios and improve the focusing quality in each scenario.
[0063] In one embodiment, Figure 4 As shown, the minimum repeating unit 231 in the filter array 23 includes four filter groups 232, and the four filter groups 232 are arranged in a matrix. Each filter group 232 includes a full-color filter 233 and a color filter 234, and each full-color filter 233 and each color filter 234 has 9 sub-filters, so the filter group 232 includes 36 sub-filters in total.
[0064] Similarly, the pixel array 24 includes a plurality of minimal repeating units 241 corresponding to the plurality of minimal repeating units 231. Each minimal repeating unit 241 includes four pixel groups 242, and the four pixel groups 242 are arranged in a matrix. Each pixel group 242 corresponds to a filter group 232.
[0065] like Figure 5As shown, the readout circuit 25 is electrically connected to the pixel array 24, and is used to control the exposure of the pixel array 24 and the reading and output of the pixel values of the pixel points. The readout circuit 25 includes a vertical drive unit 251, a control unit 252, a column processing unit 253 and a horizontal drive unit 254. The vertical drive unit 251 includes a shift register and an address decoder. The vertical drive unit 251 includes a readout scan and a reset scan function. The control unit 252 configures the timing signal according to the operation mode, and uses a variety of timing signals to control the vertical drive unit 251, the column processing unit 253 and the horizontal drive unit 254 to work together. The column processing unit 253 may have an analog-to-digital (A / D) conversion function for converting an analog pixel signal into a digital format. The horizontal drive unit 254 includes a shift register and an address decoder. The horizontal drive unit 254 sequentially scans the pixel array 24 column by column.
[0066] In one embodiment, Figure 6 As shown, each filter group 232 includes a color filter 234 and a full-color filter 233. Each full-color filter 233 in the filter group 232 is arranged in a first diagonal direction D1, and each color filter 234 in the filter group 232 is arranged in a second diagonal direction. The first diagonal D1 direction and the second diagonal D2 direction are different, which can take into account both color performance and low-light focusing quality.
[0067] The direction of the first diagonal line D1 is different from the direction of the second diagonal line D2. Specifically, the direction of the first diagonal line D1 is not parallel to the direction of the second diagonal line D2, or the direction of the first diagonal line D1 is perpendicular to the direction of the second diagonal line D2.
[0068] In other embodiments, one color filter 234 and one panchromatic filter 233 may be located on the first diagonal line D1 , and another color filter 234 and another panchromatic filter 233 may be located on the second diagonal line D2 .
[0069] In one embodiment, each pixel includes at least two sub-pixels arranged in an array, and each sub-pixel corresponds to a photosensitive element. The photosensitive element is an element that can convert a light signal into an electrical signal. For example, the photosensitive element may be a photodiode. Figure 6 As shown, each full-color pixel 2331 includes two sub-pixels d arranged in an array (ie, two photodiodes PD (Left PhotoDiode, Right PhotoDiode)), and each color pixel 2341 includes two sub-pixels d arranged in an array (ie, two photodiodes PD (Left PhotoDiode, Right PhotoDiode)).
[0070] Of course, each full-color pixel 2431 may also include 4 sub-pixels d arranged in an array (i.e., 4 photodiodes PD (Up-Left PhotoDiode, Up-Right PhotoDiode, Down-Left PhotoDiode, and Down-Right PhotoDiode)), and each color pixel 2441 includes 4 sub-pixels d arranged in an array (i.e., 4 photodiodes PD (Up-Left PhotoDiode, Up-Right PhotoDiode, Down-Left PhotoDiode, and Down-Right PhotoDiode)). This application does not limit this.
[0071] In the embodiment of the present application, since each pixel includes at least two sub-pixels arranged in an array, and each sub-pixel corresponds to a photosensitive element, the phase difference of the pixel array can be calculated based on the phase information of the at least two sub-pixels.
[0072] In one embodiment, Figure 6 As shown, the minimum repeating unit 231 in the filter array 23 includes four filter groups 232, and the four filter groups 232 are arranged in a matrix. Each filter group 232 includes two full-color filters 233 and two color filters 234. The full-color filter 233 includes nine sub-filters 2331, and the color filter 234 includes nine sub-filters 2341. The minimum repeating unit 231 is 12 rows and 12 columns of 144 sub-filters, and the arrangement is as follows:
[0073]
[0074] Wherein, w represents the full-color sub-filter 2331, and a, b and c all represent the color sub-filter 2341. The full-color sub-filter 2331 refers to a sub-filter that can filter out all light outside the visible light band, and the color sub-filter 2341 includes a red sub-filter, a green sub-filter, a blue sub-filter, a magenta sub-filter, a cyan sub-filter and a yellow sub-filter. The red sub-filter is a sub-filter that filters out all light except red light, the green sub-filter is a sub-filter that filters out all light except green light, the blue sub-filter is a sub-filter that filters out all light except blue light, the magenta sub-filter is a sub-filter that filters out all light except magenta light, the cyan sub-filter is a sub-filter that filters out all light except cyan light, and the yellow sub-filter is a sub-filter that filters out all light except yellow light.
[0075] a can be a red sub-filter, a green sub-filter, a blue sub-filter, a magenta sub-filter, a cyan sub-filter or a yellow sub-filter, b can be a red sub-filter, a green sub-filter, a blue sub-filter, a magenta sub-filter, a cyan sub-filter or a yellow sub-filter, and c can be a red sub-filter, a green sub-filter, a blue sub-filter, a magenta sub-filter, a cyan sub-filter or a yellow sub-filter. For example, b is a red sub-filter, a is a green sub-filter, and c is a blue sub-filter; or, c is a red sub-filter, a is a green sub-filter, and b is a blue sub-filter; for another example, c is a red sub-filter, a is a green sub-filter, and b is a blue sub-filter; or, a is a red sub-filter, b is a blue sub-filter, and c is a green sub-filter, etc., which are not limited here; for another example, b is a magenta sub-filter, a is a cyan sub-filter, and b is a yellow sub-filter, etc. In other embodiments, the color filter may further include sub-filters of other colors, such as an orange sub-filter, a purple sub-filter, etc., which are not limited here.
[0076] In one embodiment, Figure 7 As shown, the minimum repeating unit 231 in the filter array 23 includes four filter groups 232, and the four filter groups 232 are arranged in a matrix. Each filter group 232 includes a color filter 234 and a full-color filter 233. Each color filter 234 in the filter group 232 is arranged in the direction of the first diagonal line D1, and each full-color filter 233 in the filter group 232 is arranged in the direction of the second diagonal line D2. And the pixel array ( Figure 7 Not shown, for reference Figure 6 ) are arranged corresponding to the sub-filters of the filter array, and each pixel includes at least two sub-pixels arranged in an array, and each sub-pixel corresponds to a photosensitive element.
[0077] In one embodiment, each filter group 232 includes two full-color filters 233 and two color filters 234, the full-color filter 233 includes nine sub-filters 2331, and the color filter 234 includes nine sub-filters 2341. The minimum repeating unit 231 is 12 rows and 12 columns of 144 sub-filters. Figure 5 As shown, the arrangement is:
[0078]
[0079] Among them, w represents the full-color sub-filter, and a, b and c all represent color sub-filters.
[0080] 12 rows, 12 columns and 144 sub-filters combine the advantages of quad and RGBW. The advantage of quad is that it can locally merge the same pixels 2x2 and 3x3 (binning) to obtain images of different resolutions with high signal-to-noise ratio. The full-size quad output has high pixels, and a full-size and full-resolution image is obtained with higher clarity. The advantage of RGBW is that W pixels are used to increase the overall light intake of the image, thereby improving the image quality signal-to-noise ratio.
[0081] In one embodiment, Figure 8 As shown, a focus control method is provided, which is applied to an image sensor as in the above embodiment, the image sensor includes a pixel array and a filter array, and the method includes:
[0082] Step 820, determining a phase information output mode adapted to the light intensity of the current shooting scene according to the light intensity of the current shooting scene; wherein, in different phase information output modes, the size of the output phase array is different.
[0083] In different shooting scenes or at different times, the light intensity of the current shooting scene is not the same. Since the sensitivity of the RGB pixel array is different under different light intensities, the phase difference calculated by the RGB pixel array is less accurate under some light intensities, which in turn greatly reduces the accuracy of focusing. Among them, light intensity is also called illumination intensity. Light intensity is a physical term that refers to the luminous flux of visible light received per unit area, referred to as illuminance, and the unit is lux (Lux or lx). Light intensity is used to indicate the intensity of light and the degree of illumination of the surface area of an object. The following table shows the light intensity values under different weather and locations:
[0084] Table 1-1
[0085] Weather and location Light intensity value Sunny day with direct sunlight on the ground 100000lx Sunny day indoor center 200lx Cloudy outdoor 50-500lx Cloudy indoor 5-50lx Moonlight (Full Moon) 2500lx Clear Moon Night 0.2lx Night 0.0011lx
[0086] It can be seen from Table 1-1 above that the light intensity of the current shooting scene varies greatly in different shooting scenes or at different times.
[0087] In order to solve the problem that the phase difference calculated by the RGB pixel array is less accurate under certain light intensities, which leads to a significant reduction in the accuracy of focusing, under different light intensities of the current shooting scene, a phase information output mode adapted to the light intensity of the current shooting scene is determined, and then different phase information output modes are used to output the phase information of the pixel array. The phase information output mode refers to a mode in which the original phase information of the pixel array is processed to generate the final output phase information of the pixel array.
[0088] Among them, in different phase information output modes, the size of the phase array output is different. That is, under different light intensities of the current shooting scene, the size of the phase array output by the same pixel array is different. In other words, under different light intensities of the current shooting scene, the phase information corresponding to the same pixel array is directly output as the phase array corresponding to the pixel array or merged to a certain extent to generate the phase array corresponding to the pixel array. For example, if the light intensity of the current shooting scene is large, the phase information corresponding to the same pixel array can be directly output as the phase array corresponding to the pixel array. At this time, the size of the phase array output is equal to the size of the pixel array. If the light intensity of the current shooting scene is small, the phase information corresponding to the same pixel array can be merged to a certain extent to generate the phase array corresponding to the pixel array. At this time, the size of the phase array output is smaller than the size of the pixel array.
[0089] Since the signal-to-noise ratios of phase arrays of different sizes are different, the accuracy of the phase information output under different light intensities can be improved, thereby improving the accuracy of focusing.
[0090] Step 840: output a phase array corresponding to the pixel array according to the phase information output mode; wherein the phase array includes phase information corresponding to the target pixel in the pixel array.
[0091] After determining the phase information output mode adapted to the light intensity of the current shooting scene according to the light intensity of the current shooting scene, the phase information corresponding to the pixel array can be output according to the phase information output mode. Specifically, when outputting the phase information corresponding to the pixel array, it can be output in the form of a phase array. The phase array includes the phase information corresponding to the pixel array.
[0092] Specifically, under different light intensities in the current shooting scene, the phase information corresponding to the same pixel array is directly output as the phase array corresponding to the pixel array or merged to a certain extent to generate the phase array corresponding to the pixel array according to the phase information output mode adapted to the light intensity. This application does not limit this.
[0093] Step 860: Calculate the phase difference of the pixel array based on the phase array, and perform focus control according to the phase difference.
[0094] After outputting the phase array corresponding to the pixel array according to the phase information output mode, the phase difference of the pixel array can be calculated based on the phase information in the phase array. Assuming that the phase array of the pixel array in the second direction can be obtained, the phase difference is calculated based on the two adjacent phase information in the second direction, and finally the phase difference of the entire pixel array in the second direction is obtained. Assuming that the phase array of the pixel array in the first direction can be obtained, the phase difference is calculated based on the two adjacent phase information in the first direction, and finally the phase difference of the entire pixel array in the first direction is obtained, and the second direction is different from the first direction. Among them, the second direction can be the vertical direction of the pixel array, the first direction can be the horizontal direction of the pixel array, and the second direction is perpendicular to the first direction. Of course, the phase difference of the entire pixel array in the second direction and the first direction can be obtained at the same time, and the phase difference of the pixel array in other directions can also be calculated, such as the diagonal direction (including the first diagonal direction, and the second diagonal direction perpendicular to the first diagonal direction), etc., and this application does not limit this.
[0095] When the focus control is performed based on the calculated phase difference, since the collected phase difference parallel to the texture feature in a certain direction on the preview image corresponding to the current shooting scene is almost 0, it is obviously impossible to focus based on the collected phase difference parallel to the direction. Therefore, if the preview image corresponding to the current shooting scene includes the texture feature in the first direction, the phase difference of the pixel array in the second direction is calculated based on the phase array of the pixel array in the second direction. The focus control is performed according to the phase difference of the pixel array in the second direction.
[0096] For example, assuming that the second direction is the vertical direction of the pixel array, the first direction is the horizontal direction of the pixel array, and the second direction is perpendicular to the first direction. Then, the preview image includes texture features in the first direction, which means that the preview image includes horizontal stripes, which can be solid color, horizontal stripes. At this time, the preview image corresponding to the current shooting scene includes texture features in the horizontal direction, and focus control is performed based on the phase difference in the vertical direction.
[0097] If the preview image corresponding to the current shooting scene includes texture features in the second direction, focus control is performed based on the phase difference in the first direction. If the preview image corresponding to the current shooting scene includes texture features in the first diagonal direction, focus control is performed based on the phase difference in the second diagonal direction, and vice versa. In this way, the phase difference can be accurately collected for texture features in different directions, and then the focus can be accurately achieved.
[0098] In an embodiment of the present application, a phase information output mode adapted to the light intensity of the current shooting scene is determined according to the light intensity of the current shooting scene; wherein, in different phase information output modes, the size of the output phase array is different. According to the phase information output mode, a phase array corresponding to the pixel array is output; wherein, the phase array includes phase information corresponding to the pixel array. The phase difference of the pixel array is calculated based on the phase array, and focus control is performed according to the phase difference.
[0099] Under different light intensities of the current shooting scene, the accuracy of the original phase information that can be collected is different. Therefore, according to the light intensity of the current shooting scene, different phase information output modes can be used for the same pixel array, and phase arrays of different sizes can be output based on the original phase information. Since the signal-to-noise ratio of phase arrays of different sizes is different, the accuracy of the phase information output under different light intensities can be improved, thereby improving the accuracy of focus control.
[0100] In the previous embodiment, it is described that according to the light intensity of the current shooting scene, different phase information output modes are used for the same pixel array, a phase array corresponding to the pixel array is output, and the phase difference of the pixel array is calculated based on the phase array, and focus control is performed according to the phase difference. In this embodiment, step 820 is described in detail, and the specific implementation steps of determining the phase information output mode adapted to the light intensity of the current shooting scene according to the light intensity of the current shooting scene include:
[0101] Determine the target light intensity range to which the light intensity of the current shooting scene belongs; wherein different light intensity ranges correspond to different phase information output modes;
[0102] According to the target light intensity range, a phase information output mode adapted to the light intensity of the current shooting scene is determined.
[0103] Specifically, the light intensity can be divided into different light intensity ranges in order of magnitude based on different preset thresholds of light intensity. The preset threshold of light intensity can be determined according to exposure parameters and the size of pixels in the pixel array. The exposure parameters include shutter speed, lens aperture size, and light sensitivity (ISO).
[0104] Then, different phase information output modes are set for different light intensity ranges. Specifically, according to the order of light intensity in the light intensity range, the sizes of the phase arrays output by the phase information output modes set for different light intensity ranges decrease in sequence.
[0105] Determine which light intensity range the light intensity of the current shooting scene falls into, and use the light intensity range as the target light intensity range to which the light intensity of the current shooting scene belongs. Use the phase information output mode corresponding to the target light intensity range as the phase information output mode adapted to the light intensity of the current shooting scene.
[0106] In an embodiment of the present application, when determining a phase information output mode that matches the light intensity of the current shooting scene based on the light intensity of the current shooting scene, since different light intensity ranges correspond to different phase information output modes, first determine the target light intensity range to which the light intensity of the current shooting scene belongs. Then, based on the target light intensity range, determine a phase information output mode that matches the light intensity of the current shooting scene. Different phase information output modes are set in advance for different light intensity ranges, and the size of the phase array output in each phase information output mode is different. Therefore, based on the light intensity of the current shooting scene, the phase information of the pixel array can be calculated more finely to achieve more accurate focusing.
[0107] Following the previous embodiment, it is further described that the phase information output mode includes a full-size output mode and a first-size output mode, and the size of the phase array in the full-size output mode is larger than the size of the phase array in the first-size output mode. Fig. 9 As shown, step 824, determining a phase information output mode adapted to the light intensity of the current shooting scene according to the target light intensity range, includes:
[0108] Step 824a, if the light intensity of the current shooting scene is greater than the first preset threshold, determining that the phase information output mode adapted to the light intensity of the current shooting scene is the full-size output mode;
[0109] Step 824b: If the light intensity of the current shooting scene is greater than the second preset threshold and less than or equal to the first preset threshold, determine that the phase information output mode adapted to the light intensity of the current shooting scene is the first size output mode.
[0110] Specifically, if one of the light intensity ranges is greater than the first preset threshold, the phase information output mode corresponding to the light intensity range is the full-size output mode. If it is determined that the light intensity of the current shooting scene is greater than the first preset threshold, the light intensity of the current shooting scene falls within the light intensity range. That is, the phase information output mode adapted to the light intensity of the current shooting scene is determined to be the full-size output mode. Among them, the full-size output mode is used to output the phase array, that is, all the original phase information of the pixel array is output to generate the phase array of the pixel array.
[0111] If one of the light intensity ranges is greater than the second preset threshold and less than or equal to the first preset threshold, the phase information output mode corresponding to the light intensity range is the first size output mode. If it is determined that the light intensity of the current shooting scene is greater than the second preset threshold and less than or equal to the first preset threshold, the light intensity of the current shooting scene falls within the light intensity range. That is, the phase information output mode adapted to the light intensity of the current shooting scene is determined to be the first size output mode. Among them, the first size output mode is used to output the phase array, that is, the original phase information of the pixel array is merged and output to generate the phase array of the pixel array.
[0112] In the embodiment of the present application, since the size of the phase array in the full-size output mode is larger than the size of the phase array in the first-size output mode, if the light intensity of the current shooting scene is greater than the first preset threshold, the phase information output mode adapted to the light intensity of the current shooting scene is determined to be the full-size output mode. If the light intensity of the current shooting scene is greater than the second preset threshold, and less than or equal to the first preset threshold, the phase information output mode adapted to the light intensity of the current shooting scene is determined to be the first-size output mode. That is, if the light intensity of the current shooting scene is large, the full-size output mode is used to output a phase array with the same size as the pixel array, and if the light intensity of the current shooting scene is second, the first-size output mode is used to output a phase array smaller than the pixel array size. That is, when the light intensity of the current shooting scene is second, the signal-to-noise ratio of the phase information is improved by reducing the phase array.
[0113] In the previous embodiment, it is described that the pixel array may be an RGBW pixel array, including a plurality of minimum repeating units 241, the minimum repeating unit 241 includes a plurality of pixel groups 242, and the plurality of pixel groups 242 include a full-color pixel group 243 and a color pixel group 244. Each full-color pixel group 243 includes 9 full-color pixels 2431, and each color pixel group 244 includes 9 color pixels 2441. Each full-color pixel 2431 includes 2 sub-pixels arranged in an array, and each color pixel 2441 includes 2 sub-pixels arranged in an array.
[0114] In this embodiment, when the pixel array is an RGBW pixel array, Fig.10 As shown, if the phase information output mode is the full-size output mode, the specific implementation steps of outputting the phase array corresponding to the pixel array according to the phase information output mode include:
[0115] Step 1020, taking the color pixel group in the pixel array as the target pixel group;
[0116] Step 1040, for each target pixel group, obtaining phase information of a sub-pixel of each pixel in the target pixel group;
[0117] Step 1060 , generating a full-size phase array corresponding to the pixel array according to the phase information of the sub-pixel of the target pixel; the size of the full-size phase array is the size of 6×3 pixels arranged in the array.
[0118] This embodiment is a specific implementation step of outputting a phase array corresponding to a pixel array in full-size output mode when the light intensity of the current shooting scene is greater than a first preset threshold. The first preset threshold may be 2000 lux, which is not limited in this application. That is, at this time, the light intensity is greater than 2000 lux. Fig.11 As shown, first, a color pixel group is determined from the pixel array as a target pixel group for calculating the phase information. Because when the light intensity of the current shooting scene is greater than the first preset threshold, that is, in a well-lit scene, due to the high sensitivity of the full-color pixels, they are easily saturated in a well-lit scene, and the correct phase information cannot be obtained after saturation, so the phase information of the color pixel group can be used to achieve phase focusing (PDAF). Specifically, the phase information of some color pixel groups in the pixel array can be used to achieve phase focusing, or some pixels in some pixel groups can be used to achieve phase focusing, which is not limited in this application. Since only the phase information of the color pixel group is used for phase focusing at this time, the amount of data of the output phase information is reduced, thereby improving the efficiency of phase focusing.
[0119] Secondly, for each target pixel group, the phase information of the sub-pixel of each target pixel in the target pixel group is obtained. Each pixel includes at least two sub-pixels arranged in an array, and each sub-pixel corresponds to a photosensitive element. Assuming that each pixel includes two sub-pixels arranged in an array at this time, the two sub-pixels can be arranged up and down, or left and right, and the present application does not limit this. In the embodiment of the present application, two sub-pixels arranged left and right are selected for illustration. Then, for each target pixel group, the phase information of the sub-pixel of each target pixel in the target pixel group is obtained, that is, the phase information of the two sub-pixels arranged left and right is obtained from each target pixel. Finally, the phase information of all target pixels is output as a full-size phase array corresponding to the pixel array.
[0120] Combination Fig.11 As shown, a pixel array may include 2 red pixel groups, 4 green pixel groups, 2 blue pixel groups, and 8 full-color pixel groups. Figure 7As shown, it can be assumed that a represents green, b represents red, c represents blue, and w represents full color. And assuming that all color pixel groups in the pixel array are taken as target pixel groups, the phase information of each pixel group is calculated in sequence for the 2 red pixel groups, 4 green pixel groups and 2 blue pixel groups included in the pixel array. For example, the phase information of the red pixel group 244 is calculated for the red pixel group, and the red pixel group includes 9 red pixels arranged in a 3×3 array, which are numbered red pixel 1, red pixel 2, red pixel 3, red pixel 4, red pixel 5, red pixel 6, red pixel 7, red pixel 8, and red pixel 9 in sequence. Among them, each pixel includes two sub-pixels arranged left and right, and each sub-pixel corresponds to a photosensitive element. That is, red pixel 1 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L1 and R1 respectively; red pixel 2 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L2 and R2 respectively; red pixel 3 includes two sub-pixels L3 and R3 arranged on the left and right, and the phase information of the two sub-pixels is respectively; red pixel 4 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L4 and R4 respectively; red pixel 5 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L5 and R5 respectively; red pixel 6 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L6 and R6 respectively; red pixel 7 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L7 and R7 respectively; red pixel 8 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L8 and R8 respectively; red pixel 9 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L9 and R9 respectively.
[0121] Finally, the phase information of all target pixels is output as a full-size phase array corresponding to the red pixel array. That is, L1, R1, L2, R2, L3, R3, L4, R4, L5, R5, L6, R6, L7, R7, L8, R8, L9, R9 are arranged in sequence to generate a full-size phase array. And the size of the full-size phase array is equivalent to the size of 6×3 pixels arranged in the array. Here, the size of a pixel refers to the area size of a pixel, which is related to the length and width of the pixel.
[0122] Among them, pixel is the smallest photosensitive unit on the photosensitive device (CCD or CMOS) of a digital camera. Among them, CCD is the abbreviation of charge coupled device, and CMOS (Complementary Metal-Oxide-Semiconductor), which can be interpreted as complementary metal oxide semiconductor. Generally, pixels do not have a fixed size, and the size of pixels is related to the size and resolution of the display screen. For example, if the size of the display screen is 4.5 inches and the resolution of the display screen is 1280×720, the length of the display screen is 99.6mm and the width is 56mm. Then the length of a pixel is 99.6mm / 1280=0.0778mm, and the width is also 56mm / 720=0.0778mm. In this example, the size of the 6×3 pixels arranged in the array is: 6×0.0778mm in length and 3×0.0778mm in width. Of course, this application does not limit this. Then, the full-size phase array has a length of 6×0.0778 mm and a width of 3×0.0778 mm. Of course, in other embodiments, the pixel may not be a rectangle with equal length and width, and the pixel may have other heterogeneous structures, which is not limited in the present application.
[0123] Similarly, for other color pixel groups in the pixel array, the above method is also used to generate respective full-size phase arrays. Based on all the full-size phase arrays, the phase information of the pixel array is obtained.
[0124] At this point, the phase array can be input into ISP (Image Signal Processing), and the phase difference of the pixel array can be calculated by ISP based on the phase array. Then, the defocus distance is calculated based on the phase difference, and the DAC code value corresponding to the defocus distance is calculated. Finally, the code value is converted into a driving current through the driver IC of the motor (VCM), and the motor drives the lens to move to a clear position. Thus, focus control is achieved based on the phase difference.
[0125] In an embodiment of the present application, when the light intensity of the current shooting scene is greater than the first preset threshold, a phase array corresponding to the pixel array is output in full-size output mode. The color pixel group in the pixel array is used as the target pixel group, and for each target pixel group, the phase information of the sub-pixel of each pixel in the target pixel group is obtained. Finally, according to the phase information of the sub-pixel of the target pixel, a full-size phase array corresponding to the pixel array is generated. Since only the phase information of the color pixel group is used for phase focusing at this time, the amount of data of the output phase information is reduced, thereby improving the efficiency of phase focusing.
[0126] In one embodiment, when at least two photosensitive elements corresponding to each target pixel in the target pixel group are arranged along a first direction, Fig.12 As shown, if the phase information output mode is the first size output mode, the specific implementation steps of outputting the phase array corresponding to the pixel array according to the phase information output mode include:
[0127] Step 1220, taking at least one of the color pixel group and the full-color pixel group in the pixel array as the target pixel group;
[0128] This embodiment is a specific implementation step of outputting a phase array corresponding to a pixel array according to a first size output mode when the light intensity of the current shooting scene is greater than a second preset threshold and less than or equal to a first preset threshold. The second preset threshold may be 500 lux, which is not limited in this application. That is, at this time, the light intensity is greater than 500 lux and less than or equal to 2000 lux. Fig.12 As shown, at least one of the color pixel group and the full-color pixel group is first determined from the pixel array as the target pixel group for calculating the phase information. Because when the light intensity of the current shooting scene is greater than the second preset threshold and less than or equal to the first preset threshold, that is, in a scene with slightly weak light, the full-color pixels are not easy to saturate in the scene with slightly weak light, so at this time, the phase information of the full-color pixel group can be used to achieve phase focusing (PDAF). And in a scene with slightly weak light, the color pixels can also obtain accurate phase information in the scene with slightly weak light, so at this time, the phase information of the color pixel group can also be used to achieve phase focusing (PDAF). Therefore, when outputting the phase array corresponding to the pixel array according to the first size output mode, the color pixel group can be selected as the target pixel group, the full-color pixel group can be selected as the target pixel group, and the color pixel group and the full-color pixel group can also be selected as the target pixel group, and this application does not limit this.
[0129] Specifically, for the case where the target pixel group is a color pixel group, phase information of some color pixel groups in the pixel array can be used to achieve phase focusing, or some color pixels in some color pixel groups can be used to achieve phase focusing, which is not limited in this application. Similarly, for the case where the target pixel group is a panchromatic pixel group, phase information of some panchromatic pixel groups in the pixel array can be used to achieve phase focusing, or some panchromatic pixels in some panchromatic pixel groups can be used to achieve phase focusing, which is not limited in this application. Similarly, for the case where the target pixel group is a color pixel group and a panchromatic pixel group, phase information of some panchromatic pixel groups and some color pixel groups in the pixel array can be used to achieve phase focusing, or some panchromatic pixels in some panchromatic pixel groups and some color pixels in some color pixel groups can be used to achieve phase focusing, which is not limited in this application.
[0130] Since only the phase information of some pixel groups can be used for phase focusing, or only the phase information of some pixels in some pixel groups can be used for phase focusing, the amount of data of the output phase information is reduced, thereby improving the efficiency of phase focusing.
[0131] Step 1240, for each target pixel group, obtain phase information of multiple groups of two adjacent sub-pixels along a second direction with one sub-pixel as a sliding window step; wherein the second direction is perpendicular to the first direction;
[0132] Step 1260, combining multiple groups of phase information of two adjacent sub-pixels to generate multiple groups of first combined phase information;
[0133] Secondly, for each target pixel group, the phase information of the sub-pixel of each target pixel in the target pixel group is obtained. Wherein, each pixel includes at least two sub-pixels arranged in an array, and each sub-pixel corresponds to a photosensitive element. Assuming that each pixel includes two sub-pixels arranged in an array at this time, the two sub-pixels can be arranged up and down, or left and right, and the present application does not limit this. In the embodiment of the present application, two sub-pixels arranged left and right are selected for explanation. Then, for each target pixel group, the phase information of two adjacent sub-pixels is obtained along the second direction with one sub-pixel as the sliding window step. Then the phase information of the two adjacent sub-pixels is merged to generate the first merged phase information. For example, if the target pixel group is a full-color pixel group in a pixel array, the phase information of two adjacent sub-pixels is obtained along the second direction with one sub-pixel as the sliding window step, and the phase information of 12 pairs of adjacent two sub-pixels can be obtained. Then the phase information of the 12 groups of adjacent two sub-pixels is merged respectively to generate 12 first merged phase information.
[0134] Combination Fig.13As shown, a pixel array may include 2 red pixel groups, 4 green pixel groups, 2 blue pixel groups, and 8 full-color pixel groups. Assuming that all full-color pixel groups in the pixel array are taken as target pixel groups, the phase information of each pixel group is calculated in sequence for the 8 full-color pixel groups included in the pixel array. For example, the phase information of the full-color pixel group is calculated for the full-color pixel group, and the full-color pixel group includes 9 full-color pixels arranged in a 3×3 array, which are numbered as full-color pixel 1, full-color pixel 2, full-color pixel 3, full-color pixel 4, full-color pixel 5, full-color pixel 6, full-color pixel 7, full-color pixel 8, and full-color pixel 9 in sequence. Among them, each pixel includes two sub-pixels arranged left and right, and each sub-pixel corresponds to a photosensitive element. That is, the full-color pixel 1 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L1 and R1 respectively; the full-color pixel 2 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L2 and R2 respectively; the full-color pixel 3 includes two sub-pixels L3 and R3 arranged on the left and right, and the phase information of the two sub-pixels is respectively; the full-color pixel 4 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L4 and R4 respectively; the full-color pixel 5 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L5 and R5 respectively; the full-color pixel 6 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L6 and R6 respectively; the full-color pixel 7 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L7 and R7 respectively; the full-color pixel 8 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L8 and R8 respectively; the full-color pixel 9 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L9 and R9 respectively.
[0135] Finally, phase information of 12 groups of two adjacent sub-pixels is obtained along the second direction with one sub-pixel as the sliding window step. The phase information of the 12 groups of two adjacent sub-pixels are: L1 and L4, L2 and L5, L3 and L6, L4 and L7, L5 and L8, L6 and L9; R1 and R4, R2 and R5, R3 and R6, R4 and R7, R5 and R8, R6 and R9.
[0136] Then, the phase information of the 12 groups of two adjacent sub-pixels are merged respectively to generate 12 first merged phase information. For example, L1 and L4 are merged to generate the first merged phase information L1, L2 and L5 are merged to generate the first merged phase information L2, L3 and L6 are merged to generate the first merged phase information L3, L4 and L7 are merged to generate the first merged phase information L4, L5 and L8 are merged to generate the first merged phase information L5, L6 and L9 are merged to generate the first merged phase information L6; R1 and R4 are merged to generate the first merged phase information R1, R2 and R5 are merged to generate the first merged phase information R2, R3 and R6 are merged to generate the first merged phase information R3, R4 and R7 are merged to generate the first merged phase information R4, R5 and R8 are merged to generate the first merged phase information R5, and R6 and R9 are merged to generate the first merged phase information R6.
[0137] Step 1280: Generate a first-size phase array corresponding to the pixel array according to the multiple sets of first combined phase information. The size of the first-size phase array is the size of 4×2 pixels arranged in the array.
[0138] After the phase information of two adjacent sub-pixels is merged to generate the first merged phase information, a first-size phase array corresponding to the pixel array can be generated according to the first merged phase information. Specifically, if the target pixel group is a full-color pixel group in the pixel array, the phase information of the two adjacent sub-pixels is merged to generate 12 sets of first merged phase information. Then, the 12 sets of first merged phase information can be directly output as the first-size phase array corresponding to the full-color pixel array. That is, L1, R1, L2, R2, L3, R3, L4, R4, L5, R5, L6, R6 are arranged in sequence to generate a first-size phase array. And the size of the first-size phase array is equivalent to the size of 6×2 pixels arranged in the array.
[0139] Of course, the 12 groups of first merged phase information may also be merged or transformed to generate a first-size phase array corresponding to the pixel array. The transformation processing here may be correction and other processing on the 12 groups of first merged phase information, which is not limited in the present application. When merging the 12 groups of first merged phase information, a phase array equivalent to a size of 6×2 pixels may be merged into a phase array of a size of 4×2 pixels. Of course, the present application does not limit the specific size of the merged phase array. Here, the size of a pixel refers to the area size of a pixel, which is related to the length and width of the pixel.
[0140] Among them, a pixel is the smallest photosensitive unit on a digital camera photosensitive device (CCD or CMOS). In general, a pixel does not have a fixed size, and the size of a pixel is related to the size and resolution of the display screen. For example, if the size of the display screen is 4.5 inches and the resolution of the display screen is 1280×720, the length of the display screen is 99.6 mm and the width is 56 mm. The length of a pixel is 99.6 mm / 1280=0.0778 mm, and the width is also 56 mm / 720=0.0778 mm. In this example, the size of the 4×2 pixels arranged in the array is: 4×0.0778 mm in length and 2×0.0778 mm in width. Of course, this application does not limit this. Then, the size of the full-size phase array is 4×0.0778 mm in length and 2×0.0778 mm in width. Of course, in other embodiments, the pixel may not be a rectangle with equal length and width, and the pixel may also have other heterogeneous structures, which this application does not limit.
[0141] Similarly, for other full-color pixel groups in the pixel array, the above method is also used to generate respective first-size phase arrays. Based on all first-size phase arrays, the phase information of the pixel array is obtained.
[0142] At this time, the phase array can be input into the ISP, and the phase difference of the pixel array can be calculated by the ISP based on the phase array. Then, the defocus distance is calculated based on the phase difference, and the DAC code value corresponding to the defocus distance is calculated. Finally, the code value is converted into a driving current through the driver IC of the motor (VCM), and the motor drives the lens to move to a clear position. Thus, focus control is achieved based on the phase difference.
[0143] In an embodiment of the present application, when the light intensity of the current shooting scene is greater than the second preset threshold and less than or equal to the first preset threshold, because the light intensity at this time is slightly weak, the phase information collected by the color pixel group or the full-color pixel group is not very accurate, and some color pixel groups or some full-color pixel groups may not collect phase information. Therefore, at least one of the color pixel group or full-color pixel group in the pixel array is used as the target pixel group, and for each target pixel group, the first size output mode is used to merge the phase information of the sub-pixels to a certain extent, thereby improving the accuracy of the output phase information and improving the signal-to-noise ratio of the phase information. Finally, phase focusing is performed based on the first size phase array corresponding to the pixel array, so as to improve the accuracy of focusing.
[0144] exist Fig.12 Based on the embodiment shown, in one embodiment, step 1280, generating a first-size phase array corresponding to the pixel array according to multiple sets of first combined phase information, includes:
[0145] Merging again multiple groups of two adjacent first combined phase information to generate target phase information; wherein the sub-pixels used to generate the two adjacent first combined phase information are located at the same position in the target pixel;
[0146] A phase array of a first size of a pixel array in a first direction is generated according to the target phase information.
[0147] Combination Fig.13 As shown, for the full-color pixel group, two adjacent first merged phase information are determined from the first merged phase information. Specifically, it is determined whether the sub-pixels used to generate the first merged phase information are in the same position in the pixel; if so, the two first merged phase information are determined to be two adjacent first merged phase information. Multiple groups of two adjacent first merged phase information are merged again to generate target phase information. The target phase information is output to generate a first-size phase array of the pixel array in the first direction.
[0148] Specifically, two adjacent first merged phase information are determined from the first merged phase information L1, the first merged phase information L2, the first merged phase information L3, the first merged phase information L4, the first merged phase information L5, and the first merged phase information L6. Among them, the sub-pixels used to generate the first merged phase information L1 are the sub-pixels of the left half of the full-color pixel 1 and the full-color pixel 4, and the sub-pixels used to generate the first merged phase information L2 are the sub-pixels of the left half of the full-color pixel 2 and the full-color pixel 5. And it is determined that the sub-pixels of the left half of the color pixel 1 and the full-color pixel 4, and the sub-pixels of the left half of the full-color pixel 2 and the full-color pixel 5 are in the same position (all on the left) in their respective pixels. Therefore, it is determined that the first merged phase information L1 and the first merged phase information L2 are two adjacent first merged phase information. Similarly, it is determined that the first merged phase information L2 and the first merged phase information L3, the first merged phase information L4 and the first merged phase information L5, and the first merged phase information L5 and the first merged phase information L6 are all two adjacent first merged phase information. Similarly, it is determined that the first combined phase information R1 and the first combined phase information R2, the first combined phase information R2 and the first combined phase information R3, the first combined phase information 44 and the first combined phase information R5, and the first combined phase information R5 and the first combined phase information R6 are all two adjacent first combined phase information.
[0149] Merge the two adjacent first merged phase information again to generate the target phase information. That is, merge the first merged phase information L1 and the first merged phase information L2 again to generate the target phase information. Similarly, merge the first merged phase information L2 and the first merged phase information L3 again to generate the target phase information; merge the first merged phase information L4 and the first merged phase information L5 again to generate the target phase information; merge the first merged phase information L5 and the first merged phase information L6 again to generate the target phase information. Similarly, merge the first merged phase information R1 and the first merged phase information R2 again to generate the target phase information; merge the first merged phase information R2 and the first merged phase information R3 again to generate the target phase information; merge the first merged phase information R4 and the first merged phase information R5 again to generate the target phase information; merge the first merged phase information R5 and the first merged phase information R6 again to generate the target phase information.
[0150] All target phase information is outputted to generate a first-size phase array of the pixel array in the first direction.
[0151] In an embodiment of the present application, when the light intensity of the current shooting scene is greater than the second preset threshold and less than or equal to the first preset threshold, because the light intensity at this time is slightly weak, the phase information collected by the color pixel group or the full-color pixel group is not very accurate, and some color pixel groups or some full-color pixel groups may not collect phase information. Therefore, at least one of the color pixel group or full-color pixel group in the pixel array is used as the target pixel group, and for each target pixel group, the first size output mode is used to merge the phase information of the sub-pixel twice, so as to improve the accuracy of the output phase information and improve the signal-to-noise ratio of the phase information. Finally, phase focusing is performed based on the first size phase array corresponding to the pixel array, so as to improve the accuracy of focusing.
[0152] Continuing from the previous embodiment, if the target pixel group includes a color pixel group and a full-color pixel group, generating a first-size phase array of the pixel array in the first direction according to the target phase information includes:
[0153] Determine a first phase weight corresponding to the color pixel group and a second phase weight corresponding to the panchromatic pixel group according to the light intensity of the current shooting scene; wherein the first phase weight corresponding to the color pixel group is different under different light intensities, and the second phase weight corresponding to the panchromatic pixel group is different under different light intensities;
[0154] A first-size phase array of the pixel array in a first direction is generated based on the target phase information and the first phase weight of the color pixel group and the target phase information and the second phase weight of the panchromatic pixel group.
[0155] Specifically, in a scenario where the light intensity of the current shooting scene is greater than the second preset threshold and less than or equal to the first preset threshold, and the determined target pixel group includes a color pixel group and a panchromatic pixel group, then, when generating a first-size phase array based on the phase information of the target pixel group, the weights between different pixel groups can be considered. Among them, the first phase weight corresponding to the color pixel group and the second phase weight corresponding to the panchromatic pixel group can be determined according to the light intensity of the current shooting scene. Specifically, the closer the light intensity of the current shooting scene is to the second preset threshold, the smaller the first phase weight corresponding to the color pixel group is at this time, and the larger the second phase weight corresponding to the panchromatic pixel group is. Because the light intensity is relatively small in a scenario where the light intensity is greater than the second preset threshold and less than or equal to the first preset threshold, the larger the second phase weight corresponding to the panchromatic pixel group is, the more accurate the phase information obtained is. As the light intensity increases, the closer the light intensity of the current shooting scene is to the first preset threshold, the larger the first phase weight corresponding to the color pixel group is at this time, and the smaller the second phase weight corresponding to the panchromatic pixel group is. Because the light intensity is relatively large in the scenario where it is greater than the second preset threshold and less than or equal to the first preset threshold, the larger the first phase weight corresponding to the color pixel group, the more comprehensive and accurate the phase information obtained. Among them, the first phase weight corresponding to the color pixel group is different under different light intensities, and the second phase weight corresponding to the full-color pixel group is different under different light intensities. For example, when the light intensity of the current shooting scene is 2000lux, the first phase weight corresponding to the color pixel group is determined to be 40%, wherein the phase weight of the green pixel group is 20%, the phase weight of the red pixel group is 10%, and the phase weight of the blue pixel group is 10%. And the second phase weight corresponding to the full-color pixel group is determined to be 60%, which is not limited in this application.
[0156] Then, based on the target phase information and the first phase weight of the color pixel group, the target phase information and the second phase weight of the full-color pixel group, a first-size phase array of the pixel array in the first direction can be generated. For example, for the pixel array, based on the target phase information and the phase weight of 10% of the first red pixel group, the target phase information and the phase weight of 10% of the second red pixel group, the target phase information and the phase weight of 10% of the first blue pixel group, the target phase information and the phase weight of 10% of the second blue pixel group, and the target phase information and the phase weight of 20% of each green pixel group, and the target phase information and the phase weight of 60% of each full-color pixel group, the phase information of the pixel array in the first direction is calculated by summing up, and the first-size phase array is obtained.
[0157] In an embodiment of the present application, when performing phase focusing, if it is determined that the target pixel group includes a color pixel group and a full-color pixel group, a first-size phase array of the pixel array can be generated based on the target phase information of the color pixel group and its first phase weight, and the target phase information of the full-color pixel group and its second phase weight. In this way, based on the target phase information of the color pixel group and the full-color pixel group, a first-size phase array of the pixel array is jointly generated, which can improve the comprehensiveness of the phase information. At the same time, the phase weights of the target phase information of the color pixel group and the full-color pixel group are different under different light intensities. In this way, the accuracy of the phase information can be improved by adjusting the weight size under different light intensities.
[0158] In the foregoing embodiment, it is described that the pixel array may be an RGBW pixel array, including a plurality of minimum repeating units 241, the minimum repeating unit 241 includes a plurality of pixel groups 242, and the plurality of pixel groups 242 include a full-color pixel group 243 and a color pixel group 244. Each full-color pixel group 243 includes 9 full-color pixels 2431, and each color pixel group 244 includes 9 color pixels 2441. Each full-color pixel 2431 includes 2 sub-pixels arranged in an array, and each color pixel 2441 includes 2 sub-pixels arranged in an array.
[0159] In this embodiment, when the pixel array is an RGBW pixel array, the phase information output mode further includes a second size output mode and a third size output mode; wherein the size of the phase array in the first size output mode is greater than the size of the phase array in the second size output mode; and the size of the phase array in the second size output mode is greater than the size of the phase array in the third size output mode.
[0160] Combination Fig. 9 As shown, step 824, determining a phase information output mode adapted to the light intensity of the current shooting scene according to the target light intensity range, includes:
[0161] Step 824c, if the light intensity of the current shooting scene is greater than the third preset threshold and less than or equal to the second preset threshold, determine that the phase information output mode adapted to the light intensity of the current shooting scene is the second size output mode;
[0162] Step 824d, if the light intensity of the current shooting scene is less than or equal to the third preset threshold, determine that the phase information output mode adapted to the light intensity of the current shooting scene is the third size output mode; the second preset threshold is greater than the third preset threshold.
[0163] Specifically, if one of the light intensity ranges is greater than the third preset threshold and less than or equal to the second preset threshold, the phase information output mode corresponding to the light intensity range is the second size output mode. If it is determined that the light intensity of the current shooting scene is greater than the third preset threshold and less than or equal to the second preset threshold, the light intensity of the current shooting scene falls within the light intensity range. That is, the phase information output mode adapted to the light intensity of the current shooting scene is determined to be the second size output mode. Among them, the third preset threshold can be 50lux, which is not limited in this application. That is, it is at dusk or in an environment where the light intensity is greater than 50lux and less than or equal to 500lux.
[0164] Among them, the second size output mode is used to output the phase array, that is, the original phase information of the pixel array is combined and output to generate the phase array of the pixel array. In other words, the size of the pixel array is larger than the size of the phase array of the pixel array. For example, if the size of the pixel array is 12×12, the size of the phase array of each target pixel group in the pixel array is 2×1, and the size of the phase array is not limited in this application.
[0165] If one of the light intensity ranges is less than or equal to the third preset threshold, the phase information output mode corresponding to the light intensity range is the third size output mode. If it is determined that the light intensity of the current shooting scene is less than or equal to the third preset threshold, the light intensity of the current shooting scene falls within the light intensity range. That is, the phase information output mode adapted to the light intensity of the current shooting scene is determined to be the third size output mode. Among them, the third size output mode is used to output the phase array, that is, the original phase information of the pixel array is merged and output to generate the phase array of the pixel array. In other words, the size of the pixel array is larger than the size of the phase array of the pixel array. For example, if the size of the pixel array is 12×12, the size of the phase array of the pixel array is 4×2, and the size of the pixel array and the size of the phase array are not limited in this application.
[0166] In the embodiment of the present application, since the size of the phase array in the second size output mode is larger than the size of the phase array in the third size output mode, if the light intensity of the current shooting scene is larger than the third preset threshold value, and smaller than or equal to the second preset threshold value, the phase information output mode adapted to the light intensity of the current shooting scene is determined to be the second size output mode. If the light intensity of the current shooting scene is smaller than or equal to the third preset threshold value, the phase information output mode adapted to the light intensity of the current shooting scene is determined to be the third size output mode. That is, if the light intensity of the current shooting scene is large, the second size output mode is used to output a phase array of the same size as the pixel array, and if the light intensity of the current shooting scene is second, the third size output mode is used to output a phase array smaller than the pixel array size. That is, when the light intensity of the current shooting scene is second, the signal-to-noise ratio of the phase information is improved by reducing the phase array.
[0167] In one embodiment, at least two photosensitive elements corresponding to each target pixel in the target pixel group are arranged along the first direction; if the phase information output mode is the second size output mode, such as Fig.14 As shown, according to the phase information output mode, a phase array corresponding to the pixel array is output, including:
[0168] Step 1420, using the color pixel group and the full-color pixel group in the pixel array as the target pixel group, or using the full-color pixel group as the target pixel group;
[0169] This embodiment provides specific implementation steps for outputting a phase array corresponding to a pixel array according to a second size output mode when the light intensity of the current shooting scene is greater than a third preset threshold and less than or equal to a second preset threshold. Fig.14 As shown, first, the color pixel group and the full-color pixel group in the pixel array are used as the target pixel group, or the full-color pixel group is used as the target pixel group for calculating the phase information. Because when the light intensity of the current shooting scene is greater than the third preset threshold and less than or equal to the second preset threshold, that is, in a scene with weaker light, the full-color pixel can receive more light information, so at this time, the phase information of the full-color pixel group can be used to achieve phase focusing (PDAF). And in a scene with weaker light, the color pixels can also assist the full-color pixels in a scene with weaker light to obtain accurate phase information, so at this time, the phase information of the color pixel group and the full-color pixel group can also be used to achieve phase focusing (PDAF), or only the phase information of the full-color pixel group can be used to achieve phase focusing (PDAF). Therefore, when outputting the phase array corresponding to the pixel array according to the second size output mode, the color pixel group and the full-color pixel group can be selected as the target pixel group, or the full-color pixel group can be selected as the target pixel group. This application does not limit this.
[0170] Specifically, for the case where the target pixel group is a full-color pixel group, phase focusing can be achieved using the phase information of some full-color pixel groups in the pixel array, or some full-color pixels in some full-color pixel groups can be used to achieve phase focusing, and this application does not limit this. Similarly, for the case where the target pixel group is a color pixel group and a full-color pixel group, phase focusing can be achieved using the phase information of some full-color pixel groups and some color pixel groups in the pixel array, or some full-color pixels in some full-color pixel groups and some color pixels in some color pixel groups can be used to achieve phase focusing, and this application does not limit this.
[0171] Since only the phase information of some pixel groups can be used for phase focusing, or only the phase information of some pixels in some pixel groups can be used for phase focusing, the amount of data of the output phase information is reduced, thereby improving the efficiency of phase focusing.
[0172] Step 1440, for each target pixel group, acquiring phase information of multiple groups of three adjacent sub-pixels along the second direction;
[0173] Step 1460, combining phase information of multiple groups of three adjacent sub-pixels to generate multiple groups of second combined phase information;
[0174] Secondly, for each target pixel group, the phase information of the sub-pixel of each target pixel in the target pixel group is obtained. Wherein, each pixel includes at least two sub-pixels arranged in an array, and each sub-pixel corresponds to a photosensitive element. Assuming that each pixel includes two sub-pixels arranged in an array at this time, the two sub-pixels can be arranged up and down, or left and right, and the present application does not limit this. In the embodiment of the present application, two sub-pixels arranged left and right are selected for illustration, then, for each target pixel group, the phase information of multiple groups of three adjacent sub-pixels is obtained along the second direction. The phase information of the two adjacent sub-pixels is then merged to generate the first merged phase information. For example, if the target pixel group is a full-color pixel group in a pixel array, the phase information of multiple groups of three adjacent sub-pixels is obtained along the second direction, and the phase information of 6 groups of three adjacent sub-pixels can be obtained. The phase information of these 6 groups of three adjacent sub-pixels is then merged respectively to generate 6 groups of first merged phase information.
[0175] Combination Fig.15As shown, a pixel array may include 2 red pixel groups, 4 green pixel groups, 2 blue pixel groups, and 8 full-color pixel groups. Assuming that all full-color pixel groups in the pixel array are taken as target pixel groups, the phase information of each pixel group is calculated in sequence for the 8 full-color pixel groups included in the pixel array. For example, the phase information of the full-color pixel group is calculated for the full-color pixel group, and the full-color pixel group includes 9 full-color pixels arranged in a 3×3 array, which are numbered as full-color pixel 1, full-color pixel 2, full-color pixel 3, full-color pixel 4, full-color pixel 5, full-color pixel 6, full-color pixel 7, full-color pixel 8, and full-color pixel 9 in sequence. Among them, each pixel includes two sub-pixels arranged left and right, and each sub-pixel corresponds to a photosensitive element. That is, the full-color pixel 1 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L1 and R1 respectively; the full-color pixel 2 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L2 and R2 respectively; the full-color pixel 3 includes two sub-pixels L3 and R3 arranged on the left and right, and the phase information of the two sub-pixels is respectively; the full-color pixel 4 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L4 and R4 respectively; the full-color pixel 5 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L5 and R5 respectively; the full-color pixel 6 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L6 and R6 respectively; the full-color pixel 7 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L7 and R7 respectively; the full-color pixel 8 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L8 and R8 respectively; the full-color pixel 9 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L9 and R9 respectively.
[0176] Finally, phase information of multiple groups of three adjacent sub-pixels is obtained along the second direction. The phase information of the six groups of three adjacent sub-pixels are: L1, L4 and L7, L2, L5 and L8, L3, L6 and L9; R1, R4 and R7, R2, R5 and R8, R3, R6 and R9.
[0177] Then, the phase information of the six groups of three adjacent sub-pixels are merged respectively to generate six groups of second merged phase information. For example, L1, L4 and L7 are merged to generate the second merged phase information L1, L2, L5 and L8 are merged to generate the second merged phase information L2, and L3, L6 and L9 are merged to generate the second merged phase information L3. R1, R4 and R7 are merged to generate the second merged phase information R1, R2, R5 and R8 are merged to generate the second merged phase information R2, and R3, R6 and R9 are merged to generate the second merged phase information R3.
[0178] Step 1480: Generate a second-sized phase array corresponding to the pixel array according to the multiple sets of second combined phase information, where the size of the second-sized phase array is 2×1 pixels.
[0179] After merging the phase information of multiple groups of three adjacent sub-pixels to generate multiple groups of second merged phase information, a second-size phase array corresponding to the pixel array can be generated based on the multiple groups of second merged phase information. Specifically, if the target pixel group is a full-color pixel group in the pixel array, the phase information of multiple groups of three adjacent sub-pixels is merged to generate 6 groups of second merged phase information. Then, the 6 groups of first merged phase information can be directly output as the first-size phase array corresponding to the full-color pixel array. That is, L1, R1, L2, R2, L3, and R3 are arranged in sequence to generate a first-size phase array. And the size of the first-size phase array is equivalent to the size of 6×1 pixels arranged in the array.
[0180] Of course, the six groups of second combined phase information may also be combined or transformed to generate a second-size phase array corresponding to the pixel array. The transformation processing here may be correction and other processing on the six groups of second combined phase information, which is not limited in the present application. When the six groups of second combined phase information are combined, a phase array equivalent to a size of 6×1 pixels may be combined into a phase array of a size of 2×1 pixels. Of course, the present application does not limit the specific size of the combined phase array. Here, the size of a pixel refers to the area size of a pixel, which is related to the length and width of the pixel.
[0181] Among them, a pixel is the smallest photosensitive unit on a digital camera photosensitive device (CCD or CMOS). In general, a pixel does not have a fixed size, and the size of a pixel is related to the size and resolution of the display screen. For example, if the size of the display screen is 4.5 inches and the resolution of the display screen is 1280×720, the length of the display screen is 99.6 mm and the width is 56 mm. The length of a pixel is 99.6 mm / 1280=0.0778 mm, and the width is also 56 mm / 720=0.0778 mm. In this example, the size of the 2×1 pixels arranged in the array is: 2×0.0778 mm in length and 1×0.0778 mm in width. Of course, this application does not limit this. Then, the size of the full-size phase array is 2×0.0778 mm in length and 1×0.0778 mm in width. Of course, in other embodiments, the pixel may not be a rectangle with equal length and width, and the pixel may also have other heterogeneous structures, which this application does not limit.
[0182] Similarly, for other full-color pixel groups in the pixel array, the above method is also used to generate respective second-size phase arrays. Based on all second-size phase arrays, the phase information of the pixel array is obtained.
[0183] At this time, the phase array can be input into the ISP, and the phase difference of the pixel array can be calculated by the ISP based on the phase array. Then, the defocus distance is calculated based on the phase difference, and the DAC code value corresponding to the defocus distance is calculated. Finally, the code value is converted into a driving current through the driver IC of the motor (VCM), and the motor drives the lens to move to a clear position. Thus, focus control is achieved based on the phase difference.
[0184] In the embodiment of the present application, when the light intensity of the current shooting scene is greater than the third preset threshold and less than or equal to the second preset threshold, because the light intensity at this time is weaker, and the panchromatic pixel can receive more light information, the phase information of the panchromatic pixel group can be used to implement phase focusing (PDAF). In the scene with weaker light, the color pixel can also assist the panchromatic pixel in the scene with weaker light to obtain accurate phase information, so the phase information of the color pixel group and the panchromatic pixel group can also be used to implement phase focusing (PDAF), or only the phase information of the panchromatic pixel group can be used to implement phase focusing (PDAF). Therefore, the color pixel group and the panchromatic pixel group or the panchromatic pixel group in the pixel array are used as the target pixel group, and for each target pixel group, the second size output mode is used to merge the phase information of the sub-pixels to a certain extent, so as to improve the accuracy of the output phase information and improve the signal-to-noise ratio of the phase information. Finally, phase focusing is performed based on the second size phase array corresponding to the pixel array, so as to improve the accuracy of focusing.
[0185] In one embodiment, generating a second-size phase array corresponding to the pixel array according to the second combined phase information includes:
[0186] Merging three adjacent second combined phase information again to generate target phase information; wherein the sub-pixels used to generate the three adjacent second combined phase information are located at the same position in the target pixel;
[0187] A phase array of a second size of the pixel array in the first direction is generated according to the target phase information.
[0188] Combination Fig.15As shown, for the full-color pixel group, three adjacent second merged phase information are determined from the second merged phase information. Specifically, it is determined whether the sub-pixels used to generate the second merged phase information are in the same position in the pixel; if so, the three second merged phase information are determined to be three adjacent second merged phase information. The three adjacent second merged phase information are merged again to generate the target phase information. The target phase information is output to generate a second size phase array of the pixel array in the first direction.
[0189] Specifically, three adjacent second merged phase information are determined from the second merged phase information L1, the second merged phase information L2, the second merged phase information L3, the second merged phase information R1, the second merged phase information R2, and the second merged phase information R3. Among them, the sub-pixels used to generate the second merged phase information L1 are the sub-pixels of the left half of the full-color pixel 1, the full-color pixel 4, and the full-color pixel 7, the sub-pixels used to generate the second merged phase information L2 are the sub-pixels of the left half of the full-color pixel 2, the full-color pixel 5, and the full-color pixel 8, and the sub-pixels used to generate the second merged phase information L3 are the sub-pixels of the left half of the full-color pixel 3, the full-color pixel 6, and the full-color pixel 9. And it is determined that these sub-pixels are all in the same position (all on the left) in their respective pixels. Therefore, the second merged phase information L1, the second merged phase information L2, and the second merged phase information L3 are determined to be three adjacent second merged phase information. Similarly, it is determined that the second combined phase information R1, the second combined phase information R2, and the second combined phase information R3 are all three adjacent second combined phase information.
[0190] The three adjacent second merged phase information are merged again to generate the target phase information. That is, the second merged phase information L1, the second merged phase information L2 and the second merged phase information L3 are merged again to generate the target phase information. Similarly, the second merged phase information R1, the second merged phase information R2 and the second merged phase information R3 are merged again to generate the target phase information.
[0191] All target phase information is outputted to generate a second-size phase array of the pixel array in the first direction.
[0192] In the embodiment of the present application, when the light intensity of the current shooting scene is greater than the third preset threshold and less than or equal to the second preset threshold, because the light intensity at this time is weaker, the full-color pixel can receive more light information, so the color pixel group and the full-color pixel group or the full-color pixel group in the pixel array are used as the target pixel group, and for each target pixel group, the second size output mode is used to merge the phase information of the sub-pixel twice, so as to improve the accuracy of the output phase information and improve the signal-to-noise ratio of the phase information. Finally, phase focusing is performed based on the second size phase array corresponding to the pixel array, so as to improve the accuracy of focusing.
[0193] In one embodiment, if the target pixel group includes a color pixel group and a panchromatic pixel group, generating a second size phase array of the pixel array in the first direction according to the target phase information includes:
[0194] Determine a third phase weight corresponding to the color pixel group and a fourth phase weight corresponding to the panchromatic pixel group according to the light intensity of the current shooting scene; wherein the third phase weight corresponding to the color pixel group is different under different light intensities, and the fourth phase weight corresponding to the panchromatic pixel group is different under different light intensities;
[0195] A phase array of a second size of the pixel array in the second direction is generated based on the target phase information and the third phase weight of the color pixel group and the target phase information and the fourth phase weight of the panchromatic pixel group.
[0196] Specifically, in a scenario where the light intensity of the current shooting scene is greater than the third preset threshold and less than or equal to the second preset threshold, and the determined target pixel group includes a color pixel group and a panchromatic pixel group, then, when generating a second-size phase array based on the phase information of the target pixel group, the weights between different pixel groups can be considered. Among them, the third phase weight corresponding to the color pixel group and the fourth phase weight corresponding to the panchromatic pixel group can be determined according to the light intensity of the current shooting scene. Specifically, the closer the light intensity of the current shooting scene is to the third preset threshold, the smaller the third phase weight corresponding to the color pixel group is at this time, and the larger the fourth phase weight corresponding to the panchromatic pixel group is. Because the light intensity is relatively small in a scenario where the light intensity is greater than the third preset threshold and less than or equal to the second preset threshold, the larger the fourth phase weight corresponding to the panchromatic pixel group is, the more accurate the phase information obtained is. As the light intensity increases, the closer the light intensity of the current shooting scene is to the second preset threshold, the larger the third phase weight corresponding to the color pixel group is at this time, and the smaller the fourth phase weight corresponding to the panchromatic pixel group is. Because the light intensity is relatively large in the scenario where it is greater than the third preset threshold and less than or equal to the second preset threshold, the larger the third phase weight corresponding to the color pixel group, the more comprehensive and accurate the phase information obtained. Among them, the third phase weight corresponding to the color pixel group is different under different light intensities, and the fourth phase weight corresponding to the full-color pixel group is different under different light intensities. For example, when the light intensity of the current shooting scene is 500lux, the third phase weight corresponding to the color pixel group is determined to be 40%, wherein the phase weight of the green pixel group is 20%, the phase weight of the red pixel group is 10%, and the phase weight of the blue pixel group is 10%. And the fourth phase weight corresponding to the full-color pixel group is determined to be 60%, which is not limited in this application.
[0197] Then, based on the target phase information and the third phase weight of the color pixel group, the target phase information and the fourth phase weight of the full-color pixel group, a second-size phase array of the pixel array in the first direction can be generated. For example, for the pixel array, based on the target phase information and the phase weight of 10% of the first red pixel group, the target phase information and the phase weight of 10% of the second red pixel group, the target phase information and the phase weight of 10% of the first blue pixel group, the target phase information and the phase weight of 10% of the second blue pixel group, the target phase information and the phase weight of 20% of each green pixel group, and the target phase information and the phase weight of 60% of each full-color pixel group, the phase information of the pixel array in the first direction is calculated by summing up, and the second-size phase array is obtained.
[0198] In an embodiment of the present application, when performing phase focusing, if it is determined that the target pixel group includes a color pixel group and a full-color pixel group, a second-size phase array of the pixel array can be generated based on the target phase information of the color pixel group and its third phase weight, and the target phase information of the full-color pixel group and its fourth phase weight. In this way, based on the target phase information of the color pixel group and the full-color pixel group, a second-size phase array of the pixel array is jointly generated, which can improve the comprehensiveness of the phase information. At the same time, the phase weights of the target phase information of the color pixel group and the full-color pixel group are different under different light intensities. In this way, the accuracy of the phase information can be improved by adjusting the weight size under different light intensities.
[0199] In one embodiment, at least two photosensitive elements corresponding to each target pixel in the target pixel group are arranged along a first direction; if the light intensity of the current shooting scene is less than or equal to a third preset threshold, a phase array corresponding to the pixel array is output according to a phase information output mode, including:
[0200] Two adjacent full-color pixel groups along a second diagonal direction in the pixel array are used as target pixel groups;
[0201] This embodiment is a specific implementation step of outputting a phase array corresponding to a pixel array according to a third size output mode when the light intensity of the current shooting scene is less than or equal to a third preset threshold. In this case, it is a dark night or an environment with light intensity less than or equal to 50 lux. Fig.16 As shown, first, two panchromatic pixel groups adjacent to each other along the second diagonal direction are determined from the pixel array as target pixel groups for calculating phase information. Because when the light intensity of the current shooting scene is less than or equal to the third preset threshold, that is, in a scene with extremely dim light, the panchromatic pixels can capture more light information in a scene with extremely dim light, so at this time, the phase information of the panchromatic pixel group can be used to achieve phase focusing (PDAF). Therefore, when outputting the phase array corresponding to the pixel array in accordance with the third size output mode, the panchromatic pixel group can be selected as the target pixel group.
[0202] Specifically, when the target pixel group is a full-color pixel group, phase focusing can be achieved using the phase information of some full-color pixel groups in the pixel array, or phase focusing can be achieved using some full-color pixels in some full-color pixel groups. This application does not limit this.
[0203] Since only the phase information of some pixel groups can be used for phase focusing, or only the phase information of some pixels in some pixel groups can be used for phase focusing, the amount of data of the output phase information is reduced, thereby improving the efficiency of phase focusing.
[0204] For each full-color pixel group in the target pixel group, phase information of three sub-pixels of adjacent groups are acquired from the full-color pixel group along a second direction; wherein the second direction is perpendicular to the first direction;
[0205] Combining phase information of multiple groups of three adjacent sub-pixels to generate multiple groups of third combined phase information;
[0206] Secondly, for each target pixel group, the phase information of the sub-pixel of each target pixel in the target pixel group is obtained. Wherein, each pixel includes at least two sub-pixels arranged in an array, and each sub-pixel corresponds to a photosensitive element. Assuming that each pixel includes two sub-pixels arranged in an array at this time, the two sub-pixels can be arranged up and down, or left and right, and the present application does not limit this. In the embodiment of the present application, two sub-pixels arranged left and right are selected for explanation, then, for each target pixel group, the phase information of multiple groups of three adjacent sub-pixels is obtained along the second direction. Then, the phase information of multiple groups of three adjacent sub-pixels is merged to generate a third merged phase information. For example, the target pixel group is two full-color pixel groups adjacent to each other along the second diagonal direction in the pixel array, then the phase information of multiple groups of three adjacent sub-pixels is obtained along the second direction, and the phase information of 12 groups of three adjacent sub-pixels can be obtained. Then, the phase information of these 12 groups of three adjacent sub-pixels is merged respectively to generate 12 groups of third merged phase information.
[0207] Combination Fig.16As shown, a pixel array may include 2 red pixel groups, 4 green pixel groups, 2 blue pixel groups, and 8 full-color pixel groups. Assuming that all full-color pixel groups in the pixel array are taken as target pixel groups, the phase information of each pixel group is calculated in sequence for the 8 full-color pixel groups included in the pixel array. For example, the phase information of the full-color pixel group is calculated for the full-color pixel group, and the full-color pixel group includes 9 full-color pixels arranged in a 3×3 array, which are numbered as full-color pixel 1, full-color pixel 2, full-color pixel 3, full-color pixel 4, full-color pixel 5, full-color pixel 6, full-color pixel 7, full-color pixel 8, and full-color pixel 9 in sequence. Among them, each pixel includes two sub-pixels arranged left and right, and each sub-pixel corresponds to a photosensitive element. That is, the full-color pixel 1 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L1 and R1 respectively; the full-color pixel 2 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L2 and R2 respectively; the full-color pixel 3 includes two sub-pixels L3 and R3 arranged on the left and right, and the phase information of the two sub-pixels is respectively; the full-color pixel 4 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L4 and R4 respectively; the full-color pixel 5 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L5 and R5 respectively; the full-color pixel 6 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L6 and R6 respectively; the full-color pixel 7 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L7 and R7 respectively; the full-color pixel 8 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L8 and R8 respectively; the full-color pixel 9 includes two sub-pixels arranged on the left and right, and the phase information of the two sub-pixels is L9 and R9 respectively.
[0208] Finally, phase information of multiple groups of three adjacent sub-pixels is obtained along the second direction. The phase information of the 12 groups of three adjacent sub-pixels are: L1, L4 and L7, L2, L5 and L8, L3, L6 and L9 in the first full-color pixel group; R1, R4 and R7, R2, R5 and R8, R3, R6 and R9; L1, L4 and L7, L2, L5 and L8, L3, L6 and L9 in the second full-color pixel group; R1, R4 and R7, R2, R5 and R8, R3, R6 and R9.
[0209] Then, the phase information of the 12 groups of three adjacent sub-pixels are merged respectively to generate 12 groups of third merged phase information. For example, for the first full-color pixel group, L1, L4 and L7 in the first full-color pixel group are merged to generate the third merged phase information L1, L2, L5 and L8 are merged to generate the third merged phase information L2, and L3, L6 and L9 are merged to generate the third merged phase information L3. R1, R4 and R7 are merged to generate the third merged phase information R1, R2, R5 and R8 are merged to generate the third merged phase information R2, and R3, R6 and R9 are merged to generate the third merged phase information R3. Similarly, for the second full-color pixel group, L1, L4 and L7 in the first full-color pixel group are merged to generate the third merged phase information L1, L2, L5 and L8 are merged to generate the third merged phase information L2, and L3, L6 and L9 are merged to generate the third merged phase information L3. R1, R4 and R7 are combined to generate the third combined phase information R1, R2, R5 and R8 are combined to generate the third combined phase information R2, and R3, R6 and R9 are combined to generate the third combined phase information R3.
[0210] A phase array of a third size corresponding to the pixel array is generated according to the multiple sets of third combined phase information, and the size of the phase array of the third size is the size of 2×1 pixels arranged in the array.
[0211] After the phase information of three adjacent sub-pixels is merged to generate the third merged phase information, a third-size phase array corresponding to the pixel array can be generated according to the third merged phase information. Specifically, if the target pixel group is two adjacent full-color pixel groups along the second diagonal direction in the pixel array, the phase information of the three adjacent sub-pixels is merged to generate 12 sets of third merged phase information. Then, the 12 sets of third merged phase information can be directly output as the third-size phase array corresponding to the full-color pixel array. That is, L1, R1, L2, R2, L3, R3 corresponding to the first full-color pixel group and L1, R1, L2, R2, L3, R3 corresponding to the second full-color pixel group are arranged in sequence to generate a third-size phase array. And the size of the third-size phase array is equivalent to the size of 6×2 pixels arranged in the array.
[0212] Of course, the 12 groups of third combined phase information can also be combined or transformed to generate a third size phase array corresponding to the pixel array. The transformation processing here can be correction of the 12 groups of third combined phase information, which is not limited in this application. When the 12 groups of third combined phase information are combined, L1, L2, L3 corresponding to the first full-color pixel group are combined with L1, L2, L3 corresponding to the second full-color pixel group to generate the target phase information on the left, and R1, R2, R3 corresponding to the first full-color pixel group are combined with R1, R2, R3 corresponding to the second full-color pixel group to generate the target phase information on the right. That is, a phase array equivalent to 6×2 pixels is combined into a phase array of 2×1 pixels. Of course, this application does not limit the specific size of the combined phase array. Here, the size of a pixel refers to the area size of a pixel, which is related to the length and width of the pixel.
[0213] Among them, a pixel is the smallest photosensitive unit on a digital camera photosensitive device (CCD or CMOS). In general, a pixel does not have a fixed size, and the size of a pixel is related to the size and resolution of the display screen. For example, if the size of the display screen is 4.5 inches and the resolution of the display screen is 1280×720, the length of the display screen is 99.6 mm and the width is 56 mm. The length of a pixel is 99.6 mm / 1280=0.0778 mm, and the width is also 56 mm / 720=0.0778 mm. In this example, the size of the 2×1 pixels arranged in the array is: 2×0.0778 mm in length and 1×0.0778 mm in width. Of course, this application does not limit this. Then, the size of the full-size phase array is 2×0.0778 mm in length and 1×0.0778 mm in width. Of course, in other embodiments, the pixel may not be a rectangle with equal length and width, and the pixel may also have other heterogeneous structures, which this application does not limit.
[0214] Similarly, for other full-color pixel groups in the pixel array, the above method is also used to generate respective third-size phase arrays. Based on all third-size phase arrays, the phase information of the pixel array is obtained.
[0215] At this time, the phase array can be input into the ISP, and the phase difference of the pixel array can be calculated by the ISP based on the phase array. Then, the defocus distance is calculated based on the phase difference, and the DAC code value corresponding to the defocus distance is calculated. Finally, the code value is converted into a driving current through the driver IC of the motor (VCM), and the motor drives the lens to move to a clear position. Thus, focus control is achieved based on the phase difference.
[0216] In an embodiment of the present application, when the light intensity of the current shooting scene is less than or equal to the third preset threshold, because the light intensity at this time is extremely dim, the phase information collected by the color pixel group is not very accurate, and some color pixel groups may not collect phase information. Therefore, the two full-color pixel groups adjacent to each other along the second diagonal direction in the pixel array are used as target pixel groups, and for these two full-color pixel groups, the third-size output mode is used to merge the phase information of the sub-pixels to improve the accuracy of the output phase information and the signal-to-noise ratio of the phase information. Finally, phase focusing is performed based on the third-size phase array corresponding to the pixel array, so as to improve the focusing accuracy.
[0217] In one embodiment, generating a phase array of a third size corresponding to the pixel array according to the third combined phase information includes:
[0218] The six second combined phase information are combined again to generate target phase information; wherein the sub-pixels used to generate the six second combined phase information are located at the same sub-position in the target pixel;
[0219] A phase array of a third size of the pixel array in the first direction is generated according to the target phase information.
[0220] When merging the 12 groups of third merged phase information, L1, L2, L3 corresponding to the first full-color pixel group are merged with L1, L2, L3 corresponding to the second full-color pixel group to generate the target phase information on the left, and R1, R2, R3 corresponding to the first full-color pixel group are merged with R1, R2, R3 corresponding to the second full-color pixel group to generate the target phase information on the right. That is, the phase array equivalent to 6×2 pixels is merged into a phase array of 2×1 pixels. Of course, the present application does not limit the specific size of the merged phase array.
[0221] All target phase information is outputted to generate a phase array of the third size of the pixel array in the first direction.
[0222] In an embodiment of the present application, when the light intensity of the current shooting scene is less than or equal to the third preset threshold, because the light intensity at this time is extremely dim, the phase information collected by the color pixel group is not very accurate, and some color pixel groups may not collect phase information. Therefore, the two full-color pixel groups adjacent to each other along the second diagonal direction in the pixel array are used as target pixel groups, and for these two full-color pixel groups, the third-size output mode is used to merge the phase information of the sub-pixels to the greatest extent, thereby improving the accuracy of the output phase information and the signal-to-noise ratio of the phase information. Finally, phase focusing is performed based on the third-size phase array corresponding to the pixel array, so as to improve the accuracy of focusing.
[0223] In one embodiment, before outputting the phase array corresponding to the pixel array according to the phase information output mode, the method further includes:
[0224] Determining a target pixel array from a plurality of pixel arrays in the image sensor according to a preset extraction ratio and a preset extraction position of the pixel array for focus control;
[0225] According to the phase information output mode, a phase array corresponding to the pixel array is output, including:
[0226] According to the phase information output mode, a phase array corresponding to the target pixel array is output.
[0227] Specifically, the image sensor has a large area and contains tens of thousands of pixel arrays as the smallest units. If all phase information is extracted from the image sensor for phase focusing, the actual amount of calculation will be too large due to the large amount of phase information data, thus wasting system resources and reducing the image processing speed.
[0228] In order to save system resources and improve the image processing speed, the pixel array for focus control can be extracted from multiple pixel arrays in the image sensor according to a preset extraction ratio and a preset extraction position. For example, extraction can be performed according to a preset extraction ratio of 3%, that is, one pixel array is extracted from 32 pixel arrays as a pixel array for focus control. And the extracted pixel arrays are arranged as the vertices of a hexagon, that is, the extracted pixel arrays constitute a hexagon. In this way, phase information can be evenly acquired. Of course, the present application does not limit the preset extraction ratio and the preset extraction position.
[0229] Then, according to the light intensity of the current shooting scene, a phase information output mode adapted to the light intensity of the current shooting scene can be determined. And for the pixel array used for focus control, according to the phase information output mode, a phase array corresponding to the pixel array is output; wherein the phase array includes the phase information corresponding to the target pixel in the pixel array. Finally, the phase difference of the pixel array is calculated based on the phase array, and focus control is performed according to the phase difference.
[0230] In an embodiment of the present application, a target pixel array is determined from multiple pixel arrays in an image sensor according to a preset extraction ratio and a preset extraction position of a pixel array for focus control. In this way, it is not necessary to use all phase information in the image sensor for focusing, but only the phase information corresponding to the target pixel array is used for focusing, which greatly reduces the amount of data and improves the speed of image processing. At the same time, according to the preset extraction position, the target pixel array is determined from multiple pixel arrays in the image sensor, and the phase information can be obtained more evenly. Ultimately, the accuracy of phase focusing is improved.
[0231] In one embodiment, a focus control method is provided, further comprising:
[0232] A first preset threshold, a second preset threshold and a third preset threshold of light intensity are determined according to the exposure parameter and the size of the pixel.
[0233] Specifically, when determining the threshold of light intensity, it can be determined according to exposure parameters and pixel size, wherein the exposure parameters include shutter speed, lens aperture size and light sensitivity (ISO).
[0234] In an embodiment of the present application, a first preset threshold, a second preset threshold and a third preset threshold of light intensity are determined according to exposure parameters and pixel size, and the light intensity range is divided into four ranges. Thus, in each light intensity range, a phase information output mode corresponding to the light intensity range is adopted, thereby achieving more refined calculation of phase information.
[0235] In one embodiment, Fig.17 As shown, a focus control device 1700 is provided, which is applied to an image sensor, and the device includes:
[0236] The phase information output mode determination module 1720 is used to determine the phase information output mode adapted to the light intensity of the current shooting scene according to the light intensity of the current shooting scene; wherein, in different phase information output modes, the size of the output phase array is different;
[0237] The phase array output module 1740 is used to output a phase array corresponding to the pixel array according to the phase information output mode; wherein the phase array includes phase information corresponding to the target pixel in the pixel array;
[0238] The focus control module 1760 is used to calculate the phase difference of the pixel array based on the phase array, and perform focus control according to the phase difference.
[0239] In one embodiment, the phase information output mode determination module 1720 is further used to determine the target light intensity range to which the light intensity of the current shooting scene belongs; wherein different light intensity ranges correspond to different phase information output modes;
[0240] According to the target light intensity range, a phase information output mode adapted to the light intensity of the current shooting scene is determined.
[0241] In one embodiment, the phase information output mode includes a full-size output mode and a first-size output mode, and the size of the phase array in the full-size output mode is larger than the size of the phase array in the first-size output mode;
[0242] The phase information output mode determination module 1720 is also used to determine that the phase information output mode adapted to the light intensity of the current shooting scene is the full-size output mode if the light intensity of the current shooting scene is greater than a first preset threshold value; if the light intensity of the current shooting scene is greater than a second preset threshold value, and is less than or equal to the first preset threshold value, then determine that the phase information output mode adapted to the light intensity of the current shooting scene is the first-size output mode; the first preset threshold value is greater than the second preset threshold value.
[0243] In one embodiment, Fig.18 As shown, if the phase information output mode is the full-size output mode, the phase array output module 1740 includes:
[0244] The target pixel group determination unit 1742 is used to use the color pixel group in the pixel array as the target pixel group; the target pixel group includes the target pixel;
[0245] A phase information acquisition unit 1744 is used to acquire the phase information of the sub-pixels of the target pixels for each target pixel group;
[0246] The full-size phase array generating unit 1746 is used to generate a full-size phase array corresponding to the pixel array according to the phase information of the sub-pixels of the target pixel; the size of the full-size phase array is the size of 6×3 pixels arranged in the array.
[0247] In one embodiment, at least two photosensitive elements corresponding to each target pixel in the target pixel group are arranged along a first direction; if the phase information output mode is a first size output mode, the phase array output module 1740 includes:
[0248] The target pixel group determination unit is further used to use at least one of the color pixel group and the full-color pixel group in the pixel array as the target pixel group;
[0249] The phase information acquisition unit is further used to acquire phase information of multiple groups of two adjacent sub-pixels along a second direction with one sub-pixel as a sliding window step for each target pixel group; wherein the second direction is perpendicular to the first direction;
[0250] The first-size phase array generating unit is used to merge the phase information of multiple groups of two adjacent sub-pixels to generate multiple groups of first merged phase information; based on the multiple groups of first merged phase information, a first-size phase array corresponding to the pixel array is generated, and the size of the first-size phase array is the size of 4×2 pixels arranged in the array.
[0251] In one embodiment, the first-size phase array generating unit is further used to merge two adjacent first merged phase information again to generate target phase information; wherein the sub-pixels used to generate two adjacent first merged phase information are in the same position in the target pixel; and according to the target phase information, a first-size phase array of the pixel array in the first direction is generated.
[0252] In one embodiment, if the target pixel group includes a color pixel group and a full-color pixel group, the first-size phase array generation unit is further used to determine a first phase weight corresponding to the color pixel group and a second phase weight corresponding to the full-color pixel group according to the light intensity of the current shooting scene; wherein the first phase weight corresponding to the color pixel group is different under different light intensities, and the second phase weight corresponding to the full-color pixel group is different under different light intensities; based on the target phase information and the first phase weight of the color pixel group, and the target phase information and the second phase weight of the full-color pixel group, a first-size phase array of the pixel array in the first direction is generated.
[0253] In one embodiment, the phase information output mode further includes a second size output mode and a third size output mode; wherein the size of the phase array in the first size output mode is larger than the size of the phase array in the second size output mode; and the size of the phase array in the second size output mode is larger than the size of the phase array in the third size output mode;
[0254] The phase information output mode determination module 1720 is also used to determine that the phase information output mode adapted to the light intensity of the current shooting scene is the second size output mode if the light intensity of the current shooting scene is greater than a third preset threshold and less than or equal to the second preset threshold; if the light intensity of the current shooting scene is less than or equal to the third preset threshold, then determine that the phase information output mode adapted to the light intensity of the current shooting scene is the third size output mode; the second preset threshold is greater than the third preset threshold.
[0255] In one embodiment, at least two photosensitive elements corresponding to each target pixel in the target pixel group are arranged along the first direction; if the phase information output mode is the second size output mode, the phase array output module 1740 includes:
[0256] The target pixel group determination unit is further used to use the color pixel group and the full-color pixel group in the pixel array as the target pixel group, or use the full-color pixel group as the target pixel group;
[0257] The phase information acquisition unit is further used to acquire phase information of multiple groups of three adjacent sub-pixels along the second direction for each target pixel group;
[0258] The second-size phase array generating unit is used to merge the phase information of multiple groups of three adjacent sub-pixels to generate multiple groups of second merged phase information; and generate a second-size phase array corresponding to the pixel array according to the multiple groups of second merged phase information, wherein the size of the second-size phase array is 2×1 pixels.
[0259] In one embodiment, the second size phase array generating unit is further used to merge three adjacent second combined phase information again to generate target phase information; wherein the sub-pixels used to generate three adjacent second combined phase information are in the same position in the target pixel; and according to the target phase information, a second size phase array of the pixel array in the first direction is generated.
[0260] In one embodiment, if the target pixel group includes a color pixel group and a full-color pixel group, the second-size phase array generation unit is further used to determine a third phase weight corresponding to the color pixel group and a fourth phase weight corresponding to the full-color pixel group according to the light intensity of the current shooting scene; wherein the third phase weight corresponding to the color pixel group is different under different light intensities, and the fourth phase weight corresponding to the full-color pixel group is different under different light intensities; based on the target phase information and the third phase weight of the color pixel group, and the target phase information and the fourth phase weight of the full-color pixel group, a second-size phase array of the pixel array in the second direction is generated.
[0261] In one embodiment, at least two photosensitive elements corresponding to each target pixel in the target pixel group are arranged along a first direction; if the light intensity of the current shooting scene is less than or equal to a third preset threshold, the phase array output module 1740 includes:
[0262] The target pixel group determination unit is further used to take two adjacent full-color pixel groups along the second diagonal direction in the pixel array as target pixel groups;
[0263] The phase information acquisition unit is further used to acquire phase information of a plurality of groups of three adjacent sub-pixels from each panchromatic pixel group in the target pixel group along a second direction; wherein the second direction is perpendicular to the first direction;
[0264] The third-size phase array generating unit is used to merge the phase information of multiple groups of three adjacent sub-pixels to generate multiple groups of third merged phase information; based on the multiple groups of third merged phase information, a third-size phase array corresponding to the pixel array is generated, and the size of the third-size phase array is the size of 2×1 pixels arranged in the array.
[0265] In one embodiment, the third-size phase array generating unit is further used to merge the six second combined phase information again to generate target phase information; wherein the sub-pixels used to generate the six second combined phase information are in the same sub-position in the target pixel; and based on the target phase information, a third-size phase array of the pixel array in the first direction is generated.
[0266] In one embodiment, a focus control device is provided, further comprising:
[0267] A target pixel array determination module, used to determine a target pixel array from a plurality of pixel arrays in the image sensor according to a preset extraction ratio and a preset extraction position of a pixel array for focus control;
[0268] The phase array output module 1740 is further configured to output a phase array corresponding to the target pixel array according to a phase information output mode.
[0269] In one embodiment, a focus control device is provided, further comprising:
[0270] The threshold determination module is used to determine a first preset threshold, a second preset threshold and a third preset threshold of light intensity according to exposure parameters and pixel size.
[0271] It should be understood that, although the various steps in the above-mentioned flow chart are displayed in sequence according to the indication of the arrows, these steps are not necessarily executed in sequence according to the order indicated by the arrows. Unless there is a clear explanation in this article, the execution of these steps is not strictly limited in order, and these steps can be executed in other orders. Moreover, at least a part of the steps in the above-mentioned flow chart may include a plurality of sub-steps or a plurality of stages, and these sub-steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these sub-steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with other steps or at least a part of the sub-steps or stages of other steps.
[0272] The division of the various modules in the above focus control device is only for illustration. In other embodiments, the focus control device may be divided into different modules as needed to complete all or part of the functions of the above focus control device.
[0273] For the specific definition of the focus control device, please refer to the definition of the focus control method above, which will not be repeated here. Each module in the above-mentioned focus control device can be implemented in whole or in part by software, hardware and a combination thereof. The above-mentioned modules can be embedded in or independent of the processor in the computer device in the form of hardware, or can be stored in the memory of the computer device in the form of software, so that the processor can call and execute the operations corresponding to the above modules.
[0274] Fig.19 Schematic diagram of the internal structure of an electronic device in an embodiment. The electronic device can be any terminal device such as a mobile phone, a tablet computer, a laptop computer, a desktop computer, a PDA (Personal Digital Assistant), a POS (Point of Sales), a car computer, a wearable device, etc. The electronic device includes a processor and a memory connected via a system bus. Among them, the processor may include one or more processing units. The processor may be a CPU (Central Processing Unit) or a DSP (Digital Signal Processing), etc. The memory may include a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The computer program can be executed by the processor to implement a focus control method provided in each of the following embodiments. The internal memory provides a cache operating environment for the operating system computer program in the non-volatile storage medium.
[0275] The implementation of each module in the focus control device provided in the embodiment of the present application can be in the form of a computer program. The computer program can be run on an electronic device. The program module constituted by the computer program can be stored in the memory of the electronic device. When the computer program is executed by the processor, the steps of the method described in the embodiment of the present application are implemented.
[0276] The embodiment of the present application further provides a computer-readable storage medium, one or more non-volatile computer-readable storage media containing computer-executable instructions, when the computer-executable instructions are executed by one or more processors, the processors execute the steps of the focus control method.
[0277] An embodiment of the present application also provides a computer program product including instructions, which, when executed on a computer, enables the computer to execute a focus control method.
[0278] Any reference to memory, storage, database or other medium used in this application may include non-volatile and / or volatile memory. Non-volatile memory may include ROM (Read-Only Memory), PROM (Programmable Read-only Memory), EPROM (Erasable Programmable Read-Only Memory), EEPROM (Electrically Erasable Programmable Read-only Memory) or flash memory. Volatile memory may include RAM (Random Access Memory), which is used as an external cache memory. By way of illustration and not limitation, RAM is available in many forms, such as SRAM (Static Random Access Memory), DRAM (Dynamic Random Access Memory), SDRAM (Synchronous Dynamic Random Access Memory), Double Data Rate DDRSDRAM (Double Data Rate Synchronous Dynamic Random Access memory), ESDRAM (Enhanced Synchronous Dynamic Random Access memory), SLDRAM (Sync Link Dynamic Random Access Memory), RDRAM (Rambus Dynamic Random Access Memory), and DRDRAM (Direct Rambus Dynamic Random Access Memory).
[0279] The above embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for a person of ordinary skill in the art, several modifications and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.
Claims
1. An image sensor, characterized in that: The image sensor includes a microlens array, a pixel array and a filter array, the filter array includes a minimum repeating unit, the minimum repeating unit includes a plurality of filter groups, the filter group includes a color filter and a panchromatic filter; the color filter has a narrower spectral response than the panchromatic filter, the color filter and the panchromatic filter each include 9 sub-filters arranged in an array; the filter group includes 2 panchromatic filters and 2 color filters, the minimum repeating unit is 12 rows and 12 columns of 144 sub-filters, and the arrangement is as follows: wwwbbbwwwaaa wwwbbbwwwaaa wwwbbbwwwaaa bbbwwwaaawww bbbwwwaaawww bbbwwwaaawww wwwaaawwwccc wwwaaawwwccc wwwaaawwwccc aaawwwcccwww aaawwwcccwww aaawwwcccwww or, bbbwwwaaawww bbbwwwaaawww bbbwwwaaawww wwwbbbwwwaaa wwwbbbwwwaaa wwwbbbwwwaaa aaawwwcccwww aaawwwcccwww aaawwwcccwww wwwaaawwwccc wwwaaawwwccc wwwaaawwwccc w represents the full-color sub-filter, a, b and c represent the color sub-filters; Among them, the pixel array includes multiple full-color pixel groups and multiple color pixel groups, each of the full-color pixel groups corresponds to the full-color filter, and each of the color pixel groups corresponds to the color filter; the full-color pixel group and the color pixel group each include 9 pixels, the microlenses in the microlens array, the pixels of the pixel array and the sub-filters of the filter array are arranged correspondingly, and each pixel includes at least two sub-pixels arranged in an array, and each sub-pixel corresponds to a photosensitive element.
2. The image sensor according to claim 1, characterized in that There are four filter groups, and the four filter groups are arranged in a matrix.
3. The image sensor according to claim 2, characterized in that In each of the filter groups, the panchromatic filters are arranged in a first diagonal direction, and the color filters are arranged in a second diagonal direction, and the first diagonal direction is different from the second diagonal direction.
4. The image sensor according to claim 1, characterized in that At least two photosensitive elements corresponding to the pixel are arranged in a centrally symmetrical manner.
5. The image sensor according to claim 4, characterized in that: The at least two photosensitive elements may be in any one of a rectangular, a trapezoidal, a triangular and an L-shaped shape.
6. A focus control method, characterized in that: Applied to the image sensor according to any one of claims 1 to 5, the method comprises: According to the light intensity of the current shooting scene, determine a phase information output mode adapted to the light intensity of the current shooting scene; wherein in different phase information output modes, the size of the output phase array is different; According to the phase information output mode, output a phase array corresponding to the pixel array; wherein the phase array includes phase information corresponding to a target pixel in the pixel array; Calculating a phase difference of the pixel array based on the phase array, and performing focus control according to the phase difference; Determining the phase information output mode adapted to the light intensity of the current shooting scene according to the light intensity of the current shooting scene includes: determining a target light intensity range to which the light intensity of the current shooting scene belongs; wherein different light intensity ranges correspond to different phase information output modes; and determining the phase information output mode adapted to the light intensity of the current shooting scene according to the target light intensity range; The phase information output mode includes a full-size output mode and a first-size output mode, and the size of the phase array in the full-size output mode is larger than the size of the phase array in the first-size output mode; the determining, according to the target light intensity range, the phase information output mode adapted to the light intensity of the current shooting scene comprises: if the light intensity of the current shooting scene is greater than a first preset threshold, determining that the phase information output mode adapted to the light intensity of the current shooting scene is the full-size output mode; if the light intensity of the current shooting scene is greater than a second preset threshold, and less than or equal to the first preset threshold, determining that the phase information output mode adapted to the light intensity of the current shooting scene is the first-size output mode; the first preset threshold is greater than the second preset threshold; If the phase information output mode is a full-size output mode, then outputting a phase array corresponding to the pixel array according to the phase information output mode includes: taking a color pixel group in the pixel array as a target pixel group; the target pixel group includes a target pixel; for each target pixel group, acquiring phase information of a sub-pixel of the target pixel; generating a full-size phase array corresponding to the pixel array according to the phase information of the sub-pixel of the target pixel; the size of the full-size phase array is the size of 6×3 pixels arranged in the array; At least two photosensitive elements corresponding to each target pixel in the target pixel group are arranged along a first direction; if the phase information output mode is a first size output mode, then the phase array corresponding to the pixel array is output according to the phase information output mode, including: taking at least one of the color pixel group and the full-color pixel group in the pixel array as the target pixel group; for each target pixel group, obtaining phase information of multiple groups of two adjacent sub-pixels along a second direction with one sub-pixel as a sliding window step; wherein the second direction is perpendicular to the first direction; merging the phase information of the multiple groups of two adjacent sub-pixels to generate multiple groups of first merged phase information; generating a first size phase array corresponding to the pixel array according to the multiple groups of first merged phase information, the size of the first size phase array being the size of 4×2 pixels arranged in the array.
7. The method according to claim 6, characterized in that The step of generating a first-size phase array corresponding to the pixel array according to the multiple sets of first combined phase information includes: Merging again a plurality of sets of two adjacent first merged phase information to generate target phase information; wherein the sub-pixels used to generate the two adjacent first merged phase information are located at the same position in the target pixel; A first-size phase array of the pixel array is generated according to the target phase information.
8. The method according to claim 7, characterized in that If the target pixel group includes a color pixel group and a full-color pixel group, then generating a first-size phase array of the pixel array according to the target phase information includes: Determining a first phase weight corresponding to the color pixel group and a second phase weight corresponding to the panchromatic pixel group according to the light intensity of the current shooting scene; wherein the first phase weight corresponding to the color pixel group is different under different light intensities, and the second phase weight corresponding to the panchromatic pixel group is different under different light intensities; A first-size phase array of the pixel array is generated based on the target phase information of the color pixel group and the first phase weight, the target phase information of the panchromatic pixel group and the second phase weight.
9. The method according to claim 6, characterized in that The phase information output mode also includes a second size output mode and a third size output mode; wherein the size of the phase array in the first size output mode is larger than the size of the phase array in the second size output mode; and the size of the phase array in the second size output mode is larger than the size of the phase array in the third size output mode; The step of determining a phase information output mode adapted to the light intensity of the current shooting scene according to the target light intensity range includes: If the light intensity of the current shooting scene is greater than the third preset threshold and less than or equal to the second preset threshold, determining that the phase information output mode adapted to the light intensity of the current shooting scene is the second size output mode; If the light intensity of the current shooting scene is less than or equal to the third preset threshold, the phase information output mode adapted to the light intensity of the current shooting scene is determined to be the third size output mode; the second preset threshold is greater than the third preset threshold.
10. The method according to claim 9, characterized in that At least two photosensitive elements corresponding to each target pixel in the target pixel group are arranged along a first direction; if the phase information output mode is a second size output mode, outputting a phase array corresponding to the pixel array according to the phase information output mode includes: Using a color pixel group and a full-color pixel group in the pixel array as a target pixel group, or using the full-color pixel group as a target pixel group; For each target pixel group, phase information of multiple groups of three adjacent sub-pixels is acquired along the second direction; Combining the phase information of the multiple groups of three adjacent sub-pixels to generate multiple groups of second combined phase information; A second-size phase array corresponding to the pixel array is generated according to the multiple groups of second combined phase information, and the size of the second-size phase array is 2×1 pixels.
11. The method according to claim 10, characterized in that The step of generating a second-size phase array corresponding to the pixel array according to the plurality of sets of second combined phase information comprises: Merging three adjacent second combined phase information again to generate target phase information; wherein the sub-pixels used to generate the three adjacent second combined phase information are located at the same position in the target pixel; A phase array of a second size of the pixel array is generated according to the target phase information.
12. The method according to claim 11, characterized in that If the target pixel group includes a color pixel group and a full-color pixel group, then generating a second-size phase array of the pixel array according to the target phase information includes: Determining a third phase weight corresponding to the color pixel group and a fourth phase weight corresponding to the panchromatic pixel group according to the light intensity of the current shooting scene; wherein the third phase weight corresponding to the color pixel group is different under different light intensities, and the fourth phase weight corresponding to the panchromatic pixel group is different under different light intensities; A second-size phase array of the pixel array is generated based on the target phase information of the color pixel group and the third phase weight, the target phase information of the panchromatic pixel group and the fourth phase weight.
13. The method according to claim 9, characterized in that At least two photosensitive elements corresponding to each target pixel in the target pixel group are arranged along a first direction; if the light intensity of the current shooting scene is less than or equal to the third preset threshold, outputting a phase array corresponding to the pixel array according to the phase information output mode includes: Using two adjacent full-color pixel groups along a second diagonal direction in the pixel array as target pixel groups; For each panchromatic pixel group in the target pixel group, phase information of a plurality of groups of three adjacent sub-pixels is acquired from the panchromatic pixel group along the second direction; wherein the second direction is perpendicular to the first direction; Combining the phase information of the multiple groups of three adjacent sub-pixels to generate multiple groups of third combined phase information; A phase array of a third size corresponding to the pixel array is generated according to the multiple sets of third combined phase information, and the size of the phase array of the third size is the size of 2×1 pixels arranged in the array.
14. The method according to claim 13, characterized in that Generating a phase array of a third size corresponding to the pixel array according to the third combined phase information includes: Merging the six second combined phase information again to generate target phase information; wherein the sub-pixels used to generate the six second combined phase information are in the same sub-position in the target pixel; A phase array of a third size of the pixel array is generated according to the target phase information.
15. The method according to claim 6, characterized in that Before outputting the phase array corresponding to the pixel array according to the phase information output mode, the method further includes: Determining a target pixel array from a plurality of pixel arrays in the image sensor according to a preset extraction ratio and a preset extraction position of a pixel array for focus control; Outputting a phase array corresponding to the pixel array according to the phase information output mode includes: According to the phase information output mode, a phase array corresponding to the target pixel array is output.
16. The method according to claim 9, characterized in that The method further comprises: A first preset threshold, a second preset threshold and a third preset threshold of the light intensity are determined according to exposure parameters and the size of the pixel.
17. A focus control device, characterized in that: Applied to the image sensor according to any one of claims 1 to 5, the device comprises: A phase information output mode determination module, used to determine a phase information output mode adapted to the light intensity of the current shooting scene according to the light intensity of the current shooting scene; wherein, in different phase information output modes, the size of the output phase array is different; A phase array output module, configured to output a phase array corresponding to the pixel array according to the phase information output mode; wherein the phase array includes phase information corresponding to a target pixel in the pixel array; A focus control module, configured to calculate a phase difference of the pixel array based on the phase array, and perform focus control according to the phase difference; The phase information output mode determination module is further used to determine the target light intensity range to which the light intensity of the current shooting scene belongs; wherein different light intensity ranges correspond to different phase information output modes; and according to the target light intensity range, determine the phase information output mode adapted to the light intensity of the current shooting scene; The phase information output mode includes a full-size output mode and a first-size output mode, and the size of the phase array in the full-size output mode is larger than the size of the phase array in the first-size output mode; the phase information output mode determination module is further used to determine that the phase information output mode adapted to the light intensity of the current shooting scene is the full-size output mode if the light intensity of the current shooting scene is larger than a first preset threshold; if the light intensity of the current shooting scene is larger than a second preset threshold and smaller than or equal to the first preset threshold, determine that the phase information output mode adapted to the light intensity of the current shooting scene is the first-size output mode; the first preset threshold is larger than the second preset threshold; If the phase information output mode is a full-size output mode, the phase array output module includes: a target pixel group determination unit, configured to use a color pixel group in the pixel array as a target pixel group; the target pixel group includes a target pixel; A phase information acquisition unit, used for acquiring the phase information of the sub-pixels of the target pixels for each of the target pixel groups; A full-size phase array generating unit, used to generate a full-size phase array corresponding to the pixel array according to the phase information of the sub-pixel of the target pixel; the size of the full-size phase array is the size of 6×3 pixels arranged in the array; At least two photosensitive elements corresponding to each target pixel in the target pixel group are arranged along a first direction; if the phase information output mode is a first size output mode, the phase array output module includes: The target pixel group determination unit is further configured to use at least one of the color pixel group and the full-color pixel group in the pixel array as the target pixel group; The phase information acquisition unit is further used to acquire phase information of multiple groups of two adjacent sub-pixels along a second direction with one sub-pixel as a sliding window step for each target pixel group; wherein the second direction is perpendicular to the first direction; A first-size phase array generating unit is used to merge the phase information of the multiple groups of two adjacent sub-pixels to generate multiple groups of first merged phase information; based on the multiple groups of first merged phase information, a first-size phase array corresponding to the pixel array is generated, wherein the size of the first-size phase array is the size of 4×2 pixels arranged in the array.
18. An electronic device comprising a memory and a processor, wherein a computer program is stored in the memory, wherein: When the computer program is executed by the processor, the processor is caused to perform the steps of the focus control method according to any one of claims 6 to 16.
19. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the focus control method according to any one of claims 6 to 16 are implemented.
20. A computer program product comprising a computer program / instructions, characterized in that When the computer program / instructions are executed by a processor, the steps of the focus control method according to any one of claims 6 to 16 are implemented.
Citation Information
Patent Citations
Focusing control method and device thereof, imaging equipment, electronic equipment and computer readable storage medium
CN113660415A
Image sensor, camera, and terminal
CN213279832U