WO2020088063A1 - Electronic device - Google Patents

Electronic device Download PDF

Info

Publication number
WO2020088063A1
WO2020088063A1 PCT/CN2019/102735 CN2019102735W WO2020088063A1 WO 2020088063 A1 WO2020088063 A1 WO 2020088063A1 CN 2019102735 W CN2019102735 W CN 2019102735W WO 2020088063 A1 WO2020088063 A1 WO 2020088063A1
Authority
WO
WIPO (PCT)
Prior art keywords
structured light
display screen
spot
display area
spots
Prior art date
Application number
PCT/CN2019/102735
Other languages
French (fr)
Chinese (zh)
Inventor
张学勇
Original Assignee
Oppo广东移动通信有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Oppo广东移动通信有限公司 filed Critical Oppo广东移动通信有限公司
Publication of WO2020088063A1 publication Critical patent/WO2020088063A1/en

Links

Images

Classifications

    • GPHYSICS
    • G09EDUCATION; CRYPTOGRAPHY; DISPLAY; ADVERTISING; SEALS
    • G09GARRANGEMENTS OR CIRCUITS FOR CONTROL OF INDICATING DEVICES USING STATIC MEANS TO PRESENT VARIABLE INFORMATION
    • G09G3/00Control arrangements or circuits, of interest only in connection with visual indicators other than cathode-ray tubes
    • G09G3/20Control arrangements or circuits, of interest only in connection with visual indicators other than cathode-ray tubes for presentation of an assembly of a number of characters, e.g. a page, by composing the assembly by combination of individual elements arranged in a matrix no fixed position being assigned to or needed to be assigned to the individual characters or partial characters
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/02Constructional features of telephone sets
    • H04M1/0202Portable telephone sets, e.g. cordless phones, mobile phones or bar type handsets
    • H04M1/026Details of the structure or mounting of specific components
    • H04M1/0266Details of the structure or mounting of specific components for a display module assembly
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/02Constructional features of telephone sets
    • H04M1/0202Portable telephone sets, e.g. cordless phones, mobile phones or bar type handsets
    • H04M1/026Details of the structure or mounting of specific components

Definitions

  • This application relates to the field of consumer electronics technology, and more specifically, to an electronic device.
  • the mobile terminal can be equipped with a depth camera and a display screen.
  • the depth camera can be used to obtain the depth information of the object.
  • the display screen can be used to display text, patterns and other content. It is usually necessary to open a window on the display screen, for example, to form a bangs screen to make the display
  • the display area of the screen is staggered from the position of the depth camera.
  • Embodiments of the present application provide an electronic device.
  • the electronic device includes a display screen and a structured light component.
  • the display screen includes a display area formed with opposite front and back surfaces, the front surface being used to display images.
  • the structured light assembly includes a structured light projector that is disposed on a side of the display screen where the back side is located, and the structured light projector is used to emit structured light that passes through the display area.
  • the structured light projector is provided on the side where the back of the display screen is located, and the structured light emitted by the structured light projector passes through the display area and enters the external environment, there is no The opening of the structured light projector is aligned, and the screen of the electronic device is relatively high.
  • FIG. 1 is a schematic structural diagram of an electronic device according to some embodiments of the present application.
  • FIG. 2 is a partial structural diagram of an electronic device according to some embodiments of the present application.
  • FIG. 3 is a schematic cross-sectional view of the electronic device of some embodiments of the present application taken along line A-A shown in FIG. 2.
  • FIG. 4 is a schematic diagram of a structured light projector according to some embodiments of the present application.
  • FIG. 5 is a schematic cross-sectional view of an electronic device according to certain embodiments of the present application taken along the line A-A shown in FIG. 2.
  • FIGS. 6 and 7 are schematic diagrams of partial structures of electronic devices according to certain embodiments of the present application.
  • FIG. 8 is a schematic cross-sectional view of an electronic device according to some embodiments of the present application along a position corresponding to line A-A shown in FIG. 2.
  • 9 and 10 are schematic diagrams of partial structures of electronic devices according to some embodiments of the present application.
  • 11 to 15 are schematic cross-sectional views of the electronic device of certain embodiments of the present application along the position corresponding to line A-A shown in FIG. 2.
  • 16 is a schematic flowchart of an image acquisition method according to some embodiments of the present application.
  • 17 is a schematic block diagram of an image acquisition device according to some embodiments of the present application.
  • FIG. 20 is a schematic diagram of an image acquisition method according to some embodiments of the present application.
  • 21 is a schematic flowchart of an image acquisition method according to some embodiments of the present application.
  • 22 is a schematic diagram of an image acquisition method according to some embodiments of the present application.
  • 23 to 27 are schematic flowcharts of image acquisition methods in some embodiments of the present application.
  • FIG. 28 is a schematic diagram of an image acquisition method according to some embodiments of the present application.
  • FIG. 29 is a schematic flowchart of an image acquisition method according to some embodiments of the present application.
  • FIG. 30 is a schematic diagram of an image acquisition method according to some embodiments of the present application.
  • 31 to 34 are schematic flowcharts of an image acquisition method in some embodiments of the present application.
  • FIG. 35 is a schematic diagram of an optical path of structured light emitted by a structured light projector in some embodiments of the present application.
  • 36 to 41 are schematic flowcharts of an image acquisition method according to some embodiments of the present application.
  • the first feature is “on” or “under” the second feature may be that the first and second features are in direct contact, or the first and second features are indirectly through an intermediary contact.
  • the first feature is “above”, “above” and “above” the second feature may be that the first feature is directly above or obliquely above the second feature, or simply means that the first feature is higher in level than the second feature.
  • the first feature is "below”, “below”, and “below” the second feature may be that the first feature is directly below or obliquely below the second feature, or simply means that the first feature is less horizontal than the second feature.
  • the electronic device 1000 includes the display screen 10 and the structured light assembly 20.
  • the display screen 10 includes a display area 11 formed with a front face 12 and a back face 13 opposite to each other.
  • the front face 12 is used to display images.
  • the structured light assembly 20 includes a structured light projector 21 disposed on the side of the back surface 13 of the display screen 10, and the structured light projector 21 is used to emit light through The structured light of the display area 11 is described.
  • the structured light assembly 20 further includes a structured light camera 22, the structured light camera 22 is disposed on the side where the back surface 13 of the display screen 10 is located, and the structured light camera 22 is used In order to receive the modulated structured light passing through the display area 11.
  • the display screen 10 is formed with a through slot 14 penetrating the front surface 12 and the back surface 13, and the structured light assembly 20 further includes a structured light camera 22, which is disposed on On the side where the back surface 13 of the display screen 10 is located, the structured light camera 22 is used to receive the modulated structured light passing through the through slot 14.
  • the through slot 14 includes a notch 141 formed on the edge of the display screen 10; and / or the through slot 14 includes a through hole 142 spaced from the edge of the display screen 10.
  • the edge of the display screen 10 includes any one or more of an upper edge, a lower edge, a left edge, and a right edge.
  • the structured light assembly 20 further includes a floodlight 23 that is aligned with the structured light camera 22 and the same through slot 14.
  • the electronic device 1000 further includes a cover plate 40 that is disposed on a side of the display screen 10 where the front surface 12 is located.
  • An infrared transmission layer 50 is provided on the area corresponding to the groove 14.
  • the region of the display screen 10 corresponding to the structured light projector 21 is formed with an infrared antireflection film 60; and / or the display screen 10 corresponds to the structured light projector 21 The area where the infrared transmission layer 50 is formed.
  • the electronic device 1000 further includes a cover plate 40, the cover plate 40 is disposed on the side of the front surface 12 of the display screen 10, the cover plate 40 and the structured light are projected An infrared antireflection film 60 is formed in a region corresponding to the device 21.
  • the display screen 10 is formed with a through slot 14 penetrating through the front face 12 and the back face 13, the electronic device 1000 further includes a visible light camera 70, the visible light camera 70 and the through slot 14 is aligned, and a visible light anti-reflection film 80 and / or an infrared cut-off film 90 are formed in the area of the cover plate 40 corresponding to the through slot 14.
  • the structured light assembly 20 further includes a floodlight 23, the floodlight 23 is disposed on the side where the back surface 13 of the display screen 10 is located, and the floodlight 23 is used for To emit supplementary light passing through the display area 11.
  • the display screen 10 is formed with a through slot 14 penetrating through the front surface 12 and the back surface 13, and the structured light assembly 20 further includes a floodlight 23, and the floodlight 23 is disposed at On the side where the back surface 13 of the display screen 10 is located, the floodlight 23 is used to emit supplementary light passing through the through slot 14.
  • the display area 11 includes a first sub-display area 111 and a second sub-display area 112.
  • the structured light emitted by the structured light projector 21 passes through the first sub-display area 111.
  • the pixel density of the first sub-display area 111 is smaller than the pixel density of the second sub-display area 112.
  • the first sub-display area 111 is used to display the status icon of the electronic device 1000.
  • the first sub-display area 111 is located near the edge of the display area 11, and the second sub-display area 112 is located in the middle of the display area 11.
  • the display area 11 includes a first sub-display area 111 and a second sub-display area 112.
  • the structured light emitted by the structured light projector 21 passes through the first sub-display area 111.
  • the first sub-display area 111 and the second sub-display area 112 can be independently controlled and displayed in different display states.
  • the different display states include one or more of turning on or off, displaying at different brightness, and displaying at different refresh rates.
  • the first sub-display area 111 goes out; or when the structured light projector 21 emits structured light, the first light is turned down.
  • both the first sub-display area 111 and the second sub-display area 112 are turned on and displayed at the same refresh frequency.
  • the display screen 10 is a liquid crystal display screen, or a Micro LED display screen, or an OLED display screen.
  • the electronic device 1000 includes a display screen 10 and a structured light component 20.
  • the electronic device 1000 may further include a housing 30, which may be used to install functional devices such as the display screen 10, the structured light assembly 20, and the functional device may also be a main board, a dual camera module, a receiver, and so on.
  • the specific form of the electronic device 1000 may be a mobile phone, a tablet computer, a smart watch, a head-mounted display device, etc. This application uses the electronic device 1000 as a mobile phone for illustration. It can be understood that the specific form of the electronic device 1000 is not limited to a mobile phone, and is not limited herein.
  • the display screen 10 may be installed on the housing 30. Specifically, the display screen 10 may be installed on one surface of the housing 30 or on both opposite surfaces of the housing 30 at the same time. In the example shown in FIG. 1, the display screen 10 is installed in front of the housing 30, and the display screen 10 can cover 85% or more of the area of the front, for example, 85%, 86%, 87%, 88% , 89%, 90%, 91%, 92%, 93%, 95% and even 100%.
  • the display screen 10 can be used to display images, and the images can be text, images, videos, icons, and other information.
  • the specific type of the display screen 10 may be a liquid crystal display screen, an OLED display screen, a Micro LED display screen, or the like.
  • the display screen 10 includes a display area 11, which can be used to display images. To adapt to the needs of different types of electronic devices 1000 and different users, the shape of the display area 11 may be circular, elliptical, racetrack, rounded rectangle, rectangular, etc.
  • the display area 11 is formed with a front surface 12 and a back surface 13 that are opposite to each other.
  • the front surface 12 can be used to display an image. receive.
  • Pixels are formed in the display area 11.
  • the pixels can emit light to display corresponding colors.
  • the pixels display corresponding colors under the influence of the backlight. There is usually a microscopic gap between pixels, and light rays will diffract when passing through the microscopic gap.
  • the display screen 10 may further include a non-display area, and the non-display area may be formed on the periphery of the display area 11.
  • the non-display area may not be used for display, and the non-display area may be used for combining with the housing 30 or for wiring.
  • the non-display area may be combined with the housing 30 by viscose without affecting the display function of the display area 11.
  • the display screen 10 may also be a touch display screen integrated with a touch control function. After the user obtains the image information displayed on the display screen 10, the user may perform touch control on the display screen 10 to achieve a predetermined interactive operation.
  • the structured light component 20 can use the structured light to obtain the depth information of the target object for three-dimensional modeling, three-dimensional image generation, distance measurement, and the like.
  • the structured light assembly 20 may be installed in the housing 30 of the electronic device 1000, specifically after being installed on the bracket, and then the support and the structured light assembly 20 are installed in the housing 30 together.
  • the structured light assembly 20 may include a structured light projector 21, a structured light camera 22 and a floodlight 23.
  • the structured light projector 21 is disposed on the side where the back 13 of the display screen 10 is located, or the structured light projector 21 is disposed below the display area 11, and the structured light projector 21 is used for transmission Structured light passing through the display area 11.
  • the structured light projector 21 may include a light source 211, a collimating element 212, and a diffractive optical element 213.
  • the light (such as infrared laser light) emitted by the light source 211 is first collimated by the collimating element 212, and then diffracted by the diffractive optical element 213 It is emitted from the structured light projector 21 and then passes through the display area 11 to project to the outside world.
  • Both the microscopic gap of the display area 11 and the diffractive structure on the diffractive optical element 213 have a diffractive effect on the light emitted by the light source 211.
  • the structured light that passes through the display area 11 and enters the outside world may contain both a pattern diffracted by the diffractive optical element 213 (the pattern includes a plurality of spots diffracted by the diffractive optical element 213), and a microscopic gap diffracted by the display screen 10
  • the formed pattern (the pattern includes a plurality of spots diffracted by the diffractive optical element 213 and diffracted by the display screen 10), so that the speckle pattern after passing through the display area 11 has a high irrelevance, which is beneficial to subsequent Speckle patterns are processed.
  • the transmittance of the display area 11 can reach 60% or more, so that the structured light emitted by the structured light projector 21 passes through the display area 11 with less loss.
  • the structured light camera 22 may be an infrared camera.
  • the structured light is emitted to the target object. After being modulated by the target object, it can be acquired by the structured light camera 22.
  • the structured light camera 22 receives the modulated structured light to obtain a speckle image.
  • the speckle image is After processing, the depth data of the target object is obtained.
  • the structured light camera 22 can also be arranged on the side of the back side 13 of the display screen 10, that is, under the display screen 10, which can be specifically arranged on the same bracket as the structured light projector 21, or the structured light camera 22 is directly installed on ⁇ 30 ⁇ Housing 30.
  • the light incident surface of the structured light camera 22 can be aligned with the display area 11, and the structured light modulated by the target object passes through the display area 11 and then received by the structured light camera 22, specifically, the structured light modulated by the target object It can be diffracted by the microscopic gap of the display screen 10 and then received by the structured light camera 22.
  • the floodlight 23 can be used to emit supplementary light outward, and the supplementary light can be used to supplement the light intensity in the environment when the ambient light is weak.
  • the supplementary light may be infrared light.
  • the floodlight 23 may also be disposed on the side where the back 13 of the display screen 10 is located, that is, under the display screen 10, and may be specifically disposed on the same bracket as the structured light projector 21 and the structured light camera 22.
  • the supplementary light emitted by the floodlight 23 passes through the microscopic gap of the display area 11 and enters the external environment.
  • the reflected supplementary light can again pass through the microscopic gap to be received by the structured light camera 22.
  • the structured light projector 21 is disposed on the side where the back 13 of the display screen 10 is located, and the structured light emitted by the structured light projector 21 passes through the display area 11 and enters the external environment, there is no need In the opening where the structured light projector 21 is aligned, the screen area of the electronic device 1000 is relatively high.
  • the display screen 10 is formed with a through slot 14, and the through slot 14 does not have a display function.
  • the through groove 14 penetrates the front surface 12 and the rear surface 13.
  • the structured light camera 22 is arranged on the side where the back surface 13 of the display screen 10 is located, and the structured light camera 22 is used to receive the modulated structured light passing through the through slot 14.
  • the light incident surface of the structured light camera 22 can be aligned with the through slot 14, and the structured light modulated by the target object passes through the through slot 14 and then received by the structured light camera 22.
  • the speckle image acquired by the structured light camera 22 is the speckle image after modulation of the target object To reduce the difficulty of subsequent calculation of depth images based on speckle images.
  • the through slot 14 includes a notch 141 formed on the edge of the display screen 10, or in other words, the through slot 14 intersects the edge of the display screen 10.
  • the notch 141 may be specifically formed on any one or more edges such as the upper edge, the lower edge, the left edge, and the right edge of the display screen 10.
  • the shape of the notch 141 may be any shape such as a triangle, a semicircle, a rectangle, a track shape, etc., which is not limited herein.
  • the through slot 14 includes a through hole 142 spaced from the edge of the display screen 10, or the through slot 14 is opened within a range enclosed by the edge of the display screen 10.
  • the through hole 142 may specifically be close to any one or more edges such as the upper edge, the lower edge, the left edge, and the right edge of the display screen 10.
  • the shape of the through hole 142 may be any shape such as a triangle, a circle, a rectangle, and a racetrack, which is not limited herein.
  • the through slot 14 may also include the aforementioned notch 141 and the through hole 142 at the same time.
  • the number of the notch 141 and the through hole 142 may be equal or unequal.
  • the floodlight 23 is disposed on the side where the back 13 of the display screen 10 is located, and the floodlight 23 is used to emit supplementary light passing through the through slot 14.
  • the supplementary light is directly emitted to the outside after passing through the through slot 14, and the supplementary light will not be weakened in the process of passing through the display area 11 to ensure that the target object receives a large amount of supplementary light.
  • the through slot 14 includes a notch 141 formed on the edge of the display screen 10, or the through slot 14 intersects the edge of the display screen 10.
  • the notch 141 may be specifically formed on any one or more edges such as the upper edge, the lower edge, the left edge, and the right edge of the display screen 10.
  • the shape of the notch 141 may be any shape such as a triangle, a semicircle, a rectangle, a track shape, etc., which is not limited herein.
  • the through slot 14 includes a through hole 142 spaced from the edge of the display screen 10, or the through slot 14 is opened within a range enclosed by the edge of the display screen 10.
  • the through hole 142 may specifically be close to any one or more edges such as the upper edge, the lower edge, the left edge, and the right edge of the display screen 10.
  • the shape of the through hole 142 may be any shape such as a triangle, a circle, a rectangle, a racetrack, etc., and is not limited herein.
  • the floodlight 23 and the structured light camera 22 may correspond to the same through slot 14.
  • the floodlight 23 and the structured light camera 22 can correspond to different through slots 14.
  • the electronic device 1000 further includes a cover 40.
  • the cover 40 is disposed on the side where the front surface 12 of the display screen 10 is located.
  • an infrared transmission layer 50 is provided on the area of the cover plate 40 corresponding to the through slot 14.
  • the cover plate 40 may be made of a material with good light transmission performance, such as glass or sapphire.
  • the infrared transmission layer 50 may be an infrared transmission ink or an infrared transmission film.
  • the infrared transmission layer 50 has a high transmittance for infrared light (for example, light with a wavelength of 940 nanometers), for example, the transmittance can reach 85% Or more, and the transmittance of light other than infrared light is low or makes light other than infrared light completely impermeable. Therefore, it is difficult for the user to see the structured light camera 22 or the floodlight 23 aligned with the through slot 14 through the cover plate 40, and the appearance of the electronic device 1000 is more beautiful.
  • the display area 11 includes a first sub-display area 111 and a second sub-display area 112.
  • the structured light emitted by the structured light projector 21 passes through the first sub-display area 111, and the pixel density of the first sub-display area 111 is smaller than the pixel density of the second sub-display area 112.
  • the pixel density of the first sub-display area 111 is less than the pixel density of the second sub-display area 112, that is, the micro-gap of the first sub-display area 111 is greater than the micro-gap of the second sub-display area 112.
  • the blocking effect of light is small, and the transmittance of light passing through the first sub-display area 111 is high. Therefore, the structured light emitted by the structured light projector 21 has a higher transmittance through the first sub-display area 111.
  • the first sub-display area 111 may be used to display the status icon of the electronic device 1000, for example, to display the battery level, network connection status, system time, etc. of the electronic device 1000.
  • the first sub-display area 111 may be located near the edge of the display area 11, and the second sub-display area 112 may be located in the middle of the display area 11.
  • the display area 11 includes a first sub-display area 111 and a second sub-display area 112.
  • the structured light emitted by the structured light projector 21 passes through the first sub-display area 111.
  • the one sub-display area 111 and the second sub-display area 112 can be independently controlled and displayed in different display states.
  • the pixel density of the first sub-display area 111 and the pixel density of the second sub-display area 112 may be equal, or the pixel density of the first sub-display area 111 is less than the pixel density of the second sub-display area 112.
  • different display states may be on or off, display with different brightness, display with different refresh frequency, and so on.
  • the display states of the first sub-display area 111 and the second sub-display area 112 can be independently controlled. The user can control the normal display of the second sub-display area 112 according to actual needs, and the first sub-display area 111 cooperates with the structured light projector 21 use.
  • the first sub-display area 111 may be turned off, or the display brightness of the first sub-display area 111 may be lowered, or the refresh frequency of the first sub-display area 111 may be adjusted so that the first sub-display area 111
  • the turn-on time of the display area 111 is staggered from the turn-on time of the structured light projector 21, so as to reduce the influence of the first sub-display area 111 on the structured light projector 21 projecting the speckle pattern onto the scene.
  • both the first sub-display area 111 and the second sub-display area 112 may be turned on and displayed at the same refresh rate.
  • the electronic device 1000 further includes a cover plate 40.
  • the cover plate 40 is disposed on the side of the front surface 12 of the display screen 10.
  • the area of the cover plate 40 corresponding to the structured light projector 21 The infrared antireflection film 60 is formed.
  • the infrared anti-reflection film 60 can increase the transmittance of infrared light.
  • the infrared anti-reflection film 60 can increase the transmittance of the infrared laser through the cover plate 40 to reduce the infrared laser penetration
  • the loss of the cover 40 reduces the power consumption of the electronic device 1000.
  • the infrared antireflection film 60 may be plated on the upper surface, or the lower surface of the cover plate 40, or on both the upper surface and the lower surface.
  • the area on the cover plate 40 corresponding to the structured light camera 22 may also be formed with an infrared antireflection film 60 to reduce the loss of external infrared light passing through the cover plate 40 before reaching the structured light camera 22.
  • the area corresponding to the floodlight 23 on the cover plate 40 may also be formed with an infrared antireflection film 60 to reduce the loss of supplementary light emitted by the floodlight 23 when passing through the cover plate 40.
  • the area on the cover 40 that does not correspond to the structured light projector 21, the structured light camera 22, and the floodlight 23 may be formed with a visible light antireflection film 80 to improve the visible light emitted by the display screen 10 when passing through the cover 40 Transmittance.
  • an infrared anti-reflection film 60 is formed in the area of the display screen 10 corresponding to the structured light projector 21.
  • the infrared antireflection film 60 can increase the transmittance of infrared light.
  • the infrared antireflection film 60 can increase the transmittance of the infrared laser through the display screen 10 to reduce the infrared laser penetration
  • the loss of the display screen 10 further reduces the power consumption of the electronic device 1000.
  • the infrared antireflection film 60 may be formed on the front surface 12 or the back surface 13 of the display area 11, or the front surface 12 or the back surface 13 of the display area 11 may be formed at the same time.
  • the infrared antireflection film 60 may also be formed inside the display screen 10, for example, when the display screen 10 is a liquid crystal display, the infrared antireflection film 60 may be formed on the polarizer in the display screen 10, or formed on The electrode plate of the display screen 10 and the like.
  • the through-slot 14 when the through-slot 14 is not provided at the position corresponding to the display screen 10 and the structured light camera 22, the area of the display screen 10 and the structured light camera 22 may also be formed with an infrared antireflection film 60.
  • the through slot 14 is not provided at the position corresponding to the display screen 10 and the floodlight 23, the area corresponding to the display screen 10 and the floodlight 23 may also form an infrared antireflection film 60.
  • an infrared transmission layer 50 is formed in the area of the display screen 10 corresponding to the structured light projector 21.
  • the infrared transmission layer 50 has a high transmittance for infrared light, and a low transmittance for light other than infrared light (such as visible light) or makes light other than infrared light (such as visible light) completely impermeable.
  • the area corresponding to the display screen 10 and the structured light camera 22 may also form an infrared transmission layer 50 to reduce infrared rays passing through the display screen 10 The effect of light other than light on the structured light camera 22.
  • the infrared transmission layer 50 may also be formed in the area corresponding to the display screen 10 and the floodlight 23.
  • the display screen 10 is formed with a through slot 14 penetrating the front surface 12 and the back surface 13.
  • the electronic device 1000 further includes a visible light camera 70 that is aligned with the through slot 14.
  • a visible light antireflection film 80 and / or an infrared cutoff film 90 are formed in the region of the cover plate 40 corresponding to the through groove 14.
  • the visible light camera 70 can be used to receive visible light passing through the cover plate 40 and the through slot 14 to obtain images.
  • Forming a visible light antireflection film 80 on the area of the cover plate 40 corresponding to the through groove 14 can increase the transmittance of visible light when passing through the cover plate 40, so as to improve the imaging quality of the visible light camera 70.
  • the formation of the infrared cut-off film 90 on the area of the cover plate 40 corresponding to the through slot 14 can reduce the transmittance of infrared light when passing through the cover plate 40, or completely prevent infrared light from entering the visible light camera 70 to reduce infrared light to the visible light camera 70 The impact of imaging.
  • the present application also provides an image acquisition method, which can be used in the structured light assembly 20 described in any one of the above embodiments.
  • the structured light assembly 20 is provided on the electronic device 1000.
  • the structured light assembly 20 includes a structured light projector 21 and a structured light camera 22.
  • the structured light projector 21 is disposed on the side of the back surface 13 of the display screen 10.
  • the structured light projector 21 is used to emit structured light passing through the display area 11.
  • Image acquisition methods include:
  • the image acquisition method according to the embodiment of the present application may be implemented by the image acquiring device 400 according to the embodiment of the present application.
  • the image acquisition device 400 includes a control module 401 and a calculation module 402.
  • Step 00 and step 01 can be implemented by the control module 401.
  • Step 02 may be implemented by the calculation module 402. That is to say, the control module 401 can be used to control the structured light projector 21 to emit structured light toward the display area 11 of the display screen 10, and to control the structured light camera 22 to capture speckle images generated by the structured light.
  • the calculation module 402 may be used to obtain a depth image based on the measured spots in the speckle image and the reference spots in the reference image.
  • the image acquisition method according to the embodiment of the present application may be applied to the structured light assembly 20 described in any one of the above embodiments.
  • the structured light assembly 20 further includes a processor 200, and steps 00, 01, and 02 can be implemented by the processor 200. That is to say, the processor 200 can be used to control the structured light projector 21 to emit structured light toward the display area 11 of the display screen 10, control the structured light camera 22 to capture the speckle image generated by the structured light, and according to the speckle image Obtain the depth image by measuring the spot in the reference spot and the reference spot in the reference image.
  • the processor 200 of the structured light module 20 and the processor of the electronic device 1000 may be two independent processors; or, the processor 200 of the structured light module 20 and the processor of the electronic device 1000 may be the same processor. In a specific embodiment of the present application, the processor 200 of the structured light assembly 20 and the processor of the electronic device 1000 are the same processor 200.
  • the structured light projector 21 after the structured light projector 21 is turned on, it can project structured light into the scene, and the structured light projected into the scene will form a speckle pattern with multiple spots. Due to the different distances between multiple target objects in the scene and the structured light projector 21, the speckle pattern projected onto the target object will be modulated due to the difference in the height of the target object surface, and cause multiple of the speckle patterns The spots are shifted to different degrees. After the shifted spots are collected by the structured light camera 22, a speckle image including a plurality of measurement spots can be formed.
  • the processor 200 After the processor 200 acquires the speckle image, it can calculate the depth data of multiple pixels according to the offset of the measured speckle in the speckle image relative to the reference speckle in the reference image, and multiple pixels with depth data can be formed A depth image.
  • the reference image is obtained by calibration in advance.
  • the image acquisition method and the electronic device 1000 of the embodiment of the present application place the structured light projector 21 on the side of the back 13 of the display screen 10, that is, the structured light projector 21 is provided under the display screen 10, and the display screen 10 does not need to be opened and structured
  • the through slot 14 aligned with the light projector 21 has a relatively high screen occupation of the electronic device 1000, and does not affect the acquisition of depth images.
  • the structured light projector 21 and the structured light camera 22 are arranged together on the side of the back 13 of the display screen 10, and the display screen 10 is provided with
  • the structured light camera 22 receives the modulated structured light passing through the through slot 14.
  • controlling the structured light camera 22 to capture the speckle image generated by the structured light in step 01 includes:
  • the structured light camera 22 Control the structured light camera 22 to receive the structured light directly diffracted by the display area 11 and reflected by the target object when it is emitted to obtain a speckle image.
  • the speckle image includes a plurality of measurement spots, and the plurality of measurement spots including the laser light is only The first measuring spot diffracted by the diffractive optical element 213 (shown in FIG.
  • the first measurement spot is that after the laser beam is diffracted by the diffractive optical element 213 and passes through the display screen 10, it is not diffracted by the display screen 10, that is, it is directly projected onto the target object without encountering a microscopic gap, and is modulated and reflected by the target object
  • the second measurement spot is formed by the laser light diffracted by the diffractive optical element 213 and then diffracted by the display screen 10 after passing through the display screen 10, that is, it is projected onto the target object after encountering a microscopic gap, and is modulated and reflected by the target object;
  • Step 02 Obtaining a depth image based on the measured spots in the speckle image and the reference spots in the reference image includes:
  • step 011 may be implemented by the control module 401.
  • Step 021 can be implemented by the calculation module 402.
  • both step 011 and step 021 may be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to receive the structured light that is diffracted by the display area 11 and reflected directly by the target object when being emitted to obtain a speckle image, and the speckle image includes multiple measurement spots
  • the multiple measurement spots include the first measurement spot formed by laser light diffracted by the diffractive optical element 213 and reflected by the target object, and the first measurement spot formed by laser light diffracted by the diffractive optical element 213 and then diffracted by the display screen 10 second time and reflected by the target object Two measuring spots.
  • the processor 200 may also be used to obtain a depth image according to the first measurement spot and the second measurement spot in the speckle image and the reference spot in the reference image.
  • the structured light projector 21 generally includes a light source 211, a collimating element 212 and a diffractive optical element 213.
  • the light source 211 is used to emit laser light
  • the collimating element 212 is used to collimate the laser light emitted by the light source 211
  • the diffractive optical element 213 is used to diffract the laser light collimated by the collimating element 212 to project structured light into the scene
  • the structured light in the scene forms a speckle pattern, and the speckle pattern includes a plurality of spots, which are formed by the diffraction of the laser light only through the diffractive optical element 213.
  • LCD screens, OLED screens, Micro LED screens, and other types of display screens 10 usually have a fixed pixel arrangement structure on the display area 11, and microscopic gaps are formed between adjacent pixels. When a single-point laser passes through these microscopic gaps Will be diffracted to produce a series of spots. When the pixel arrangement structure in the display area 11 is different, the arrangement of the spots of the speckle pattern formed after the single-point laser passes through the display area 11 is also different.
  • the structured light emitted by the structured light projector 21 is usually an infrared laser.
  • the infrared laser emitted by the structured light projector 21 passes through the display area 11 will also be The gap is diffracted to produce a speckle pattern with multiple spots.
  • the plurality of spots in the speckle pattern projected by the structured light projector 21 in the space simultaneously include the first spot formed by the laser light diffracted only by the diffractive optical element 213 and the laser light is diffracted once by the diffractive optical element 213 and then by the display screen 10 The second spot formed by the second diffraction.
  • the structured light camera 22 When the structured light camera 22 is imaging, the structured light camera 22 receives the structured light reflected by the target object in the scene to form a speckle image.
  • the display screen 10 is provided with a through slot 14, the light incident surface of the structured light camera 22 is aligned with the through slot 14, the through slot 14 does not have a micro gap, and is diffracted once by the diffractive optical element 213
  • the laser light reflected by the second-order diffraction of the display screen 10 and modulated by the target object will not be diffracted when passing through the slot 14.
  • the structured light camera 22 receives the structured light diffracted by the display area 11 and reflected directly by the target object.
  • the multiple measurement spots in the formed speckle image simultaneously include the first measurement spot formed by laser light diffracted only by the diffractive optical element 213 and reflected by the target object and the laser light is diffracted once by the diffractive optical element 213 and then diffracted by the display screen 10 twice The second measurement spot formed by the reflection of the target object.
  • the processor 200 may directly calculate the depth image according to the first measurement spot and the second measurement spot in the speckle image and the reference spot in the reference image.
  • the calculation method of the depth image may include the following two.
  • step 021 includes:
  • the image acquisition method also includes:
  • the structured light camera 22 is controlled to receive the structured light that is diffracted by the display area 11 and reflected directly by the calibrated object when it exits to obtain a reference image, and the reference image includes multiple reference spots.
  • step 0211 and step 0212 can be implemented by the calculation module 402.
  • Step 031 can be implemented by the control module 401.
  • Step 0211, step 0212, and step 031 may be implemented by the processor 200. That is to say, the processor 200 can also be used to calculate the offsets of all measurement spots relative to all reference spots and calculate depth data according to the offsets to obtain depth images.
  • the processor 200 can also be used to control the structured light camera 22 to receive the structured light directly diffracted by the display area 11 and reflected by the calibrated object when it is calibrated to obtain the reference image.
  • the reference image includes multiple reference spots.
  • the structured light projector 21 and the structured light camera 22 are both provided on the side of the back 13 of the display screen 10, and the display screen 10 is provided with a structured light camera 22
  • the structured light camera 22 can receive the modulated structured light passing through the through-slot 14 through the through-slot 14 where the light incident surface is aligned.
  • the processor 200 controls the structured light projector 21 to emit structured light.
  • the structured light passes through the display area 11 and is projected onto a calibration object at a predetermined distance from the structured light assembly 20, such as the calibration plate, and is reflected back by the calibration plate
  • the structured light passing through the through slot 14 is received by the structured light camera 22.
  • the structured light camera 22 receives the structured light emitted by the structured light projector 21, diffracted by the display screen 10 and reflected by the calibration plate, and then directly incident through the through slot 14, the formed reference image includes multiple reference spots .
  • the reference spot simultaneously includes a first reference spot corresponding to the first measurement spot and a second reference spot corresponding to the second measurement spot.
  • the first reference spot is formed when the laser light is diffracted by the diffractive optical element 213 when passing through the diffractive optical element 213, and is not diffracted by the display screen 10 after passing through the display screen 10, and is modulated and reflected by the calibration plate;
  • the second reference spot is formed by the laser light
  • the diffractive optical element 213 is diffracted once by the diffractive optical element 213, and when passing through the display screen 10, it is diffracted again by the display screen 10, and is modulated and reflected by the calibration plate.
  • the processor 200 does not The first measurement spot and the second measurement spot are distinguished, and the first reference spot and the second reference spot in the reference image are not distinguished, but the depth image is directly based on all the measurement spots and all the reference spots. Calculation. Specifically, the processor 200 first calculates the offsets of all measurement spots relative to all reference spots, and then calculates multiple depth data based on the multiple offsets, thereby obtaining a depth image.
  • step 021 includes:
  • the image acquisition method also includes:
  • the structured light camera 22 is controlled to receive the structured light directly reflected by the calibrated object after being emitted from the structured light projector 21 and directly incident to obtain a first reference image, and the first reference image includes multiple reference spots
  • the multiple reference spots include a first reference spot formed by multiple laser beams diffracted by the diffractive optical element 213 only and reflected by the calibration object;
  • the structured light camera 22 is controlled to receive the structured light diffracted by the display area 11 and reflected directly by the calibrated object when being emitted to obtain a second reference image, which includes a plurality of reference spots,
  • the multiple reference spots include a first reference spot formed by laser light diffracted only by the diffractive optical element 213 and reflected by the calibrated object, and a second reference spot formed by the laser light diffracted once by the diffractive optical element 213 and then diffracted by the display screen 10 and reflected by the calibrated object Reference spot
  • the measurement spot whose actual ratio is greater than the preset ratio is classified as the first measurement spot, and the measurement spot whose actual ratio is less than the first preset ratio is classified as the second measurement spot.
  • Step 0213, step 0214, step 041, step 051, step 061, and step 071 can all be implemented by the calculation module 402. Both step 032 and step 033 can be implemented by the control module 401.
  • Step 0213, step 0214, step 032, step 033, step 041, step 051, step 061, and step 071 may all be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to receive the structured light directly reflected by the calibrated object and directly incident after being emitted from the structured light projector 21 when the reference image is calibrated to obtain the first reference image, When the reference image is calibrated, the structured light camera 22 is controlled to receive the structured light that is diffracted by the display area 11 and reflected directly by the calibrated object when being emitted to obtain a second reference image, compare the first reference image with the second reference image to obtain the second Two reference spots, calculating the ratio between the average value of the brightness of the plurality of second reference spots and the average value of the brightness of the plurality of first reference spots as a preset ratio, and calculating the average of the brightness of the plurality of first reference spots Value as the preset brightness.
  • the processor 200 can also be used to calculate the actual ratio between each measurement spot and the preset brightness, classify the measurement spots whose actual ratio is greater than the preset ratio as the first measurement spots, and classify the measurement spots whose actual ratio is less than the preset ratio It is classified as the second measurement spot.
  • the processor 200 may be further used to calculate the offset of the first measurement spot relative to the first reference spot, and the offset of the second measurement spot relative to the second reference spot, and calculate depth data according to the offset to obtain a depth image .
  • the processor 200 needs to calibrate the first reference image and the second reference image. Specifically, the processor 200 first controls the structured light projector 21 to emit structured light to the calibration plate in a scene without the screen 10 blocking, and then controls the structured light camera 22 to receive the structured light directly reflected by the calibration plate to obtain the first A reference image, where the multiple reference spots included in the first reference image are the first reference spots, the first reference spots are laser beams diffracted by the diffractive optical element 213 when passing through the diffractive optical element 213, and directly exit the calibration plate It is formed by direct reflection after being modulated and reflected by the calibration plate. Subsequently, the processor 200 calibrates the second reference image according to the first calculation method, that is, the reference image calibration method in step 031.
  • the second reference image includes both the first reference spot corresponding to the first measurement spot and the second reference spot corresponding to the second measurement spot.
  • the relative positions between the calibration plate, the structured light projector 21 and the structured light camera 22 remain unchanged, and the structured light projector 21 and the structured light camera 21 The relative position between them also remains unchanged.
  • the processor 200 marks the coordinates of the first reference spot in the first reference image, and filters out the first reference spots in the second reference image according to the coordinates of the first reference spot, and the remaining reference spots in the second reference image This is the second reference spot. In this way, the processor 200 can distinguish the first reference spot and the second reference spot among all reference spots of the second reference image.
  • the measurement spots in the speckle image also need to be distinguished.
  • the first measurement spot and the second measurement spot can be distinguished by brightness. It can be understood that the first measurement spot is formed by the first-order diffraction of laser light through the diffractive optical element 213, and the second measurement spot is formed by the first-order diffraction of the laser light through the diffractive optical element 213 and the second-order diffraction of the display screen 10 to form the second measurement.
  • the number of times the laser spot is diffracted is greater than the number of times the laser spot forming the first measurement spot is diffracted. Therefore, the energy loss of the laser spot forming the first measurement spot is small, and the energy loss of the laser spot forming the second measurement spot is large.
  • the brightness of the second measurement spot will be lower than the brightness of the first measurement spot. As such, it is feasible to distinguish the first measurement spot from the second measurement spot based on the brightness. Then, after the reference image calibration is completed, it is necessary to further calibrate the preset brightness and the preset ratio for distinguishing the first measurement spot from the second measurement spot. Specifically, after the processor 200 distinguishes the first reference spot and the second reference spot, the processor 200 calculates the average value of the brightness of the plurality of first reference spots in the second reference image, and calculates the second reference image The average value of the brightness of the plurality of second reference spots.
  • the processor 200 takes the average value of the brightness of the plurality of first reference spots as the preset brightness, and takes the ratio between the average value of the brightness of the plurality of second reference spots and the average value of the brightness of the plurality of first reference spots As a preset ratio.
  • the processor 200 first calculates the brightness of each measurement spot. Subsequently, the processor 200 calculates the actual ratio between each measurement spot and the preset brightness, and classifies the measurement spots whose actual ratio is greater than or equal to the preset ratio as the first measurement spot, and measures the actual ratio less than the preset ratio The spots are classified as second measurement spots, thereby distinguishing the first measurement spots from the second measurement spots. For example, as shown in FIG. 22, assuming that the preset ratio is 0.8, the speckle image captured by the structured light camera 22 in actual use includes measurement spot A and measurement spot B. Among them, if the ratio between the brightness of the measurement spot A and the preset brightness is less than 0.8, the measurement spot A is classified into the second measurement spot.
  • the measurement spot A is diffracted by the laser through the diffraction optical element 213 and then displayed
  • the measurement spot B is a measurement spot formed by laser light diffracted once by the diffractive optical element 213 and reflected by the target object.
  • the preset ratio of 0.8 is only an example.
  • the processor 200 can use the speckle image and the second measurement spot.
  • Two reference images calculate depth data. Specifically, the processor 200 first calculates the offset of the first measurement spot relative to the first reference spot, and the offset of the second measurement spot relative to the second reference spot. Subsequently, the processor 200 calculates multiple depth data based on multiple offsets, and the multiple depth data can constitute a depth image.
  • the second calculation method distinguishes between the first measurement spot and the second measurement spot, and distinguishes between the first reference spot and the second reference spot, which can be based on the more accurate first measurement spot
  • the corresponding relationship with the first reference spot and the corresponding relationship between the second measurement spot and the second reference spot are calculated to obtain a more accurate offset, further obtain more accurate depth data, and improve the accuracy of the acquired depth image.
  • the preset brightness and the preset ratio are determined by the ambient brightness of the scene and the luminous power of the structured light projector 21. It can be understood that there is an infrared light component in the ambient light, and this part of the infrared light component may be superimposed on the measurement spot to increase the brightness of the measurement spot; the luminous power of the structured light projector 21 is closely related to the brightness of the measurement spot. When it is larger, the brightness of the measurement spot is correspondingly higher; when the luminous power is smaller, the brightness of the measurement spot is correspondingly lower. Therefore, different ambient brightness and luminous power should have different preset brightness and preset ratio.
  • the preset brightness and preset ratio under different ambient brightness and different luminous power can also be calibrated according to the calibration process of step 032 and step 033.
  • the ambient brightness of the calibration scene and the luminous power of the structured light projector 21 are changed to obtain a preset brightness and a preset ratio corresponding to the ambient brightness and luminous power, wherein the light emission of the structured light projector 21 is changed
  • the power can be realized by changing the driving current of the light source 211.
  • the corresponding relationship among the ambient brightness, the luminous power, the preset brightness and the preset ratio can be stored in the memory 300 (shown in FIG. 1) in the form of a mapping table.
  • the processor 200 first obtains the ambient brightness and luminous power of the scene, and looks up the preset brightness and preset ratio corresponding to the current ambient brightness and luminous power in the mapping table, Then, the first measurement spot and the second measurement spot are distinguished based on the searched preset brightness and preset ratio. In this way, the accuracy of the distinction between the first measurement spot and the second measurement spot can be improved.
  • the diffractive optical element 213 can be used to compensate the structured light diffracted by the display screen 10 in addition to diffracting the laser light emitted by the light source 211 of the structured light projector 21 to increase the number of measurement spots or reference spots.
  • the uniformity of the brightness makes the uniformity of the brightness of the multiple spots in the speckle pattern projected into the scene better, which is beneficial to improve the accuracy of acquiring the depth image.
  • the convex or concave structures in the diffractive optical element 213 may be arranged densely in the middle and sparse on both sides, then the diffraction effect of the middle part of the diffractive optical element 213 is stronger than that of the edge part.
  • the laser light incident on the middle portion of the diffractive optical element 213 can be diffracted with more light beams, and the laser light incident on the edge portion of the diffractive optical element 213 can be diffracted with less light beams, thereby making the speckle projected into the scene
  • the brightness of the pattern has high uniformity.
  • both the structured light projector 21 and the structured light camera 22 are located on the display screen 10
  • the processor 200 can directly calculate the depth image based on the first measurement spot and the second measurement spot, compared to By using only the first measurement spot to calculate the depth image, the diffraction effect of the display screen 10 increases the number of measurement spots and the randomness of the arrangement of the measurement spots, which is beneficial to improve the accuracy of acquiring the depth image.
  • the image acquisition method according to the embodiment of the present application can appropriately simplify the complexity of the structure of the diffraction grating in the diffractive optical element 213, and in turn, the number of measurement spots and the randomness of the arrangement are increased by the diffraction effect of the display screen 10, While ensuring the accuracy of acquiring the depth image, the manufacturing process of the structured light projector 21 can be simplified.
  • step 01 includes:
  • the speckle image includes a plurality of measurement spots, and the plurality of measurement spots including the laser light is only The first measurement spot diffracted by the diffractive optical element 213 and reflected by the target object and the second measurement spot formed by the laser beam diffracted once by the diffractive optical element 213 and secondarily diffracted by the display screen 10 and reflected by the target object; specifically, the first The measurement spot is formed after the laser beam is diffracted by the diffractive optical element 213 and is not diffracted by the display screen 10 when passing through the display screen 10, that is, it is directly projected onto the target object without encountering a micro gap, and is modulated and reflected by the target object; second The measurement spot is formed by the laser beam diffracted by the diffractive optical element 213 and then diffracted by the display screen 10 after passing through the display screen 10, that is, it is
  • Step 02 includes:
  • Step 011 may be implemented by the control module 401.
  • Both step 022 and step 023 can be implemented by the calculation module 402.
  • Step 011, step 022, and step 023 may all be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to receive the structured light diffracted by the display area 11 and reflected directly by the target object when it is emitted to obtain a speckle image and filter out the second of the speckle images The speckle is measured to obtain a first measurement spot, and a depth image is obtained according to the first measurement spot and the reference spot in the reference image.
  • the structure The optical camera 22 captures a speckle image containing the first measurement spot and the second measurement spot.
  • the processor 200 may filter out the second measurement spots in the speckle image, and only calculate the depth image based on the remaining first measurement spots with the reference spots in the reference image.
  • the reference spot in the reference image should include only the first reference spot formed by a plurality of laser beams diffracted only by the diffractive optical element 213 and reflected by the calibration object.
  • the influence of the display screen 10 on the structured light can be eliminated, so that the depth image acquired by the electronic device 1000 can be ensured when the screen footprint of the electronic device 1000 is relatively high.
  • the accuracy is also higher.
  • the image acquisition method also includes:
  • the structured light camera 22 is controlled to receive the structured light directly reflected by the calibrated object after being emitted from the structured light projector 21 and directly incident to obtain a first reference image, and the first reference image includes multiple reference spots
  • the multiple reference spots include a first reference spot formed by multiple laser beams diffracted by the diffractive optical element 213 only and reflected by the calibration object;
  • Step 023 includes:
  • Step 032 may be implemented by the control module 401. Both Step 0231 and Step 0232 can be implemented by the calculation module 402.
  • Step 032, step 0231, and step 0232 may all be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to receive the structured light directly reflected by the calibrated object after being emitted from the structured light projector 21 and directly incident when the reference image is calibrated to obtain the first reference image and calculate the first A measurement spot is offset from the first reference spot, and depth data is calculated according to the offset to obtain a depth image.
  • the speckle image should be the first reference image containing only the first reference spots corresponding to the first measurement spots To calculate the depth image.
  • the calibration process of the first reference image is the same as the calibration process of placing the structured light projector 21 in a scene that is not covered by the display screen 10 in step 032, and will not be repeated here.
  • the multiple reference spots in the first reference image captured by structured light are the first reference spots formed by laser light diffracted only by the diffractive optical element 213 and reflected by the calibration object. In this way, the processor 200 can calculate the offset of the first measurement spot relative to the first reference spot, and then calculate multiple depth data based on the multiple offsets to obtain a depth image.
  • the processor 200 may filter out the second measurement spot by brightness. That is to say, referring to FIG. 25, in some embodiments, the image acquisition method further includes:
  • the structured light camera 22 is controlled to receive the structured light directly reflected by the calibrated object and directly incident after exiting from the structured light projector 21 to obtain a first reference image, and the first reference image includes multiple Reference spots, the multiple reference spots include a first reference spot formed by a plurality of laser beams diffracted only by the diffractive optical element 213 and reflected by the calibration object;
  • the structured light camera 22 is controlled to receive the structured light diffracted by the display area 11 and reflected directly by the calibrated object when being emitted to obtain a second reference image, which includes a plurality of reference spots,
  • the multiple reference spots include a first reference spot formed by laser light diffracted by the diffractive optical element 213 and reflected by the calibration object and a laser beam diffracted once by the diffractive optical element 213 and then diffracted by the display screen 10 twice and reflected by the calibration object Two reference spots;
  • Step 022 includes:
  • 0223 Filter out the second measurement spot from all the measurement spots to obtain the first measurement spot.
  • Step 032 and step 033 can be implemented by the control module 401.
  • Step 041, step 051, step 0221, step 0222, and step 0223 can all be implemented by the calculation module 401.
  • Step 032, step 033, step 041, step 051, step 0221, step 0222 and step 0223 can all be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to receive the structured light directly reflected by the calibrated object after being emitted from the structured light projector 21 and directly incident when the reference image is calibrated to obtain the first reference image, and When the reference image is calibrated, the structured light camera 22 is controlled to receive the structured light directly diffracted by the display area 11 and reflected by the calibration object when it is emitted to obtain a second reference image.
  • the processor 200 may also be used to compare the first reference image and the second reference image to obtain the second reference spot, and calculate the average value of the brightness of the plurality of second reference spots and the average value of the brightness of the plurality of first reference spots
  • the ratio is used as the preset ratio
  • the average value of the brightness of the plurality of first reference spots is calculated and used as the preset brightness.
  • the processor 200 can also be used to calculate the actual ratio between each measurement spot and the preset brightness, classify the measurement spots whose actual ratio is greater than the preset ratio as the first measurement spots, and classify the measurement spots whose actual ratio is less than the preset ratio It is classified as a second measurement spot, and the second measurement spot is filtered out from all the measurement spots to obtain the first measurement spot.
  • the process of calibrating the first reference image described in step 032 is the same as the calibration process of calibrating the structured light projector 21 in the scene that is not blocked by the display screen 10 in step 032, and the second calibration described in step 033
  • the process of the reference image and the aforementioned step 031 place the structured light projector 21 and the structured light camera 22 on the side of the back side 13 of the display screen 10, and the light incident surface of the structured light camera 22 is aligned with the through slot 14 of the display screen 10
  • the calibration process for calibration in the same scenario is the same and will not be repeated here.
  • the processor 200 may use the same method as the foregoing step 041, that is, determine the first in the second reference image according to the coordinates of the first reference spot in the first reference image The reference spot, and the remaining reference spot is the second reference spot, thereby distinguishing the first reference spot and the second reference spot. Subsequently, the processor 200 can calculate the preset brightness and the preset ratio based on the distinguished first reference spot and second reference spot calibration in the same manner as the foregoing step 051.
  • the processor 200 may adopt the same manner as the aforementioned step 061 and the aforementioned step 071, that is, distinguish the first measurement spot from the second based on the calibrated preset ratio and preset brightness Measure the spots, then filter out the second measurement spots, leaving only the first measurement spots, then calculate the offset of the first measurement spots relative to the first reference spots, and finally calculate the depth data based on the offsets, thereby obtaining the depth image .
  • the preset brightness and the preset ratio are also determined by the ambient brightness of the scene and the luminous power of the structured light projector 21. In this way, the accuracy of filtering out the second measurement spot can be improved.
  • the diffractive optical element 213 can be used to compensate the structured light diffracted by the display screen 10 in addition to diffracting the laser light emitted by the light source 211 of the structured light projector 21 to increase the number of measurement spots or reference spots.
  • the uniformity of the brightness makes the uniformity of the brightness of the multiple spots in the speckle pattern projected into the scene better, which is beneficial to improve the accuracy of acquiring the depth image.
  • the structured light projector 21 and the structured light are located under the display screen 10
  • the structured light camera 22 receives the modulated structured light passing through the through slot 14, it is filtered first
  • the second measurement spot calculates the depth image based only on the remaining first measurement spot, which reduces the amount of data processing by the processor 200 and helps speed up the process of acquiring the depth image.
  • step 01 includes:
  • the structured light camera 22 Control the structured light camera 22 to receive the structured light diffracted by the display area 11 and reflected by the target object when it is emitted and then diffracted by the display area 11 to obtain a speckle image.
  • the speckle image includes multiple measurement spots, multiple The measurement spot includes a laser beam that is diffracted only once by the diffractive optical element 213 (shown in FIG. 4) and reflected by the target object.
  • the laser beam passes through the diffractive optical element 213 and is diffracted once by the display screen 10 and diffracted again by the target object
  • the second measurement spot is that the laser beam is diffracted by the display screen 10 after being diffracted by the diffractive optical element 213, and then diffracted by the display screen 10 After being projected onto the target object, it is not diffracted by the display screen 10 when it is modulated and reflected by the target object and passes through the display screen 10 again; the
  • Step 02 includes:
  • Step 012 may be implemented by the control module 401.
  • Step 024 can be implemented by the calculation module 402.
  • step 012 and step 024 may be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to receive the structured light diffracted by the display area 11 when it is emitted and reflected by the target object and then diffracted by the display area 11 after being incident to obtain a speckle image. The processor 200 may also be used to calculate a depth image based on the first measurement spot, the second measurement spot, and the third measurement spot in the speckle image and the reference spot in the reference image.
  • the light source 211 of the structured light projector 21 emits laser light to be diffracted by the diffractive optical element 213 to form structured light and project it into the scene to form a speckle pattern.
  • the speckle pattern includes a plurality of spots, which are formed by the diffraction of laser light only through the diffractive optical element 213.
  • the structured light camera 22 When the structured light camera 22 is imaging, the structured light camera 22 receives the structured light reflected by the target object in the scene to form a speckle image.
  • the display screen 10 since the display screen 10 does not have a through slot 14, the first diffraction by the diffractive optical element 213 and the second diffraction by the display screen 10, and the laser light reflected back after being modulated by the target object will pass through the display screen 10 again Diffracted by the display area 11 in the display screen 10, the structured light camera 22 receives the diffraction by the display area 11 when passing through the display area 11 after being emitted, and is diffracted by the display area 11 again after passing through the display area 11 after being reflected by the target object Structured light, the multiple measurement spots in the formed speckle image also include the first measurement spot formed by laser light diffracted only by the diffractive optical element 213 and reflected by the target object.
  • the processor 200 can directly calculate the depth image from the first measurement spot, the second measurement spot, the third measurement spot, and the reference image in the speckle image.
  • the multiple reference spots in the reference image need to include a first reference spot, a second reference spot, and a third reference spot.
  • the calculation method of the depth image may include the following two.
  • step 024 includes:
  • the image acquisition method also includes:
  • the structured light camera 22 is controlled to receive the structured light diffracted by the display area 11 when it is emitted and diffracted by the display area 22 after being reflected by the calibrated object to obtain the reference image. spot.
  • Step 0241 and step 0242 can be implemented by the calculation module 402.
  • Step 034 can be implemented by the control module 401.
  • Step 0241, step 0242, and step 034 may be implemented by the processor 200. That is to say, the processor 200 can also be used to calculate the offsets of all measurement spots relative to all reference spots, and calculate depth data according to the offsets to obtain depth images.
  • the processor 200 can also be used to control the structured light camera 22 to receive the structured light diffracted by the display area 11 when diffracted by the display area 11 and reflected by the calibrated object and then diffracted by the display area 22 when it is incident to obtain the reference image. Includes multiple reference spots.
  • the structured light projector 21 and the structured light camera 22 are both disposed on the side of the back surface 13 of the display screen 10, and the display screen 10 is not provided with a through slot 14.
  • the processor 200 controls the structured light projector 21 to emit structured light.
  • the structured light passes through the display area 11 and is projected to the calibration plate at a predetermined distance from the structured light assembly 20.
  • the structured light reflected back by the calibration plate again After passing through the display area 11, it is received by the structured light camera 22.
  • the structured light camera 22 receives the structured light emitted by the structured light projector 21, diffracted by the display screen 10, reflected by the calibration plate, and then diffracted through the display screen 10.
  • the formed reference image includes many Reference spots.
  • the reference spots simultaneously include a first reference spot corresponding to the first measurement spot, a second reference spot corresponding to the second measurement spot, and a third reference spot corresponding to the third measurement spot.
  • the first reference spot is that the laser light is diffracted by the diffractive optical element 213 once when passing through the diffractive optical element 213, and is not diffracted by the display screen 10 after passing through the display screen 10, and is reflected by the calibration plate and still passes through the display screen 10 when it passes through the display screen 10 again. 10 formed by diffraction.
  • the second reference spot is that the laser light is diffracted by the diffractive optical element 213 once when passing through the diffractive optical element 213, and is secondarily diffracted by the display screen 10 after passing through the display screen 10, and is reflected by the calibration plate, but not by the display screen after passing through the display screen 10 again 10 formed by diffraction.
  • the third reference spot is that the laser light is first diffracted by the diffractive optical element 213 when passing through the diffractive optical element 213, and is secondarily diffracted by the display screen 10 after passing through the display screen 10, and reflected by the calibration plate, and then by the display screen 10 after passing through the display screen 10 again Formed by the third diffraction.
  • the speckle image includes the first measurement spot, the second measurement spot, and the third measurement spot
  • the reference image includes the first reference spot, the second reference spot, and the third reference spot at the same time.
  • the processor 200 does not distinguish between the first measurement spot, the second measurement spot, and the third measurement spot in the speckle image, nor does it distinguish the first reference spot, the second measurement spot in the reference image.
  • the second reference spot and the third reference spot are distinguished, but the depth image is calculated directly based on all the measurement spots and all the reference spots. Specifically, the processor 200 first calculates the offsets of all measurement spots relative to all reference spots, and then calculates multiple depth data based on the multiple offsets, thereby obtaining a depth image.
  • step 024 includes:
  • 0243 Calculate the offset of the first measurement spot relative to the first reference spot, the offset of the second measurement spot relative to the second reference spot, and the offset of the third measurement spot relative to the third reference spot;
  • the image acquisition method also includes:
  • the structured light camera 22 is controlled to receive the structured light directly reflected by the calibrated object and directly incident after exiting from the structured light projector 21 to obtain a first reference image, and the first reference image includes multiple reference spots
  • the multiple reference spots include a first reference spot formed by multiple laser beams diffracted by the diffractive optical element 213 only and reflected by the calibration object;
  • the structured light camera 22 is controlled to receive the structured light that is diffracted by the display area 11 and reflected directly by the calibrated object when being emitted to obtain a second reference image
  • the second reference image includes multiple reference spots
  • the multiple reference spots include a first reference spot formed by laser light diffracted only by the diffractive optical element 213 and reflected by the calibrated object, and a second reference spot formed by the laser light diffracted once by the diffractive optical element 213 and then diffracted by the display screen 10 twice and reflected by the calibrated object Reference spot
  • the structured light camera 22 is controlled to receive the structured light diffracted by the display area 11 and diffracted by the display area 11 when it is diffracted by the display area 11 and reflected by the calibration object to obtain the third reference image.
  • the third reference image includes multiple reference spots.
  • the multiple reference spots include a first reference spot formed by laser light diffracted only by the diffractive optical element 213 and reflected by the calibration object.
  • the laser light is diffracted by the diffractive optical element 213 once and then diffracted by the display screen 10
  • the second reference spot diffracted and reflected by the calibration object, and the laser beam is diffracted once by the diffractive optical element 213 and then diffracted again by the display panel 10 and reflected by the calibration object. spot;
  • 042 Compare the first reference image with the second reference image to obtain the second reference spot, and compare the third reference image with the second reference image to obtain the third reference spot;
  • Step 0243, step 0244, step 042, step 052, step 062, and step 072 may all be implemented by the calculation module 402.
  • Step 035, step 036, and step 037 can all be implemented by the control module 401.
  • Step 0243, step 0244, step 035, step 036, step 037, step 042, step 052, step 062, and step 072 may all be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to receive the structured light that is directly reflected by the calibrated object and directly incident after being emitted from the structured light projector 21 when the reference image is calibrated to obtain the first reference image.
  • the structured light camera 22 is controlled to receive the structured light that is diffracted by the display area 11 and reflected directly by the calibrated object when being emitted to obtain a second reference image, and when the reference image is calibrated, the structured light camera 22 is controlled to receive and display the emitted light After the area 11 is diffracted and reflected by the calibration object, the structured light is diffracted by the display area 11 again when incident through the display area 11 to obtain a third reference image.
  • the processor 200 may also be used to compare the first reference image and the second reference image to obtain a second reference spot, and to compare the third reference image and the second reference image to obtain a third reference spot, and calculate a plurality of second reference spots
  • the ratio between the average values is used as the second preset ratio, and the average value of the brightness of the plurality of first reference spots is calculated and used as the preset brightness.
  • the processor 200 can also be used to calculate the actual ratio between each measured spot and the preset brightness, classify the measured spots whose actual ratio is greater than the first preset ratio as the first measured spot, and classify the actual ratio as being smaller than the first preset ratio
  • the measurement spots larger than the second preset ratio are classified as second measurement spots, and the measurement spots whose actual ratio is smaller than the second preset ratio are classified as third measurement spots.
  • the processor 200 needs to calibrate the first reference image, the second reference image, and the third reference image.
  • the processor 200 first controls the structured light projector 21 to emit structured light to the calibration plate in a scene without the screen 10 blocking, and then controls the structured light camera 22 to receive the structured light directly reflected by the calibration plate to obtain the first One reference image.
  • the multiple reference spots included in the first reference image are the first reference spots.
  • the first reference spots are laser beams diffracted by the diffractive optical element 213 when passing through the diffractive optical element 213, and are directly emitted to the calibration plate and modulated by the calibration plate It is formed by direct incidence after reflection.
  • both the structured light projector 21 and the structured light camera 22 are provided on the side of the back surface 13 of the display screen 10, and the display screen 10 is provided with a through slot 14 aligned with the light incident surface of the structured light camera 22, structured light
  • the processor 200 controls the structured light projector 21 to emit structured light.
  • the structured light passes through the display area 11 and is projected to a predetermined distance from the structured light assembly 20
  • the structured light reflected by the calibration plate passes through the through slot 14 and is received by the structured light camera 22 to obtain a second reference image.
  • the multiple reference spots in the second reference image include both the first reference spot and the second reference spot.
  • the first reference spot is formed when the laser light is diffracted by the diffractive optical element 213 when passing through the diffractive optical element 213, and is not diffracted by the display screen 10 after passing through the display screen 10, and is modulated and reflected by the calibration plate;
  • the second reference spot is formed by the laser light
  • the diffractive optical element 213 is diffracted once by the diffractive optical element 213, and when passing through the display screen 10, it is diffracted again by the display screen 10, and is modulated and reflected by the calibration plate.
  • the processor 200 calibrates the third reference image according to the first calculation method, that is, the reference image calibration method described in step 034.
  • the third reference image includes a first reference spot corresponding to the first measurement spot, a second reference spot corresponding to the second measurement spot, and a third reference spot corresponding to the third measurement spot.
  • the relative position between the calibration plate, the structured light projector 21 and the structured light camera 22 remains unchanged, and the structured light projector The relative position between 21 and structured light camera 21 also remains unchanged.
  • the processor 200 first marks the first coordinates of the first reference spot in the first reference image, and then filters out the first reference spots in the second reference image according to the coordinates of the first reference spot, and the remaining in the second reference image
  • the reference spot is the second reference spot.
  • the processor 200 marks the second coordinates of the second reference spot in the second reference image.
  • the processor 200 filters out the first reference spot and the second reference spot in the third reference image according to the first coordinate and the second coordinate in the second reference image, and the remaining reference spot in the third reference image is the third Reference spots. In this way, the processor 200 can distinguish the first reference spot, the second reference spot, and the third reference spot among all reference spots of the third reference image.
  • the measurement spots in the speckle image also need to be distinguished.
  • the first measurement spot, the second measurement spot, and the third measurement spot can be distinguished by brightness. It can be understood that the first measurement spot is formed by the first order diffraction of the laser light through the diffractive optical element 213, the second measurement spot is formed by the first order diffraction of the laser light through the diffractive optical element 213 and the second order diffraction of the display screen 10, and the third measurement spot It is formed by the first diffraction of the diffractive optical element 213 and the second and third diffraction of the display screen 10.
  • the laser beam forming the second measurement spot is diffracted more times than the laser beam forming the first measurement spot is diffracted to form the third measurement
  • the number of times the laser spot is diffracted is greater than the number of times the laser spot forming the second measurement spot is diffracted. Therefore, the energy loss of the laser spot forming the first measurement spot is the smallest, and the energy loss of the laser spot forming the third measurement spot is the largest.
  • the brightness of the second measurement spot will be lower than the brightness of the first measurement spot, and the brightness of the third measurement spot will be lower than the brightness of the second measurement spot. As such, it is feasible to distinguish the first measurement spot, the second measurement spot, and the spot measurement spot based on the brightness.
  • the processor 200 distinguishes the first reference spot, the second reference spot, and the third reference spot
  • the processor 200 calculates the average value of the brightness of the plurality of first reference spots in the third reference image, and calculates The average value of the brightness of the plurality of second reference spots in the third reference image and the average value of the brightness of the plurality of third reference spots in the third reference image are obtained.
  • the processor 200 takes the average value of the brightness of the plurality of first reference spots as the preset brightness, and takes the ratio between the average value of the brightness of the plurality of second reference spots and the average value of the brightness of the plurality of first reference spots As the first preset ratio, a ratio between the average value of the brightness of the plurality of third reference spots and the average value of the brightness of the plurality of first reference spots is taken as the second preset ratio.
  • the processor 200 first calculates the brightness of each measurement spot. Subsequently, the processor 200 calculates the actual ratio between each measurement spot and the preset brightness, and classifies the measurement spot whose actual ratio is greater than or equal to the first preset ratio as the first measurement spot, and classifies the actual ratio as being less than the first preset
  • the measurement spots whose ratio is greater than or equal to the second preset ratio are classified as the second measurement spots, and the measurement spots whose actual ratio is less than the second preset ratio are classified as the third measurement spots, thereby distinguishing the first measurement spots, The second measurement spot and the third measurement. For example, as shown in FIG.
  • the speckle image captured by the structured light camera 22 in actual use includes measurement spot A, measurement spot B, and measurement spot C.
  • the measurement spot A is classified as the second measurement spot, which means that the measurement spot A is the laser light passing through the diffractive optical element 213 Measurement spot formed by first diffraction and second order diffraction by the display screen 10 and reflected by the target object; if the ratio between the brightness of the measurement spot B and the preset brightness is greater than or equal to 0.8, the measurement spot B is classified as the first In the measurement spot, it is stated that the measurement spot B is a measurement spot formed by laser light diffracted once by the diffractive optical element 213 and reflected by the target object; if the ratio between the brightness of the measurement spot C and the preset brightness is less than 0.6, the measurement spot will be measured C is classified into the third measurement spot.
  • the measurement spot C is a measurement that the laser beam is diffracted once by the diffractive optical element 213 and then diffracted again by the display screen 10 and reflected by the calibration object. spot.
  • the preset ratios 0.8 and 0.6 are only examples.
  • process The device 200 can use the speckle image and the third reference image to calculate the depth data. Specifically, the processor 200 first calculates the offset of the first measurement spot relative to the first reference spot, the offset of the second measurement spot relative to the second reference spot, and the offset of the third measurement spot relative to the third reference spot Displacement. Subsequently, the processor 200 calculates multiple depth data based on multiple offsets, and the multiple depth data can constitute a depth image.
  • the second calculation method distinguishes the first measurement spot, the second measurement spot, and the third measurement spot, and distinguishes the first reference spot, the second reference spot, and the third reference spot, It can be calculated based on the more accurate correspondence between the first measurement spot and the first reference spot, the correspondence between the second measurement spot and the second reference spot, and the correspondence between the third measurement spot and the third reference spot.
  • the offset of the data can further obtain more accurate depth data and improve the accuracy of the acquired depth image.
  • the preset brightness, the first preset ratio and the second preset ratio are determined by the ambient brightness of the scene and the luminous power of the structured light projector 21. In this way, the accuracy of distinguishing the first measurement spot, the second measurement spot, and the third measurement spot can be improved.
  • the diffractive optical element 213 can be used to compensate the structured light diffracted by the display screen 10 in addition to diffracting the laser light emitted by the light source 211 of the structured light projector 21 to increase the number of measurement spots or reference spots.
  • the uniformity of the brightness makes the uniformity of the brightness of the multiple spots in the speckle pattern projected into the scene better, which is beneficial to improve the accuracy of acquiring the depth image.
  • both the structured light projector 21 and the structured light camera 22 are located on the side of the back 13 of the display screen 10, and the structured light camera 22 receives the image twice through the display area 11
  • the processor 200 can directly calculate the depth image based on the first measurement spot, the second measurement spot, and the third measurement spot.
  • the display screen 10 The diffractive effect increases the number of measurement spots and the randomness of the arrangement of measurement spots, which is beneficial to improve the accuracy of acquiring depth images.
  • the image acquisition method according to the embodiment of the present application can appropriately simplify the complexity of the structure of the diffraction grating in the diffractive optical element 213, and in turn, the number of measurement spots and the randomness of the arrangement are increased by the diffraction effect of the display screen 10, While ensuring the accuracy of acquiring the depth image, the manufacturing process of the structured light projector 21 can be simplified.
  • step 01 includes:
  • the speckle image includes multiple measurement spots, multiple The measurement spot includes a first measurement spot where the laser light is diffracted only once by the diffractive optical element 213 and reflected by the target object, and a second measurement is formed when the laser light is diffracted once by the diffractive optical element 213 and then diffracted by the display screen 10 twice and reflected by the target object.
  • the speckle and the laser are diffracted once by the diffractive optical element 213 and then diffracted again by the display screen 10 and reflected by the target object.
  • the third measurement spot is formed by the third diffraction of the display screen 10; specifically, the first measurement spot is the laser
  • the diffractive optical element 213 is not diffracted by the display screen 10 after passing through the display screen 10, that is, it is directly projected onto the target object without encountering a micro gap, and is formed after being modulated and reflected by the target object;
  • the second measurement spot is the laser light passing through
  • the diffractive optical element 213 is diffracted by the display screen 10 after passing through the display screen 10 after being diffracted, that is, projected after encountering a micro gap
  • the target object, which is modulated and reflected by the target object is not diffracted by the display screen 10 when it passes through the display screen 10 again;
  • the third measurement spot is that the laser light is diffracted by the diffractive optical element 213 after passing through the display screen 10 and then diffracted by the display screen 10. It is projected to the target object after reaching the microscopic gap, and is modulated and reflected by the target object, passes through the display screen
  • Step 02 includes:
  • Step 012 may be implemented by the control module 401. Both step 025 and step 026 can be implemented by the calculation module 402.
  • Step 012, step 025, and step 026 may be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to receive the structured light diffracted by the display area 11 when diffracted by the display area 11 after being emitted and reflected by the target object and then diffracted by the display area 11 to obtain a speckle image and filter out scattered light
  • the second measurement spot and the third measurement spot in the spot image to obtain the first measurement spot
  • the depth image is obtained according to the first measurement spot and the reference spot in the reference image.
  • the structured light camera 22 captures the first measurement Speckle images of spots, second measurement spots and third measurement spots.
  • the processor 200 may filter out the second measurement spot and the third measurement spot in the speckle image, and only use the remaining first measurement spot to do the depth image with the reference spot in the reference image Calculation.
  • the reference spot in the reference image should include only the first reference spot formed by a plurality of laser beams diffracted only by the diffractive optical element 213 and reflected by the calibration object.
  • the influence of the display screen 10 on the structured light can be eliminated, thereby ensuring that the electronic device 1000 has a relatively high screen footprint, the electronic device 1000 The accuracy of the acquired depth image is also high.
  • the image acquisition method also includes:
  • the structured light camera 22 is controlled to receive the structured light directly reflected by the calibrated object and directly incident after exiting from the structured light projector 21 to obtain a first reference image, and the first reference image includes multiple reference spots
  • the multiple reference spots include a first reference spot formed by multiple laser beams diffracted by the diffractive optical element 213 only and reflected by the calibration object;
  • Step 026 includes:
  • Step 035 may be implemented by the control module 401. Both step 0261 and step 0262 can be implemented by the calculation module 402.
  • Step 035, step 0261, and step 0262 can all be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to receive the structured light directly reflected by the calibrated object after being emitted from the structured light projector 21 and directly incident when the reference image is calibrated to obtain the first reference image and calculate the first A measurement spot offset relative to the first reference spot, and calculating depth data according to the offset to obtain a depth image.
  • the speckle image should now contain only the first reference spot corresponding to the first measurement spot
  • the first reference image is used to calculate the depth image.
  • the calibration process of the first reference image is the same as the calibration process of placing the structured light projector 21 in a scene that is not covered by the display screen 10 in step 035, which will not be repeated here.
  • the multiple reference spots in the first reference image captured by structured light are the first reference spots formed by laser light diffracted only by the diffractive optical element 213 and reflected by the calibration object. In this way, the processor 200 can calculate the offset of the first measurement spot relative to the first reference spot, and then calculate multiple depth data based on the multiple offsets to obtain a depth image.
  • the processor 200 may filter out the second measurement spot and the third measurement spot by brightness. That is to say, referring to FIG. 33, in some embodiments, the image acquisition method further includes:
  • the structured light camera 22 is controlled to receive the structured light directly reflected by the calibrated object and directly incident after exiting from the structured light projector 21 to obtain a first reference image, and the first reference image includes multiple reference spots
  • the multiple reference spots include a first reference spot formed by multiple laser beams diffracted by the diffractive optical element 213 only and reflected by the calibration object;
  • the structured light camera 22 is controlled to receive the structured light that is diffracted by the display area 11 and reflected directly by the calibrated object when being emitted to obtain a second reference image, and the second reference image includes multiple reference spots,
  • the multiple reference spots include a first reference spot formed by laser light diffracted by the diffractive optical element 213 and reflected by the calibration object and a laser beam diffracted once by the diffractive optical element 213 and then diffracted by the display screen 10 twice and reflected by the calibration object Two reference spots;
  • the structured light camera 22 is controlled to receive the structured light diffracted by the display area 11 and diffracted by the display area 11 when it is diffracted by the display area 11 and reflected by the calibration object to obtain the third reference image.
  • the third reference image includes multiple reference spots.
  • the multiple reference spots include a first reference spot formed by laser light diffracted only by the diffractive optical element 213 and reflected by the calibration object.
  • the laser light is diffracted by the diffractive optical element 213 once and then diffracted by the display screen 10
  • the second reference spot diffracted and reflected by the calibration object, and the laser beam is diffracted once by the diffractive optical element 213 and then diffracted again by the display panel 10 and reflected by the calibration object. spot;
  • 052 Calculate the ratio between the average value of the brightness of the plurality of second reference spots and the average value of the brightness of the plurality of first reference spots as the first preset ratio, and calculate the plurality of third The ratio between the average value of the brightness of the reference spots and the average value of the brightness of the plurality of first reference spots is used as the second preset ratio, and the average value of the brightness of the plurality of first reference spots is calculated and As the preset brightness;
  • Step 025 includes:
  • the measurement spots whose actual ratio is greater than the first preset ratio are classified as the first measurement spots, and the measurement spots whose actual ratio is less than the first preset ratio and greater than the second preset ratio are classified as the second measurement spots, and Measurement spots whose actual ratio is less than the second preset ratio are classified as third measurement spots;
  • 0253 Filter the second measurement spot and the third measurement spot from all the measurement spots to obtain the first measurement spot.
  • Step 035, step 036, and step 037 may all be implemented by the control module 401.
  • Step 042, step 052, step 0251, step 0252, and step 0253 can all be implemented by the calculation module 401.
  • Step 035, step 036, step 037, step 042, step 052, step 0251, step 0252, and step 0253 can all be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to receive the structured light that is directly reflected by the calibrated object and directly incident after being emitted from the structured light projector 21 when the reference image is calibrated to obtain the first reference image.
  • the structured light camera 22 is controlled to receive the structured light that is diffracted by the display area 11 and reflected directly by the calibrated object when being emitted to obtain a second reference image, and when the reference image is calibrated, the structured light camera 22 is controlled to receive and display the emitted light After the area 11 is diffracted and reflected by the calibration object, the structured light is diffracted by the display area 11 again when incident through the display area 11 to obtain a third reference image.
  • the processor 200 may be further used to compare the first reference image with the second reference image to obtain the second reference spot, and compare the third reference image with the second reference image to obtain the first Three reference spots, calculating a ratio between the average value of the brightness of the plurality of second reference spots and the average value of the brightness of the plurality of first reference spots as the first preset ratio, calculating a plurality of The ratio between the average value of the brightness of the third reference spots and the average value of the brightness of the plurality of first reference spots is used as the second preset ratio, and the average of the brightness of the plurality of first reference spots is calculated Value as the preset brightness.
  • the processor 200 can also be used to calculate the actual ratio between each measured spot and the preset brightness, classify the measured spots whose actual ratio is greater than the first preset ratio as the first measured spot, and classify the actual ratio as being smaller than the first preset ratio
  • the measurement spots that are greater than the second preset ratio are classified as second measurement spots, the measurement spots whose actual ratio is less than the second preset ratio are classified as third measurement spots, and the second measurement spots are filtered out of all measurement spots And the third measurement spot to obtain the first measurement spot.
  • the process of calibrating the first reference image described in step 035 is the same as the calibration process in step 035 where the structured light projector 21 is placed in a scene that is not blocked by the display screen 10, and the second process described in step 036
  • the process of the reference image and the foregoing step 036 place the structured light projector 21 and the structured light camera 22 on the side of the back side 13 of the display screen 10, and the structured light camera 22 enters the light surface and aligns with the through slot 14 of the display screen 10
  • the calibration process for the calibration in the same scenario is the same.
  • the process of calibrating the third reference image described in step 037 is the same as that in the previous step 037.
  • the structured light projector 21 and the structured light camera 22 are placed on the back side 13 of the display screen 10
  • the calibration process for the calibration in the scenario where the display screen 10 does not have the through slot 14 is consistent, and will not be repeated here.
  • the processor 200 can determine the first coordinate of the first reference spot in the first reference image in the same manner as the foregoing step 042
  • the first reference spot in the second reference image, the remaining reference spot in the second reference image is the second reference spot, and the second coordinates of the second reference spot are marked to distinguish the first reference spot in the second reference image And the second reference spot.
  • the processor 200 determines the first reference spot and the second reference spot in the third reference image according to the first coordinate and the second coordinate, and the remaining reference spot in the third reference image is the third The reference spots, so that the first reference spots, the second reference spots, and the third reference spots in the third reference image can be distinguished.
  • the processor 200 can calibrate to obtain the preset brightness, the first preset ratio, and the second preset based on the distinguished first reference spot, second reference spot, and third reference spot in the same manner as the foregoing step 052 ratio.
  • the processor 200 may adopt the same method as the foregoing step 062 and the foregoing step 072, that is, distinguish based on the calibrated first preset ratio, second preset ratio, and preset brightness
  • the first measurement spot, the second measurement spot and the third measurement spot are filtered out, and then the second measurement spot and the third measurement spot are filtered out, leaving only the first measurement spot, and then calculating the first measurement spot relative to the first reference spot
  • the offset, and finally the depth data is calculated based on the offset to obtain a depth image.
  • the preset brightness, the first preset ratio and the second preset ratio are also determined by the ambient brightness of the scene and the luminous power of the structured light projector 21. In this way, the accuracy of filtering the second measurement spot and the third measurement spot can be improved.
  • the diffractive optical element 213 can be used to compensate the structured light diffracted by the display screen 10 in addition to diffracting the laser light emitted by the light source 211 of the structured light projector 21 to increase the number of measurement spots or reference spots.
  • the uniformity of the brightness makes the uniformity of the brightness of the multiple spots in the speckle pattern projected into the scene better, which is beneficial to improve the accuracy of acquiring the depth image.
  • the second measurement spot and the third measurement spot are filtered out first Calculating the depth image only based on the remaining first measurement spots reduces the amount of data processing by the processor 200, which is beneficial to speed up the process of acquiring the depth image.
  • the electronic device 1000 when the structured light projector 21 is disposed on the side of the back surface 13 of the display screen 10, the electronic device 1000 further includes a compensation optical element 500.
  • the compensation optical element 500 is provided between the diffractive optical element and the display screen 10.
  • the structured light emitted by the structured light projector 21 sequentially passes through the compensation optical element 500 and the display screen 10 and exits into the scene.
  • the compensation optical element 500 is used to cancel the diffraction effect of the display screen 10.
  • the structured light camera 22 may be disposed on the side of the back surface 13 of the display screen 10, and the display screen 10 may not have a through slot 14, correspondingly, the structured light camera 22 receives the compensation optical element 500 and the display area 11 sequentially , The display area 11, the modulated structured light of the compensation optical element 500; or, the structured light camera 22 may be provided on the side of the back 13 of the display screen 10, and the display screen 10 is provided with a through slot 14, the structured light camera 22 The light incident surface is aligned with the through slot 14, and correspondingly, the structured light camera 22 receives the modulated structured light that sequentially passes through the compensation optical element 500, the display area 11, and the through slot 14.
  • Step 01 includes:
  • the compensation optical element 500 is used to offset the display screen 10 Diffraction, the speckle image includes multiple measurement spots, and the multiple measurement spots include measurement spots formed by laser light diffracted only by the diffractive optical element 213 and reflected by the target object;
  • step 013 may be implemented by the control module 401.
  • Step 013 may be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to receive the structured light that passes through the compensation optical element 500 and the display area 11 of the display screen 10 and is reflected by the target object in order to obtain a speckle image.
  • a compensation optical element 500 is provided between the structured light projector 21 and the display screen 10 to offset the diffraction effect of the display screen 10.
  • the compensation optical element 500 and the display screen 10 may be arranged at a certain distance (as shown in FIG. 35); or, the compensation optical element 500 and the back surface 13 of the display screen 10 may be provided in close contact (not shown). In this way, the compensation optical element 500 and the portion of the display screen 10 opposite to the compensation optical element 500 can form a plane mirror, and the number of spots will not be changed when the structured light passes through the plane mirror.
  • the speckle formed by the structured light emitted into the scene may be regarded as including only the laser light diffracted by the diffractive optical element 213, and the measurement spot may be regarded as the laser only diffracted by the diffractive optical element 213 and reflected by the target object.
  • step 013 when the structured light camera 22 is disposed on the side of the back surface 13 of the display screen 10, and the display screen 10 is provided with the structure
  • step 013 when the light incident surface of the optical camera 22 is aligned with the through slot 14, step 013 includes:
  • the image acquisition method also includes:
  • the structured light camera 22 is controlled to receive the structured light that directly passes through the compensation optical element 500 and the display area 11 and is reflected by the calibrated object when being emitted to obtain a reference image.
  • the reference image includes multiple reference spots, The multiple reference spots include reference spots formed by laser light diffracted only by the diffractive optical element 213 and reflected by the calibration object;
  • Step 02 includes:
  • Step 0131 and step 038 can be implemented by the control module 401.
  • Both step 0271 and step 0272 can be implemented by the calculation module 402.
  • Step 0131, step 038, step 0271, and step 0272 can all be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to receive the structured light that directly passes through the compensation optical element 500 and the display area 11 and is reflected by the target object in order to obtain the speckle image and the calibration reference image
  • the processor 200 can also be used to control the structured light camera 22 to receive the structured light that directly passes through the compensation optical element 500 and the display area 11 and is reflected by the target object in order to obtain the speckle image and the calibration reference image
  • Time-controlled structured light camera 22 receives structured light that directly passes through the compensation optical element 500 and the display area 11 and is reflected by the calibration object at the time of emission to obtain a reference image, calculate the offset of the measurement spot relative to the reference spot, and according to the offset Calculate the depth data to get the depth image.
  • the area of the compensation optical element 500 should be slightly greater than or equal to the divergent area formed by the structured light emitted by the structured light projector 21, so that all the structured light emitted by the structured light projector 21 can pass through the compensation optical element 500, which can be offset
  • the diffraction effect of the display screen 10 is lost.
  • the compensation optical element 500 cannot block the light incident surface of the structured light camera 22, that is, the compensation optical element 500 cannot overlap the through slot 14. It can be understood that the through slot 14 does not have a diffractive effect, and the structured light reflected by the target object will not be diffracted when passing through the through slot 14, therefore, it is not necessary to provide a compensation optical element 500 at the position of the through slot 14 to offset the display area 11 diffraction effect.
  • the compensation optical element 500 is provided at the position of the through slot 14, the structured light passing through the compensation optical element 500 will be diffracted by the compensation optical element 500, resulting in the speckle image received by the structured light camera 22 including the laser beam After one diffraction, the diffractive optical element 213 passes through the compensation optical element 500 and the plane mirror formed by the portion of the display screen 10 opposite to the compensation optical element 500 and is diffracted by the compensation optical element 500 to form a measurement spot.
  • the structured light camera 22 When the structured light camera 22 is disposed on the side of the back surface 13 of the display screen 10, and the display screen 10 is provided with a through slot 14 aligned with the light incident surface of the structured light camera 22, the light source 211 of the structured light projector 21 emits The laser light will pass through the compensation optical element 500 and the display area 11 in turn.
  • the structured light camera 22 receives the light through the plane mirror composed of the compensation optical element 500 and the display screen 10, is modulated by the target object, and then reflects through the through slot 14 Structured light.
  • the speckle image captured by the structured light camera 22 includes only measurement spots formed by laser light diffracted only once by the diffractive optical element 213 and reflected by the target object, without occurrence of laser light
  • the measurement spot formed by the diffractive optical element 213 is diffracted once and diffracted again by the display screen 10 and reflected by the target object.
  • the reference spot in the reference image should also only include the reference spot formed by laser light diffracted only once by the diffractive optical element 213 and reflected by the calibration object, then the calibration scene should be: placing the structured light projector 21 and structured light camera 22 On the side where the back surface 13 of the display screen 10 provided with the compensation optical element 500 is located, the light incident surface of the structured light camera 22 is aligned with the through slot 14 of the display screen 10. In this way, in the calibration scene and the actual use scene, the installation positions of the structured light projector 21 and the structured light camera 22 relative to the display screen 10 are the same.
  • the processor 200 controls the structured light projector 21 to emit structured light.
  • the structured light sequentially passes through the compensation optical element 500 and the display screen 10 and then is projected to the calibration plate at a predetermined distance from the structured light assembly 20, and the structured light reflected back by the calibration plate
  • the structured light camera 22 receives the through slot 14.
  • the structured light camera 22 receives the laser light which is diffracted by the diffractive optical element 211 once after being emitted by the light source 211 and reflected by the calibration plate, and then directly incident through the through slot 14.
  • the multiple reference spots included in the formed reference image are The laser beam is diffracted only once by the diffractive optical element 213 and reflected by the calibration object to form a reference spot.
  • the processor 200 does not need to filter out the measurement spots formed by the laser through two diffractions when calculating the depth image, and can directly calculate the depth image based on the measurement spots formed by the only laser through only one diffraction and the reference spots in the reference image. Specifically, the processor 200 calculates the offset between the measurement spot and the reference spot, and then calculates the depth data according to the offset, thereby obtaining a depth image.
  • step 013 when the structured light camera 22 is disposed on the back side of the display screen 10, and the display screen 10 is not provided with a through slot 14, step 013 includes:
  • 0132 Control the structured light camera 22 to sequentially pass through the compensation optical element 500 and the display area 11 when it is emitted and reflected by the target object, and then to pass through the structured light of the display area 11 and the compensation optical element 500 in order to obtain a speckle image;
  • the image acquisition method also includes:
  • the structured light camera 22 is controlled to pass through the compensation optical element 500 and the display area 11 sequentially when receiving the emission and is reflected by the calibrated object, and then passes through the structured light of the display area 11 and the compensation optical element 500 in order to obtain a reference Image
  • the reference image includes multiple reference spots
  • the multiple reference spots include reference spots formed by laser light diffracted only by the diffractive optical element 213 and reflected by the calibration object;
  • Step 02 includes:
  • step 0132 and step 039 may be implemented by the control module 401.
  • step 0271 and step 0272 can be implemented by the calculation module 402.
  • Step 0132, step 039, step 0271, and step 0272 can all be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to sequentially pass through the compensation optical element 500 and the display area 11 when it is emitted and reflected by the target object, and then to pass through the structured light of the display area 11 and the compensation optical element 500 in sequence when it is incident To obtain a speckle image, control the structured light camera 22 to sequentially pass through the compensation optical element 500 and the display area 11 when receiving the emitted light, and to reflect the structured light passing through the display area 11 and the compensation optical element 500 when it is incident after being reflected by the calibration object To obtain a reference image, calculate an offset of the measurement spot relative to the reference spot, and calculate depth data according to the offset to obtain a depth image.
  • the compensation optical element 500 should completely cover the structured light projector 21 and the structured light camera 22 at the same time. In this way, on the one hand, the structured light emitted by the structured light projector 21 can all pass through the compensation optical element 500, which can cancel the diffraction effect of the display screen 10; on the other hand, the structured light reflected by the target object can also all pass through the compensation optic
  • the element 500 counteracts the diffraction effect of the display screen 10, so that the speckle image captured by the structured light camera 22 includes only measurement spots formed by laser light diffracted only once by the diffractive optical element 213 and reflected by the target object.
  • the structured light camera 22 when the structured light camera 22 is disposed on the side where the back 13 of the display screen 10 is located, and the display screen 10 is not provided with a through slot 14, the laser light emitted by the light source 211 of the structured light projector 21 will sequentially pass through the compensation optical element 500 and the display area 11, the structured light camera 22 receives the light through the plane mirror composed of the compensation optical element 500 and the display screen 10, is reflected by the target object, and then passes through the plane mirror composed of the display screen 10 and the compensation optical element 500 Structured light incident.
  • the speckle image captured by the structured light camera 22 includes only measurement spots formed by laser light diffracted only once by the diffractive optical element 213 and reflected by the target object, without occurrence of laser light
  • the diffractive optical element 213 is diffracted once and then diffracted by the display screen 10 twice and reflected by the target object to form a measurement spot, nor will the laser light diffracted by the diffractive optical element 213 once by the display screen 10 and diffracted again by the target object
  • the reference spot in the reference image should also only include the reference spot formed by laser light diffracted only once by the diffractive optical element 213 and reflected by the calibration object, then the calibration scene should be: placing the structured light projector 21 and structured light camera 22 On the side where the back surface 13 of the display screen 10 provided with the compensation optical element 500 is located, the display screen 10 is not provided with a through slot 14. In this way, in the calibration scene and the actual use scene, the installation positions of the structured light projector 21 and the structured light camera 22 relative to the display screen 10 are the same.
  • the processor 200 controls the structured light projector 21 to emit structured light.
  • the structured light sequentially passes through the compensation optical element 500 and the display screen 10 and then is projected to the calibration plate at a predetermined distance from the structured light assembly 20, and the structured light reflected back by the calibration plate
  • the structured light camera 22 After passing through the display screen 10 and the compensation optical element 500 in sequence, it is received by the structured light camera 22, and the multiple reference spots included in the formed reference image are the reference spots formed by the laser light diffracted only once by the diffractive optical element 213 and reflected by the calibration object .
  • the processor 200 calculates the depth image, it is not necessary to filter out the measurement spots formed by the laser through multiple diffractions, and the depth image can be directly calculated based on the measurement spots formed by the laser through only one diffraction and the reference spots in the reference image. Specifically, the processor 200 calculates the offset between the measurement spot and the reference spot, and then calculates the depth data according to the offset, thereby obtaining a depth image.
  • the image acquisition method compensates for the diffraction effect of the display screen 10 by providing the compensation optical element 500.
  • the speckle image captured by the structured light camera 22 includes only the laser light diffracted by the diffractive optical element 213 once.
  • the processor 200 does not need to perform the filtering operation, and can be directly based on all measurement spots and reference images in the speckle image All reference blobs in are used to calculate depth images, which simplifies the calculation process of depth images and speeds up the acquisition of depth images.
  • the diffractive optical element 213 in the structured light projector 21 is replaced with an optical element 214.
  • the optical element 214 is used to compensate the brightness of the structured light diffracted by the display screen 10. Of uniformity.
  • Step 01 includes:
  • the uniformity of the brightness of the diffracted structured light, and the speckle image includes multiple measurement spots.
  • Step 014 may be implemented by the control module 401.
  • Step 014 may also be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to receive the structured light diffracted by the display area 11 of the display screen 10 and reflected by the target object when it exits to obtain a speckle image. 21 in the structured light projector The optical element 214 is used to compensate the uniformity of the brightness of the structured light diffracted by the display screen 10.
  • a micro gap is formed between adjacent pixels in the display area 11 of the display screen 10, and the structured light emitted by the structured light projector 21 passes through the display area 11 and is diffracted by the display area 11 to form multiple spots.
  • the brightness distribution of the spots diffracted by the display area 11 is not uniform.
  • the image acquisition method of the embodiment of the present application forms a plurality of spots by means of the diffraction effect of the display screen 10, and replaces the diffractive optical element 213 in the structured light projector 21 with one that can compensate for the uniformity of the brightness of the structured light diffracted by the display screen 10.
  • the optical element 214 that is, the laser light emitted by the light source 211 of the structured light projector 21 passes through the optical element 214 and the display screen 10 in sequence, and there are multiple spots in the speckle pattern projected onto the scene, and the brightness of the spots is relatively uniform, where, The spots are diffracted by the display screen 10, and the uniformity of the brightness of the spots is compensated by the optical element 214.
  • the measurement spots in the speckle image captured by the structured light camera 22 are directly formed by the diffraction effect of the display screen 10, and the processor 200 can calculate the depth image based on these measurement spots.
  • the optical element 214 compensates for the uniformity of the brightness of the structured light diffracted by the display screen 10, which is beneficial to improve the accuracy of the acquired depth image.
  • step 014 when the structured light projector 21 and the structured light camera 22 are both disposed on the back side of the display screen 10, and the display screen 10 is provided with a through slot 14, and when the light incident surface of the structured light camera 22 is aligned with the through slot 14, step 014 includes:
  • the speckle image includes a plurality of measurement spots, and the plurality of measurement spots includes a first measurement spot formed by laser light diffused through the optical element 214 and then diffracted by the display screen 10 once and reflected by the target object;
  • the image acquisition method also includes:
  • the structured light camera 22 is controlled to receive the structured light diffracted by the display area 11 and reflected directly by the calibrated object when it is emitted to obtain the reference image, and the optical element 214 is used to compensate the structured light diffracted by the display screen 10
  • the uniformity of the brightness, the reference image includes a plurality of reference spots, and the plurality of reference spots includes a first reference spot formed by laser light diffused through the optical element 214 and then diffracted by the display screen 10 once and reflected by the calibration object;
  • Step 02 includes:
  • both step 0141 and step 091 can be implemented by the control module 401.
  • Both step 0281 and step 0282 can be implemented by the calculation module 402.
  • Step 0141, step 091, step 0281, and step 0282 can all be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to receive the structured light diffracted by the display area 11 and reflected directly by the target object when it is emitted to obtain a speckle image, and the optical element 214 is used to compensate the display screen 10 The uniformity of the brightness of the diffracted structured light.
  • the processor 200 can also be used to control the structured light camera 22 to receive the structured light that is diffracted by the display area 11 and reflected directly by the calibration object to obtain the reference image when the reference image is calibrated, and the optical element 214 is used to compensate the display screen 10 The uniformity of the brightness of the diffracted structured light.
  • the processor 200 may also be used to calculate an offset of the first measurement spot relative to the first reference spot, and calculate depth data according to the offset to obtain a depth image.
  • the structured light camera 22 when the structured light camera 22 is disposed on the side of the back surface 13 of the display screen 10, and the display screen 10 is provided with a through slot 14 aligned with the light incident surface of the structured light camera 22, the structured light projector 21
  • the laser light emitted by the light source 211 sequentially passes through the optical element 214 and the display area 11 of the display screen 10 to form structured light and exit into the scene.
  • the structured light is reflected by the target object and then enters the through slot 14 to be received by the structured light camera 22.
  • the speckle image captured by the structured light camera 22 includes only the first measurement spot formed by the laser light diffused through the optical element 214 and then diffracted by the display screen 10 once and reflected by the target object.
  • the reference spot in the reference image should also include only the first reference spot formed by the laser diffused through the optical element 214 and then diffracted by the display screen 10 once and reflected by the calibration object, then the calibration scene should be the one with the optical element 214
  • the structured light projector 21 and the structured light camera 22 are placed on the side of the back surface 13 of the display screen 10, and the light incident surface of the structured light camera 22 is aligned with the through slot 14 of the display screen 10. In this way, in the calibration scene and the actual use scene, the installation positions of the structured light projector 21 and the structured light camera 22 relative to the display screen 10 are the same.
  • the processor 200 controls the light source 211 of the structured light projector 21 to emit laser light, and the laser light passes through the optical element 214 and the display screen 10 in turn to form structured light and is projected onto the calibration plate at a predetermined distance from the structured light assembly 20, which is reflected back by the calibration plate
  • the structured light passing through the through slot 14 is received by the structured light camera 22.
  • the structured light camera 22 receives the laser light emitted by the light source 211, diffused by the diffractive optical element 213, diffracted by the display screen 10 once and reflected by the calibration plate, and then directly incident through the through slot 14, the reference image formed includes
  • the multiple reference spots are the first reference spots formed by the laser light diffusing through the optical element 214 and then diffracted by the display screen 10 once and reflected by the calibration object.
  • the processor 200 When calculating the depth image, the processor 200 directly calculates the depth image based on the first measurement spot and the first reference spot in the reference image. Specifically, the processor 200 calculates the offset between the first measurement spot and the first reference spot, and then calculates depth data according to the offset, thereby obtaining a depth image.
  • step 014 when the structured light camera 22 is disposed on the side of the back of the display screen 10 and the display screen 10 is not provided with a through slot 14, step 014 includes:
  • the optical element 214 is used to compensate the structure of the diffraction of the display screen 10
  • the uniformity of the brightness of the light, the speckle image includes multiple measurement spots, the multiple measurement spots include the first measurement spot formed by the laser light diffused through the optical element 214 and then diffracted by the display screen 10 once and reflected by the target object, and the laser light passes through the optical The element 214 diffuses a second measurement spot formed by the second diffraction of the display screen 10 after being diffracted once by the display screen 10 and reflected by the target object.
  • Step 0142 can be implemented by the control module 401.
  • Step 0142 can also be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to receive the structured light diffracted by the display area 11 when diffracted by the display area 11 after being emitted and reflected by the target object and then diffracted by the display area 11 to obtain a speckle image.
  • the optical element 214 It is used to compensate the uniformity of the brightness of the structured light diffracted by the display screen 10.
  • the structured light camera 22 when the structured light camera 22 is disposed on the side where the back 13 of the display screen 10 is located, and the display screen 10 is not provided with a through slot 14, the laser light emitted by the light source 211 of the structured light projector 21 passes through the optical element 214 and After the display area 11 of the display screen 10, structured light is formed and emitted into the scene. The structured light is reflected by the target object and then enters through the display screen 10 to be received by the structured light camera 22.
  • the speckle image captured by the optical camera 22 includes a plurality of laser spots diffused by the optical element 214 and then diffracted once by the display screen 10 and reflected by the target object, and the first measurement spot formed by the laser beam diffused by the optical element 214 and then by the display screen 10 The second measurement spot formed by the second diffraction of the display screen 10 after being diffracted once and reflected by the target object.
  • the processor 200 may directly calculate the depth image according to the first measurement spot and the second measurement spot in the speckle image and the reference spot in the reference image.
  • the calculation method of the depth image may include the following two.
  • step 02 includes:
  • the image acquisition method also includes:
  • the structured light camera 22 is controlled to receive the structured light diffracted by the display area 11 when diffracted by the display area 11 after being emitted and reflected by the calibrated object and then diffracted by the display area 11 to obtain the reference image.
  • the uniformity of the brightness of the structured light diffracted by the screen 10 the reference image includes a plurality of reference spots, the plurality of reference spots including the first reference spots formed after the laser light diffuses through the optical element 214 and is diffracted by the display screen 10 once and reflected by the calibration object The second laser beam is diffused by the optical element 214 and then diffracted by the display screen 10 once and reflected by the calibration object, and then is second diffracted by the display screen 10 second diffraction.
  • Step 0283 and step 0284 can be implemented by the calculation module 402.
  • Step 092 can be implemented by the control module 401.
  • Step 0283, step 0284, and step 092 may also be implemented by the processor 200. That is to say, the processor 200 can also be used to calculate the offsets of all measurement spots relative to all reference spots, and calculate depth data according to the offsets to obtain depth images.
  • the processor 200 can also be used to control the structured light camera 22 to receive the structured light diffracted by the display area 11 when diffracted by the display area 11 and reflected by the calibrated object and then diffracted by the display area 11 when the reference image is calibrated to obtain the reference image. It is used to compensate the uniformity of the brightness of the structured light diffracted by the display screen 10.
  • the structured light projector 21 provided with the optical element 214 and the structured light camera 22 are placed on the side of the back surface 13 of the display screen 10, wherein the display screen 10 does not have a through slot 14 .
  • the installation positions of the structured light projector 21 and the structured light camera 22 relative to the display screen 10 are the same.
  • the processor 200 controls the light source 211 of the structured light projector 21 to emit laser light, and the laser light passes through the optical element 214 and the display screen 10 in turn to form structured light and is projected onto the calibration plate at a predetermined distance from the structured light assembly 20, which is reflected back by the calibration plate After passing through the display screen 10, the structured light is received by the structured light camera 22.
  • the reference image captured by the structured light camera 22 includes multiple first reference spots and multiple second reference spots at the same time. Among them, the first reference spot is the laser light diffused through the optical element 214 and then diffracted by the display screen 10 and reflected by the calibrated object.
  • the second reference spot is the laser light diffused through the optical element 214 and then diffracted by the display screen 10 and the calibrated object After reflection, it is formed by the second order diffraction of the display screen 10 again.
  • the speckle image includes both the first measurement spot and the second measurement spot
  • the reference image includes both the first reference spot and the second reference spot.
  • the processor 200 does not distinguish between the first measurement spot and the second measurement spot in the speckle image, nor does it distinguish between the first reference spot and the second reference spot in the reference image Instead, the depth image is calculated directly based on all the measurement spots and reference spots. Specifically, the processor 200 first calculates the offsets of all measurement spots relative to all reference spots, and then calculates multiple depth data based on the multiple offsets, thereby obtaining a depth image.
  • step 02 includes:
  • the image acquisition method also includes:
  • the structured light camera 22 is controlled to receive the structured light diffracted by the display area 11 and reflected directly by the calibrated object when it is emitted to obtain the reference image, and the optical element 214 is used to compensate the structured light diffracted by the display screen 10
  • the uniformity of the brightness, the reference image includes a plurality of reference spots, and the plurality of reference spots includes a first reference spot formed by laser light diffused through the optical element 214 and then diffracted by the display screen 10 once and reflected by the calibration object;
  • the structured light camera 22 is controlled to receive the structured light diffracted by the display area 11 when diffracted by the display area 11 after being emitted and reflected by the calibrated object and then diffracted by the display area 11 to obtain the reference image, and the optical element 214 is used to compensate the display
  • the reference image includes a plurality of reference spots, the plurality of reference spots including the first reference spots formed after the laser light diffuses through the optical element 214 and is diffracted by the display screen 10 once and reflected by the calibration object
  • Step 0285, step 0286, step 43, step 053, step 063, and step 073 can all be implemented by the calculation module 402. Both step 091 and step 092 can be implemented by the control module 401.
  • Step 0285, step 0286, step 091, step 092, and step 43, step 053, step 063, and step 073 can all be implemented by the processor 200. That is to say, the processor 200 can also be used to calculate the offset of the first measurement spot relative to the first reference spot, and the offset of the second measurement spot relative to the second reference spot, and calculate the depth according to the offset Data to obtain depth images.
  • the processor 200 can also be used to control the structured light camera 22 to receive the structured light directly diffracted by the display area 11 and reflected by the calibration object when the reference image is calibrated to obtain the reference image, and to control the structured light when the reference image is calibrated
  • the camera 22 receives the structured light diffracted by the display area 11 when it is emitted and reflected by the calibration object and then diffracted by the display area 11 when incident to obtain a reference image, wherein the optical element 214 is used to compensate the brightness of the structured light diffracted by the display screen 10 Uniformity.
  • the processor 200 may also be used to compare the first reference image and the second reference image to obtain the second reference spot, and calculate the average value of the brightness of the plurality of second reference spots and the average value of the brightness of the plurality of first reference spots The ratio is used as the preset ratio, and the average value of the brightness of the plurality of first reference spots is calculated and used as the preset brightness.
  • the processor 200 can also be used to calculate the actual ratio between each measurement spot and the preset brightness, classify the measurement spots whose actual ratio is greater than the preset ratio as the first measurement spots, and classify the measurement spots whose actual ratio is less than the preset ratio It is classified as the second measurement spot.
  • the processor 200 needs to calibrate the first reference image and the second reference image.
  • the calibration process of the first reference image and the aforementioned step 091 place the structured light projector 21 provided with the optical element 214 and the structured light camera 22 on the side of the back side 13 of the display screen 10, and the structured light camera 22 enters the light
  • the calibration process in the scene where the surface is aligned with the through slot 14 of the display screen 10 is consistent.
  • the calibration process of the second reference image is the same as the step 092 where the structured light projector 21 provided with the optical element 214 and the structured light camera 22 are placed
  • the calibration process is the same on the side where the back surface 13 of the display screen 10 is located, and the display screen 10 does not have the through slot 14, and will not be repeated here.
  • the processor 200 calibrates the first reference image and the second reference image
  • the processor 200 marks the coordinates of the first reference spot in the first reference image, and filters out the second reference image according to the coordinates of the first reference spot
  • One reference spot, and the remaining reference spots in the second reference image are the second reference spots. In this way, the processor can distinguish the first reference spot and the second reference spot from all the reference spots in the second reference image.
  • the measurement spots in the speckle image also need to be distinguished.
  • the first measurement spot and the second measurement spot can be distinguished by brightness. It can be understood that the first measurement spot is formed by the laser diffused through the optical element 214 and then diffracted by the display screen 10 once, and the second measurement spot is formed by the diffused optical element 214 and then formed by the first and second diffraction of the display screen 10, forming the first The second measurement spot laser is diffracted more times than the first measurement spot laser is diffracted. Therefore, the energy loss of the laser forming the first measurement spot is smaller, and the energy loss of the laser forming the second measurement spot is larger The brightness of the second measurement spot will be lower than the brightness of the first measurement spot.
  • the first measurement spot and the second measurement spot can be distinguished based on the brightness. Then, after the reference image calibration is completed, it is necessary to further calibrate the brightness for distinguishing the first measurement spot from the second measurement spot. That is to say, after the processor 200 distinguishes the first reference spot and the second reference spot, the processor 200 needs to calculate the average value of the brightness of the plurality of first reference spots in the second reference image, and calculate the first The average value of the brightness of multiple second reference spots in the two reference images.
  • the processor 200 takes the average value of the brightness of the plurality of first reference spots as the preset brightness, and takes the ratio between the average value of the brightness of the plurality of second reference spots and the average value of the brightness of the plurality of first reference spots As a preset ratio.
  • the processor 200 first calculates the brightness of each measurement spot. Subsequently, the processor 200 calculates the actual ratio between each measurement spot and the preset brightness, and classifies the measurement spots whose actual ratio is greater than or equal to the preset ratio as the first measurement spot, and measures the actual ratio less than the preset ratio The spots are classified as second measurement spots, thereby distinguishing the first measurement spots from the second measurement spots.
  • the processor 200 can use the speckle image and the second measurement spot.
  • Two reference images calculate depth data. Specifically, the processor 200 first calculates the offset of the first measurement spot relative to the first reference spot, and the offset of the second measurement spot relative to the second reference spot. Subsequently, the processor 200 calculates multiple depth data based on multiple offsets, and the multiple depth data can constitute a depth image.
  • the second calculation method distinguishes between the first measurement spot and the second measurement spot, and distinguishes between the first reference spot and the second reference spot, which can be based on the more accurate first measurement spot
  • the corresponding relationship with the first reference spot and the corresponding relationship between the second measurement spot and the second reference spot are calculated to obtain a more accurate offset, further obtain more accurate depth data, and improve the accuracy of the acquired depth image.
  • the preset brightness and the preset ratio are determined by the ambient brightness of the scene and the luminous power of the structured light projector 21. In this way, the accuracy of the distinction between the first measurement spot and the second measurement spot can be improved.
  • the measurement spots in the speckle image captured by the structured light camera 22 are directly formed by the diffraction effect of the display screen 10, and the processor 200 can calculate the depth image based on these measurement spots .
  • the optical element 214 compensates the brightness uniformity of the structured light diffracted by the display screen 10, which is beneficial to improve the accuracy of acquiring the depth image.
  • first and second are used for description purposes only, and cannot be understood as indicating or implying relative importance or implicitly indicating the number of technical features indicated.
  • the features defined with “first” and “second” may include at least one of the features either explicitly or implicitly.
  • the meaning of “plurality” is at least two, such as two, three, etc., unless otherwise specifically limited.

Landscapes

  • Engineering & Computer Science (AREA)
  • Signal Processing (AREA)
  • Physics & Mathematics (AREA)
  • Computer Hardware Design (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Projection Apparatus (AREA)
  • Length Measuring Devices By Optical Means (AREA)

Abstract

An electronic device (1000), comprising a display screen (10) and a structured light assembly (20), wherein the display screen (10) comprises a display area (11) having a front face (12) and a back face (13) facing opposite directions, and the front face (12) is used for displaying an image; and the structured light assembly (20) comprises a structured light projector (21). The structured light projector (21) is arranged on the side of the back face (13) of the display screen (10), and the structured light projector (21) is used for emitting structured light passing through the display area (11).

Description

电子装置Electronic device
优先权信息Priority information
本申请请求2018年10月31日向中国国家知识产权局提交的、专利申请号为201811287335.0的专利申请的优先权和权益,并且通过参照将其全文并入此处。This application requests the priority and rights of the patent application with the patent application number 201811287335.0 filed with the State Intellectual Property Office of China on October 31, 2018, and the full text of which is hereby incorporated by reference.
技术领域Technical field
本申请涉及消费性电子技术领域,更具体而言,涉及一种电子装置。This application relates to the field of consumer electronics technology, and more specifically, to an electronic device.
背景技术Background technique
移动终端中可以配置有深度相机和显示屏,深度相机可用于获取物体的深度信息,显示屏可用于显示文字、图案等内容,通常需要在显示屏上开窗,例如形成刘海屏,以使显示屏的显示区与深度相机的位置错开。The mobile terminal can be equipped with a depth camera and a display screen. The depth camera can be used to obtain the depth information of the object. The display screen can be used to display text, patterns and other content. It is usually necessary to open a window on the display screen, for example, to form a bangs screen to make the display The display area of the screen is staggered from the position of the depth camera.
发明内容Summary of the invention
本申请实施方式提供一种电子装置。Embodiments of the present application provide an electronic device.
本申请实施方式的电子装置包括显示屏及结构光组件。所述显示屏包括显示区,所述显示区形成有相背的正面及背面,所述正面用于显示影像。所述结构光组件包括结构光投射器,所述结构光投射器设置在所述显示屏的所述背面所在的一侧,所述结构光投射器用于发射穿过所述显示区的结构光。The electronic device according to the embodiment of the present application includes a display screen and a structured light component. The display screen includes a display area formed with opposite front and back surfaces, the front surface being used to display images. The structured light assembly includes a structured light projector that is disposed on a side of the display screen where the back side is located, and the structured light projector is used to emit structured light that passes through the display area.
本申请实施方式的电子装置中,由于结构光投射器设置在显示屏的背面所在的一侧,且结构光投射器发射的结构光穿过显示区后进入外界环境,显示屏上不需要开设与结构光投射器对准的开口,电子装置的屏占比较高。In the electronic device of the embodiment of the present application, since the structured light projector is provided on the side where the back of the display screen is located, and the structured light emitted by the structured light projector passes through the display area and enters the external environment, there is no The opening of the structured light projector is aligned, and the screen of the electronic device is relatively high.
本申请的实施方式的附加方面和优点将在下面的描述中部分给出,部分将从下面的描述中变得明显,或通过本申请的实施方式的实践了解到。Additional aspects and advantages of the embodiments of the present application will be partially given in the following description, and some will become apparent from the following description, or be learned through practice of the embodiments of the present application.
附图说明BRIEF DESCRIPTION
本申请的上述和/或附加的方面和优点从结合下面附图对实施方式的描述中将变得明显和容易理解,其中:The above and / or additional aspects and advantages of the present application will become apparent and easily understood from the description of the embodiments in conjunction with the following drawings, in which:
图1是本申请某些实施方式的电子装置的结构示意图。FIG. 1 is a schematic structural diagram of an electronic device according to some embodiments of the present application.
图2是本申请某些实施方式的电子装置的部分结构示意图。FIG. 2 is a partial structural diagram of an electronic device according to some embodiments of the present application.
图3是本申请某些实施方式的电子装置沿图2所示的A-A线的截面示意图。FIG. 3 is a schematic cross-sectional view of the electronic device of some embodiments of the present application taken along line A-A shown in FIG. 2.
图4是本申请某些实施方式的结构光投射器的结构示意图。4 is a schematic diagram of a structured light projector according to some embodiments of the present application.
图5是本申请某些实施方式的电子装置沿与图2所示的A-A线对应位置的截面示意图。FIG. 5 is a schematic cross-sectional view of an electronic device according to certain embodiments of the present application taken along the line A-A shown in FIG. 2.
图6和图7是本申请某些实施方式的电子装置的部分结构示意图。6 and 7 are schematic diagrams of partial structures of electronic devices according to certain embodiments of the present application.
图8是本申请某些实施方式的电子装置沿与图2所示的A-A线对应位置的截面示意图。FIG. 8 is a schematic cross-sectional view of an electronic device according to some embodiments of the present application along a position corresponding to line A-A shown in FIG. 2.
图9和图10是本申请某些实施方式的电子装置的部分结构示意图。9 and 10 are schematic diagrams of partial structures of electronic devices according to some embodiments of the present application.
图11至图15是本申请某些实施方式的电子装置沿与图2所示的A-A线对应位置的截面示意图。11 to 15 are schematic cross-sectional views of the electronic device of certain embodiments of the present application along the position corresponding to line A-A shown in FIG. 2.
图16是本申请某些实施方式的图像获取方法的流程示意图。16 is a schematic flowchart of an image acquisition method according to some embodiments of the present application.
图17是本申请某些实施方式的图像获取装置的模块示意图。17 is a schematic block diagram of an image acquisition device according to some embodiments of the present application.
图18和图19是本申请某些实施方式的图像获取方法的流程示意图。18 and 19 are schematic flowcharts of image acquisition methods in some embodiments of the present application.
图20是本申请某些实施方式的图像获取方法的场景示意图。FIG. 20 is a schematic diagram of an image acquisition method according to some embodiments of the present application.
图21是本申请某些实施方式的图像获取方法的流程示意图。21 is a schematic flowchart of an image acquisition method according to some embodiments of the present application.
图22是本申请某些实施方式的图像获取方法的场景示意图。22 is a schematic diagram of an image acquisition method according to some embodiments of the present application.
图23至图27是本申请某些实施方式的图像获取方法的流程示意图。23 to 27 are schematic flowcharts of image acquisition methods in some embodiments of the present application.
图28是本申请某些实施方式的图像获取方法的场景示意图。FIG. 28 is a schematic diagram of an image acquisition method according to some embodiments of the present application.
图29是本申请某些实施方式的图像获取方法的流程示意图。FIG. 29 is a schematic flowchart of an image acquisition method according to some embodiments of the present application.
图30是本申请某些实施方式的图像获取方法的场景示意图。FIG. 30 is a schematic diagram of an image acquisition method according to some embodiments of the present application.
图31至图34是本申请某些实施方式的图像获取方法的流程示意图。31 to 34 are schematic flowcharts of an image acquisition method in some embodiments of the present application.
图35是本申请某些实施方式的结构光投射器发射的结构光的光路示意图。FIG. 35 is a schematic diagram of an optical path of structured light emitted by a structured light projector in some embodiments of the present application.
图36至图41是本申请某些实施方式的图像获取方法的流程示意图。36 to 41 are schematic flowcharts of an image acquisition method according to some embodiments of the present application.
具体实施方式detailed description
以下结合附图对本申请的实施方式作进一步说明。附图中相同或类似的标号自始至终表示相同或类似的元件或具有相同或类似功能的元件。The embodiments of the present application will be further described below with reference to the drawings. The same or similar reference numerals in the drawings indicate the same or similar elements or the elements having the same or similar functions throughout.
另外,下面结合附图描述的本申请的实施方式是示例性的,仅用于解释本申请的实施方式,而不能理解为对本申请的限制。In addition, the embodiments of the present application described below with reference to the drawings are exemplary, and are only used to explain the embodiments of the present application, and cannot be construed as limiting the present application.
在本申请中,除非另有明确的规定和限定,第一特征在第二特征“上”或“下”可以是第一和第二特征直接接触,或第一和第二特征通过中间媒介间接接触。而且,第一特征在第二特征“之上”、“上方”和“上面”可是第一特征在第二特征正上方或斜上方,或仅仅表示第一特征水平高度高于第二特征。第一特征在第二特征“之下”、“下方”和“下面”可以是第一特征在第二特征正下方或斜下方,或仅仅表示第一特征水平高度小于第二特征。In this application, unless clearly specified and defined otherwise, the first feature is “on” or “under” the second feature may be that the first and second features are in direct contact, or the first and second features are indirectly through an intermediary contact. Moreover, the first feature is “above”, “above” and “above” the second feature may be that the first feature is directly above or obliquely above the second feature, or simply means that the first feature is higher in level than the second feature. The first feature is "below", "below", and "below" the second feature may be that the first feature is directly below or obliquely below the second feature, or simply means that the first feature is less horizontal than the second feature.
本申请实施方式的电子装置1000包括显示屏10及结构光组件20。所述显示屏10包括显示区11,所述显示区11形成有相背的正面12及背面13,所述正面12用于显示影像。所述结构光组件20包括结构光投射器21,所述结构光投射器21设置在所述显示屏10的所述背面13所在的一侧,所述结构光投射器21用于发射穿过所述显示区11的结构光。The electronic device 1000 according to the embodiment of the present application includes the display screen 10 and the structured light assembly 20. The display screen 10 includes a display area 11 formed with a front face 12 and a back face 13 opposite to each other. The front face 12 is used to display images. The structured light assembly 20 includes a structured light projector 21 disposed on the side of the back surface 13 of the display screen 10, and the structured light projector 21 is used to emit light through The structured light of the display area 11 is described.
在某些实施方式中,所述结构光组件20还包括结构光摄像头22,所述结构光摄像头22设置在所述显示屏10的所述背面13所在的一侧,所述结构光摄像头22用于接收穿过所述显示区11的被调制后的结构光。In some embodiments, the structured light assembly 20 further includes a structured light camera 22, the structured light camera 22 is disposed on the side where the back surface 13 of the display screen 10 is located, and the structured light camera 22 is used In order to receive the modulated structured light passing through the display area 11.
在某些实施方式中,所述显示屏10形成有贯穿所述正面12及所述背面13的通槽14,所述结构光组件20还包括结构光摄像头22,所述结构光摄像头22设置在所述显示屏10的所述背面13所在的一侧,所述结构光摄像头22用于接收穿过所述通槽14的被调制后的结构光。In some embodiments, the display screen 10 is formed with a through slot 14 penetrating the front surface 12 and the back surface 13, and the structured light assembly 20 further includes a structured light camera 22, which is disposed on On the side where the back surface 13 of the display screen 10 is located, the structured light camera 22 is used to receive the modulated structured light passing through the through slot 14.
在某些实施方式中,所述通槽14包括形成在所述显示屏10的边缘上的缺口141;及/或所述通槽14包括与所述显示屏10的边缘间隔的通孔142。In some embodiments, the through slot 14 includes a notch 141 formed on the edge of the display screen 10; and / or the through slot 14 includes a through hole 142 spaced from the edge of the display screen 10.
在某些实施方式中,所述显示屏10的边缘包括上边缘、下边缘、左边缘及右边缘中的任意一个或多个。In some embodiments, the edge of the display screen 10 includes any one or more of an upper edge, a lower edge, a left edge, and a right edge.
在某些实施方式中,所述结构光组件20还包括泛光灯23,所述泛光灯23与所述结构光摄像头22与同一个所述通槽14对准。In some embodiments, the structured light assembly 20 further includes a floodlight 23 that is aligned with the structured light camera 22 and the same through slot 14.
在某些实施方式中,所述电子装置1000还包括盖板40,所述盖板40设置在所述显示屏10的所述正面12所在的一侧,所述盖板40的与所述通槽14对应的区域上设置有红外透过层50。In some embodiments, the electronic device 1000 further includes a cover plate 40 that is disposed on a side of the display screen 10 where the front surface 12 is located. An infrared transmission layer 50 is provided on the area corresponding to the groove 14.
在某些实施方式中,所述显示屏10的与所述结构光投射器21对应的区域形成有红外增透膜60;及/或所述显示屏10的与所述结构光投射器21对应的区域形成有红外透过层50。In some embodiments, the region of the display screen 10 corresponding to the structured light projector 21 is formed with an infrared antireflection film 60; and / or the display screen 10 corresponds to the structured light projector 21 The area where the infrared transmission layer 50 is formed.
在某些实施方式中,所述电子装置1000还包括盖板40,所述盖板40设置在所述显示屏10的正面12所在的一侧,所述盖板40的与所述结构光投射器21对应的区域形成有红外增透膜60。In some embodiments, the electronic device 1000 further includes a cover plate 40, the cover plate 40 is disposed on the side of the front surface 12 of the display screen 10, the cover plate 40 and the structured light are projected An infrared antireflection film 60 is formed in a region corresponding to the device 21.
在某些实施方式中,所述显示屏10形成有贯穿所述正面12及所述背面13的通槽14,所述电子装置1000还包括可见光摄像头70,所述可见光摄像头70与所述通槽14对准设置,所述盖板40上与所述通槽14对应的区域形成有可见光增透膜80、及/或红外截止膜90。In some embodiments, the display screen 10 is formed with a through slot 14 penetrating through the front face 12 and the back face 13, the electronic device 1000 further includes a visible light camera 70, the visible light camera 70 and the through slot 14 is aligned, and a visible light anti-reflection film 80 and / or an infrared cut-off film 90 are formed in the area of the cover plate 40 corresponding to the through slot 14.
在某些实施方式中,所述结构光组件20还包括泛光灯23,所述泛光灯23设置在所述显示屏10的所述背面13所在的一侧,所述泛光灯23用于发射穿过所述显示区11的补充光线。In some embodiments, the structured light assembly 20 further includes a floodlight 23, the floodlight 23 is disposed on the side where the back surface 13 of the display screen 10 is located, and the floodlight 23 is used for To emit supplementary light passing through the display area 11.
在某些实施方式中,所述显示屏10形成有贯穿所述正面12及所述背面13的通槽14,所述结构光组件20还包括泛光灯23,所述泛光灯23设置在所述显示屏10的所述背面13所在的一侧,所述泛光灯23用于发射穿过所述通槽14的补充光线。In some embodiments, the display screen 10 is formed with a through slot 14 penetrating through the front surface 12 and the back surface 13, and the structured light assembly 20 further includes a floodlight 23, and the floodlight 23 is disposed at On the side where the back surface 13 of the display screen 10 is located, the floodlight 23 is used to emit supplementary light passing through the through slot 14.
在某些实施方式中,所述显示区11包括第一子显示区111及第二子显示区112,所述结构光投射器21发射的结构光穿过所述第一子显示区111,所述第一子显示区111的像素密度小于所述第二子显示区112的像素密度。In some embodiments, the display area 11 includes a first sub-display area 111 and a second sub-display area 112. The structured light emitted by the structured light projector 21 passes through the first sub-display area 111. The pixel density of the first sub-display area 111 is smaller than the pixel density of the second sub-display area 112.
在某些实施方式中,所述第一子显示区111用于显示电子装置1000的状态图标。In some embodiments, the first sub-display area 111 is used to display the status icon of the electronic device 1000.
在某些实施方式中,所述第一子显示区111位于所述显示区11的靠近边缘的位置,所述第二子显示区112位于所述显示区11的中间位置。In some embodiments, the first sub-display area 111 is located near the edge of the display area 11, and the second sub-display area 112 is located in the middle of the display area 11.
在某些实施方式中,所述显示区11包括第一子显示区111及第二子显示区112,所述结构光投射器21发射的结构光穿过所述第一子显示区111,所述第一子显示区111与所述第二子显示区112能够被独立控制并以不同的显示状态显示。In some embodiments, the display area 11 includes a first sub-display area 111 and a second sub-display area 112. The structured light emitted by the structured light projector 21 passes through the first sub-display area 111. The first sub-display area 111 and the second sub-display area 112 can be independently controlled and displayed in different display states.
在某些实施方式中,所述不同的显示状态包括点亮或熄灭、以不同的亮度显示和以不同的刷新频率显示中的一种或多种。In some embodiments, the different display states include one or more of turning on or off, displaying at different brightness, and displaying at different refresh rates.
在某些实施方式中,所述结构光投射器21在发射结构光时,所述第一子显示区111熄灭;或所述结构光投射器21在发射结构光时,调低所述第一子显示区111的显示亮度;或所述结构光投射器21在发射结构光时,调节所述第一子显示区111的刷新频率以使所述第一子显示区111的开启时间与所述结构光投射器21的开启时间错开。In some embodiments, when the structured light projector 21 emits structured light, the first sub-display area 111 goes out; or when the structured light projector 21 emits structured light, the first light is turned down. The display brightness of the sub-display area 111; or when the structured light projector 21 emits structured light, adjust the refresh frequency of the first sub-display area 111 so that the turn-on time of the first sub-display area 111 and the The opening time of the structured light projector 21 is staggered.
在某些实施方式中,所述结构光投射器21未启用时,所述第一子显示区111和所述第二子显示区112均开启,并以相同的刷新频率显示。In some embodiments, when the structured light projector 21 is not activated, both the first sub-display area 111 and the second sub-display area 112 are turned on and displayed at the same refresh frequency.
在某些实施方式中,所述显示屏10为液晶显示屏、或Micro LED显示屏、或OLED显示屏。In some embodiments, the display screen 10 is a liquid crystal display screen, or a Micro LED display screen, or an OLED display screen.
请参阅图1及图2,本申请实施方式的电子装置1000包括显示屏10及结构光组件20。电子装置1000还可以包括壳体30,壳体30可用于安装显示屏10、结构光组件20等功能器件,功能器件还可以是主板、双摄模组、受话器等。电子装置1000的具体形式可以是手机、平板电脑、智能手表、头显设备等,本申请以电子装置1000为手机进行说明,可以理解,电子装置1000的具体形式不限于手机,在此不作限制。Please refer to FIGS. 1 and 2. The electronic device 1000 according to the embodiment of the present application includes a display screen 10 and a structured light component 20. The electronic device 1000 may further include a housing 30, which may be used to install functional devices such as the display screen 10, the structured light assembly 20, and the functional device may also be a main board, a dual camera module, a receiver, and so on. The specific form of the electronic device 1000 may be a mobile phone, a tablet computer, a smart watch, a head-mounted display device, etc. This application uses the electronic device 1000 as a mobile phone for illustration. It can be understood that the specific form of the electronic device 1000 is not limited to a mobile phone, and is not limited herein.
显示屏10可以安装在壳体30上,具体地,显示屏10可以安装在壳体30的一个面上,或者同时安装在壳体30的相背的两个面上。在如图1所示的例子中,显示屏10安装在壳体30的前面,显示屏10的可以覆盖该前面的面积的85%及以上,例如达到85%、86%、87%、88%、89%、90%、91%、92%、93%、95%甚至是100%。显示屏10可以用于显示影像,影像可以是文字、图像、视频、图标等信息。显示屏10的具体类型可以是液晶显示屏、OLED显示屏、Micro LED显示屏等。显示屏10包括显示区11,显示区11可用于显示影像。适配不同类型的电子装置1000及不同用户的需求,显示区11的形状可以呈圆形、椭圆形、跑道形、圆角矩形、矩形等形状。The display screen 10 may be installed on the housing 30. Specifically, the display screen 10 may be installed on one surface of the housing 30 or on both opposite surfaces of the housing 30 at the same time. In the example shown in FIG. 1, the display screen 10 is installed in front of the housing 30, and the display screen 10 can cover 85% or more of the area of the front, for example, 85%, 86%, 87%, 88% , 89%, 90%, 91%, 92%, 93%, 95% and even 100%. The display screen 10 can be used to display images, and the images can be text, images, videos, icons, and other information. The specific type of the display screen 10 may be a liquid crystal display screen, an OLED display screen, a Micro LED display screen, or the like. The display screen 10 includes a display area 11, which can be used to display images. To adapt to the needs of different types of electronic devices 1000 and different users, the shape of the display area 11 may be circular, elliptical, racetrack, rounded rectangle, rectangular, etc.
请结合图3,显示区11形成有相背的正面12及背面13,正面12可以用于显示影像,光线沿背面13指向正面12的方向向外发射,且在光线穿过正面12后由用户接收。显示区11内形成有像素,在一个例子中,像素可以自发光以呈现对应的颜色,在另一个例子中,像素在背光的作用下呈现对应的颜色。而像素与像素之间通常具有微观间隙,光线穿过该微观间隙时会发生衍射。Referring to FIG. 3, the display area 11 is formed with a front surface 12 and a back surface 13 that are opposite to each other. The front surface 12 can be used to display an image. receive. Pixels are formed in the display area 11. In one example, the pixels can emit light to display corresponding colors. In another example, the pixels display corresponding colors under the influence of the backlight. There is usually a microscopic gap between pixels, and light rays will diffract when passing through the microscopic gap.
在某些例子中,显示屏10还可包括非显示区,非显示区可以形成在显示区11的周缘。非显示区可以不用于显示,非显示区可用于与壳体30结合或用于走线,例如可以将非显示区与壳体30通过粘胶结合,而不会影响显示区11的显示功能。显示屏10还可以是集成有触控功能的触控显示屏,用户获取显示屏10显示的影像信息后,可以在显示屏10上进行触控以实现预定的交互操作。In some examples, the display screen 10 may further include a non-display area, and the non-display area may be formed on the periphery of the display area 11. The non-display area may not be used for display, and the non-display area may be used for combining with the housing 30 or for wiring. For example, the non-display area may be combined with the housing 30 by viscose without affecting the display function of the display area 11. The display screen 10 may also be a touch display screen integrated with a touch control function. After the user obtains the image information displayed on the display screen 10, the user may perform touch control on the display screen 10 to achieve a predetermined interactive operation.
结构光组件20可以利用结构光获取目标物体的深度信息,以用于三维建模、生成三维图像、测距等。结构光组件20可以安装在电子装置1000的壳体30内,具体可以安装在支架上后,再将支架及结构光组件20一同安装在壳体30内。结构光组件20可以包括结构光投射器21、结构光摄像头22及泛光灯23。The structured light component 20 can use the structured light to obtain the depth information of the target object for three-dimensional modeling, three-dimensional image generation, distance measurement, and the like. The structured light assembly 20 may be installed in the housing 30 of the electronic device 1000, specifically after being installed on the bracket, and then the support and the structured light assembly 20 are installed in the housing 30 together. The structured light assembly 20 may include a structured light projector 21, a structured light camera 22 and a floodlight 23.
请参阅图1至图4,结构光投射器21设置在显示屏10的背面13所在的一侧,或者说,结构光投射器21设置在显示区11下方,结构光投射器21用于发射穿过显示区11的结构光。具体地,结构光投射器21可以包括光源211、准直元件212及衍射光学元件213,光源211发出的光(例如红外激光)先经过准直元件212准直,再经衍射光学元件213衍射后从结构光投射器21中发出,然后再穿过显示区11以投射到外界。显示区11的微观间隙与衍射光学元件213上的衍射结构对光源211发出的光均具有衍射作用。Please refer to FIG. 1 to FIG. 4, the structured light projector 21 is disposed on the side where the back 13 of the display screen 10 is located, or the structured light projector 21 is disposed below the display area 11, and the structured light projector 21 is used for transmission Structured light passing through the display area 11. Specifically, the structured light projector 21 may include a light source 211, a collimating element 212, and a diffractive optical element 213. The light (such as infrared laser light) emitted by the light source 211 is first collimated by the collimating element 212, and then diffracted by the diffractive optical element 213 It is emitted from the structured light projector 21 and then passes through the display area 11 to project to the outside world. Both the microscopic gap of the display area 11 and the diffractive structure on the diffractive optical element 213 have a diffractive effect on the light emitted by the light source 211.
穿过显示区11并进入外界的结构光中,可能同时包含由衍射光学元件213衍射形成的图案(图案中包括多个由衍射光学元件213衍射的斑点),以及由显示屏10的微观间隙衍射形成的图案(图案中包 括多个由衍射光学元件213衍射又被显示屏10衍射的斑点),以使穿过显示区11后的散斑图案具有较高的不相关性,利于后续对获得的散斑图案进行处理。在一个例子中,显示区11的透过率可以达到60%或以上,以使结构光投射器21发出的结构光穿过显示区11时损耗较小。The structured light that passes through the display area 11 and enters the outside world may contain both a pattern diffracted by the diffractive optical element 213 (the pattern includes a plurality of spots diffracted by the diffractive optical element 213), and a microscopic gap diffracted by the display screen 10 The formed pattern (the pattern includes a plurality of spots diffracted by the diffractive optical element 213 and diffracted by the display screen 10), so that the speckle pattern after passing through the display area 11 has a high irrelevance, which is beneficial to subsequent Speckle patterns are processed. In one example, the transmittance of the display area 11 can reach 60% or more, so that the structured light emitted by the structured light projector 21 passes through the display area 11 with less loss.
结构光摄像头22可以是红外摄像头,结构光发射到目标物体,由目标物体调制后,可以由结构光摄像头22获取,结构光摄像头22接收被调制的结构光后得到散斑图像,散斑图像被处理后得到目标物体的深度数据。结构光摄像头22也可以设置在显示屏10的背面13所在的一侧,即设置在显示屏10下,具体可以与结构光投射器21设置在同一个支架上,或者结构光摄像头22直接安装在壳体30上。此时,结构光摄像头22的入光面可以对准显示区11,被目标物体调制后的结构光穿过显示区11后再由结构光摄像头22接收,具体地,被目标物体调的结构光可以由显示屏10的微观间隙衍射后,再由结构光摄像头22接收。The structured light camera 22 may be an infrared camera. The structured light is emitted to the target object. After being modulated by the target object, it can be acquired by the structured light camera 22. The structured light camera 22 receives the modulated structured light to obtain a speckle image. The speckle image is After processing, the depth data of the target object is obtained. The structured light camera 22 can also be arranged on the side of the back side 13 of the display screen 10, that is, under the display screen 10, which can be specifically arranged on the same bracket as the structured light projector 21, or the structured light camera 22 is directly installed on壳 30 上。 Housing 30. At this time, the light incident surface of the structured light camera 22 can be aligned with the display area 11, and the structured light modulated by the target object passes through the display area 11 and then received by the structured light camera 22, specifically, the structured light modulated by the target object It can be diffracted by the microscopic gap of the display screen 10 and then received by the structured light camera 22.
泛光灯23可以用于向外发射补充光线,补充光线可以用于在环境光线较弱时补充环境中的光线强度。在一个例子中,补充光线可以是红外光。补充光线发射到目标物体上被目标物体反射后,可以由结构光摄像头22获取以得到目标物体的二维图像,二维图像信息可用于身份识别。泛光灯23也可以设置在显示屏10的背面13所在的一侧,即设置在显示屏10下,具体可以与结构光投射器21及结构光摄像头22设置在同一个支架上。此时,泛光灯23发出的补充光线穿过显示区11的微观间隙后进入外界环境,被反射后的补充光线可以再次穿过微观间隙以被结构光摄像头22接收。The floodlight 23 can be used to emit supplementary light outward, and the supplementary light can be used to supplement the light intensity in the environment when the ambient light is weak. In one example, the supplementary light may be infrared light. After the supplementary light is emitted onto the target object and reflected by the target object, it can be acquired by the structured light camera 22 to obtain a two-dimensional image of the target object, and the two-dimensional image information can be used for identity recognition. The floodlight 23 may also be disposed on the side where the back 13 of the display screen 10 is located, that is, under the display screen 10, and may be specifically disposed on the same bracket as the structured light projector 21 and the structured light camera 22. At this time, the supplementary light emitted by the floodlight 23 passes through the microscopic gap of the display area 11 and enters the external environment. The reflected supplementary light can again pass through the microscopic gap to be received by the structured light camera 22.
综上,由于结构光投射器21设置在显示屏10的背面13所在的一侧,且结构光投射器21发射的结构光穿过显示区11后进入外界环境,显示屏10上不需要开设与结构光投射器21对准的开口,电子装置1000的屏占比较高。In summary, since the structured light projector 21 is disposed on the side where the back 13 of the display screen 10 is located, and the structured light emitted by the structured light projector 21 passes through the display area 11 and enters the external environment, there is no need In the opening where the structured light projector 21 is aligned, the screen area of the electronic device 1000 is relatively high.
请参阅图5,在某些实施方式中,显示屏10形成有通槽14,通槽14不具有显示功能。通槽14贯穿正面12及背面13。结构光摄像头22设置在显示屏10的背面13所在的一侧的同时,结构光摄像头22用于接收穿过通槽14的被调制后的结构光。Please refer to FIG. 5. In some embodiments, the display screen 10 is formed with a through slot 14, and the through slot 14 does not have a display function. The through groove 14 penetrates the front surface 12 and the rear surface 13. The structured light camera 22 is arranged on the side where the back surface 13 of the display screen 10 is located, and the structured light camera 22 is used to receive the modulated structured light passing through the through slot 14.
此时,结构光摄像头22的入光面可以对准通槽14,被目标物体调制后的结构光穿过通槽14后再由结构光摄像头22接收。本实施方式中,由于被调制后的结构光不需要穿过显示区11的微观间隙,不会由微观间隙再次衍射,结构光摄像头22获取的散斑图像即为目标物体调制后的散斑图像,减少后续基于散斑图像计算深度图像的处理难度。At this time, the light incident surface of the structured light camera 22 can be aligned with the through slot 14, and the structured light modulated by the target object passes through the through slot 14 and then received by the structured light camera 22. In this embodiment, since the modulated structured light does not need to pass through the microscopic gap of the display area 11 and will not be diffracted again by the microscopic gap, the speckle image acquired by the structured light camera 22 is the speckle image after modulation of the target object To reduce the difficulty of subsequent calculation of depth images based on speckle images.
具体地,在如图6所示的例子中,通槽14包括形成在显示屏10的边缘上的缺口141,或者说,通槽14与显示屏10的边缘相交。缺口141具体可以形成在显示屏10的上边缘、下边缘、左边缘、右边缘等任意一个或多个边缘上。缺口141的形状可以是三角形、半圆形、矩形、跑道形等任意形状,在此不作限制。Specifically, in the example shown in FIG. 6, the through slot 14 includes a notch 141 formed on the edge of the display screen 10, or in other words, the through slot 14 intersects the edge of the display screen 10. The notch 141 may be specifically formed on any one or more edges such as the upper edge, the lower edge, the left edge, and the right edge of the display screen 10. The shape of the notch 141 may be any shape such as a triangle, a semicircle, a rectangle, a track shape, etc., which is not limited herein.
在如图7所示的例子中,通槽14包括与显示屏10的边缘间隔的通孔142,或者说,通槽14开设在显示屏10的边缘围成的范围内。通孔142具体可以靠近显示屏10的上边缘、下边缘、左边缘、右边缘等任意一个或多个边缘上。通孔142的形状可以是三角形、圆形、矩形、跑道形等任意形状,在此不作限制。In the example shown in FIG. 7, the through slot 14 includes a through hole 142 spaced from the edge of the display screen 10, or the through slot 14 is opened within a range enclosed by the edge of the display screen 10. The through hole 142 may specifically be close to any one or more edges such as the upper edge, the lower edge, the left edge, and the right edge of the display screen 10. The shape of the through hole 142 may be any shape such as a triangle, a circle, a rectangle, and a racetrack, which is not limited herein.
在一些例子中,通槽14也可以同时包括上述的缺口141及通孔142。缺口141及通孔142的数量可以相等或不相等。In some examples, the through slot 14 may also include the aforementioned notch 141 and the through hole 142 at the same time. The number of the notch 141 and the through hole 142 may be equal or unequal.
请参阅图8,在某些实施方式中,泛光灯23设置在显示屏10的背面13所在的一侧的同时,泛光灯23用于发射穿过通槽14的补充光线。Referring to FIG. 8, in some embodiments, the floodlight 23 is disposed on the side where the back 13 of the display screen 10 is located, and the floodlight 23 is used to emit supplementary light passing through the through slot 14.
此时,补充光线穿过通槽14后直接发射到外界,补充光线不会在穿过显示区11的过程中被削弱,保证目标物体接收到较多的补光量。At this time, the supplementary light is directly emitted to the outside after passing through the through slot 14, and the supplementary light will not be weakened in the process of passing through the display area 11 to ensure that the target object receives a large amount of supplementary light.
与结构光摄像头22类似,如图9所示,通槽14包括形成在显示屏10的边缘上的缺口141,或者说,通槽14与显示屏10的边缘相交。缺口141具体可以形成在显示屏10的上边缘、下边缘、左边缘、右边缘等任意一个或多个边缘上。缺口141的形状可以是三角形、半圆形、矩形、跑道形等任意形状,在此不作限制。Similar to the structured light camera 22, as shown in FIG. 9, the through slot 14 includes a notch 141 formed on the edge of the display screen 10, or the through slot 14 intersects the edge of the display screen 10. The notch 141 may be specifically formed on any one or more edges such as the upper edge, the lower edge, the left edge, and the right edge of the display screen 10. The shape of the notch 141 may be any shape such as a triangle, a semicircle, a rectangle, a track shape, etc., which is not limited herein.
或者,如图10所示,通槽14包括与显示屏10的边缘间隔的通孔142,或者说,通槽14开设在显示屏10的边缘围成的范围内。通孔142具体可以靠近显示屏10的上边缘、下边缘、左边缘、右边缘等任意一个或多个边缘上。通孔142的形状可以是三角形、圆形、矩形、跑道形等任意形状,在此不作限 制。Alternatively, as shown in FIG. 10, the through slot 14 includes a through hole 142 spaced from the edge of the display screen 10, or the through slot 14 is opened within a range enclosed by the edge of the display screen 10. The through hole 142 may specifically be close to any one or more edges such as the upper edge, the lower edge, the left edge, and the right edge of the display screen 10. The shape of the through hole 142 may be any shape such as a triangle, a circle, a rectangle, a racetrack, etc., and is not limited herein.
另外,在图8至图10所示的例子中,泛光灯23与结构光摄像头22可以对应同一个通槽14。在图11所示例子中,泛光灯23与结构光摄像头22可以对应不同的通槽14。In addition, in the examples shown in FIGS. 8 to 10, the floodlight 23 and the structured light camera 22 may correspond to the same through slot 14. In the example shown in FIG. 11, the floodlight 23 and the structured light camera 22 can correspond to different through slots 14.
请参阅图3、图5、图8及图11,在某些实施方式中,电子装置1000还包括盖板40,盖板40设置在显示屏10的正面12所在的一侧。当显示屏10开设有通槽14时,盖板40的与通槽14对应的区域上设置有红外透过层50。Please refer to FIG. 3, FIG. 5, FIG. 8 and FIG. 11. In some embodiments, the electronic device 1000 further includes a cover 40. The cover 40 is disposed on the side where the front surface 12 of the display screen 10 is located. When the display screen 10 is provided with a through slot 14, an infrared transmission layer 50 is provided on the area of the cover plate 40 corresponding to the through slot 14.
盖板40可以由玻璃或者蓝宝石等透光性能较好的材料制成。红外透过层50可以是红外透过油墨或红外透过膜,红外透过层50对红外光(例如波长为940纳米的光)具有较高的透过率,例如透过率可以达到85%或以上,而对红外光以外的光线的透过率较低或者使得红外光以外的光线完全不能透过。因此,用户难以通过盖板40看到与通槽14对准的结构光摄像头22或者泛光灯23,电子装置1000的外观较美观。The cover plate 40 may be made of a material with good light transmission performance, such as glass or sapphire. The infrared transmission layer 50 may be an infrared transmission ink or an infrared transmission film. The infrared transmission layer 50 has a high transmittance for infrared light (for example, light with a wavelength of 940 nanometers), for example, the transmittance can reach 85% Or more, and the transmittance of light other than infrared light is low or makes light other than infrared light completely impermeable. Therefore, it is difficult for the user to see the structured light camera 22 or the floodlight 23 aligned with the through slot 14 through the cover plate 40, and the appearance of the electronic device 1000 is more beautiful.
请再参阅图1,在某些实施方式中,显示区11包括第一子显示区111及第二子显示区112。结构光投射器21发射的结构光穿过第一子显示区111,第一子显示区111的像素密度小于第二子显示区112的像素密度。Please refer to FIG. 1 again. In some embodiments, the display area 11 includes a first sub-display area 111 and a second sub-display area 112. The structured light emitted by the structured light projector 21 passes through the first sub-display area 111, and the pixel density of the first sub-display area 111 is smaller than the pixel density of the second sub-display area 112.
第一子显示区111的像素密度小于第二子显示区112的像素密度,也就是第一子显示区111的微观间隙要大于第二子显示区112的微观间隙,第一子显示区111对光线的阻隔作用较小,穿过第一子显示区111的光线的透过率较高。因此,结构光投射器21发射的结构光在透过第一子显示区111的透过率较高。The pixel density of the first sub-display area 111 is less than the pixel density of the second sub-display area 112, that is, the micro-gap of the first sub-display area 111 is greater than the micro-gap of the second sub-display area 112. The blocking effect of light is small, and the transmittance of light passing through the first sub-display area 111 is high. Therefore, the structured light emitted by the structured light projector 21 has a higher transmittance through the first sub-display area 111.
在一个例子中,第一子显示区111可以用于显示电子装置1000的状态图标,例如用于显示电子装置1000的电池电量、网络连接状态、系统时间等。第一子显示区111可以位于显示区11的靠近边缘的位置,第二子显示区112可以位于显示区11的中间位置。In one example, the first sub-display area 111 may be used to display the status icon of the electronic device 1000, for example, to display the battery level, network connection status, system time, etc. of the electronic device 1000. The first sub-display area 111 may be located near the edge of the display area 11, and the second sub-display area 112 may be located in the middle of the display area 11.
请再参阅图1,在某些实施方式中,显示区11包括第一子显示区111及第二子显示区112,结构光投射器21发射的结构光穿过第一子显示区111,第一子显示区111与第二子显示区112能够被独立控制并以不同的显示状态显示。此时,第一子显示区111的像素密度与第二子显示区112的像素密度可以相等,或者,第一子显示区111的像素密度小于第二子显示区112的像素密度。Please refer to FIG. 1 again. In some embodiments, the display area 11 includes a first sub-display area 111 and a second sub-display area 112. The structured light emitted by the structured light projector 21 passes through the first sub-display area 111. The one sub-display area 111 and the second sub-display area 112 can be independently controlled and displayed in different display states. At this time, the pixel density of the first sub-display area 111 and the pixel density of the second sub-display area 112 may be equal, or the pixel density of the first sub-display area 111 is less than the pixel density of the second sub-display area 112.
其中,不同的显示状态可以是点亮或熄灭、以不同的亮度显示、以不同的刷新频率显示等。第一子显示区111与第二子显示区112的显示状态可以被独立控制,用户可以依据实际需求控制第二子显示区112正常显示,且第一子显示区111与结构光投射器21配合使用。例如,结构光投射器21在发射结构光时,第一子显示区111可以熄灭、或者调低第一子显示区111的显示亮度、或者调节第一子显示区111的刷新频率使第一子显示区111的开启时间与结构光投射器21的开启时间错开,以减少第一子显示区111显示时对结构光投射器21向场景投射散斑图案的影响。结构光投射器21未启用时,第一子显示区111和第二子显示区112可以均开启,并以相同的刷新频率显示。Among them, different display states may be on or off, display with different brightness, display with different refresh frequency, and so on. The display states of the first sub-display area 111 and the second sub-display area 112 can be independently controlled. The user can control the normal display of the second sub-display area 112 according to actual needs, and the first sub-display area 111 cooperates with the structured light projector 21 use. For example, when the structured light projector 21 emits structured light, the first sub-display area 111 may be turned off, or the display brightness of the first sub-display area 111 may be lowered, or the refresh frequency of the first sub-display area 111 may be adjusted so that the first sub-display area 111 The turn-on time of the display area 111 is staggered from the turn-on time of the structured light projector 21, so as to reduce the influence of the first sub-display area 111 on the structured light projector 21 projecting the speckle pattern onto the scene. When the structured light projector 21 is not activated, both the first sub-display area 111 and the second sub-display area 112 may be turned on and displayed at the same refresh rate.
请参阅图12,在某些实施方式中,电子装置1000还包括盖板40,盖板40设置在显示屏10的正面12所在的一侧,盖板40的与结构光投射器21对应的区域形成有红外增透膜60。Please refer to FIG. 12. In some embodiments, the electronic device 1000 further includes a cover plate 40. The cover plate 40 is disposed on the side of the front surface 12 of the display screen 10. The area of the cover plate 40 corresponding to the structured light projector 21 The infrared antireflection film 60 is formed.
红外增透膜60可以增加红外光的透过率,当结构光投射器21投射红外激光时,红外增透膜60可以增加红外激光穿过盖板40的透过率,以减少红外激光穿过盖板40时的损耗,进而降低电子装置1000的功耗。具体地,红外增透膜60可以镀在盖板40的上表面、或下表面、或同时镀在上表面及下表面。The infrared anti-reflection film 60 can increase the transmittance of infrared light. When the structured light projector 21 projects an infrared laser, the infrared anti-reflection film 60 can increase the transmittance of the infrared laser through the cover plate 40 to reduce the infrared laser penetration The loss of the cover 40 reduces the power consumption of the electronic device 1000. Specifically, the infrared antireflection film 60 may be plated on the upper surface, or the lower surface of the cover plate 40, or on both the upper surface and the lower surface.
当然,盖板40上与结构光摄像头22对应的区域也可以形成有红外增透膜60,以减少外界的红外光到达结构光摄像头22前穿过盖板40的损耗。盖板40上与泛光灯23对应的区域也可以形成有红外增透膜60,以减少泛光灯23发出的补充光线在穿过盖板40时的损耗。此时盖板40上未与结构光投射器21、结构光摄像头22及泛光灯23对应的区域可以形成有可见光增透膜80,以提高显示屏10发出的可见光穿过盖板40时的透过率。Of course, the area on the cover plate 40 corresponding to the structured light camera 22 may also be formed with an infrared antireflection film 60 to reduce the loss of external infrared light passing through the cover plate 40 before reaching the structured light camera 22. The area corresponding to the floodlight 23 on the cover plate 40 may also be formed with an infrared antireflection film 60 to reduce the loss of supplementary light emitted by the floodlight 23 when passing through the cover plate 40. At this time, the area on the cover 40 that does not correspond to the structured light projector 21, the structured light camera 22, and the floodlight 23 may be formed with a visible light antireflection film 80 to improve the visible light emitted by the display screen 10 when passing through the cover 40 Transmittance.
请参阅图13,在某些实施方式中,显示屏10的与结构光投射器21对应的区域形成有红外增透膜60。Referring to FIG. 13, in some embodiments, an infrared anti-reflection film 60 is formed in the area of the display screen 10 corresponding to the structured light projector 21.
红外增透膜60可以增加红外光的透过率,当结构光投射器21投射红外激光时,红外增透膜60可以增加红外激光穿过显示屏10的透过率,以减少红外激光穿过显示屏10时的损耗,进而降低电子装置1000的功耗。具体地,红外增透膜60可以形成在显示区11的正面12、或背面13、或同时形成显示区 11的正面12或背面13。在一个例子中,红外增透膜60还可以形成在显示屏10的内部,例如当显示屏10为液晶显示屏时,红外增透膜60可以形成在显示屏10内的偏光片上、或者形成在显示屏10的电极板上等。The infrared antireflection film 60 can increase the transmittance of infrared light. When the structured light projector 21 projects an infrared laser, the infrared antireflection film 60 can increase the transmittance of the infrared laser through the display screen 10 to reduce the infrared laser penetration The loss of the display screen 10 further reduces the power consumption of the electronic device 1000. Specifically, the infrared antireflection film 60 may be formed on the front surface 12 or the back surface 13 of the display area 11, or the front surface 12 or the back surface 13 of the display area 11 may be formed at the same time. In one example, the infrared antireflection film 60 may also be formed inside the display screen 10, for example, when the display screen 10 is a liquid crystal display, the infrared antireflection film 60 may be formed on the polarizer in the display screen 10, or formed on The electrode plate of the display screen 10 and the like.
当然,当显示屏10与结构光摄像头22对应的位置未开设通槽14时,显示屏10与结构光摄像头22对应的区域也可以形成红外增透膜60。当显示屏10与泛光灯23对应的位置未开设通槽14时,显示屏10与泛光灯23对应的区域也可以形成红外增透膜60。Of course, when the through-slot 14 is not provided at the position corresponding to the display screen 10 and the structured light camera 22, the area of the display screen 10 and the structured light camera 22 may also be formed with an infrared antireflection film 60. When the through slot 14 is not provided at the position corresponding to the display screen 10 and the floodlight 23, the area corresponding to the display screen 10 and the floodlight 23 may also form an infrared antireflection film 60.
请参阅图14,在某些实施方式中,显示屏10的与结构光投射器21对应的区域形成有红外透过层50。如上所述,红外透过层50对红外光具有较高的透过率,而对红外光以外的光线(如可见光)透过率较低或者使得红外光以外的光线(如可见光)完全不能透过,用户难以看到结构光投射器21。Referring to FIG. 14, in some embodiments, an infrared transmission layer 50 is formed in the area of the display screen 10 corresponding to the structured light projector 21. As described above, the infrared transmission layer 50 has a high transmittance for infrared light, and a low transmittance for light other than infrared light (such as visible light) or makes light other than infrared light (such as visible light) completely impermeable. However, it is difficult for the user to see the structured light projector 21.
同时,当显示屏10与结构光摄像头22对应的位置未开设通槽14时,显示屏10与结构光摄像头22对应的区域也可以形成红外透过层50,以减少穿过显示屏10的红外光以外的光线对结构光摄像头22的影响。当显示屏10与泛光灯23对应的位置未开设通槽14时,显示屏10与泛光灯23对应的区域也可以形成红外透过层50。At the same time, when the through-slot 14 is not provided at the position corresponding to the display screen 10 and the structured light camera 22, the area corresponding to the display screen 10 and the structured light camera 22 may also form an infrared transmission layer 50 to reduce infrared rays passing through the display screen 10 The effect of light other than light on the structured light camera 22. When the through slot 14 is not provided at the position corresponding to the display screen 10 and the floodlight 23, the infrared transmission layer 50 may also be formed in the area corresponding to the display screen 10 and the floodlight 23.
请参阅图15,在某些实施方式中,显示屏10形成有贯穿正面12及背面13的通槽14。电子装置1000还包括可见光摄像头70,可见光摄像头70与通槽14对准设置。盖板40上与通槽14对应的区域形成有可见光增透膜80、及/或红外截止膜90。Please refer to FIG. 15. In some embodiments, the display screen 10 is formed with a through slot 14 penetrating the front surface 12 and the back surface 13. The electronic device 1000 further includes a visible light camera 70 that is aligned with the through slot 14. A visible light antireflection film 80 and / or an infrared cutoff film 90 are formed in the region of the cover plate 40 corresponding to the through groove 14.
可见光摄像头70可用于接收穿过盖板40和通槽14的可见光以获取影像。在盖板40上与通槽14对应的区域形成可见光增透膜80可以增加可见光穿过盖板40时的透过率,以便于提高可见光摄像头70的成像质量。在盖板40上与通槽14对应的区域形成红外截止膜90可以降低红外光穿过盖板40时的透过率,或者完全阻止红外光进入可见光摄像头70,以减少红外光对可见光摄像头70成像时的影响。The visible light camera 70 can be used to receive visible light passing through the cover plate 40 and the through slot 14 to obtain images. Forming a visible light antireflection film 80 on the area of the cover plate 40 corresponding to the through groove 14 can increase the transmittance of visible light when passing through the cover plate 40, so as to improve the imaging quality of the visible light camera 70. The formation of the infrared cut-off film 90 on the area of the cover plate 40 corresponding to the through slot 14 can reduce the transmittance of infrared light when passing through the cover plate 40, or completely prevent infrared light from entering the visible light camera 70 to reduce infrared light to the visible light camera 70 The impact of imaging.
请参阅图1及图16,本申请还提供一种图像获取方法,可用于上述任意一项实施方式所述的结构光组件20。结构光组件20设置在电子装置1000上。结构光组件20包括结构光投射器21和结构光摄像头22,结构光投射器21设置在显示屏10的背面13所在一侧,结构光投射器21用于发射穿过显示区11的结构光。图像获取方法包括:Please refer to FIGS. 1 and 16. The present application also provides an image acquisition method, which can be used in the structured light assembly 20 described in any one of the above embodiments. The structured light assembly 20 is provided on the electronic device 1000. The structured light assembly 20 includes a structured light projector 21 and a structured light camera 22. The structured light projector 21 is disposed on the side of the back surface 13 of the display screen 10. The structured light projector 21 is used to emit structured light passing through the display area 11. Image acquisition methods include:
00:控制结构光投射器21朝显示屏10的显示区11发射结构光;00: Control the structured light projector 21 to emit structured light toward the display area 11 of the display screen 10;
01:控制结构光摄像头22拍摄由结构光产生的散斑图像;和01: Control the structured light camera 22 to capture speckle images generated by structured light; and
02:根据散斑图像中的测量斑点和参考图像中的参考斑点获取深度图像。02: Obtain a depth image based on the measurement spots in the speckle image and the reference spots in the reference image.
请参阅图1及图17,本申请实施方式的图像获取方法可以由本申请实施方式的图像获取装置400实现。图像获取装置400包括控制模块401和计算模块402。步骤00和步骤01可以由控制模块401实现。步骤02可以由计算模块402实现。也即是说,控制模块401可用于控制结构光投射器21朝显示屏10的显示区11发射结构光、以及控制结构光摄像头22拍摄由结构光产生的散斑图像。计算模块402可用于根据散斑图像中的测量斑点和参考图像中的参考斑点获取深度图像。Please refer to FIGS. 1 and 17. The image acquisition method according to the embodiment of the present application may be implemented by the image acquiring device 400 according to the embodiment of the present application. The image acquisition device 400 includes a control module 401 and a calculation module 402. Step 00 and step 01 can be implemented by the control module 401. Step 02 may be implemented by the calculation module 402. That is to say, the control module 401 can be used to control the structured light projector 21 to emit structured light toward the display area 11 of the display screen 10, and to control the structured light camera 22 to capture speckle images generated by the structured light. The calculation module 402 may be used to obtain a depth image based on the measured spots in the speckle image and the reference spots in the reference image.
请再参阅图1,本申请实施方式的图像获取方法可以应用于上述任意一项实施方式所述的结构光组件20中。结构光组件20还包括处理器200,步骤00、步骤01和步骤02均可以由处理器200实现。也即是说,处理器200可用于控制结构光投射器21朝显示屏10的显示区11发射结构光、控制结构光摄像头22拍摄由结构光产生的散斑图像、以及根据所述散斑图像中的测量斑点和参考图像中的参考斑点获取深度图像。其中,结构光组件20的处理器200与电子装置1000的处理器可以为两个独立的处理器;或者,结构光组件20的处理器200与电子装置1000的处理器可以为同一个处理器。在本申请的具体实施例中,结构光组件20的处理器200与电子装置1000的处理器为同一个处理器200。Please refer to FIG. 1 again. The image acquisition method according to the embodiment of the present application may be applied to the structured light assembly 20 described in any one of the above embodiments. The structured light assembly 20 further includes a processor 200, and steps 00, 01, and 02 can be implemented by the processor 200. That is to say, the processor 200 can be used to control the structured light projector 21 to emit structured light toward the display area 11 of the display screen 10, control the structured light camera 22 to capture the speckle image generated by the structured light, and according to the speckle image Obtain the depth image by measuring the spot in the reference spot and the reference spot in the reference image. The processor 200 of the structured light module 20 and the processor of the electronic device 1000 may be two independent processors; or, the processor 200 of the structured light module 20 and the processor of the electronic device 1000 may be the same processor. In a specific embodiment of the present application, the processor 200 of the structured light assembly 20 and the processor of the electronic device 1000 are the same processor 200.
具体地,结构光投射器21开启后可以向场景中投射结构光,投射到场景中的结构光会形成带有多个斑点的散斑图案。由于场景中的多个目标物体与结构光投射器21之间的距离不同,投射到目标物体上的散斑图案会因为目标物体表面高度的不同而被调制,并使得散斑图案中的多个斑点发生不同程度的偏移,偏移后的斑点被结构光摄像头22采集后即可形成包括多个测量斑点的散斑图像。处理器200获取散斑图像后,可以根据散斑图像中的测量斑点相对于参考图像中的参考斑点的偏移量计算得到多个像素的深度数据,多个带有深度数据的像素即可构成一幅深度图像。其中,参考图像为事先标定得到。Specifically, after the structured light projector 21 is turned on, it can project structured light into the scene, and the structured light projected into the scene will form a speckle pattern with multiple spots. Due to the different distances between multiple target objects in the scene and the structured light projector 21, the speckle pattern projected onto the target object will be modulated due to the difference in the height of the target object surface, and cause multiple of the speckle patterns The spots are shifted to different degrees. After the shifted spots are collected by the structured light camera 22, a speckle image including a plurality of measurement spots can be formed. After the processor 200 acquires the speckle image, it can calculate the depth data of multiple pixels according to the offset of the measured speckle in the speckle image relative to the reference speckle in the reference image, and multiple pixels with depth data can be formed A depth image. Among them, the reference image is obtained by calibration in advance.
本申请实施方式的图像获取方法和电子装置1000将结构光投射器21设置在显示屏10背面13所在一侧,即结构光投射器21设置在显示屏10下,显示屏10不需要开设与结构光投射器21对准的通槽14, 电子装置1000的屏占比较高,同时也不会影响深度图像的获取。The image acquisition method and the electronic device 1000 of the embodiment of the present application place the structured light projector 21 on the side of the back 13 of the display screen 10, that is, the structured light projector 21 is provided under the display screen 10, and the display screen 10 does not need to be opened and structured The through slot 14 aligned with the light projector 21 has a relatively high screen occupation of the electronic device 1000, and does not affect the acquisition of depth images.
请参阅图1、图5、图8及图18,在某些实施方式中,结构光投射器21和结构光摄像头22一起设置在显示屏10的背面13所在一侧,且显示屏10开设有与结构光摄像头22的入光面对准的通槽14时,结构光摄像头22接收的是穿过通槽14的被调制后的结构光。此时,步骤01控制结构光摄像头22拍摄由结构光产生的散斑图像包括:Please refer to FIGS. 1, 5, 8 and 18. In some embodiments, the structured light projector 21 and the structured light camera 22 are arranged together on the side of the back 13 of the display screen 10, and the display screen 10 is provided with When the through slot 14 aligned with the light incident surface of the structured light camera 22 is received, the structured light camera 22 receives the modulated structured light passing through the through slot 14. At this time, controlling the structured light camera 22 to capture the speckle image generated by the structured light in step 01 includes:
011:控制结构光摄像头22接收出射时经显示区11衍射并被目标物体反射后直接入射的结构光以得到散斑图像,散斑图像中包括多个测量斑点,多个测量斑点包括激光仅被衍射光学元件213(图4所示)衍射并被目标物体反射形成的第一测量斑点和激光经过衍射光学元件213一次衍射再由显示屏10二次衍射并被目标物体反射形成的第二测量斑点;具体地,第一测量斑点是激光经过衍射光学元件213衍射后在经过显示屏10时并没有被显示屏10衍射,即没有遇到微观间隙而直接投射到目标物体,并被目标物体调制反射后形成的;第二测量斑点是激光经过衍射光学元件213衍射后经过显示屏10时又被显示屏10衍射,即遇到微观间隙后投射到目标物体,并被目标物体调制反射后形成的;011: Control the structured light camera 22 to receive the structured light directly diffracted by the display area 11 and reflected by the target object when it is emitted to obtain a speckle image. The speckle image includes a plurality of measurement spots, and the plurality of measurement spots including the laser light is only The first measuring spot diffracted by the diffractive optical element 213 (shown in FIG. 4) and reflected by the target object and the laser beam pass through the diffractive optical element 213 for a first diffraction and then diffracted again by the display screen 10 and reflected by the target object to form a second measuring spot ; Specifically, the first measurement spot is that after the laser beam is diffracted by the diffractive optical element 213 and passes through the display screen 10, it is not diffracted by the display screen 10, that is, it is directly projected onto the target object without encountering a microscopic gap, and is modulated and reflected by the target object The second measurement spot is formed by the laser light diffracted by the diffractive optical element 213 and then diffracted by the display screen 10 after passing through the display screen 10, that is, it is projected onto the target object after encountering a microscopic gap, and is modulated and reflected by the target object;
步骤02根据散斑图像中的测量斑点和参考图像中的参考斑点获取深度图像包括:Step 02: Obtaining a depth image based on the measured spots in the speckle image and the reference spots in the reference image includes:
021:根据散斑图像中的第一测量斑点及第二测量斑点与参考图像中的参考斑点获取深度图像。021: Acquire a depth image according to the first measurement spot and the second measurement spot in the speckle image and the reference spot in the reference image.
请再参阅图17,在某些实施方式中,步骤011可以由控制模块401实现。步骤021可以由计算模块402实现。Please refer to FIG. 17 again. In some embodiments, step 011 may be implemented by the control module 401. Step 021 can be implemented by the calculation module 402.
请再参阅图1,在某些实施方式中,步骤011和步骤021均可以由处理器200实现。也即是说,处理器200还可用于控制结构光摄像头22接收出射时经显示区11衍射并被目标物体反射后直接入射的结构光以得到散斑图像,散斑图像中包括多个测量斑点,多个测量斑点包括激光仅被衍射光学元件213衍射并被目标物体反射形成的第一测量斑点和激光经过衍射光学元件213一次衍射再由显示屏10二次衍射并被目标物体反射形成的第二测量斑点。处理器200还可用于根据散斑图像中的第一测量斑点及第二测量斑点与参考图像中的参考斑点获取深度图像。Please refer to FIG. 1 again. In some embodiments, both step 011 and step 021 may be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to receive the structured light that is diffracted by the display area 11 and reflected directly by the target object when being emitted to obtain a speckle image, and the speckle image includes multiple measurement spots The multiple measurement spots include the first measurement spot formed by laser light diffracted by the diffractive optical element 213 and reflected by the target object, and the first measurement spot formed by laser light diffracted by the diffractive optical element 213 and then diffracted by the display screen 10 second time and reflected by the target object Two measuring spots. The processor 200 may also be used to obtain a depth image according to the first measurement spot and the second measurement spot in the speckle image and the reference spot in the reference image.
具体地,请结合图4,结构光投射器21通常包括光源211、准直元件212和衍射光学元件213。其中,光源211用于发射激光;准直元件212用于准直光源211发射的激光;衍射光学元件213用于衍射经准直元件212准直后的激光以向场景中投射结构光,投射到场景中的结构光形成散斑图案,散斑图案中包括多个斑点,这些斑点是激光仅经过衍射光学元件213的衍射形成的。Specifically, referring to FIG. 4, the structured light projector 21 generally includes a light source 211, a collimating element 212 and a diffractive optical element 213. Among them, the light source 211 is used to emit laser light; the collimating element 212 is used to collimate the laser light emitted by the light source 211; the diffractive optical element 213 is used to diffract the laser light collimated by the collimating element 212 to project structured light into the scene The structured light in the scene forms a speckle pattern, and the speckle pattern includes a plurality of spots, which are formed by the diffraction of the laser light only through the diffractive optical element 213.
LCD屏、OLED屏、Micro LED屏等类型的显示屏10的显示区11上通常形成有固定的像素排布结构,相邻像素之间形成有微观间隙,当单点激光穿过这些微观间隙时会被衍射以产生一系列的斑点。显示区11中像素排布结构不同时,单点激光穿过显示区11后形成的散斑图案的斑点的排布也不一样。结构光投射器21发射的结构光通常为红外激光。如此,当结构光投射器21置于显示屏10背面13所在一侧,即显示屏10下方时,结构光投射器21发射的红外激光穿过显示区11时也会被显示区11中的微观间隙所衍射以产生具有多个斑点的散斑图案。由此,结构光投射器21投射到空间中的散斑图案中的多个斑点同时包括激光仅被衍射光学元件213衍射形成的第一斑点和激光经过衍射光学元件213一次衍射再由显示屏10二次衍射形成的第二斑点。LCD screens, OLED screens, Micro LED screens, and other types of display screens 10 usually have a fixed pixel arrangement structure on the display area 11, and microscopic gaps are formed between adjacent pixels. When a single-point laser passes through these microscopic gaps Will be diffracted to produce a series of spots. When the pixel arrangement structure in the display area 11 is different, the arrangement of the spots of the speckle pattern formed after the single-point laser passes through the display area 11 is also different. The structured light emitted by the structured light projector 21 is usually an infrared laser. In this way, when the structured light projector 21 is placed on the side of the back 13 of the display screen 10, that is, below the display screen 10, the infrared laser emitted by the structured light projector 21 passes through the display area 11 will also be The gap is diffracted to produce a speckle pattern with multiple spots. Thereby, the plurality of spots in the speckle pattern projected by the structured light projector 21 in the space simultaneously include the first spot formed by the laser light diffracted only by the diffractive optical element 213 and the laser light is diffracted once by the diffractive optical element 213 and then by the display screen 10 The second spot formed by the second diffraction.
结构光摄像头22成像时,结构光摄像头22会接收由场景中的目标物体反射回的结构光以形成散斑图像。在本申请实施方式中,由于显示屏10开设有通槽14,结构光摄像头22的入光面与通槽14对准,通槽14不具有微观间隙,经衍射光学元件213一次衍射、又经显示屏10二次衍射并被目标物体调制后反射回的激光经过通槽14时不会被衍射,结构光摄像头22接收的是经显示区11衍射并被目标物体反射后直接入射的结构光,形成的散斑图像中的多个测量斑点同时包括激光仅被衍射光学元件213衍射并被目标物体反射形成的第一测量斑点和激光经过衍射光学元件213一次衍射再由显示屏10二次衍射并被目标物体反射形成的第二测量斑点。When the structured light camera 22 is imaging, the structured light camera 22 receives the structured light reflected by the target object in the scene to form a speckle image. In the embodiment of the present application, since the display screen 10 is provided with a through slot 14, the light incident surface of the structured light camera 22 is aligned with the through slot 14, the through slot 14 does not have a micro gap, and is diffracted once by the diffractive optical element 213 The laser light reflected by the second-order diffraction of the display screen 10 and modulated by the target object will not be diffracted when passing through the slot 14. The structured light camera 22 receives the structured light diffracted by the display area 11 and reflected directly by the target object. The multiple measurement spots in the formed speckle image simultaneously include the first measurement spot formed by laser light diffracted only by the diffractive optical element 213 and reflected by the target object and the laser light is diffracted once by the diffractive optical element 213 and then diffracted by the display screen 10 twice The second measurement spot formed by the reflection of the target object.
结构光摄像头22拍摄到散斑图像后,处理器200可以直接根据散斑图像中的第一测量斑点及第二测量斑点与参考图像中的参考斑点来计算深度图像。其中,深度图像的计算方式可以包括下述的两种。After the speckle image is captured by the structured light camera 22, the processor 200 may directly calculate the depth image according to the first measurement spot and the second measurement spot in the speckle image and the reference spot in the reference image. The calculation method of the depth image may include the following two.
请参阅图19,在一个计算方式中,步骤021包括:Referring to FIG. 19, in a calculation method, step 021 includes:
0211:计算所有测量斑点相对于所有参考斑点的偏移量;及0211: Calculate the offset of all measurement spots relative to all reference spots; and
0212:根据偏移量计算深度数据以得到深度图像。0212: Calculate depth data according to the offset to obtain a depth image.
对应地,图像获取方法还包括:Correspondingly, the image acquisition method also includes:
031:在标定参考图像时,控制结构光摄像头22接收出射时经显示区11衍射并被标定物体反射后直接入射的结构光以得到参考图像,参考图像中包括多个参考斑点。031: When calibrating the reference image, the structured light camera 22 is controlled to receive the structured light that is diffracted by the display area 11 and reflected directly by the calibrated object when it exits to obtain a reference image, and the reference image includes multiple reference spots.
请再参阅图17,步骤0211和步骤0212均可以由计算模块402实现。步骤031可以由控制模块401实现。Please refer to FIG. 17 again, both step 0211 and step 0212 can be implemented by the calculation module 402. Step 031 can be implemented by the control module 401.
请再参阅图1,步骤0211、步骤0212和步骤031均可以由处理器200实现。也即是说,处理器200还可用于计算所有测量斑点相对于所有参考斑点的偏移量及根据偏移量计算深度数据以得到深度图像。处理器200还可用于在标定参考图像时,控制结构光摄像头22接收出射时经显示区11衍射并被标定物体反射后直接入射的结构光以得到参考图像,参考图像中包括多个参考斑点。Please refer to FIG. 1 again. Step 0211, step 0212, and step 031 may be implemented by the processor 200. That is to say, the processor 200 can also be used to calculate the offsets of all measurement spots relative to all reference spots and calculate depth data according to the offsets to obtain depth images. The processor 200 can also be used to control the structured light camera 22 to receive the structured light directly diffracted by the display area 11 and reflected by the calibrated object when it is calibrated to obtain the reference image. The reference image includes multiple reference spots.
具体地,请结合图20,在标定参考图像的过程中,结构光投射器21与结构光摄像头22均设置在显示屏10的背面13所在一侧,且显示屏10开设有与结构光摄像头22的入光面对准的通槽14,结构光摄像头22可以接收穿过通槽14的被调制后的结构光。如此,在标定场景下和实际使用场景下,结构光投射器21与结构光摄像头22相对于显示屏10的设置位置是一致的。在标定场景下,处理器200控制结构光投射器21发射结构光,结构光穿过显示区11后投射到与结构光组件20相隔预定距离的标定物体,如标定板处,被标定板反射回的结构光穿过通槽14被结构光摄像头22接收。此时,结构光摄像头22接收到的是由结构光投射器21发出后经显示屏10衍射并被标定板反射后经由通槽14直接入射的结构光,形成的参考图像中包括多个参考斑点。其中,参考斑点同时包括与第一测量斑点对应的第一参考斑点和与第二测量斑点对应的第二参考斑点。第一参考斑点是激光在经过衍射光学元件213时被衍射光学元件213衍射,且在经过显示屏10未被显示屏10衍射,并被标定板调制反射后形成的;第二参考斑点是激光经过衍射光学元件213时被衍射光学元件213一次衍射,且在经过显示屏10时又被显示屏10二次衍射,并被标定板调制反射后形成的。虽然散斑图像中同时包括第一测量斑点和第二测量斑点,参考图像中同时包括第一参考斑点和第二参考斑点,但是在此计算方式中,处理器200并不会对散斑图像中的第一测量斑点和第二测量斑点做区分,也不会对参考图像中的第一参考斑点和第二参考斑点做区分,而是直接基于所有的测量斑点和所有的参考斑点来进行深度图像的计算。具体地,处理器200首先计算所有测量斑点相对于所有参考斑点的偏移量,再基于多个偏移量计算出多个深度数据,从而得到深度图像。Specifically, referring to FIG. 20, in the process of calibrating the reference image, the structured light projector 21 and the structured light camera 22 are both provided on the side of the back 13 of the display screen 10, and the display screen 10 is provided with a structured light camera 22 The structured light camera 22 can receive the modulated structured light passing through the through-slot 14 through the through-slot 14 where the light incident surface is aligned. In this way, in the calibration scene and the actual use scene, the installation positions of the structured light projector 21 and the structured light camera 22 relative to the display screen 10 are the same. In the calibration scenario, the processor 200 controls the structured light projector 21 to emit structured light. The structured light passes through the display area 11 and is projected onto a calibration object at a predetermined distance from the structured light assembly 20, such as the calibration plate, and is reflected back by the calibration plate The structured light passing through the through slot 14 is received by the structured light camera 22. At this time, the structured light camera 22 receives the structured light emitted by the structured light projector 21, diffracted by the display screen 10 and reflected by the calibration plate, and then directly incident through the through slot 14, the formed reference image includes multiple reference spots . Wherein, the reference spot simultaneously includes a first reference spot corresponding to the first measurement spot and a second reference spot corresponding to the second measurement spot. The first reference spot is formed when the laser light is diffracted by the diffractive optical element 213 when passing through the diffractive optical element 213, and is not diffracted by the display screen 10 after passing through the display screen 10, and is modulated and reflected by the calibration plate; the second reference spot is formed by the laser light The diffractive optical element 213 is diffracted once by the diffractive optical element 213, and when passing through the display screen 10, it is diffracted again by the display screen 10, and is modulated and reflected by the calibration plate. Although the speckle image includes both the first measurement spot and the second measurement spot, and the reference image includes both the first reference spot and the second reference spot, in this calculation method, the processor 200 does not The first measurement spot and the second measurement spot are distinguished, and the first reference spot and the second reference spot in the reference image are not distinguished, but the depth image is directly based on all the measurement spots and all the reference spots. Calculation. Specifically, the processor 200 first calculates the offsets of all measurement spots relative to all reference spots, and then calculates multiple depth data based on the multiple offsets, thereby obtaining a depth image.
请参阅图21,在另一个计算方式中,步骤021包括:Referring to FIG. 21, in another calculation method, step 021 includes:
0213:计算第一测量斑点相对于第一参考斑点的偏移量、以及第二测量斑点相对于第二参考斑点的偏移量;及0213: Calculate the offset of the first measurement spot relative to the first reference spot, and the offset of the second measurement spot relative to the second reference spot; and
0214:根据偏移量计算深度数据以得到深度图像。0214: Calculate depth data according to the offset to obtain a depth image.
此时,图像获取方法还包括:At this time, the image acquisition method also includes:
032:在标定参考图像时,控制结构光摄像头22接收从结构光投射器21出射后直接被标定物体反射并直接入射的结构光以得到第一参考图像,第一参考图像中包括多个参考斑点,多个参考斑点包括多个激光仅被衍射光学元件213衍射并被标定物体反射形成的第一参考斑点;032: When calibrating the reference image, the structured light camera 22 is controlled to receive the structured light directly reflected by the calibrated object after being emitted from the structured light projector 21 and directly incident to obtain a first reference image, and the first reference image includes multiple reference spots The multiple reference spots include a first reference spot formed by multiple laser beams diffracted by the diffractive optical element 213 only and reflected by the calibration object;
033:在标定参考图像时,控制结构光摄像头22接收出射时经显示区11衍射并被标定物体反射后直接入射的结构光以得到第二参考图像,第二参考图像中包括多个参考斑点,多个参考斑点包括激光仅被衍射光学元件213衍射并被标定物体反射形成的第一参考斑点和激光经过衍射光学元件213一次衍射再由显示屏10二次衍射并被标定物体反射形成的第二参考斑点;033: When calibrating the reference image, the structured light camera 22 is controlled to receive the structured light diffracted by the display area 11 and reflected directly by the calibrated object when being emitted to obtain a second reference image, which includes a plurality of reference spots, The multiple reference spots include a first reference spot formed by laser light diffracted only by the diffractive optical element 213 and reflected by the calibrated object, and a second reference spot formed by the laser light diffracted once by the diffractive optical element 213 and then diffracted by the display screen 10 and reflected by the calibrated object Reference spot
041:比对第一参考图像与第二参考图像以获取第二参考斑点;041: Compare the first reference image with the second reference image to obtain a second reference spot;
051:计算多个第二参考斑点的亮度的平均值与多个第一参考斑点的亮度的平均值之间的比值并作为预设比值,及计算多个第一参考斑点的亮度的平均值并作为预设亮度;051: Calculate the ratio between the average value of the brightness of the multiple second reference spots and the average value of the brightness of the multiple first reference spots as the preset ratio, and calculate the average value of the brightness of the multiple first reference spots and As the preset brightness;
061:计算每个测量斑点与预设亮度之间的实际比值;及061: Calculate the actual ratio between each measured spot and the preset brightness; and
071:将实际比值大于预设比值的测量斑点归类为第一测量斑点,及将实际比值小于第一预设比值的测量斑点归类为第二测量斑点。071: The measurement spot whose actual ratio is greater than the preset ratio is classified as the first measurement spot, and the measurement spot whose actual ratio is less than the first preset ratio is classified as the second measurement spot.
请再参阅图17,步骤0213、步骤0214、步骤041、步骤051、步骤061和步骤071均可以由计算模块402实现。步骤032和步骤033均可以由控制模块401实现。Please refer to FIG. 17 again. Step 0213, step 0214, step 041, step 051, step 061, and step 071 can all be implemented by the calculation module 402. Both step 032 and step 033 can be implemented by the control module 401.
请再参阅图1,步骤0213、步骤0214、步骤032、步骤033、步骤041、步骤051、步骤061和步骤071均可以由处理器200实现。也即是说,处理器200还可用于在标定参考图像时控制结构光摄像头 22接收从所述结构光投射器21出射后直接被标定物体反射并直接入射的结构光以得到第一参考图像、在标定参考图像时控制结构光摄像头22接收出射时经显示区11衍射并被标定物体反射后直接入射的结构光以得到第二参考图像、比对第一参考图像与第二参考图像以获取第二参考斑点、计算多个第二参考斑点的亮度的平均值与多个第一参考斑点的亮度的平均值之间的比值并作为预设比值、及计算多个第一参考斑点的亮度的平均值并作为预设亮度。处理器200还可用于计算每个测量斑点与预设亮度之间的实际比值、将实际比值大于预设比值的测量斑点归类为第一测量斑点、及将实际比值小于预设比值的测量斑点归类为第二测量斑点。处理器200还可用于计算第一测量斑点相对于第一参考斑点的偏移量、以及第二测量斑点相对于第二参考斑点的偏移量、以及根据偏移量计算深度数据以得到深度图像。Please refer to FIG. 1 again. Step 0213, step 0214, step 032, step 033, step 041, step 051, step 061, and step 071 may all be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to receive the structured light directly reflected by the calibrated object and directly incident after being emitted from the structured light projector 21 when the reference image is calibrated to obtain the first reference image, When the reference image is calibrated, the structured light camera 22 is controlled to receive the structured light that is diffracted by the display area 11 and reflected directly by the calibrated object when being emitted to obtain a second reference image, compare the first reference image with the second reference image to obtain the second Two reference spots, calculating the ratio between the average value of the brightness of the plurality of second reference spots and the average value of the brightness of the plurality of first reference spots as a preset ratio, and calculating the average of the brightness of the plurality of first reference spots Value as the preset brightness. The processor 200 can also be used to calculate the actual ratio between each measurement spot and the preset brightness, classify the measurement spots whose actual ratio is greater than the preset ratio as the first measurement spots, and classify the measurement spots whose actual ratio is less than the preset ratio It is classified as the second measurement spot. The processor 200 may be further used to calculate the offset of the first measurement spot relative to the first reference spot, and the offset of the second measurement spot relative to the second reference spot, and calculate depth data according to the offset to obtain a depth image .
此种计算方式下,处理器200需要标定出第一参考图像和第二参考图像。具体地,处理器200首先控制结构光投射器21在没有显示屏10遮挡的场景下发射结构光至标定板处,再控制结构光摄像头22接收由标定板反射后直接入射的结构光以得到第一参考图像,其中,第一参考图像中包括的多个参考斑点为第一参考斑点,第一参考斑点是激光在经过衍射光学元件213时被衍射光学元件213衍射,且直接出射到标定板后被标定板调制反射后直接入射形成的。随后,处理器200按照第一种计算方式,即前述步骤031中参考图像的标定方式标定出第二参考图像。此时第二参考图像中同时包括与第一测量斑点对应的第一参考斑点和与第二测量斑点对应的第二参考斑点。其中,第一参考图像和第二参考图像的标定场景中,标定板与结构光投射器21及结构光摄像头22之间的相对位置是保持不变的,结构光投射器21与结构光摄像头21之间的相对位置也保持不变。随后,处理器200标记出第一参考图像中的第一参考斑点的坐标,并根据第一参考斑点的坐标在第二参考图像中筛选出第一参考斑点,第二参考图像中剩余的参考斑点即为第二参考斑点。如此,处理器200即可在第二参考图像的所有参考斑点中区分出第一参考斑点和第二参考斑点。In this calculation mode, the processor 200 needs to calibrate the first reference image and the second reference image. Specifically, the processor 200 first controls the structured light projector 21 to emit structured light to the calibration plate in a scene without the screen 10 blocking, and then controls the structured light camera 22 to receive the structured light directly reflected by the calibration plate to obtain the first A reference image, where the multiple reference spots included in the first reference image are the first reference spots, the first reference spots are laser beams diffracted by the diffractive optical element 213 when passing through the diffractive optical element 213, and directly exit the calibration plate It is formed by direct reflection after being modulated and reflected by the calibration plate. Subsequently, the processor 200 calibrates the second reference image according to the first calculation method, that is, the reference image calibration method in step 031. At this time, the second reference image includes both the first reference spot corresponding to the first measurement spot and the second reference spot corresponding to the second measurement spot. Among them, in the calibration scene of the first reference image and the second reference image, the relative positions between the calibration plate, the structured light projector 21 and the structured light camera 22 remain unchanged, and the structured light projector 21 and the structured light camera 21 The relative position between them also remains unchanged. Subsequently, the processor 200 marks the coordinates of the first reference spot in the first reference image, and filters out the first reference spots in the second reference image according to the coordinates of the first reference spot, and the remaining reference spots in the second reference image This is the second reference spot. In this way, the processor 200 can distinguish the first reference spot and the second reference spot among all reference spots of the second reference image.
由于后续计算深度数据时,散斑图像中的测量斑点也需要进行区分。具体地,可以通过亮度来区分出第一测量斑点和第二测量斑点。可以理解,第一测量斑点是激光仅经过衍射光学元件213的一次衍射形成的,第二测量斑点是激光经过衍射光学元件213的一次衍射和显示屏10的二次衍射形成的,形成第二测量斑点的激光被衍射的次数多于形成第一测量斑点的激光被衍射的次数,因此,形成第一测量斑点的激光的能量损耗较小,形成第二测量斑点的激光的能量损耗较大,第二测量斑点的亮度会低于第一测量斑点的亮度。如此,基于亮度来区分出第一测量斑点和第二测量斑点是可行的。那么,在参考图像标定完毕后还需要进一步标定出用于区分第一测量斑点和第二测量斑点的预设亮度及预设比值。具体地,在处理器200区分出第一参考斑点和第二参考斑点后,处理器200计算出第二参考图像中多个第一参考斑点的亮度的平均值,并计算出第二参考图像中多个第二参考斑点的亮度的平均值。随后,处理器200将多个第一参考斑点的亮度的平均值作为预设亮度,将多个第二参考斑点的亮度的平均值与多个第一参考斑点的亮度的平均值之间的比值作为预设比值。As the depth data is calculated later, the measurement spots in the speckle image also need to be distinguished. Specifically, the first measurement spot and the second measurement spot can be distinguished by brightness. It can be understood that the first measurement spot is formed by the first-order diffraction of laser light through the diffractive optical element 213, and the second measurement spot is formed by the first-order diffraction of the laser light through the diffractive optical element 213 and the second-order diffraction of the display screen 10 to form the second measurement The number of times the laser spot is diffracted is greater than the number of times the laser spot forming the first measurement spot is diffracted. Therefore, the energy loss of the laser spot forming the first measurement spot is small, and the energy loss of the laser spot forming the second measurement spot is large. The brightness of the second measurement spot will be lower than the brightness of the first measurement spot. As such, it is feasible to distinguish the first measurement spot from the second measurement spot based on the brightness. Then, after the reference image calibration is completed, it is necessary to further calibrate the preset brightness and the preset ratio for distinguishing the first measurement spot from the second measurement spot. Specifically, after the processor 200 distinguishes the first reference spot and the second reference spot, the processor 200 calculates the average value of the brightness of the plurality of first reference spots in the second reference image, and calculates the second reference image The average value of the brightness of the plurality of second reference spots. Subsequently, the processor 200 takes the average value of the brightness of the plurality of first reference spots as the preset brightness, and takes the ratio between the average value of the brightness of the plurality of second reference spots and the average value of the brightness of the plurality of first reference spots As a preset ratio.
在后续的深度数据计算中,处理器200首先计算出每个测量斑点的亮度。随后,处理器200计算每个测量斑点与预设亮度之间的实际比值,并将实际比值大于或等于预设比值的测量斑点归类为第一测量斑点,将实际比值小于预设比值的测量斑点归类为第二测量斑点,从而区分出第一测量斑点和第二测量斑点。例如,如图22所示,假设预设比值为0.8,实际使用中结构光摄像头22拍摄的散斑图像中包括测量斑点A和测量斑点B。其中,测量斑点A的亮度与预设亮度之间的比值若小于0.8,则将测量斑点A归类到第二测量斑点,此时说明测量斑点A是激光经衍射光学元件213一次衍射再由显示屏10二次衍射并被目标物体反射形成的测量斑点;测量斑点B的亮度与预设亮度之间的比值大于或等于0.8,则将测量斑点B归类到第一测量斑点中,此时说明测量斑点B是激光经衍射光学元件213一次衍射并被目标物体反射形成的测量斑点。其中,预设比值0.8仅为示例。In the subsequent depth data calculation, the processor 200 first calculates the brightness of each measurement spot. Subsequently, the processor 200 calculates the actual ratio between each measurement spot and the preset brightness, and classifies the measurement spots whose actual ratio is greater than or equal to the preset ratio as the first measurement spot, and measures the actual ratio less than the preset ratio The spots are classified as second measurement spots, thereby distinguishing the first measurement spots from the second measurement spots. For example, as shown in FIG. 22, assuming that the preset ratio is 0.8, the speckle image captured by the structured light camera 22 in actual use includes measurement spot A and measurement spot B. Among them, if the ratio between the brightness of the measurement spot A and the preset brightness is less than 0.8, the measurement spot A is classified into the second measurement spot. At this time, the measurement spot A is diffracted by the laser through the diffraction optical element 213 and then displayed The measurement spot formed by the second diffraction of the screen 10 and reflected by the target object; the ratio between the brightness of the measurement spot B and the preset brightness is greater than or equal to 0.8, then the measurement spot B is classified into the first measurement spot, which is explained at this time The measurement spot B is a measurement spot formed by laser light diffracted once by the diffractive optical element 213 and reflected by the target object. Among them, the preset ratio of 0.8 is only an example.
处理器200区分出第一测量斑点和第二测量斑点后,由于第二参考图像中的第一参考斑点和第二参考斑点也已经被区分出,则处理器200即可利用散斑图像和第二参考图像计算出深度数据。具体地,处理器200首先计算第一测量斑点相对于第一参考斑点的偏移量、以及第二测量斑点相对于第二参考斑点的偏移量。随后,处理器200基于多个偏移量计算出多个深度数据,多个深度数据即可构成一幅深度图像。After the processor 200 distinguishes the first measurement spot and the second measurement spot, since the first reference spot and the second reference spot in the second reference image have also been distinguished, the processor 200 can use the speckle image and the second measurement spot. Two reference images calculate depth data. Specifically, the processor 200 first calculates the offset of the first measurement spot relative to the first reference spot, and the offset of the second measurement spot relative to the second reference spot. Subsequently, the processor 200 calculates multiple depth data based on multiple offsets, and the multiple depth data can constitute a depth image.
与第一种计算方式相比,第二种计算方式对第一测量斑点和第二测量斑点进行区分,对第一参考斑点和第二参考斑点进行区分,可以基于更为准确的第一测量斑点与第一参考斑点的对应关系、以及第二 测量斑点与第二参考斑点的对应关系计算得到更为准确的偏移量,进一步得到较为准确的深度数据,提升获取的深度图像的精度。Compared with the first calculation method, the second calculation method distinguishes between the first measurement spot and the second measurement spot, and distinguishes between the first reference spot and the second reference spot, which can be based on the more accurate first measurement spot The corresponding relationship with the first reference spot and the corresponding relationship between the second measurement spot and the second reference spot are calculated to obtain a more accurate offset, further obtain more accurate depth data, and improve the accuracy of the acquired depth image.
在某些实施方式中,预设亮度和预设比值由场景的环境亮度以及结构光投射器21的发光功率决定。可以理解,环境光线中存在红外光成分,这部分红外光成分可能会与测量斑点进行叠加使得测量斑点的亮度有所增加;结构光投射器21的发光功率与测量斑点的亮度息息相关,当发光功率较大时,测量斑点的亮度也相应较高;当发光功率较小时,测量斑点的亮度也相应较低。因此,不同的环境亮度和发光功率应该具有不同的预设亮度和预设比值。不同环境亮度和不同发光功率下的预设亮度和预设比值同样可以按照步骤032和步骤033的标定过程标定得到。在标定过程中,对标定场景的环境亮度以及结构光投射器21的发光功率进行改变以获得对应该环境亮度及发光功率的预设亮度和预设比值,其中,改变结构光投射器21的发光功率具体可以通过改变光源211的驱动电流来实现。环境亮度、发光功率、预设亮度及预设比值四者的对应关系可以以映射表的形式存储在存储器300(图1所示)中。在后续以第二种计算方式计算深度图像时,处理器200首先获取场景的环境亮度和发光功率,并在映射表中查找与当前的环境亮度和发光功率对应的预设亮度和预设比值,再基于查找的预设亮度和预设比值区分出第一测量斑点和第二测量斑点。如此,可以提升第一测量斑点和第二测量斑点的区分的准确性。In some embodiments, the preset brightness and the preset ratio are determined by the ambient brightness of the scene and the luminous power of the structured light projector 21. It can be understood that there is an infrared light component in the ambient light, and this part of the infrared light component may be superimposed on the measurement spot to increase the brightness of the measurement spot; the luminous power of the structured light projector 21 is closely related to the brightness of the measurement spot. When it is larger, the brightness of the measurement spot is correspondingly higher; when the luminous power is smaller, the brightness of the measurement spot is correspondingly lower. Therefore, different ambient brightness and luminous power should have different preset brightness and preset ratio. The preset brightness and preset ratio under different ambient brightness and different luminous power can also be calibrated according to the calibration process of step 032 and step 033. During the calibration process, the ambient brightness of the calibration scene and the luminous power of the structured light projector 21 are changed to obtain a preset brightness and a preset ratio corresponding to the ambient brightness and luminous power, wherein the light emission of the structured light projector 21 is changed The power can be realized by changing the driving current of the light source 211. The corresponding relationship among the ambient brightness, the luminous power, the preset brightness and the preset ratio can be stored in the memory 300 (shown in FIG. 1) in the form of a mapping table. In the subsequent calculation of the depth image in the second calculation method, the processor 200 first obtains the ambient brightness and luminous power of the scene, and looks up the preset brightness and preset ratio corresponding to the current ambient brightness and luminous power in the mapping table, Then, the first measurement spot and the second measurement spot are distinguished based on the searched preset brightness and preset ratio. In this way, the accuracy of the distinction between the first measurement spot and the second measurement spot can be improved.
在某些实施方式中,衍射光学元件213除了用于衍射结构光投射器21的光源211发射的激光以增加测量斑点或参考斑点的数量之外,还可以用于补偿显示屏10衍射的结构光的亮度均匀性,使得投射到场景中的散斑图案中的多个斑点的亮度的均匀性较好,有利图提升深度图像的获取精度。具体地,衍射光学元件213中的凸起或凹陷结构可以呈中间密、两边疏的排布,则衍射光学元件213的中间部分的衍射作用比边缘部分的衍射作用强。如此,入射到衍射光学元件213的中间部分的激光可以被衍射出更多光束,入射到衍射光学元件213的边缘部分的激光会被衍射出较少的光束,从而使得投射到场景中的散斑图案的亮度具有较高的均匀性。In some embodiments, the diffractive optical element 213 can be used to compensate the structured light diffracted by the display screen 10 in addition to diffracting the laser light emitted by the light source 211 of the structured light projector 21 to increase the number of measurement spots or reference spots. The uniformity of the brightness makes the uniformity of the brightness of the multiple spots in the speckle pattern projected into the scene better, which is beneficial to improve the accuracy of acquiring the depth image. Specifically, the convex or concave structures in the diffractive optical element 213 may be arranged densely in the middle and sparse on both sides, then the diffraction effect of the middle part of the diffractive optical element 213 is stronger than that of the edge part. In this way, the laser light incident on the middle portion of the diffractive optical element 213 can be diffracted with more light beams, and the laser light incident on the edge portion of the diffractive optical element 213 can be diffracted with less light beams, thereby making the speckle projected into the scene The brightness of the pattern has high uniformity.
现有技术中,而显示屏的与深度相机错开设置导致移动终端的屏占比较低,综上,本申请实施方式的图像获取方法在结构光投射器21和结构光摄像头22均位于显示屏10的背面13所在一侧,且结构光摄像头22接收的是穿过通槽14的被调制的结构光时,处理器200可直接根据第一测量斑点及第二测量斑点计算深度图像,相比于仅使用第一测量斑点来计算深度图像的方式,显示屏10的衍射作用增加了测量斑点的数量和测量斑点排布的随机性,有利于提升深度图像的获取精度。进一步地,本申请实施方式的图像获取方法可以适当简化衍射光学元件213中衍射光栅的结构的复杂性,转而借助显示屏10的衍射作用来增加测量斑点的数量和排布的随机性,在保障深度图像的获取精度的同时可以简化结构光投射器21的制作工艺。In the prior art, the staggered setting of the display screen and the depth camera results in a relatively low screen occupation of the mobile terminal. In summary, in the image acquisition method of the embodiment of the present application, both the structured light projector 21 and the structured light camera 22 are located on the display screen 10 When the structured light camera 22 receives the modulated structured light passing through the through slot 14, the processor 200 can directly calculate the depth image based on the first measurement spot and the second measurement spot, compared to By using only the first measurement spot to calculate the depth image, the diffraction effect of the display screen 10 increases the number of measurement spots and the randomness of the arrangement of the measurement spots, which is beneficial to improve the accuracy of acquiring the depth image. Further, the image acquisition method according to the embodiment of the present application can appropriately simplify the complexity of the structure of the diffraction grating in the diffractive optical element 213, and in turn, the number of measurement spots and the randomness of the arrangement are increased by the diffraction effect of the display screen 10, While ensuring the accuracy of acquiring the depth image, the manufacturing process of the structured light projector 21 can be simplified.
请参阅图1、图5、图8及图23,在某些实施方式中,在结构光投射器21和结构光摄像头22一起设置在显示屏10的背面13所在一侧,且显示屏10开设有与结构光摄像头22的入光面对准的通槽14时,结构光摄像头22接收的是穿过通槽14的被调制后的结构光。此时,步骤01包括:Please refer to FIG. 1, FIG. 5, FIG. 8 and FIG. 23. In some embodiments, the structured light projector 21 and the structured light camera 22 are arranged together on the side of the back 13 of the display screen 10, and the display screen 10 is opened When there is a through slot 14 aligned with the light incident surface of the structured light camera 22, the structured light camera 22 receives the modulated structured light passing through the through slot 14. At this time, step 01 includes:
011:控制结构光摄像头22接收出射时经显示区11衍射并被目标物体反射后直接入射的结构光以得到散斑图像,散斑图像中包括多个测量斑点,多个测量斑点包括激光仅被衍射光学元件213衍射并被目标物体反射形成的第一测量斑点和激光经过衍射光学元件213一次衍射再由显示屏10二次衍射并被目标物体反射形成的第二测量斑点;具体地,第一测量斑点是激光经过衍射光学元件213衍射后在经过显示屏10时并没有被显示屏10衍射,即没有遇到微观间隙而直接投射到目标物体,并被目标物体调制反射后形成的;第二测量斑点是激光经过衍射光学元件213衍射后经过显示屏10时又被显示屏10衍射,即遇到微观间隙后投射到目标物体,并被目标物体调制反射后形成的;011: Control the structured light camera 22 to receive the structured light directly diffracted by the display area 11 and reflected by the target object when it is emitted to obtain a speckle image. The speckle image includes a plurality of measurement spots, and the plurality of measurement spots including the laser light is only The first measurement spot diffracted by the diffractive optical element 213 and reflected by the target object and the second measurement spot formed by the laser beam diffracted once by the diffractive optical element 213 and secondarily diffracted by the display screen 10 and reflected by the target object; specifically, the first The measurement spot is formed after the laser beam is diffracted by the diffractive optical element 213 and is not diffracted by the display screen 10 when passing through the display screen 10, that is, it is directly projected onto the target object without encountering a micro gap, and is modulated and reflected by the target object; second The measurement spot is formed by the laser beam diffracted by the diffractive optical element 213 and then diffracted by the display screen 10 after passing through the display screen 10, that is, it is projected onto the target object after encountering a microscopic gap, and is modulated and reflected by the target object;
步骤02包括: Step 02 includes:
022:滤除散斑图像中的第二测量斑点以得到第一测量斑点;022: Filter out the second measurement spot in the speckle image to obtain the first measurement spot;
023:根据第一测量斑点及参考图像中的参考斑点获取深度图像。023: Acquire a depth image according to the first measurement spot and the reference spot in the reference image.
请再参阅图17,步骤011可以由控制模块401实现。步骤022和步骤023均可以由计算模块402实现。Please refer to FIG. 17 again. Step 011 may be implemented by the control module 401. Both step 022 and step 023 can be implemented by the calculation module 402.
请再参阅图1,步骤011、步骤022和步骤023均可以由处理器200实现。也即是说,处理器200还可用于控制结构光摄像头22接收出射时经显示区11衍射并被目标物体反射后直接入射的结构光以得到散斑图像、滤除散斑图像中的第二测量斑点以得到第一测量斑点、以及根据第一测量斑点及参考图像 中的参考斑点获取深度图像。Please refer to FIG. 1 again. Step 011, step 022, and step 023 may all be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to receive the structured light diffracted by the display area 11 and reflected directly by the target object when it is emitted to obtain a speckle image and filter out the second of the speckle images The speckle is measured to obtain a first measurement spot, and a depth image is obtained according to the first measurement spot and the reference spot in the reference image.
具体地,结构光投射器21和结构光摄像头22一起设置在显示屏10的背面13所在一侧,且显示屏10开设有与结构光摄像头22的入光面对准的通槽14时,结构光摄像头22拍摄到的是包含第一测量斑点和第二测量斑点的散斑图像。在后续深度图像的计算中,处理器200可以滤除散斑图像中的第二测量斑点,仅基于剩下的第一测量斑点来与参考图像中的参考斑点做深度图像的计算。此时,参考图像中的参考斑点应该仅包括多个激光仅被衍射光学元件213衍射并被标定物体反射形成的第一参考斑点。因此,通过滤除散斑图像中的第二测量斑点的方式可以消除显示屏10对结构光的影响,从而在保证电子装置1000的屏占比较高的情况下,电子装置1000获取的深度图像的精度也较高。Specifically, when the structured light projector 21 and the structured light camera 22 are provided together on the side of the back surface 13 of the display screen 10, and the display screen 10 is provided with a through slot 14 aligned with the light incident surface of the structured light camera 22, the structure The optical camera 22 captures a speckle image containing the first measurement spot and the second measurement spot. In the calculation of the subsequent depth image, the processor 200 may filter out the second measurement spots in the speckle image, and only calculate the depth image based on the remaining first measurement spots with the reference spots in the reference image. At this time, the reference spot in the reference image should include only the first reference spot formed by a plurality of laser beams diffracted only by the diffractive optical element 213 and reflected by the calibration object. Therefore, by filtering out the second measurement speckle in the speckle image, the influence of the display screen 10 on the structured light can be eliminated, so that the depth image acquired by the electronic device 1000 can be ensured when the screen footprint of the electronic device 1000 is relatively high. The accuracy is also higher.
也即是说,请参阅图24,图像获取方法还包括:That is to say, please refer to Figure 24, the image acquisition method also includes:
032:在标定参考图像时,控制结构光摄像头22接收从结构光投射器21出射后直接被标定物体反射并直接入射的结构光以得到第一参考图像,第一参考图像中包括多个参考斑点,多个参考斑点包括多个激光仅被衍射光学元件213衍射并被标定物体反射形成的第一参考斑点;032: When calibrating the reference image, the structured light camera 22 is controlled to receive the structured light directly reflected by the calibrated object after being emitted from the structured light projector 21 and directly incident to obtain a first reference image, and the first reference image includes multiple reference spots The multiple reference spots include a first reference spot formed by multiple laser beams diffracted by the diffractive optical element 213 only and reflected by the calibration object;
步骤023包括:Step 023 includes:
0231:计算第一测量斑点相对于第一参考斑点的偏移量;及0231: Calculate the offset of the first measurement spot relative to the first reference spot; and
0232:根据偏移量计算深度数据以得到深度图像。0232: Calculate depth data according to the offset to obtain a depth image.
请再参阅图17,步骤032可以由控制模块401实现。步骤0231和步骤0232均可以由计算模块402实现。Please refer to FIG. 17 again. Step 032 may be implemented by the control module 401. Both Step 0231 and Step 0232 can be implemented by the calculation module 402.
请再参阅图1,步骤032、步骤0231和步骤0232均可以由处理器200实现。也即是说,处理器200还可用于在标定参考图像时控制结构光摄像头22接收从结构光投射器21出射后直接被标定物体反射并直接入射的结构光以得到第一参考图像、计算第一测量斑点相对于第一参考斑点的偏移量、根据偏移量计算深度数据以得到深度图像。Please refer to FIG. 1 again. Step 032, step 0231, and step 0232 may all be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to receive the structured light directly reflected by the calibrated object after being emitted from the structured light projector 21 and directly incident when the reference image is calibrated to obtain the first reference image and calculate the first A measurement spot is offset from the first reference spot, and depth data is calculated according to the offset to obtain a depth image.
具体地,处理器200滤除第二测量斑点后,散斑图像中仅剩余第一测量斑点,则此时散斑图像应该与仅包含对应第一测量斑点的第一参考斑点的第一参考图像来进行深度图像的计算。其中,第一参考图像的标定过程与前述步骤032中将结构光投射器21放在没有显示屏10遮挡的场景下进行标定的标定过程一致,在此不再赘述。结构光拍摄的第一参考图像中的多个参考斑点是激光仅被衍射光学元件213衍射并被标定物体反射形成的第一参考斑点。如此,处理器200即可计算出第一测量斑点相对于第一参考斑点的偏移量,再基于多个偏移量计算出多个深度数据,从而得到深度图像。Specifically, after the processor 200 filters out the second measurement spots, only the first measurement spots remain in the speckle image, then the speckle image should be the first reference image containing only the first reference spots corresponding to the first measurement spots To calculate the depth image. The calibration process of the first reference image is the same as the calibration process of placing the structured light projector 21 in a scene that is not covered by the display screen 10 in step 032, and will not be repeated here. The multiple reference spots in the first reference image captured by structured light are the first reference spots formed by laser light diffracted only by the diffractive optical element 213 and reflected by the calibration object. In this way, the processor 200 can calculate the offset of the first measurement spot relative to the first reference spot, and then calculate multiple depth data based on the multiple offsets to obtain a depth image.
处理器200可以通过亮度来滤除第二测量斑点。也即是说,请参阅图25,在某些实施方式中,图像获取方法还包括:The processor 200 may filter out the second measurement spot by brightness. That is to say, referring to FIG. 25, in some embodiments, the image acquisition method further includes:
032:在标定参考图像时,控制结构光摄像头22接收从结构光投射器21出射后直接被标定物体反射并直接入射的结构光以得到第一参考图像,第一参考图像中包括多个所述参考斑点,多个参考斑点包括多个激光仅被衍射光学元件213衍射并被标定物体反射形成的第一参考斑点;032: When calibrating the reference image, the structured light camera 22 is controlled to receive the structured light directly reflected by the calibrated object and directly incident after exiting from the structured light projector 21 to obtain a first reference image, and the first reference image includes multiple Reference spots, the multiple reference spots include a first reference spot formed by a plurality of laser beams diffracted only by the diffractive optical element 213 and reflected by the calibration object;
033:在标定参考图像时,控制结构光摄像头22接收出射时经显示区11衍射并被标定物体反射后直接入射的结构光以得到第二参考图像,第二参考图像中包括多个参考斑点,多个参考斑点包括激光仅被衍射光学元件213衍射并被标定物体反射后形成的第一参考斑点和激光经过衍射光学元件213一次衍射再由显示屏10二次衍射并被标定物体反射形成的第二参考斑点;033: When calibrating the reference image, the structured light camera 22 is controlled to receive the structured light diffracted by the display area 11 and reflected directly by the calibrated object when being emitted to obtain a second reference image, which includes a plurality of reference spots, The multiple reference spots include a first reference spot formed by laser light diffracted by the diffractive optical element 213 and reflected by the calibration object and a laser beam diffracted once by the diffractive optical element 213 and then diffracted by the display screen 10 twice and reflected by the calibration object Two reference spots;
041:比对第一参考图像与第二参考图像以获取第二参考斑点;及041: Compare the first reference image with the second reference image to obtain a second reference spot; and
051:计算多个第二参考斑点的亮度的平均值与多个第一参考斑点的亮度的平均值之间的比值作为预设比值,及计算多个第一参考斑点的亮度的平均值并作为预设亮度;051: Calculate the ratio between the average value of the brightness of the plurality of second reference spots and the average value of the brightness of the plurality of first reference spots as the preset ratio, and calculate the average value of the brightness of the plurality of first reference spots as Preset brightness
步骤022包括:Step 022 includes:
0221:计算每个测量斑点与预设亮度之间的实际比值;0221: Calculate the actual ratio between each measured spot and the preset brightness;
0222:将实际比值大于预设比值的测量斑点归类为第一测量斑点,及将实际比值小于预设比值的测量斑点归类为第二测量斑点;及0222: classify the measurement spot whose actual ratio is greater than the preset ratio as the first measurement spot, and classify the measurement spot whose actual ratio is less than the preset ratio as the second measurement spot; and
0223:从所有测量斑点中滤除第二测量斑点以得到第一测量斑点。0223: Filter out the second measurement spot from all the measurement spots to obtain the first measurement spot.
请再参阅图17,步骤032和步骤033均可以由控制模块401实现。步骤041、步骤051、步骤0221、步骤0222和步骤0223均可以由计算模块401实现。Please refer to FIG. 17 again. Step 032 and step 033 can be implemented by the control module 401. Step 041, step 051, step 0221, step 0222, and step 0223 can all be implemented by the calculation module 401.
请再参阅图1,步骤032、步骤033、步骤041、步骤051、步骤0221、步骤0222和步骤0223均可 以由处理器200实现。也即是说,处理器200还可用于在标定参考图像时控制结构光摄像头22接收从结构光投射器21出射后直接被标定物体反射并直接入射的结构光以得到第一参考图像、以及在标定参考图像时控制结构光摄像头22接收出射时经显示区11衍射并被标定物体反射后直接入射的结构光以得到第二参考图像。处理器200还可用于比对第一参考图像与第二参考图像以获取第二参考斑点、计算多个第二参考斑点的亮度的平均值与多个第一参考斑点的亮度的平均值之间的比值作为预设比值、及计算多个第一参考斑点的亮度的平均值并作为预设亮度。处理器200还可用于计算每个测量斑点与预设亮度之间的实际比值、将实际比值大于预设比值的测量斑点归类为第一测量斑点、及将实际比值小于预设比值的测量斑点归类为第二测量斑点、以及从所有测量斑点中滤除第二测量斑点以得到第一测量斑点。Please refer to FIG. 1 again. Step 032, step 033, step 041, step 051, step 0221, step 0222 and step 0223 can all be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to receive the structured light directly reflected by the calibrated object after being emitted from the structured light projector 21 and directly incident when the reference image is calibrated to obtain the first reference image, and When the reference image is calibrated, the structured light camera 22 is controlled to receive the structured light directly diffracted by the display area 11 and reflected by the calibration object when it is emitted to obtain a second reference image. The processor 200 may also be used to compare the first reference image and the second reference image to obtain the second reference spot, and calculate the average value of the brightness of the plurality of second reference spots and the average value of the brightness of the plurality of first reference spots The ratio is used as the preset ratio, and the average value of the brightness of the plurality of first reference spots is calculated and used as the preset brightness. The processor 200 can also be used to calculate the actual ratio between each measurement spot and the preset brightness, classify the measurement spots whose actual ratio is greater than the preset ratio as the first measurement spots, and classify the measurement spots whose actual ratio is less than the preset ratio It is classified as a second measurement spot, and the second measurement spot is filtered out from all the measurement spots to obtain the first measurement spot.
其中,步骤032所述的标定第一参考图像的过程与前述步骤032中将结构光投射器21放在没有显示屏10遮挡的场景下进行标定的标定过程一致,步骤033所述的标定第二参考图像的过程与前述步骤031中将结构光投射器21和结构光摄像头22均放在显示屏10的背面13所在一侧,且结构光摄像头22入光面对准显示屏10的通槽14的场景下进行标定的标定过程一致,在此不再赘述。Among them, the process of calibrating the first reference image described in step 032 is the same as the calibration process of calibrating the structured light projector 21 in the scene that is not blocked by the display screen 10 in step 032, and the second calibration described in step 033 The process of the reference image and the aforementioned step 031 place the structured light projector 21 and the structured light camera 22 on the side of the back side 13 of the display screen 10, and the light incident surface of the structured light camera 22 is aligned with the through slot 14 of the display screen 10 The calibration process for calibration in the same scenario is the same and will not be repeated here.
在得到第一参考图像和第二参考图像后,处理器200即可采用与前述步骤041相同的方式,即根据第一参考图像中第一参考斑点的坐标来确定出第二参考图像中第一参考斑点,剩余的参考斑点即为第二参考斑点,从而区分出第一参考斑点和第二参考斑点。随后,处理器200即可采用与前述步骤051相同的方式来基于区分出的第一参考斑点和第二参考斑点标定计算预设亮度和预设比值。After obtaining the first reference image and the second reference image, the processor 200 may use the same method as the foregoing step 041, that is, determine the first in the second reference image according to the coordinates of the first reference spot in the first reference image The reference spot, and the remaining reference spot is the second reference spot, thereby distinguishing the first reference spot and the second reference spot. Subsequently, the processor 200 can calculate the preset brightness and the preset ratio based on the distinguished first reference spot and second reference spot calibration in the same manner as the foregoing step 051.
同样地,在后续深度图像的计算中,处理器200可采用与前述步骤061和前述步骤071相同的方式,即基于标定好的预设比值和预设亮度来区分出第一测量斑点和第二测量斑点,随后滤除第二测量斑点,仅留下第一测量斑点,再计算第一测量斑点相对于第一参考斑点的偏移量,最后基于偏移量计算出深度数据,从而得到深度图像。Similarly, in the calculation of the subsequent depth image, the processor 200 may adopt the same manner as the aforementioned step 061 and the aforementioned step 071, that is, distinguish the first measurement spot from the second based on the calibrated preset ratio and preset brightness Measure the spots, then filter out the second measurement spots, leaving only the first measurement spots, then calculate the offset of the first measurement spots relative to the first reference spots, and finally calculate the depth data based on the offsets, thereby obtaining the depth image .
在某些实施方式中,预设亮度和预设比值同样由场景的环境亮度以及结构光投射器21的发光功率决定。如此,可以提高第二测量斑点的滤除的准确性。In some embodiments, the preset brightness and the preset ratio are also determined by the ambient brightness of the scene and the luminous power of the structured light projector 21. In this way, the accuracy of filtering out the second measurement spot can be improved.
在某些实施方式中,衍射光学元件213除了用于衍射结构光投射器21的光源211发射的激光以增加测量斑点或参考斑点的数量之外,还可以用于补偿显示屏10衍射的结构光的亮度均匀性,使得投射到场景中的散斑图案中的多个斑点的亮度的均匀性较好,有利于提升深度图像的获取精度。In some embodiments, the diffractive optical element 213 can be used to compensate the structured light diffracted by the display screen 10 in addition to diffracting the laser light emitted by the light source 211 of the structured light projector 21 to increase the number of measurement spots or reference spots. The uniformity of the brightness makes the uniformity of the brightness of the multiple spots in the speckle pattern projected into the scene better, which is beneficial to improve the accuracy of acquiring the depth image.
综上,本申请实施方式的图像获取方法在结构光投射器21和结构光均位于显示屏10下,且结构光摄像头22接收穿过通槽14的被调制后的结构光时,先滤除第二测量斑点,仅根据剩余的第一测量斑点来计算深度图像,减少了处理器200的数据处理量,有利于加快深度图像的获取进程。In summary, in the image acquisition method of the embodiment of the present application, when both the structured light projector 21 and the structured light are located under the display screen 10, and the structured light camera 22 receives the modulated structured light passing through the through slot 14, it is filtered first The second measurement spot calculates the depth image based only on the remaining first measurement spot, which reduces the amount of data processing by the processor 200 and helps speed up the process of acquiring the depth image.
请参阅图1、图3及图26,在某些实施方式中,结构光投射器21和结构光摄像头22均设置在显示屏10的背面13所在的一侧,显示屏10未开设通槽14,结构光摄像头22接收的是穿过显示区11两次的被调制后的结构光。此时,步骤01包括:Please refer to FIG. 1, FIG. 3 and FIG. 26. In some embodiments, the structured light projector 21 and the structured light camera 22 are both disposed on the side of the back surface 13 of the display screen 10, and the display screen 10 has no through slot 14 The structured light camera 22 receives modulated structured light that passes through the display area 11 twice. At this time, step 01 includes:
012:控制结构光摄像头22接收出射时经显示区11衍射并被目标物体反射后入射时再经显示区11衍射的结构光以得到散斑图像,散斑图像中包括多个测量斑点,多个测量斑点包括激光仅被衍射光学元件213(图4所示)一次衍射并被目标物体反射形成的第一测量斑点、激光经过衍射光学元件213一次衍射再由显示屏10二次衍射并被目标物体反射形成的第二测量斑点、及激光经过衍射光学元件213一次衍射再由显示屏10二次衍射并被目标物体反射后又一次由显示屏10三次衍射形成的第三测量斑点;具体地,第一测量斑点是激光经过衍射光学元件213衍射后在经过显示屏10时并没有被显示屏10衍射,即没有遇到微观间隙而直接投射到目标物体,并被目标物体调制反射后形成的;第二测量斑点是激光经过衍射光学元件213衍射后经过显示屏10时又被显示屏10衍射,即遇到微观间隙后投射到目标物体,被目标物体调制反射后再次经过显示屏10时未被显示屏10衍射形成的;第三测量斑点是激光经过衍射光学元件213衍射后经过显示屏10又被显示屏10衍射,即遇到微观间隙后投射到目标物体,被目标物体调制反射后再次经过显示屏10又一次被显示屏10中的微观间隙衍射后形成的;012: Control the structured light camera 22 to receive the structured light diffracted by the display area 11 and reflected by the target object when it is emitted and then diffracted by the display area 11 to obtain a speckle image. The speckle image includes multiple measurement spots, multiple The measurement spot includes a laser beam that is diffracted only once by the diffractive optical element 213 (shown in FIG. 4) and reflected by the target object. The laser beam passes through the diffractive optical element 213 and is diffracted once by the display screen 10 and diffracted again by the target object The second measurement spot formed by reflection and the third measurement spot formed by the laser beam diffracted once by the diffractive optical element 213 and then diffracted again by the display screen 10 and reflected by the target object and then diffracted by the display screen 10 three times; specifically, the A measurement spot is formed after the laser beam is diffracted by the diffractive optical element 213 and is not diffracted by the display screen 10 when passing through the display screen 10, that is, it is directly projected onto the target object without encountering a micro gap, and is modulated and reflected by the target object; The second measurement spot is that the laser beam is diffracted by the display screen 10 after being diffracted by the diffractive optical element 213, and then diffracted by the display screen 10 After being projected onto the target object, it is not diffracted by the display screen 10 when it is modulated and reflected by the target object and passes through the display screen 10 again; the third measurement spot is that the laser light is diffracted by the diffractive optical element 213 after passing through the display screen 10 and then diffracted by the display screen 10 , That is, it is projected onto the target object after encountering the micro gap, and is modulated and reflected by the target object again after passing through the display screen 10 and diffracted by the micro gap in the display screen 10 again;
步骤02包括: Step 02 includes:
024:根据散斑图像中的第一测量斑点、第二测量斑点、及第三测量斑点与参考图像中的参考斑点计算深度图像。024: Calculate the depth image based on the first measurement spot, the second measurement spot, and the third measurement spot in the speckle image and the reference spot in the reference image.
请再参阅图17,步骤012可以由控制模块401实现。步骤024可以由计算模块402实现。Please refer to FIG. 17 again. Step 012 may be implemented by the control module 401. Step 024 can be implemented by the calculation module 402.
请再参阅图1,步骤012和步骤024均可以由处理器200实现。也即是说,处理器200还可用于控 制结构光摄像头22接收出射时经显示区11衍射并被目标物体反射后入射时再经显示区11衍射的结构光以得到散斑图像。处理器200还可用于根据散斑图像中的第一测量斑点、第二测量斑点、及第三测量斑点与参考图像中的参考斑点计算深度图像。Please refer to FIG. 1 again. Both step 012 and step 024 may be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to receive the structured light diffracted by the display area 11 when it is emitted and reflected by the target object and then diffracted by the display area 11 after being incident to obtain a speckle image. The processor 200 may also be used to calculate a depth image based on the first measurement spot, the second measurement spot, and the third measurement spot in the speckle image and the reference spot in the reference image.
具体地,请结合图4,结构光投射器21的光源211发射激光经过衍射光学元件213衍射后形成结构光投射到场景中以形成散斑图案。散斑图案中包括多个斑点,这些斑点是激光仅经过衍射光学元件213的衍射形成的。Specifically, referring to FIG. 4, the light source 211 of the structured light projector 21 emits laser light to be diffracted by the diffractive optical element 213 to form structured light and project it into the scene to form a speckle pattern. The speckle pattern includes a plurality of spots, which are formed by the diffraction of laser light only through the diffractive optical element 213.
结构光摄像头22成像时,结构光摄像头22会接收由场景中的目标物体反射回的结构光以形成散斑图像。在本申请实施方式中,由于显示屏10未开设通槽14,经衍射光学元件213一次衍射又经显示屏10二次衍射,并被目标物体调制后反射回的激光经过显示屏10时会再次被显示屏10中的显示区11衍射,结构光摄像头22接收的是出射后经过显示区11时被显示区11衍射,在被目标物体反射后再次经过显示区11时又被显示区11衍射的结构光,形成的散斑图像中的多个测量斑点同时包括激光仅被衍射光学元件213衍射并被目标物体反射形成的第一测量斑点、激光经过衍射光学元件213一次衍射再由显示屏10二次衍射并被目标物体反射形成的第二测量斑点、以及激光经过衍射光学元件213一次衍射再由显示屏10二次衍射并被目标物体反射后又一次由显示屏10三次衍射形成的第三测量斑点。When the structured light camera 22 is imaging, the structured light camera 22 receives the structured light reflected by the target object in the scene to form a speckle image. In the embodiment of the present application, since the display screen 10 does not have a through slot 14, the first diffraction by the diffractive optical element 213 and the second diffraction by the display screen 10, and the laser light reflected back after being modulated by the target object will pass through the display screen 10 again Diffracted by the display area 11 in the display screen 10, the structured light camera 22 receives the diffraction by the display area 11 when passing through the display area 11 after being emitted, and is diffracted by the display area 11 again after passing through the display area 11 after being reflected by the target object Structured light, the multiple measurement spots in the formed speckle image also include the first measurement spot formed by laser light diffracted only by the diffractive optical element 213 and reflected by the target object. The second measurement spot formed by the second diffraction and reflected by the target object, and the third measurement formed by the laser once diffracted by the diffractive optical element 213 and then diffracted again by the display screen 10 and reflected by the target object by the third diffraction of the display screen 10 spot.
结构光摄像头22拍摄得到散斑图像后,处理器200可以直接根据散斑图像中的第一测量斑点、第二测量斑点及第三测量斑点与参考图像计算深度图像。此时,参考图像中的多个参考斑点需包括第一参考斑点、第二参考斑点和第三参考斑点。其中,深度图像的计算方式可以包括下述的两种。After the structured light camera 22 captures the speckle image, the processor 200 can directly calculate the depth image from the first measurement spot, the second measurement spot, the third measurement spot, and the reference image in the speckle image. At this time, the multiple reference spots in the reference image need to include a first reference spot, a second reference spot, and a third reference spot. The calculation method of the depth image may include the following two.
请参阅图27,在一个计算方式中,步骤024包括:Referring to FIG. 27, in a calculation method, step 024 includes:
0241:计算所有测量斑点相对于所有参考斑点的偏移量;及0241: Calculate the offset of all measurement spots relative to all reference spots; and
0242:根据偏移量计算深度数据以得到深度图像。0242: Calculate depth data according to the offset to obtain a depth image.
对应地,图像获取方法还包括:Correspondingly, the image acquisition method also includes:
034:在标定参考图像时,控制结构光摄像头22接收出射时经显示区11衍射并被标定物体反射后入射时再经显示区22衍射的结构光以得到参考图像,参考图像中包括多个参考斑点。034: When the reference image is calibrated, the structured light camera 22 is controlled to receive the structured light diffracted by the display area 11 when it is emitted and diffracted by the display area 22 after being reflected by the calibrated object to obtain the reference image. spot.
请再参阅图17,步骤0241和步骤0242均可以由计算模块402实现。步骤034可以由控制模块401实现。Please refer to FIG. 17 again. Step 0241 and step 0242 can be implemented by the calculation module 402. Step 034 can be implemented by the control module 401.
请再参阅图1,步骤0241、步骤0242和步骤034均可以由处理器200实现。也即是说,处理器200还可用于计算所有测量斑点相对于所有参考斑点的偏移量、以及根据偏移量计算深度数据以得到深度图像。处理器200还可用于在标定参考图像时,控制结构光摄像头22接收出射时经显示区11衍射并被标定物体反射后入射时再经显示区22衍射的结构光以得到参考图像,参考图像中包括多个参考斑点。Please refer to FIG. 1 again. Step 0241, step 0242, and step 034 may be implemented by the processor 200. That is to say, the processor 200 can also be used to calculate the offsets of all measurement spots relative to all reference spots, and calculate depth data according to the offsets to obtain depth images. The processor 200 can also be used to control the structured light camera 22 to receive the structured light diffracted by the display area 11 when diffracted by the display area 11 and reflected by the calibrated object and then diffracted by the display area 22 when it is incident to obtain the reference image. Includes multiple reference spots.
具体地,请结合图28,在标定参考图像的过程中,结构光投射器21与结构光摄像头22均设置在显示屏10的背面13所在一侧,且显示屏10未开设有通槽14。如此,在标定场景下和实际使用场景下,结构光投射器21与结构光摄像头22相对于显示屏10的设置位置是一致的。在标定场景下,处理器200控制结构光投射器21发射结构光,结构光穿过显示区11后投射到与结构光组件20相隔预定距离的标定板处,被标定板反射回的结构光再次穿过显示区11后被结构光摄像头22接收。此时,结构光摄像头22接收到的是由结构光投射器21发出后经显示屏10衍射,被标定板反射后,再经由显示屏10衍射后入射的结构光,形成的参考图像中包括多个参考斑点。其中,参考斑点同时包括与第一测量斑点对应的第一参考斑点、与第二测量斑点对应的第二参考斑点、与第三测量斑点对应的第三参考斑点。第一参考斑点是激光经过衍射光学元件213时被衍射光学元件213一次衍射,且在经过显示屏10未被显示屏10衍射,并被标定板反射后再次经过显示屏10时仍旧未被显示屏10衍射形成的。第二参考斑点是激光经过衍射光学元件213时被衍射光学元件213一次衍射,且在经过显示屏10被显示屏10二次衍射,并被标定板反射后再次经过显示屏10时未被显示屏10衍射形成的。第三参考斑点是激光经过衍射光学元件213时被衍射光学元件213一次衍射,且在经过显示屏10被显示屏10二次衍射,并被标定板反射后再次经过显示屏10时被显示屏10三次衍射形成的。Specifically, referring to FIG. 28, in the process of calibrating the reference image, the structured light projector 21 and the structured light camera 22 are both disposed on the side of the back surface 13 of the display screen 10, and the display screen 10 is not provided with a through slot 14. In this way, in the calibration scene and the actual use scene, the installation positions of the structured light projector 21 and the structured light camera 22 relative to the display screen 10 are the same. In the calibration scenario, the processor 200 controls the structured light projector 21 to emit structured light. The structured light passes through the display area 11 and is projected to the calibration plate at a predetermined distance from the structured light assembly 20. The structured light reflected back by the calibration plate again After passing through the display area 11, it is received by the structured light camera 22. At this time, the structured light camera 22 receives the structured light emitted by the structured light projector 21, diffracted by the display screen 10, reflected by the calibration plate, and then diffracted through the display screen 10. The formed reference image includes many Reference spots. Wherein, the reference spots simultaneously include a first reference spot corresponding to the first measurement spot, a second reference spot corresponding to the second measurement spot, and a third reference spot corresponding to the third measurement spot. The first reference spot is that the laser light is diffracted by the diffractive optical element 213 once when passing through the diffractive optical element 213, and is not diffracted by the display screen 10 after passing through the display screen 10, and is reflected by the calibration plate and still passes through the display screen 10 when it passes through the display screen 10 again. 10 formed by diffraction. The second reference spot is that the laser light is diffracted by the diffractive optical element 213 once when passing through the diffractive optical element 213, and is secondarily diffracted by the display screen 10 after passing through the display screen 10, and is reflected by the calibration plate, but not by the display screen after passing through the display screen 10 again 10 formed by diffraction. The third reference spot is that the laser light is first diffracted by the diffractive optical element 213 when passing through the diffractive optical element 213, and is secondarily diffracted by the display screen 10 after passing through the display screen 10, and reflected by the calibration plate, and then by the display screen 10 after passing through the display screen 10 again Formed by the third diffraction.
虽然散斑图像中同时包括第一测量斑点、第二测量斑点和第三测量斑点,参考图像中同时包括第一参考斑点、第二参考斑点和第三参考斑点。但是在此计算方式中,处理器200并不会对散斑图像中的第一测量斑点、第二测量斑点和第三测量斑点做区分,也不会对参考图像中的第一参考斑点、第二参考斑点和第三参考斑点做区分,而是直接基于所有的测量斑点和所有的参考斑点来进行深度图像的计算。具 体地,处理器200首先计算所有测量斑点相对于所有参考斑点的偏移量,再基于多个偏移量计算出多个深度数据,从而得到深度图像。Although the speckle image includes the first measurement spot, the second measurement spot, and the third measurement spot, the reference image includes the first reference spot, the second reference spot, and the third reference spot at the same time. However, in this calculation method, the processor 200 does not distinguish between the first measurement spot, the second measurement spot, and the third measurement spot in the speckle image, nor does it distinguish the first reference spot, the second measurement spot in the reference image. The second reference spot and the third reference spot are distinguished, but the depth image is calculated directly based on all the measurement spots and all the reference spots. Specifically, the processor 200 first calculates the offsets of all measurement spots relative to all reference spots, and then calculates multiple depth data based on the multiple offsets, thereby obtaining a depth image.
请参阅图29,在另一个计算方式中,步骤024包括:Referring to FIG. 29, in another calculation method, step 024 includes:
0243:计算第一测量斑点相对于第一参考斑点的偏移量、第二测量斑点相对于第二参考斑点的偏移量、以及第三测量斑点相对于第三参考斑点的偏移量;及0243: Calculate the offset of the first measurement spot relative to the first reference spot, the offset of the second measurement spot relative to the second reference spot, and the offset of the third measurement spot relative to the third reference spot; and
0244:根据偏移量计算深度数据以得到深度图像。0244: Calculate depth data according to the offset to obtain a depth image.
此时,图像获取方法还包括:At this time, the image acquisition method also includes:
035:在标定参考图像时,控制结构光摄像头22接收从结构光投射器21出射后直接被标定物体反射并直接入射的结构光以得到第一参考图像,第一参考图像中包括多个参考斑点,多个参考斑点包括多个激光仅被衍射光学元件213衍射并被标定物体反射形成的第一参考斑点;035: When calibrating the reference image, the structured light camera 22 is controlled to receive the structured light directly reflected by the calibrated object and directly incident after exiting from the structured light projector 21 to obtain a first reference image, and the first reference image includes multiple reference spots The multiple reference spots include a first reference spot formed by multiple laser beams diffracted by the diffractive optical element 213 only and reflected by the calibration object;
036:在标定参考图像时,控制结构光摄像头22接收出射时经显示区11衍射并被标定物体反射后直接入射的结构光以得到第二参考图像,第二参考图像中包括多个参考斑点,多个参考斑点包括激光仅被衍射光学元件213衍射并被标定物体反射形成的第一参考斑点和激光经过衍射光学元件213一次衍射再由显示屏10二次衍射并被标定物体反射形成的第二参考斑点;036: When the reference image is calibrated, the structured light camera 22 is controlled to receive the structured light that is diffracted by the display area 11 and reflected directly by the calibrated object when being emitted to obtain a second reference image, and the second reference image includes multiple reference spots, The multiple reference spots include a first reference spot formed by laser light diffracted only by the diffractive optical element 213 and reflected by the calibrated object, and a second reference spot formed by the laser light diffracted once by the diffractive optical element 213 and then diffracted by the display screen 10 twice and reflected by the calibrated object Reference spot
037:在标定参考图像时,控制结构光摄像头22接收出射时经显示区11衍射并被标定物体反射后在经过显示区11入射时又被显示区11衍射的结构光以得到第三参考图像,第三参考图像中包括多个参考斑点,多个参考斑点包括激光仅被衍射光学元件213衍射并被标定物体反射形成的第一参考斑点、激光经过衍射光学元件213一次衍射再由显示屏10二次衍射并被标定物体反射形成的第二参考斑点、及激光经过衍射光学元件213一次衍射再由显示屏10二次衍射并被标定物体反射后又一次由显示屏10三次衍射形成的第三参考斑点;037: When the reference image is calibrated, the structured light camera 22 is controlled to receive the structured light diffracted by the display area 11 and diffracted by the display area 11 when it is diffracted by the display area 11 and reflected by the calibration object to obtain the third reference image. The third reference image includes multiple reference spots. The multiple reference spots include a first reference spot formed by laser light diffracted only by the diffractive optical element 213 and reflected by the calibration object. The laser light is diffracted by the diffractive optical element 213 once and then diffracted by the display screen 10 The second reference spot diffracted and reflected by the calibration object, and the laser beam is diffracted once by the diffractive optical element 213 and then diffracted again by the display panel 10 and reflected by the calibration object. spot;
042:比对第一参考图像与第二参考图像以获取第二参考斑点,及比对第三参考图像与第二参考图像以获取第三参考斑点;042: Compare the first reference image with the second reference image to obtain the second reference spot, and compare the third reference image with the second reference image to obtain the third reference spot;
052:计算多个第二参考斑点的亮度的平均值与多个第一参考斑点的亮度的平均值之间的比值作为第一预设比值,计算多个第三参考斑点的亮度的平均值与多个第一参考斑点的亮度的平均值之间的比值作为第二预设比值,及计算多个第一参考斑点的亮度的平均值并作为预设亮度;052: Calculate the ratio between the average value of the brightness of the multiple second reference spots and the average value of the brightness of the multiple first reference spots as the first preset ratio, and calculate the average value of the brightness of the multiple third reference spots and The ratio between the average values of the brightness of the plurality of first reference spots is used as the second preset ratio, and the average value of the brightness of the plurality of first reference spots is calculated and used as the preset brightness;
062:计算每个测量斑点与预设亮度之间的实际比值;和062: Calculate the actual ratio between each measured spot and the preset brightness; and
072:将实际比值大于第一预设比值的测量斑点归类为第一测量斑点,将实际比值小于第一预设比值且大于第二预设比值的测量斑点归类为第二测量斑点,将实际比值小于第二预设比值的测量斑点归类为第三测量斑点。072: Classify the measurement spot whose actual ratio is greater than the first preset ratio as the first measurement spot, classify the measurement spot whose actual ratio is less than the first preset ratio and greater than the second preset ratio as the second measurement spot, and classify The measurement spots whose actual ratio is less than the second preset ratio are classified as the third measurement spots.
请再参阅图17,步骤0243、步骤0244、步骤042、步骤052、步骤062和步骤072均可以由计算模块402实现。步骤035、步骤036和步骤037均可以由控制模块401实现。Please refer to FIG. 17 again. Step 0243, step 0244, step 042, step 052, step 062, and step 072 may all be implemented by the calculation module 402. Step 035, step 036, and step 037 can all be implemented by the control module 401.
请再参阅图1,步骤0243、步骤0244、步骤035、步骤036、步骤037、步骤042、步骤052、步骤062和步骤072均可以由处理器200实现。也即是说,处理器200还可用于在标定参考图像时控制结构光摄像头22接收从结构光投射器21出射后直接被标定物体反射并直接入射的结构光以得到第一参考图像、在标定参考图像时控制结构光摄像头22接收出射时经显示区11衍射并被标定物体反射后直接入射的结构光以得到第二参考图像、以及在标定参考图像时控制结构光摄像头22接收出射时经显示区11衍射并被标定物体反射后在经过显示区11入射时又被显示区11衍射的结构光以得到第三参考图像。处理器200还可用于比对第一参考图像与第二参考图像以获取第二参考斑点、及比对第三参考图像与第二参考图像以获取第三参考斑点、计算多个第二参考斑点的亮度的平均值与多个第一参考斑点的亮度的平均值之间的比值作为第一预设比值、计算多个第三参考斑点的亮度的平均值与多个第一参考斑点的亮度的平均值之间的比值作为第二预设比值、及计算多个第一参考斑点的亮度的平均值并作为预设亮度。处理器200还可用于计算每个测量斑点与预设亮度之间的实际比值、将实际比值大于第一预设比值的测量斑点归类为第一测量斑点、将实际比值小于第一预设比值且大于第二预设比值的测量斑点归类为第二测量斑点、以及将实际比值小于第二预设比值的测量斑点归类为第三测量斑点。Please refer to FIG. 1 again. Step 0243, step 0244, step 035, step 036, step 037, step 042, step 052, step 062, and step 072 may all be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to receive the structured light that is directly reflected by the calibrated object and directly incident after being emitted from the structured light projector 21 when the reference image is calibrated to obtain the first reference image. When the reference image is referenced, the structured light camera 22 is controlled to receive the structured light that is diffracted by the display area 11 and reflected directly by the calibrated object when being emitted to obtain a second reference image, and when the reference image is calibrated, the structured light camera 22 is controlled to receive and display the emitted light After the area 11 is diffracted and reflected by the calibration object, the structured light is diffracted by the display area 11 again when incident through the display area 11 to obtain a third reference image. The processor 200 may also be used to compare the first reference image and the second reference image to obtain a second reference spot, and to compare the third reference image and the second reference image to obtain a third reference spot, and calculate a plurality of second reference spots The ratio between the average value of the brightness of the plurality of first reference spots and the average value of the brightness of the plurality of first reference spots as the first preset ratio, calculating the average value of the brightness of the plurality of third reference spots and the brightness of the plurality of first reference spots The ratio between the average values is used as the second preset ratio, and the average value of the brightness of the plurality of first reference spots is calculated and used as the preset brightness. The processor 200 can also be used to calculate the actual ratio between each measured spot and the preset brightness, classify the measured spots whose actual ratio is greater than the first preset ratio as the first measured spot, and classify the actual ratio as being smaller than the first preset ratio The measurement spots larger than the second preset ratio are classified as second measurement spots, and the measurement spots whose actual ratio is smaller than the second preset ratio are classified as third measurement spots.
此种计算方式下,处理器200需要标定出第一参考图像、第二参考图像和第三参考图像。In this calculation mode, the processor 200 needs to calibrate the first reference image, the second reference image, and the third reference image.
具体地,处理器200首先控制结构光投射器21在没有显示屏10遮挡的场景下发射结构光至标定板处,再控制结构光摄像头22接收由标定板反射后直接入射的结构光以得到第一参考图像。其中,第一 参考图像中包括的多个参考斑点为第一参考斑点,第一参考斑点是激光在经过衍射光学元件213时被衍射光学元件213衍射,且直接出射到标定板后被标定板调制反射后直接入射形成的。Specifically, the processor 200 first controls the structured light projector 21 to emit structured light to the calibration plate in a scene without the screen 10 blocking, and then controls the structured light camera 22 to receive the structured light directly reflected by the calibration plate to obtain the first One reference image. Among them, the multiple reference spots included in the first reference image are the first reference spots. The first reference spots are laser beams diffracted by the diffractive optical element 213 when passing through the diffractive optical element 213, and are directly emitted to the calibration plate and modulated by the calibration plate It is formed by direct incidence after reflection.
随后,在结构光投射器21与结构光摄像头22均设置在显示屏10的背面13所在一侧,且显示屏10开设有与结构光摄像头22的入光面对准的通槽14,结构光摄像头22可以接收穿过通槽14的被调制后的结构光的场景下,处理器200控制结构光投射器21发射结构光,结构光穿过显示区11后投射到与结构光组件20相隔预定距离的标定板处,被标定板反射回的结构光穿过通槽14被结构光摄像头22接收从而得到第二参考图像。其中,第二参考图像中的多个参考斑点同时包括第一参考斑点和第二参考斑点。第一参考斑点是激光在经过衍射光学元件213时被衍射光学元件213衍射,且在经过显示屏10未被显示屏10衍射,并被标定板调制反射后形成的;第二参考斑点是激光经过衍射光学元件213时被衍射光学元件213一次衍射,且在经过显示屏10时又被显示屏10二次衍射,并被标定板调制反射后形成的。Subsequently, both the structured light projector 21 and the structured light camera 22 are provided on the side of the back surface 13 of the display screen 10, and the display screen 10 is provided with a through slot 14 aligned with the light incident surface of the structured light camera 22, structured light When the camera 22 can receive the modulated structured light passing through the through slot 14, the processor 200 controls the structured light projector 21 to emit structured light. The structured light passes through the display area 11 and is projected to a predetermined distance from the structured light assembly 20 At the distance of the calibration plate, the structured light reflected by the calibration plate passes through the through slot 14 and is received by the structured light camera 22 to obtain a second reference image. Wherein, the multiple reference spots in the second reference image include both the first reference spot and the second reference spot. The first reference spot is formed when the laser light is diffracted by the diffractive optical element 213 when passing through the diffractive optical element 213, and is not diffracted by the display screen 10 after passing through the display screen 10, and is modulated and reflected by the calibration plate; the second reference spot is formed by the laser light The diffractive optical element 213 is diffracted once by the diffractive optical element 213, and when passing through the display screen 10, it is diffracted again by the display screen 10, and is modulated and reflected by the calibration plate.
随后,处理器200按照第一种计算方式,即步骤034中所述的参考图像的标定方式标定出第三参考图像。此时第三参考图像中同时包括与第一测量斑点对应的第一参考斑点、与第二测量斑点对应的第二参考斑点、以及与第三测量斑点对应的第三参考斑点。Subsequently, the processor 200 calibrates the third reference image according to the first calculation method, that is, the reference image calibration method described in step 034. At this time, the third reference image includes a first reference spot corresponding to the first measurement spot, a second reference spot corresponding to the second measurement spot, and a third reference spot corresponding to the third measurement spot.
其中,在第一参考图像、第二参考图像和第三参考图像的标定场景中,标定板与结构光投射器21及结构光摄像头22之间的相对位置是保持不变的,结构光投射器21与结构光摄像头21之间的相对位置也保持不变。Among them, in the calibration scene of the first reference image, the second reference image, and the third reference image, the relative position between the calibration plate, the structured light projector 21 and the structured light camera 22 remains unchanged, and the structured light projector The relative position between 21 and structured light camera 21 also remains unchanged.
随后,处理器200首先标记出第一参考图像中的第一参考斑点的第一坐标,再根据第一参考斑点的坐标在第二参考图像中筛选出第一参考斑点,第二参考图像中剩余的参考斑点即为第二参考斑点。处理器200标记出第二参考斑点在第二参考图像中的第二坐标。处理器200再根据第二参考图像中的第一坐标和第二坐标在第三参考图像中分别筛选出第一参考斑点和第二参考斑点,第三参考图像中剩余的参考斑点即为第三参考斑点。如此,处理器200即可在第三参考图像的所有参考斑点中区分出第一参考斑点、第二参考斑点和第三参考斑点。Subsequently, the processor 200 first marks the first coordinates of the first reference spot in the first reference image, and then filters out the first reference spots in the second reference image according to the coordinates of the first reference spot, and the remaining in the second reference image The reference spot is the second reference spot. The processor 200 marks the second coordinates of the second reference spot in the second reference image. The processor 200 then filters out the first reference spot and the second reference spot in the third reference image according to the first coordinate and the second coordinate in the second reference image, and the remaining reference spot in the third reference image is the third Reference spots. In this way, the processor 200 can distinguish the first reference spot, the second reference spot, and the third reference spot among all reference spots of the third reference image.
由于后续计算深度数据时,散斑图像中的测量斑点也需要进行区分。具体地,可以通过亮度来区分出第一测量斑点、第二测量斑点和第三测量斑点。可以理解,第一测量斑点是激光仅经过衍射光学元件213的一次衍射形成的,第二测量斑点是激光经过衍射光学元件213的一次衍射和显示屏10的二次衍射形成的,第三测量斑点是经过衍射光学元件213一次衍射和显示屏10的二次及三次衍射形成的,形成第二测量斑点的激光被衍射的次数多于形成第一测量斑点的激光被衍射的次数,形成第三测量斑点的激光被衍射的次数多于形成第二测量斑点的激光被衍射的次数,因此,形成第一测量斑点的激光的能量损耗最小,形成第三测量斑点的激光的能量损耗最大。第二测量斑点的亮度会低于第一测量斑点的亮度,第三测量斑点的亮度会低于第二测量斑点的亮度。如此,基于亮度来区分出第一测量斑点、第二测量斑点和点测量斑点是可行的。那么,在参考图像标定完毕后还需要进一步标定出用于区分第一测量斑点、第二测量斑点和第三测量斑点的预设亮度和预设比值。具体地,在处理器200区分出第一参考斑点、第二参考斑点和第三参考斑点后,处理器200计算出第三参考图像中的多个第一参考斑点的亮度的平均值,并计算出第三参考图像中多个第二参考斑点的亮度的平均值以及第三参考图像中多个第三参考斑点的亮度的平均值。随后,处理器200将多个第一参考斑点的亮度的平均值作为预设亮度,将多个第二参考斑点的亮度的平均值与多个第一参考斑点的亮度的平均值之间的比值作为第一预设比值,将多个第三参考斑点的亮度的平均值与多个第一参考斑点的亮度的平均值之间的比值作为第二预设比值。As the depth data is calculated later, the measurement spots in the speckle image also need to be distinguished. Specifically, the first measurement spot, the second measurement spot, and the third measurement spot can be distinguished by brightness. It can be understood that the first measurement spot is formed by the first order diffraction of the laser light through the diffractive optical element 213, the second measurement spot is formed by the first order diffraction of the laser light through the diffractive optical element 213 and the second order diffraction of the display screen 10, and the third measurement spot It is formed by the first diffraction of the diffractive optical element 213 and the second and third diffraction of the display screen 10. The laser beam forming the second measurement spot is diffracted more times than the laser beam forming the first measurement spot is diffracted to form the third measurement The number of times the laser spot is diffracted is greater than the number of times the laser spot forming the second measurement spot is diffracted. Therefore, the energy loss of the laser spot forming the first measurement spot is the smallest, and the energy loss of the laser spot forming the third measurement spot is the largest. The brightness of the second measurement spot will be lower than the brightness of the first measurement spot, and the brightness of the third measurement spot will be lower than the brightness of the second measurement spot. As such, it is feasible to distinguish the first measurement spot, the second measurement spot, and the spot measurement spot based on the brightness. Then, after the reference image calibration is completed, it is necessary to further calibrate the preset brightness and the preset ratio for distinguishing the first measurement spot, the second measurement spot, and the third measurement spot. Specifically, after the processor 200 distinguishes the first reference spot, the second reference spot, and the third reference spot, the processor 200 calculates the average value of the brightness of the plurality of first reference spots in the third reference image, and calculates The average value of the brightness of the plurality of second reference spots in the third reference image and the average value of the brightness of the plurality of third reference spots in the third reference image are obtained. Subsequently, the processor 200 takes the average value of the brightness of the plurality of first reference spots as the preset brightness, and takes the ratio between the average value of the brightness of the plurality of second reference spots and the average value of the brightness of the plurality of first reference spots As the first preset ratio, a ratio between the average value of the brightness of the plurality of third reference spots and the average value of the brightness of the plurality of first reference spots is taken as the second preset ratio.
在后续的深度数据计算中,处理器200首先计算出每个测量斑点的亮度。随后,处理器200计算每个测量斑点与预设亮度之间的实际比值,并将实际比值大于或等于第一预设比值的测量斑点归类为第一测量斑点,将实际比值小于第一预设比值且大于或等于第二预设比值的测量斑点归类为第二测量斑点,将实际比值小于第二预设比值的测量斑点归类为第三测量斑点,从而区分出第一测量斑点、第二测量斑点和第三测量。例如,如图30所示,假设预设比值为0.8,实际使用中结构光摄像头22拍摄的散斑图像中包括测量斑点A、测量斑点B和测量斑点C。其中,测量斑点A的亮度与预设亮度之间的比值若小于0.8且大于或等于0.6,,则将测量斑点A归类到第二测量斑点,此时说明测量斑点A是激光经衍射光学元件213一次衍射再由显示屏10二次衍射并被目标物体反射形成的测量斑点;测量斑点B的亮度与预设亮度之间的比值若大于或等于0.8,则将测量斑点B归类到第一测量斑点中,此时说明测量斑点B是激光经衍射光学元件213一次衍射并被目标物体反射形成的测量斑点;测量斑点C的亮度与预设亮度 之间的比值若小于0.6,则将测量斑点C归类到第三测量斑点中,此时说明测量斑点C是激光经过衍射光学元件213一次衍射再由显示屏10二次衍射并被标定物体反射后又一次由显示屏10三次衍射形成的测量斑点。其中,预设比值0.8、0.6仅为示例。In the subsequent depth data calculation, the processor 200 first calculates the brightness of each measurement spot. Subsequently, the processor 200 calculates the actual ratio between each measurement spot and the preset brightness, and classifies the measurement spot whose actual ratio is greater than or equal to the first preset ratio as the first measurement spot, and classifies the actual ratio as being less than the first preset The measurement spots whose ratio is greater than or equal to the second preset ratio are classified as the second measurement spots, and the measurement spots whose actual ratio is less than the second preset ratio are classified as the third measurement spots, thereby distinguishing the first measurement spots, The second measurement spot and the third measurement. For example, as shown in FIG. 30, assuming that the preset ratio is 0.8, the speckle image captured by the structured light camera 22 in actual use includes measurement spot A, measurement spot B, and measurement spot C. Among them, if the ratio between the brightness of the measurement spot A and the preset brightness is less than 0.8 and greater than or equal to 0.6, then the measurement spot A is classified as the second measurement spot, which means that the measurement spot A is the laser light passing through the diffractive optical element 213 Measurement spot formed by first diffraction and second order diffraction by the display screen 10 and reflected by the target object; if the ratio between the brightness of the measurement spot B and the preset brightness is greater than or equal to 0.8, the measurement spot B is classified as the first In the measurement spot, it is stated that the measurement spot B is a measurement spot formed by laser light diffracted once by the diffractive optical element 213 and reflected by the target object; if the ratio between the brightness of the measurement spot C and the preset brightness is less than 0.6, the measurement spot will be measured C is classified into the third measurement spot. At this time, the measurement spot C is a measurement that the laser beam is diffracted once by the diffractive optical element 213 and then diffracted again by the display screen 10 and reflected by the calibration object. spot. Among them, the preset ratios 0.8 and 0.6 are only examples.
处理器200区分出第一测量斑点、第二测量斑点和第三测量斑点后,由于第三参考图像中的第一参考斑点、第二参考斑点和第三参考斑点也已经被区分出,则处理器200即可利用散斑图像和第三参考图像计算出深度数据。具体地,处理器200首先计算第一测量斑点相对于第一参考斑点的偏移量、第二测量斑点相对于第二参考斑点的偏移量、第三测量斑点相对于第三参考斑点的偏移量。随后,处理器200基于多个偏移量计算出多个深度数据,多个深度数据即可构成一幅深度图像。After the processor 200 distinguishes the first measurement spot, the second measurement spot, and the third measurement spot, since the first reference spot, the second reference spot, and the third reference spot in the third reference image have also been distinguished, then process The device 200 can use the speckle image and the third reference image to calculate the depth data. Specifically, the processor 200 first calculates the offset of the first measurement spot relative to the first reference spot, the offset of the second measurement spot relative to the second reference spot, and the offset of the third measurement spot relative to the third reference spot Displacement. Subsequently, the processor 200 calculates multiple depth data based on multiple offsets, and the multiple depth data can constitute a depth image.
与第一种计算方式相比,第二种计算方式对第一测量斑点、第二测量斑点和第三测量斑点进行区分,对第一参考斑点、第二参考斑点和第三参考斑点进行区分,可以基于更为准确的第一测量斑点与第一参考斑点的对应关系、第二测量斑点与第二参考斑点的对应关系、以及第三测量斑点与第三参考斑点的对应关系计算得到更为准确的偏移量,进一步得到较为准确的深度数据,提升获取的深度图像的精度。Compared with the first calculation method, the second calculation method distinguishes the first measurement spot, the second measurement spot, and the third measurement spot, and distinguishes the first reference spot, the second reference spot, and the third reference spot, It can be calculated based on the more accurate correspondence between the first measurement spot and the first reference spot, the correspondence between the second measurement spot and the second reference spot, and the correspondence between the third measurement spot and the third reference spot The offset of the data can further obtain more accurate depth data and improve the accuracy of the acquired depth image.
在某些实施方式中,预设亮度、第一预设比值和第二预设比值由场景的环境亮度以及结构光投射器21的发光功率决定。如此,可以提升第一测量斑点、第二测量斑点及第三测量斑点的区分的准确性。In some embodiments, the preset brightness, the first preset ratio and the second preset ratio are determined by the ambient brightness of the scene and the luminous power of the structured light projector 21. In this way, the accuracy of distinguishing the first measurement spot, the second measurement spot, and the third measurement spot can be improved.
在某些实施方式中,衍射光学元件213除了用于衍射结构光投射器21的光源211发射的激光以增加测量斑点或参考斑点的数量之外,还可以用于补偿显示屏10衍射的结构光的亮度均匀性,使得投射到场景中的散斑图案中的多个斑点的亮度的均匀性较好,有利图提升深度图像的获取精度。In some embodiments, the diffractive optical element 213 can be used to compensate the structured light diffracted by the display screen 10 in addition to diffracting the laser light emitted by the light source 211 of the structured light projector 21 to increase the number of measurement spots or reference spots. The uniformity of the brightness makes the uniformity of the brightness of the multiple spots in the speckle pattern projected into the scene better, which is beneficial to improve the accuracy of acquiring the depth image.
综上,本申请实施方式的图像获取方法在结构光投射器21和结构光摄像头22均位于显示屏10的背面13所在一侧,且结构光摄像头22接收的是穿过显示区11两次的被调制的结构光时,处理器200可直接基于第一测量斑点、第二测量斑点以及第三测量斑点计算深度图像,相比于仅使用第一测量斑点来计算深度图像的方式,显示屏10的衍射作用增加了测量斑点的数量和测量斑点排布的随机性,有利于提升深度图像的获取精度。进一步地,本申请实施方式的图像获取方法可以适当简化衍射光学元件213中衍射光栅的结构的复杂性,转而借助显示屏10的衍射作用来增加测量斑点的数量和排布的随机性,在保障深度图像的获取精度的同时可以简化结构光投射器21的制作工艺。In summary, in the image acquisition method of the embodiment of the present application, both the structured light projector 21 and the structured light camera 22 are located on the side of the back 13 of the display screen 10, and the structured light camera 22 receives the image twice through the display area 11 When the structured light is modulated, the processor 200 can directly calculate the depth image based on the first measurement spot, the second measurement spot, and the third measurement spot. Compared with the method of calculating the depth image using only the first measurement spot, the display screen 10 The diffractive effect increases the number of measurement spots and the randomness of the arrangement of measurement spots, which is beneficial to improve the accuracy of acquiring depth images. Further, the image acquisition method according to the embodiment of the present application can appropriately simplify the complexity of the structure of the diffraction grating in the diffractive optical element 213, and in turn, the number of measurement spots and the randomness of the arrangement are increased by the diffraction effect of the display screen 10, While ensuring the accuracy of acquiring the depth image, the manufacturing process of the structured light projector 21 can be simplified.
请参阅图1、图3及图31,在某些实施方式中,结构光投射器21和结构光摄像头22均设置在显示屏10的背面13所在的一侧,显示屏10未开设通槽14,结构光摄像头22接收的是穿过显示区11两次的被调制后的结构光。此时,步骤01包括:Please refer to FIG. 1, FIG. 3 and FIG. 31. In some embodiments, the structured light projector 21 and the structured light camera 22 are both disposed on the side of the back side 13 of the display screen 10, and the display screen 10 does not have a through slot 14 The structured light camera 22 receives modulated structured light that passes through the display area 11 twice. At this time, step 01 includes:
012:控制结构光摄像头22接收出射时经显示区11衍射并被目标物体反射后入射时再经显示区11衍射的结构光以得到散斑图像,散斑图像中包括多个测量斑点,多个测量斑点包括激光仅被衍射光学元件213一次衍射并被目标物体反射形成的第一测量斑点、激光经过衍射光学元件213一次衍射再由显示屏10二次衍射并被目标物体反射形成的第二测量斑点、及激光经过衍射光学元件213一次衍射再由显示屏10二次衍射并被目标物体反射后又一次由显示屏10三次衍射形成的第三测量斑点;具体地,第一测量斑点是激光经过衍射光学元件213衍射后在经过显示屏10时并没有被显示屏10衍射,即没有遇到微观间隙而直接投射到目标物体,并被目标物体调制反射后形成的;第二测量斑点是激光经过衍射光学元件213衍射后经过显示屏10时又被显示屏10衍射,即遇到微观间隙后投射到目标物体,被目标物体调制反射后再次经过显示屏10时未被显示屏10衍射形成的;第三测量斑点是激光经过衍射光学元件213衍射后经过显示屏10又被显示屏10衍射,即遇到微观间隙后投射到目标物体,被目标物体调制反射后再次经过显示屏10又一次被显示屏10中的微观间隙衍射后形成的;012: Control the structured light camera 22 to receive the structured light diffracted by the display area 11 and reflected by the target object when it is emitted and then diffracted by the display area 11 to obtain a speckle image. The speckle image includes multiple measurement spots, multiple The measurement spot includes a first measurement spot where the laser light is diffracted only once by the diffractive optical element 213 and reflected by the target object, and a second measurement is formed when the laser light is diffracted once by the diffractive optical element 213 and then diffracted by the display screen 10 twice and reflected by the target object The speckle and the laser are diffracted once by the diffractive optical element 213 and then diffracted again by the display screen 10 and reflected by the target object. The third measurement spot is formed by the third diffraction of the display screen 10; specifically, the first measurement spot is the laser The diffractive optical element 213 is not diffracted by the display screen 10 after passing through the display screen 10, that is, it is directly projected onto the target object without encountering a micro gap, and is formed after being modulated and reflected by the target object; the second measurement spot is the laser light passing through The diffractive optical element 213 is diffracted by the display screen 10 after passing through the display screen 10 after being diffracted, that is, projected after encountering a micro gap The target object, which is modulated and reflected by the target object, is not diffracted by the display screen 10 when it passes through the display screen 10 again; the third measurement spot is that the laser light is diffracted by the diffractive optical element 213 after passing through the display screen 10 and then diffracted by the display screen 10. It is projected to the target object after reaching the microscopic gap, and is modulated and reflected by the target object, passes through the display screen 10 again and is diffracted by the microscopic gap in the display screen 10 again;
步骤02包括: Step 02 includes:
025:滤除散斑图像中的第二测量斑点及第三测量斑点以得到第一测量斑点;及025: filter out the second measurement spot and the third measurement spot in the speckle image to obtain the first measurement spot; and
026:根据第一测量斑点与参考图像中的参考斑点获取深度图像。026: Acquire a depth image according to the first measurement spot and the reference spot in the reference image.
请再参阅图17,步骤012可以由控制模块401实现。步骤025和步骤026均可以由计算模块402实现。Please refer to FIG. 17 again. Step 012 may be implemented by the control module 401. Both step 025 and step 026 can be implemented by the calculation module 402.
请再参阅图1,步骤012、步骤025和步骤026均可以由处理器200实现。也即是说,处理器200还可用于控制结构光摄像头22接收出射时经显示区11衍射并被目标物体反射后入射时再经显示区11衍射的结构光以得到散斑图像、滤除散斑图像中的第二测量斑点及第三测量斑点以得到第一测量斑点、以及根据第一测量斑点与参考图像中的参考斑点获取深度图像。Please refer to FIG. 1 again. Step 012, step 025, and step 026 may be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to receive the structured light diffracted by the display area 11 when diffracted by the display area 11 after being emitted and reflected by the target object and then diffracted by the display area 11 to obtain a speckle image and filter out scattered light The second measurement spot and the third measurement spot in the spot image to obtain the first measurement spot, and the depth image is obtained according to the first measurement spot and the reference spot in the reference image.
具体地,结构光投射器21和结构光摄像头22一起设置在显示屏10的背面13所在一侧,且显示屏10未开设有通槽14时,结构光摄像头22拍摄到的是包含第一测量斑点、第二测量斑点和第三测量斑点的散斑图像。在后续深度图像的计算中,处理器200可以滤除散斑图像中的第二测量斑点和第三测量斑点,仅基于剩下的第一测量斑点来与参考图像中的参考斑点做深度图像的计算。此时,参考图像中的参考斑点应该仅包括多个激光仅被衍射光学元件213衍射并被标定物体反射形成的第一参考斑点。因此,通过滤除散斑图像中的第二测量斑点和第三测量斑点的方式可以消除显示屏10对结构光的影响,从而在保证电子装置1000的屏占比较高的情况下,电子装置1000获取的深度图像的精度也较高。Specifically, when the structured light projector 21 and the structured light camera 22 are arranged on the side of the back side 13 of the display screen 10, and the display screen 10 is not provided with a through slot 14, the structured light camera 22 captures the first measurement Speckle images of spots, second measurement spots and third measurement spots. In the calculation of the subsequent depth image, the processor 200 may filter out the second measurement spot and the third measurement spot in the speckle image, and only use the remaining first measurement spot to do the depth image with the reference spot in the reference image Calculation. At this time, the reference spot in the reference image should include only the first reference spot formed by a plurality of laser beams diffracted only by the diffractive optical element 213 and reflected by the calibration object. Therefore, by filtering out the second measurement spot and the third measurement spot in the speckle image, the influence of the display screen 10 on the structured light can be eliminated, thereby ensuring that the electronic device 1000 has a relatively high screen footprint, the electronic device 1000 The accuracy of the acquired depth image is also high.
也即是说,请参阅图32,图像获取方法还包括:That is to say, please refer to Figure 32, the image acquisition method also includes:
035:在标定参考图像时,控制结构光摄像头22接收从结构光投射器21出射后直接被标定物体反射并直接入射的结构光以得到第一参考图像,第一参考图像中包括多个参考斑点,多个参考斑点包括多个激光仅被衍射光学元件213衍射并被标定物体反射形成的第一参考斑点;035: When calibrating the reference image, the structured light camera 22 is controlled to receive the structured light directly reflected by the calibrated object and directly incident after exiting from the structured light projector 21 to obtain a first reference image, and the first reference image includes multiple reference spots The multiple reference spots include a first reference spot formed by multiple laser beams diffracted by the diffractive optical element 213 only and reflected by the calibration object;
步骤026包括:Step 026 includes:
0261:计算第一测量斑点相对于第一参考斑点的偏移量;及0261: Calculate the offset of the first measurement spot relative to the first reference spot; and
0262:根据偏移量计算深度数据以得到深度图像。0262: Calculate depth data according to the offset to obtain a depth image.
请再参阅图17,步骤035可以由控制模块401实现。步骤0261和步骤0262均可以由计算模块402实现。Please refer to FIG. 17 again. Step 035 may be implemented by the control module 401. Both step 0261 and step 0262 can be implemented by the calculation module 402.
请再参阅图1,步骤035、步骤0261和步骤0262均可以由处理器200实现。也即是说,处理器200还可用于在标定参考图像时控制结构光摄像头22接收从结构光投射器21出射后直接被标定物体反射并直接入射的结构光以得到第一参考图像、计算第一测量斑点相对于第一参考斑点的偏移量、以及根据偏移量计算深度数据以得到深度图像。Please refer to FIG. 1 again. Step 035, step 0261, and step 0262 can all be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to receive the structured light directly reflected by the calibrated object after being emitted from the structured light projector 21 and directly incident when the reference image is calibrated to obtain the first reference image and calculate the first A measurement spot offset relative to the first reference spot, and calculating depth data according to the offset to obtain a depth image.
具体地,处理器200滤除第二测量斑点和第三测量斑点后,散斑图像中仅剩余第一测量斑点,则此时散斑图像应该与仅包含对应第一测量斑点的第一参考斑点的第一参考图像来进行深度图像的计算。其中,第一参考图像的标定过程与前述步骤035中将结构光投射器21放在没有显示屏10遮挡的场景下进行标定的标定过程一致,在此不再赘述。结构光拍摄的第一参考图像中的多个参考斑点是激光仅被衍射光学元件213衍射并被标定物体反射形成的第一参考斑点。如此,处理器200即可计算出第一测量斑点相对于第一参考斑点的偏移量,再基于多个偏移量计算出多个深度数据,从而得到深度图像。Specifically, after the processor 200 filters out the second measurement spot and the third measurement spot, only the first measurement spot remains in the speckle image, then the speckle image should now contain only the first reference spot corresponding to the first measurement spot The first reference image is used to calculate the depth image. The calibration process of the first reference image is the same as the calibration process of placing the structured light projector 21 in a scene that is not covered by the display screen 10 in step 035, which will not be repeated here. The multiple reference spots in the first reference image captured by structured light are the first reference spots formed by laser light diffracted only by the diffractive optical element 213 and reflected by the calibration object. In this way, the processor 200 can calculate the offset of the first measurement spot relative to the first reference spot, and then calculate multiple depth data based on the multiple offsets to obtain a depth image.
处理器200可以通过亮度来滤除第二测量斑点和第三测量斑点。也即是说,请参阅图33,在某些实施方式中,图像获取方法还包括:The processor 200 may filter out the second measurement spot and the third measurement spot by brightness. That is to say, referring to FIG. 33, in some embodiments, the image acquisition method further includes:
035:在标定参考图像时,控制结构光摄像头22接收从结构光投射器21出射后直接被标定物体反射并直接入射的结构光以得到第一参考图像,第一参考图像中包括多个参考斑点,多个参考斑点包括多个激光仅被衍射光学元件213衍射并被标定物体反射形成的第一参考斑点;035: When calibrating the reference image, the structured light camera 22 is controlled to receive the structured light directly reflected by the calibrated object and directly incident after exiting from the structured light projector 21 to obtain a first reference image, and the first reference image includes multiple reference spots The multiple reference spots include a first reference spot formed by multiple laser beams diffracted by the diffractive optical element 213 only and reflected by the calibration object;
036:在标定参考图像时,控制结构光摄像头22接收出射时经显示区11衍射并被标定物体反射后直接入射的结构光以得到第二参考图像,第二参考图像中包括多个参考斑点,多个参考斑点包括激光仅被衍射光学元件213衍射并被标定物体反射后形成的第一参考斑点和激光经过衍射光学元件213一次衍射再由显示屏10二次衍射并被标定物体反射形成的第二参考斑点;036: When the reference image is calibrated, the structured light camera 22 is controlled to receive the structured light that is diffracted by the display area 11 and reflected directly by the calibrated object when being emitted to obtain a second reference image, and the second reference image includes multiple reference spots, The multiple reference spots include a first reference spot formed by laser light diffracted by the diffractive optical element 213 and reflected by the calibration object and a laser beam diffracted once by the diffractive optical element 213 and then diffracted by the display screen 10 twice and reflected by the calibration object Two reference spots;
037:在标定参考图像时,控制结构光摄像头22接收出射时经显示区11衍射并被标定物体反射后在经过显示区11入射时又被显示区11衍射的结构光以得到第三参考图像,第三参考图像中包括多个参考斑点,多个参考斑点包括激光仅被衍射光学元件213衍射并被标定物体反射形成的第一参考斑点、激光经过衍射光学元件213一次衍射再由显示屏10二次衍射并被标定物体反射形成的第二参考斑点、及激光经过衍射光学元件213一次衍射再由显示屏10二次衍射并被标定物体反射后又一次由显示屏10三次衍射形成的第三参考斑点;037: When the reference image is calibrated, the structured light camera 22 is controlled to receive the structured light diffracted by the display area 11 and diffracted by the display area 11 when it is diffracted by the display area 11 and reflected by the calibration object to obtain the third reference image. The third reference image includes multiple reference spots. The multiple reference spots include a first reference spot formed by laser light diffracted only by the diffractive optical element 213 and reflected by the calibration object. The laser light is diffracted by the diffractive optical element 213 once and then diffracted by the display screen 10 The second reference spot diffracted and reflected by the calibration object, and the laser beam is diffracted once by the diffractive optical element 213 and then diffracted again by the display panel 10 and reflected by the calibration object. spot;
042:比对所述第一参考图像与所述第二参考图像以获取所述第二参考斑点,及比对所述第三参考图像与所述第二参考图像以获取所述第三参考斑点;042: Compare the first reference image and the second reference image to obtain the second reference spot, and compare the third reference image and the second reference image to obtain the third reference spot ;
052:计算多个所述第二参考斑点的亮度的平均值与多个所述第一参考斑点的亮度的平均值之间的比值作为所述第一预设比值,计算多个所述第三参考斑点的亮度的平均值与多个所述第一参考斑点的亮度的平均值之间的比值作为所述第二预设比值,及计算多个所述第一参考斑点的亮度的平均值并作为所述预设亮度;052: Calculate the ratio between the average value of the brightness of the plurality of second reference spots and the average value of the brightness of the plurality of first reference spots as the first preset ratio, and calculate the plurality of third The ratio between the average value of the brightness of the reference spots and the average value of the brightness of the plurality of first reference spots is used as the second preset ratio, and the average value of the brightness of the plurality of first reference spots is calculated and As the preset brightness;
步骤025包括:Step 025 includes:
0251:计算每个测量斑点与预设亮度之间的实际比值;0251: Calculate the actual ratio between each measured spot and the preset brightness;
0252:将实际比值大于第一预设比值的测量斑点归类为第一测量斑点,将实际比值小于第一预设比值且大于第二预设比值的测量斑点归类为第二测量斑点,将实际比值小于第二预设比值的测量斑点归类为第三测量斑点;及0252: The measurement spots whose actual ratio is greater than the first preset ratio are classified as the first measurement spots, and the measurement spots whose actual ratio is less than the first preset ratio and greater than the second preset ratio are classified as the second measurement spots, and Measurement spots whose actual ratio is less than the second preset ratio are classified as third measurement spots; and
0253:从所有测量斑点中滤除第二测量斑点和第三测量斑点以得到第一测量斑点。0253: Filter the second measurement spot and the third measurement spot from all the measurement spots to obtain the first measurement spot.
请再参阅图17,步骤035、步骤036和步骤037均可以由控制模块401实现。步骤042、步骤052、步骤0251、步骤0252和步骤0253均可以由计算模块401实现。Please refer to FIG. 17 again. Step 035, step 036, and step 037 may all be implemented by the control module 401. Step 042, step 052, step 0251, step 0252, and step 0253 can all be implemented by the calculation module 401.
请再参阅图1,步骤035、步骤036、步骤037、步骤042、步骤052、步骤0251、步骤0252和步骤0253均可以由处理器200实现。也即是说,处理器200还可用于在标定参考图像时控制结构光摄像头22接收从结构光投射器21出射后直接被标定物体反射并直接入射的结构光以得到第一参考图像、在标定参考图像时控制结构光摄像头22接收出射时经显示区11衍射并被标定物体反射后直接入射的结构光以得到第二参考图像、以及在标定参考图像时控制结构光摄像头22接收出射时经显示区11衍射并被标定物体反射后在经过显示区11入射时又被显示区11衍射的结构光以得到第三参考图像。处理器200还可用于比对所述第一参考图像与所述第二参考图像以获取所述第二参考斑点、比对所述第三参考图像与所述第二参考图像以获取所述第三参考斑点、计算多个所述第二参考斑点的亮度的平均值与多个所述第一参考斑点的亮度的平均值之间的比值作为所述第一预设比值、计算多个所述第三参考斑点的亮度的平均值与多个所述第一参考斑点的亮度的平均值之间的比值作为所述第二预设比值、及计算多个所述第一参考斑点的亮度的平均值并作为所述预设亮度。处理器200还可用于计算每个测量斑点与预设亮度之间的实际比值、将实际比值大于第一预设比值的测量斑点归类为第一测量斑点、将实际比值小于第一预设比值且大于第二预设比值的测量斑点归类为第二测量斑点、将实际比值小于第二预设比值的测量斑点归类为第三测量斑点、及从所有测量斑点中滤除第二测量斑点和第三测量斑点以得到第一测量斑点。Please refer to FIG. 1 again. Step 035, step 036, step 037, step 042, step 052, step 0251, step 0252, and step 0253 can all be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to receive the structured light that is directly reflected by the calibrated object and directly incident after being emitted from the structured light projector 21 when the reference image is calibrated to obtain the first reference image. When the reference image is referenced, the structured light camera 22 is controlled to receive the structured light that is diffracted by the display area 11 and reflected directly by the calibrated object when being emitted to obtain a second reference image, and when the reference image is calibrated, the structured light camera 22 is controlled to receive and display the emitted light After the area 11 is diffracted and reflected by the calibration object, the structured light is diffracted by the display area 11 again when incident through the display area 11 to obtain a third reference image. The processor 200 may be further used to compare the first reference image with the second reference image to obtain the second reference spot, and compare the third reference image with the second reference image to obtain the first Three reference spots, calculating a ratio between the average value of the brightness of the plurality of second reference spots and the average value of the brightness of the plurality of first reference spots as the first preset ratio, calculating a plurality of The ratio between the average value of the brightness of the third reference spots and the average value of the brightness of the plurality of first reference spots is used as the second preset ratio, and the average of the brightness of the plurality of first reference spots is calculated Value as the preset brightness. The processor 200 can also be used to calculate the actual ratio between each measured spot and the preset brightness, classify the measured spots whose actual ratio is greater than the first preset ratio as the first measured spot, and classify the actual ratio as being smaller than the first preset ratio The measurement spots that are greater than the second preset ratio are classified as second measurement spots, the measurement spots whose actual ratio is less than the second preset ratio are classified as third measurement spots, and the second measurement spots are filtered out of all measurement spots And the third measurement spot to obtain the first measurement spot.
其中,步骤035所述的标定第一参考图像的过程与前述步骤035中将结构光投射器21放在没有显示屏10遮挡的场景下进行标定的标定过程一致,步骤036所述的标定第二参考图像的过程与前述步骤036中将结构光投射器21和结构光摄像头22均放在显示屏10的背面13所在一侧,且结构光摄像头22入光面对准显示屏10的通槽14的场景下进行标定的标定过程一致,步骤037所述的标定第三参考图像的过程与前述步骤037中将结构光投射器21和结构光摄像头22均放在显示屏10的背面13所在一侧,且显示屏10未开设通槽14的场景下进行标定的标定过程一致,在此不再赘述。Among them, the process of calibrating the first reference image described in step 035 is the same as the calibration process in step 035 where the structured light projector 21 is placed in a scene that is not blocked by the display screen 10, and the second process described in step 036 The process of the reference image and the foregoing step 036 place the structured light projector 21 and the structured light camera 22 on the side of the back side 13 of the display screen 10, and the structured light camera 22 enters the light surface and aligns with the through slot 14 of the display screen 10 The calibration process for the calibration in the same scenario is the same. The process of calibrating the third reference image described in step 037 is the same as that in the previous step 037. The structured light projector 21 and the structured light camera 22 are placed on the back side 13 of the display screen 10 In addition, the calibration process for the calibration in the scenario where the display screen 10 does not have the through slot 14 is consistent, and will not be repeated here.
在得到第一参考图像、第二参考图像和第三参考图像后,处理器200即可采用与前述步骤042相同的方式,即根据第一参考图像中第一参考斑点的第一坐标来确定出第二参考图像中第一参考斑点,第二参考图像中剩余的参考斑点即为第二参考斑点,标记出第二参考斑点的第二坐标,从而在第二参考图像中区分出第一参考斑点和第二参考斑点。随后,处理器200根据第一坐标和第二坐标在第三参考图像中确定出第三参考图像中的第一参考斑点和第二参考斑点,第三参考图像中剩余的参考斑点即为第三参考斑点,从而可以区分出第三参考图像中的第一参考斑点、第二参考斑点及第三参考斑点。随后,处理器200即可采用与前述步骤052相同的方式来基于区分出的第一参考斑点、第二参考斑点和第三参考斑点标定得到预设亮度、第一预设比值和第二预设比值。After obtaining the first reference image, the second reference image, and the third reference image, the processor 200 can determine the first coordinate of the first reference spot in the first reference image in the same manner as the foregoing step 042 The first reference spot in the second reference image, the remaining reference spot in the second reference image is the second reference spot, and the second coordinates of the second reference spot are marked to distinguish the first reference spot in the second reference image And the second reference spot. Subsequently, the processor 200 determines the first reference spot and the second reference spot in the third reference image according to the first coordinate and the second coordinate, and the remaining reference spot in the third reference image is the third The reference spots, so that the first reference spots, the second reference spots, and the third reference spots in the third reference image can be distinguished. Then, the processor 200 can calibrate to obtain the preset brightness, the first preset ratio, and the second preset based on the distinguished first reference spot, second reference spot, and third reference spot in the same manner as the foregoing step 052 ratio.
同样地,在后续深度图像的计算中,处理器200可采用与前述步骤062和前述步骤072相同的方式,即基于标定好的第一预设比值、第二预设比值和预设亮度来区分出第一测量斑点、第二测量斑点和第三测量斑点,随后滤除第二测量斑点和第三测量斑点,仅留下第一测量斑点,再计算第一测量斑点相对于第一参考斑点的偏移量,最后基于偏移量计算出深度数据,从而得到深度图像。Similarly, in the calculation of the subsequent depth image, the processor 200 may adopt the same method as the foregoing step 062 and the foregoing step 072, that is, distinguish based on the calibrated first preset ratio, second preset ratio, and preset brightness The first measurement spot, the second measurement spot and the third measurement spot are filtered out, and then the second measurement spot and the third measurement spot are filtered out, leaving only the first measurement spot, and then calculating the first measurement spot relative to the first reference spot The offset, and finally the depth data is calculated based on the offset to obtain a depth image.
在某些实施方式中,预设亮度、第一预设比值和第二预设比值同样由场景的环境亮度以及结构光投射器21的发光功率决定。如此,可以提高第二测量斑点和第三测量斑点的滤除的准确性。In some embodiments, the preset brightness, the first preset ratio and the second preset ratio are also determined by the ambient brightness of the scene and the luminous power of the structured light projector 21. In this way, the accuracy of filtering the second measurement spot and the third measurement spot can be improved.
在某些实施方式中,衍射光学元件213除了用于衍射结构光投射器21的光源211发射的激光以增加测量斑点或参考斑点的数量之外,还可以用于补偿显示屏10衍射的结构光的亮度均匀性,使得投射到场景中的散斑图案中的多个斑点的亮度的均匀性较好,有利于提升深度图像的获取精度。In some embodiments, the diffractive optical element 213 can be used to compensate the structured light diffracted by the display screen 10 in addition to diffracting the laser light emitted by the light source 211 of the structured light projector 21 to increase the number of measurement spots or reference spots. The uniformity of the brightness makes the uniformity of the brightness of the multiple spots in the speckle pattern projected into the scene better, which is beneficial to improve the accuracy of acquiring the depth image.
综上,本申请实施方式的图像获取方法在结构光投射器21和结构光均位于显示屏10下,且显示屏10未开设通槽14时,先滤除第二测量斑点以及第三测量斑点,仅根据剩余的第一测量斑点来计算深度 图像,减少了处理器200的数据处理量,有利于加快深度图像的获取进程。In summary, in the image acquisition method of the embodiment of the present application, when both the structured light projector 21 and the structured light are located under the display screen 10, and the display screen 10 does not have a through slot 14, the second measurement spot and the third measurement spot are filtered out first Calculating the depth image only based on the remaining first measurement spots reduces the amount of data processing by the processor 200, which is beneficial to speed up the process of acquiring the depth image.
请参阅图1、图34及图35,在某些实施方式中,在结构光投射器21设置在显示屏10的背面13所在的一侧时,电子装置1000还包括补偿光学元件500。补偿光学元件500设置在衍射光学元件与显示屏10之间。结构光投射器21发出的结构光依次穿过补偿光学元件500和显示屏10出射到场景中。补偿光学元件500用于抵消显示屏10的衍射作用。此时,结构光摄像头22可设置在显示屏10的背面13所在一侧,且显示屏10可未开设通槽14,对应地,结构光摄像头22接收依次穿过补偿光学元件500、显示区11、显示区11、补偿光学元件500的被调制的结构光;或者,结构光摄像头22可设置在显示屏10的背面13所在一侧,且显示屏10开设有通槽14,结构光摄像头22的入光面与通槽14对准,对应地,结构光摄像头22接收依次穿过补偿光学元件500、显示区11、通槽14的被调制的结构光。Please refer to FIGS. 1, 34 and 35. In some embodiments, when the structured light projector 21 is disposed on the side of the back surface 13 of the display screen 10, the electronic device 1000 further includes a compensation optical element 500. The compensation optical element 500 is provided between the diffractive optical element and the display screen 10. The structured light emitted by the structured light projector 21 sequentially passes through the compensation optical element 500 and the display screen 10 and exits into the scene. The compensation optical element 500 is used to cancel the diffraction effect of the display screen 10. At this time, the structured light camera 22 may be disposed on the side of the back surface 13 of the display screen 10, and the display screen 10 may not have a through slot 14, correspondingly, the structured light camera 22 receives the compensation optical element 500 and the display area 11 sequentially , The display area 11, the modulated structured light of the compensation optical element 500; or, the structured light camera 22 may be provided on the side of the back 13 of the display screen 10, and the display screen 10 is provided with a through slot 14, the structured light camera 22 The light incident surface is aligned with the through slot 14, and correspondingly, the structured light camera 22 receives the modulated structured light that sequentially passes through the compensation optical element 500, the display area 11, and the through slot 14.
步骤01包括: Step 01 includes:
013:控制结构光摄像头22接收出射时依次经过补偿光学元件500及显示屏10的显示区11并被目标物体反射后的结构光以得到散斑图像,补偿光学元件500用于抵消显示屏10的衍射作用,散斑图像包括多个测量斑点,多个测量斑点包括激光仅被衍射光学元件213衍射并被目标物体反射形成的测量斑点;013: Control the structured light camera 22 to receive the structured light that passes through the compensation optical element 500 and the display area 11 of the display screen 10 and is reflected by the target object in order to obtain a speckle image when the light is emitted. The compensation optical element 500 is used to offset the display screen 10 Diffraction, the speckle image includes multiple measurement spots, and the multiple measurement spots include measurement spots formed by laser light diffracted only by the diffractive optical element 213 and reflected by the target object;
请参阅图17,步骤013可以由控制模块401实现。Referring to FIG. 17, step 013 may be implemented by the control module 401.
请再参阅图1,步骤013可以由处理器200实现。也即是说,处理器200还可用于控制结构光摄像头22接收出射时依次经过补偿光学元件500及显示屏10的显示区11并被目标物体反射后的结构光以得到散斑图像。Please refer to FIG. 1 again. Step 013 may be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to receive the structured light that passes through the compensation optical element 500 and the display area 11 of the display screen 10 and is reflected by the target object in order to obtain a speckle image.
本申请实施方式的图像获取方法,在结构光投射器21与显示屏10之间设置一个补偿光学元件500,以抵消显示屏10的衍射作用。其中,补偿光学元件500与显示屏10可以间隔一定距离设置(如图35所示);或者,补偿光学元件500与显示屏10的背面13可以贴合设置(图未示)。如此,补偿光学元件500及显示屏10的与补偿光学元件500相对的部分可以构成一个平面镜,结构光经过平面镜时斑点的数量不会被改变,因此,出射到场景中的结构光形成的散斑图案中的斑点可以认为是仅包括激光仅被衍射光学元件213衍射形成的斑点,测量斑点可以认为是激光仅衍射光学元件213衍射并被目标物体反射形成的。In the image acquisition method according to the embodiment of the present application, a compensation optical element 500 is provided between the structured light projector 21 and the display screen 10 to offset the diffraction effect of the display screen 10. Wherein, the compensation optical element 500 and the display screen 10 may be arranged at a certain distance (as shown in FIG. 35); or, the compensation optical element 500 and the back surface 13 of the display screen 10 may be provided in close contact (not shown). In this way, the compensation optical element 500 and the portion of the display screen 10 opposite to the compensation optical element 500 can form a plane mirror, and the number of spots will not be changed when the structured light passes through the plane mirror. Therefore, the speckle formed by the structured light emitted into the scene The speckles in the pattern may be regarded as including only the laser light diffracted by the diffractive optical element 213, and the measurement spot may be regarded as the laser only diffracted by the diffractive optical element 213 and reflected by the target object.
具体地,请结合图1、图5、图8及图36,在某些实施方式中,当结构光摄像头22设置在显示屏10的背面13所在的一侧,且显示屏10开设有与结构光摄像头22的入光面对准的通槽14时,步骤013包括:Specifically, please refer to FIG. 1, FIG. 5, FIG. 8 and FIG. 36. In some embodiments, when the structured light camera 22 is disposed on the side of the back surface 13 of the display screen 10, and the display screen 10 is provided with the structure When the light incident surface of the optical camera 22 is aligned with the through slot 14, step 013 includes:
0131:控制结构光摄像头22接收出射时依次经过补偿光学元件500及显示区11并被目标物体反射后直接入射的结构光以得到散斑图像;0131: Control the structured light camera 22 to directly receive the structured light that directly passes through the compensation optical element 500 and the display area 11 and is reflected by the target object when being emitted to obtain a speckle image;
图像获取方法还包括:The image acquisition method also includes:
038:在标定参考图像时,控制结构光摄像头22接收出射时经过补偿光学元件500及显示区11并被标定物体反射后直接入射的结构光以得到参考图像,参考图像中包括多个参考斑点,多个参考斑点包括激光仅被衍射光学元件213衍射并被标定物体反射形成的参考斑点;038: When the reference image is calibrated, the structured light camera 22 is controlled to receive the structured light that directly passes through the compensation optical element 500 and the display area 11 and is reflected by the calibrated object when being emitted to obtain a reference image. The reference image includes multiple reference spots, The multiple reference spots include reference spots formed by laser light diffracted only by the diffractive optical element 213 and reflected by the calibration object;
步骤02包括: Step 02 includes:
0271:计算测量斑点相对于参考斑点的偏移量;及0271: Calculate the offset of the measurement spot relative to the reference spot; and
0272:根据偏移量计算深度数据以得到深度图像。0272: Calculate depth data according to the offset to obtain a depth image.
请再参阅图17,步骤0131和步骤038均可以由控制模块401实现。步骤0271和步骤0272均可以由计算模块402实现。Please refer to FIG. 17 again. Step 0131 and step 038 can be implemented by the control module 401. Both step 0271 and step 0272 can be implemented by the calculation module 402.
请再参阅图1,步骤0131、步骤038、步骤0271和步骤0272均可以由处理器200实现。也即是说,处理器200还可用于控制结构光摄像头22接收出射时依次经过补偿光学元件500及显示区11并被目标物体反射后直接入射的结构光以得到散斑图像、在标定参考图像时控制结构光摄像头22接收出射时经过补偿光学元件500及显示区11并被标定物体反射后直接入射的结构光以得到参考图像、计算测量斑点相对于参考斑点的偏移量、以及根据偏移量计算深度数据以得到深度图像。Please refer to FIG. 1 again. Step 0131, step 038, step 0271, and step 0272 can all be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to receive the structured light that directly passes through the compensation optical element 500 and the display area 11 and is reflected by the target object in order to obtain the speckle image and the calibration reference image Time-controlled structured light camera 22 receives structured light that directly passes through the compensation optical element 500 and the display area 11 and is reflected by the calibration object at the time of emission to obtain a reference image, calculate the offset of the measurement spot relative to the reference spot, and according to the offset Calculate the depth data to get the depth image.
其中,补偿光学元件500的面积应略大于或等于结构光投射器21发射的结构光形成的发散面积,如此,结构光投射器21发射的结构光能全部穿过补偿光学元件500,从而可以抵消掉显示屏10的衍射作用。另外,补偿光学元件500不能对结构光摄像头22的入光面产生遮挡,即补偿光学元件500不能 与通槽14重叠。可以理解,通槽14并不具有衍射作用,由目标物体反射回来的结构光穿过通槽14时并不会被衍射,因此,无需在通槽14位置处设置补偿光学元件500来抵消显示区11的衍射作用。相反地,如果在通槽14位置处设置补偿光学元件500,反而会使得穿过补偿光学元件500的结构光被补偿光学元件500衍射,从而导致结构光摄像头22接收的散斑图像中包括激光经衍射光学元件213一次衍射后穿过补偿光学元件500及显示屏10的与补偿光学元件500相对的部分构成的平面镜并再经补偿光学元件500衍射形成的测量斑点。Wherein, the area of the compensation optical element 500 should be slightly greater than or equal to the divergent area formed by the structured light emitted by the structured light projector 21, so that all the structured light emitted by the structured light projector 21 can pass through the compensation optical element 500, which can be offset The diffraction effect of the display screen 10 is lost. In addition, the compensation optical element 500 cannot block the light incident surface of the structured light camera 22, that is, the compensation optical element 500 cannot overlap the through slot 14. It can be understood that the through slot 14 does not have a diffractive effect, and the structured light reflected by the target object will not be diffracted when passing through the through slot 14, therefore, it is not necessary to provide a compensation optical element 500 at the position of the through slot 14 to offset the display area 11 diffraction effect. Conversely, if the compensation optical element 500 is provided at the position of the through slot 14, the structured light passing through the compensation optical element 500 will be diffracted by the compensation optical element 500, resulting in the speckle image received by the structured light camera 22 including the laser beam After one diffraction, the diffractive optical element 213 passes through the compensation optical element 500 and the plane mirror formed by the portion of the display screen 10 opposite to the compensation optical element 500 and is diffracted by the compensation optical element 500 to form a measurement spot.
当结构光摄像头22设置在显示屏10的背面13所在的一侧,且显示屏10开设有与结构光摄像头22的入光面对准的通槽14时,结构光投射器21的光源211发射的激光会依次经过补偿光学元件500和显示区11,结构光摄像头22接收的是穿过由补偿光学元件500和显示屏10组成的平面镜出射后被目标物体调制后反射再穿过通槽14入射的结构光。由于补偿光学元件500抵消了显示区11的衍射作用,结构光摄像头22拍摄的散斑图像仅包括激光仅被衍射光学元件213一次衍射并被目标物体反射形成的测量斑点,而不会出现激光经衍射光学元件213一次衍射又经显示屏10二次衍射并被目标物体反射形成的测量斑点。When the structured light camera 22 is disposed on the side of the back surface 13 of the display screen 10, and the display screen 10 is provided with a through slot 14 aligned with the light incident surface of the structured light camera 22, the light source 211 of the structured light projector 21 emits The laser light will pass through the compensation optical element 500 and the display area 11 in turn. The structured light camera 22 receives the light through the plane mirror composed of the compensation optical element 500 and the display screen 10, is modulated by the target object, and then reflects through the through slot 14 Structured light. Since the compensation optical element 500 counteracts the diffraction effect of the display area 11, the speckle image captured by the structured light camera 22 includes only measurement spots formed by laser light diffracted only once by the diffractive optical element 213 and reflected by the target object, without occurrence of laser light The measurement spot formed by the diffractive optical element 213 is diffracted once and diffracted again by the display screen 10 and reflected by the target object.
对应地,参考图像中的参考斑点也应该仅包括激光仅被衍射光学元件213一次衍射并被标定物体反射形成的参考斑点,则标定场景应为:将结构光投射器21和结构光摄像头22放置在设置有补偿光学元件500的显示屏10的背面13所在一侧,结构光摄像头22的入光面与显示屏10的通槽14对准。如此,在标定场景下和实际使用场景下,结构光投射器21与结构光摄像头22相对于显示屏10的设置位置是一致的。处理器200控制结构光投射器21发射结构光,结构光依次穿过补偿光学元件500和显示屏10后投射到与结构光组件20相隔预定距离的标定板处,被标定板反射回的结构光穿过通槽14被结构光摄像头22接收。此时,结构光摄像头22接收的是由光源211发出后经衍射光学元件211一次衍射并被标定板反射后经由通槽14直接入射的激光,形成的参考图像中包括的多个参考斑点即为激光仅被衍射光学元件213一次衍射并被标定物体反射形成的参考斑点。Correspondingly, the reference spot in the reference image should also only include the reference spot formed by laser light diffracted only once by the diffractive optical element 213 and reflected by the calibration object, then the calibration scene should be: placing the structured light projector 21 and structured light camera 22 On the side where the back surface 13 of the display screen 10 provided with the compensation optical element 500 is located, the light incident surface of the structured light camera 22 is aligned with the through slot 14 of the display screen 10. In this way, in the calibration scene and the actual use scene, the installation positions of the structured light projector 21 and the structured light camera 22 relative to the display screen 10 are the same. The processor 200 controls the structured light projector 21 to emit structured light. The structured light sequentially passes through the compensation optical element 500 and the display screen 10 and then is projected to the calibration plate at a predetermined distance from the structured light assembly 20, and the structured light reflected back by the calibration plate The structured light camera 22 receives the through slot 14. At this time, the structured light camera 22 receives the laser light which is diffracted by the diffractive optical element 211 once after being emitted by the light source 211 and reflected by the calibration plate, and then directly incident through the through slot 14. The multiple reference spots included in the formed reference image are The laser beam is diffracted only once by the diffractive optical element 213 and reflected by the calibration object to form a reference spot.
处理器200计算深度图像时无需滤除激光经过两次衍射形成的测量斑点,可直接基于仅有的激光仅经过一次衍射形成的测量斑点及参考图像中的参考斑点计算深度图像。具体地,处理器200计算测量斑点与参考斑点之间的偏移量,再根据偏移量计算深度数据,从而得到深度图像。The processor 200 does not need to filter out the measurement spots formed by the laser through two diffractions when calculating the depth image, and can directly calculate the depth image based on the measurement spots formed by the only laser through only one diffraction and the reference spots in the reference image. Specifically, the processor 200 calculates the offset between the measurement spot and the reference spot, and then calculates the depth data according to the offset, thereby obtaining a depth image.
同样地,请结合图3和图37,在某些实施方式中,当结构光摄像头22设置在显示屏10的背面所在一侧,且显示屏10未开设有通槽14时,步骤013包括:Similarly, please refer to FIG. 3 and FIG. 37. In some embodiments, when the structured light camera 22 is disposed on the back side of the display screen 10, and the display screen 10 is not provided with a through slot 14, step 013 includes:
0132:控制结构光摄像头22接收出射时依次经过补偿光学元件500及显示区11并被目标物体反射后入射时依次经过显示区11及补偿光学元件500的结构光以得到散斑图像;0132: Control the structured light camera 22 to sequentially pass through the compensation optical element 500 and the display area 11 when it is emitted and reflected by the target object, and then to pass through the structured light of the display area 11 and the compensation optical element 500 in order to obtain a speckle image;
图像获取方法还包括:The image acquisition method also includes:
039:在标定参考图像时,控制结构光摄像头22接收出射时依次经过补偿光学元件500及显示区11并被标定物体反射后入射时依次经过显示区11及补偿光学元件500的结构光以得到参考图像,参考图像包括多个参考斑点,多个参考斑点包括激光仅被衍射光学元件213衍射并被标定物体反射形成的参考斑点;039: When the reference image is calibrated, the structured light camera 22 is controlled to pass through the compensation optical element 500 and the display area 11 sequentially when receiving the emission and is reflected by the calibrated object, and then passes through the structured light of the display area 11 and the compensation optical element 500 in order to obtain a reference Image, the reference image includes multiple reference spots, and the multiple reference spots include reference spots formed by laser light diffracted only by the diffractive optical element 213 and reflected by the calibration object;
步骤02包括: Step 02 includes:
0271:计算测量斑点相对于参考斑点的偏移量;及0271: Calculate the offset of the measurement spot relative to the reference spot; and
0272:根据偏移量计算深度数据以得到深度图像。0272: Calculate depth data according to the offset to obtain a depth image.
请再参阅图17,步骤0132和步骤039均可以由控制模块401实现。步骤0271和步骤0272均可以由计算模块402实现。Please refer to FIG. 17 again. Both step 0132 and step 039 may be implemented by the control module 401. Both step 0271 and step 0272 can be implemented by the calculation module 402.
请再参阅图1,步骤0132、步骤039、步骤0271和步骤0272均可以由处理器200实现。也即是说,处理器200还可用于控制结构光摄像头22接收出射时依次经过补偿光学元件500及显示区11并被目标物体反射后入射时依次经过显示区11及补偿光学元件500的结构光以得到散斑图像、在标定参考图像时控制结构光摄像头22接收出射时依次经过补偿光学元件500及显示区11并被标定物体反射后入射时依次经过显示区11及补偿光学元件500的结构光以得到参考图像、计算测量斑点相对于参考斑点的偏移量、以及根据偏移量计算深度数据以得到深度图像。Please refer to FIG. 1 again. Step 0132, step 039, step 0271, and step 0272 can all be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to sequentially pass through the compensation optical element 500 and the display area 11 when it is emitted and reflected by the target object, and then to pass through the structured light of the display area 11 and the compensation optical element 500 in sequence when it is incident To obtain a speckle image, control the structured light camera 22 to sequentially pass through the compensation optical element 500 and the display area 11 when receiving the emitted light, and to reflect the structured light passing through the display area 11 and the compensation optical element 500 when it is incident after being reflected by the calibration object To obtain a reference image, calculate an offset of the measurement spot relative to the reference spot, and calculate depth data according to the offset to obtain a depth image.
其中,补偿光学元件500应同时完全覆盖结构光投射器21和结构光摄像头22。如此,一方面结构光投射器21发射的结构光能全部穿过补偿光学元件500,从而可以抵消显示屏10的衍射作用;另一方 面被目标物体反射回的结构光也能全部穿过补偿光学元件500以抵消显示屏10的衍射作用,从而使得结构光摄像头22拍摄的散斑图像中仅包括激光仅被衍射光学元件213一次衍射并被目标物体反射形成的测量斑点。The compensation optical element 500 should completely cover the structured light projector 21 and the structured light camera 22 at the same time. In this way, on the one hand, the structured light emitted by the structured light projector 21 can all pass through the compensation optical element 500, which can cancel the diffraction effect of the display screen 10; on the other hand, the structured light reflected by the target object can also all pass through the compensation optic The element 500 counteracts the diffraction effect of the display screen 10, so that the speckle image captured by the structured light camera 22 includes only measurement spots formed by laser light diffracted only once by the diffractive optical element 213 and reflected by the target object.
具体地,当结构光摄像头22设置在显示屏10的背面13所在的一侧,且显示屏10未开设有通槽14时,结构光投射器21的光源211发射的激光会依次经过补偿光学元件500和显示区11,结构光摄像头22接收的是穿过由补偿光学元件500和显示屏10组成的平面镜出射后被目标物体反射,再穿过由显示屏10和补偿光学元件500组成的平面镜后入射的结构光。由于补偿光学元件500抵消了显示区11的衍射作用,结构光摄像头22拍摄的散斑图像仅包括激光仅被衍射光学元件213一次衍射并被目标物体反射形成的测量斑点,而不会出现激光经衍射光学元件213一次衍射又经显示屏10二次衍射并被目标物体反射形成的测量斑点,也不会出现激光经衍射光学元件213一次衍射又经显示屏10二次衍射并被目标物体反射后又被显示屏10三次衍射形成的测量斑点。Specifically, when the structured light camera 22 is disposed on the side where the back 13 of the display screen 10 is located, and the display screen 10 is not provided with a through slot 14, the laser light emitted by the light source 211 of the structured light projector 21 will sequentially pass through the compensation optical element 500 and the display area 11, the structured light camera 22 receives the light through the plane mirror composed of the compensation optical element 500 and the display screen 10, is reflected by the target object, and then passes through the plane mirror composed of the display screen 10 and the compensation optical element 500 Structured light incident. Since the compensation optical element 500 counteracts the diffraction effect of the display area 11, the speckle image captured by the structured light camera 22 includes only measurement spots formed by laser light diffracted only once by the diffractive optical element 213 and reflected by the target object, without occurrence of laser light The diffractive optical element 213 is diffracted once and then diffracted by the display screen 10 twice and reflected by the target object to form a measurement spot, nor will the laser light diffracted by the diffractive optical element 213 once by the display screen 10 and diffracted again by the target object The measurement spot formed by the third-order diffraction of the display screen 10 again.
对应地,参考图像中的参考斑点也应该仅包括激光仅被衍射光学元件213一次衍射并被标定物体反射形成的参考斑点,则标定场景应为:将结构光投射器21和结构光摄像头22放置在设置有补偿光学元件500的显示屏10的背面13所在一侧,其中显示屏10未开设有通槽14。如此,在标定场景下和实际使用场景下,结构光投射器21与结构光摄像头22相对于显示屏10的设置位置是一致的。处理器200控制结构光投射器21发射结构光,结构光依次穿过补偿光学元件500和显示屏10后投射到与结构光组件20相隔预定距离的标定板处,被标定板反射回的结构光依次穿过显示屏10和补偿光学元件500后被结构光摄像头22接收,形成的参考图像中包括的多个参考斑点即为激光仅被衍射光学元件213一次衍射并被标定物体反射形成的参考斑点。Correspondingly, the reference spot in the reference image should also only include the reference spot formed by laser light diffracted only once by the diffractive optical element 213 and reflected by the calibration object, then the calibration scene should be: placing the structured light projector 21 and structured light camera 22 On the side where the back surface 13 of the display screen 10 provided with the compensation optical element 500 is located, the display screen 10 is not provided with a through slot 14. In this way, in the calibration scene and the actual use scene, the installation positions of the structured light projector 21 and the structured light camera 22 relative to the display screen 10 are the same. The processor 200 controls the structured light projector 21 to emit structured light. The structured light sequentially passes through the compensation optical element 500 and the display screen 10 and then is projected to the calibration plate at a predetermined distance from the structured light assembly 20, and the structured light reflected back by the calibration plate After passing through the display screen 10 and the compensation optical element 500 in sequence, it is received by the structured light camera 22, and the multiple reference spots included in the formed reference image are the reference spots formed by the laser light diffracted only once by the diffractive optical element 213 and reflected by the calibration object .
处理器200计算深度图像时无需滤除激光经过多次衍射形成的测量斑点,可直接基于仅有的激光仅经过一次衍射形成的测量斑点及参考图像中的参考斑点计算深度图像。具体地,处理器200计算测量斑点与参考斑点之间的偏移量,再根据偏移量计算深度数据,从而得到深度图像。When the processor 200 calculates the depth image, it is not necessary to filter out the measurement spots formed by the laser through multiple diffractions, and the depth image can be directly calculated based on the measurement spots formed by the laser through only one diffraction and the reference spots in the reference image. Specifically, the processor 200 calculates the offset between the measurement spot and the reference spot, and then calculates the depth data according to the offset, thereby obtaining a depth image.
综上,本申请实施方式的图像获取方法通过设置补偿光学元件500来抵消显示屏10的衍射作用,如此,结构光摄像头22拍摄的散斑图像中仅包括激光仅被衍射光学元件213一次衍射并被目标物体反射形成的测量斑点,而不会出现激光经衍射光学元件213一次衍射后又经显示屏10二次衍射并被目标物体反射形成的测量斑点、以及激光经衍射光学元件213一次衍射后又经显示屏10二次衍射并被目标物体反射后再经显示屏10三次衍射形成的测量斑点,处理器200无需执行滤点的操作,可以直接基于散斑图像中的所有测量斑点及参考图像中的所有参考斑点计算深度图像,简化深度图像的计算过程,加快深度图像的获取进度。In summary, the image acquisition method according to the embodiment of the present application compensates for the diffraction effect of the display screen 10 by providing the compensation optical element 500. In this way, the speckle image captured by the structured light camera 22 includes only the laser light diffracted by the diffractive optical element 213 once. The measurement spot reflected by the target object without the measurement spot formed by the laser diffracted by the diffractive optical element 213 once and then diffracted by the display screen 10 second time and reflected by the target object, and the laser spot diffracted by the diffractive optical element 213 once The measurement spot formed by the second diffraction of the display screen 10 and reflected by the target object and then by the third diffraction of the display screen 10, the processor 200 does not need to perform the filtering operation, and can be directly based on all measurement spots and reference images in the speckle image All reference blobs in are used to calculate depth images, which simplifies the calculation process of depth images and speeds up the acquisition of depth images.
请参阅图1、图4和图38,在某些实施方式中,结构光投射器21中的衍射光学元件213替换为光学元件214,光学元件214用于补偿显示屏10衍射的结构光的亮度的均匀性。步骤01包括:Please refer to FIG. 1, FIG. 4 and FIG. 38. In some embodiments, the diffractive optical element 213 in the structured light projector 21 is replaced with an optical element 214. The optical element 214 is used to compensate the brightness of the structured light diffracted by the display screen 10. Of uniformity. Step 01 includes:
014:控制结构光摄像头22接收出射时经显示屏10的显示区11衍射并被目标物体反射后的结构光以得到散斑图像,结构光投射器中21中的光学元件214用于补偿显示屏10衍射的结构光的亮度的均匀性,散斑图像中包括多个测量斑点。014: Control the structured light camera 22 to receive the structured light diffracted by the display area 11 of the display screen 10 and reflected by the target object when it is emitted to obtain a speckle image, and the optical element 214 in the structured light projector 21 is used to compensate the display screen 10 The uniformity of the brightness of the diffracted structured light, and the speckle image includes multiple measurement spots.
请再参阅图17,步骤014可以由控制模块401实现。Please refer to FIG. 17 again. Step 014 may be implemented by the control module 401.
请再参阅图1,步骤014还可以由处理器200实现。也即是说,处理器200还可用于控制结构光摄像头22接收出射时经显示屏10的显示区11衍射并被目标物体反射后的结构光以得到散斑图像,结构光投射器中21中的光学元件214用于补偿显示屏10衍射的结构光的亮度的均匀性。Please refer to FIG. 1 again. Step 014 may also be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to receive the structured light diffracted by the display area 11 of the display screen 10 and reflected by the target object when it exits to obtain a speckle image. 21 in the structured light projector The optical element 214 is used to compensate the uniformity of the brightness of the structured light diffracted by the display screen 10.
具体地,显示屏10的显示区11中的相邻像素之间形成有微观间隙,结构光投射器21发出的结构光穿过显示区11后会被显示区11衍射形成多个斑点。但显示区11衍射的斑点的亮度分布不均匀。Specifically, a micro gap is formed between adjacent pixels in the display area 11 of the display screen 10, and the structured light emitted by the structured light projector 21 passes through the display area 11 and is diffracted by the display area 11 to form multiple spots. However, the brightness distribution of the spots diffracted by the display area 11 is not uniform.
本申请实施方式的图像获取方法借助显示屏10的衍射作用形成多个斑点,并将结构光投射器21中的衍射光学元件213替换成可以补偿显示屏10衍射的结构光的亮度的均匀性的光学元件214,即结构光投射器21的光源211发出的激光依次穿过光学元件214和显示屏10后,投射到场景的散斑图案中有多个斑点,且斑点的亮度较为均匀,其中,斑点由显示屏10衍射,斑点的亮度的均匀性由光学元件214进行补偿。The image acquisition method of the embodiment of the present application forms a plurality of spots by means of the diffraction effect of the display screen 10, and replaces the diffractive optical element 213 in the structured light projector 21 with one that can compensate for the uniformity of the brightness of the structured light diffracted by the display screen 10. The optical element 214, that is, the laser light emitted by the light source 211 of the structured light projector 21 passes through the optical element 214 and the display screen 10 in sequence, and there are multiple spots in the speckle pattern projected onto the scene, and the brightness of the spots is relatively uniform, where, The spots are diffracted by the display screen 10, and the uniformity of the brightness of the spots is compensated by the optical element 214.
如此,结构光摄像头22拍摄的散斑图像中的测量斑点是直接借助显示屏10的衍射作用形成的,处理器200可以基于这些测量斑点来计算深度图像。光学元件214补偿显示屏10衍射的结构光的亮度均 匀性有利于提升获取的深度图像的精度。In this way, the measurement spots in the speckle image captured by the structured light camera 22 are directly formed by the diffraction effect of the display screen 10, and the processor 200 can calculate the depth image based on these measurement spots. The optical element 214 compensates for the uniformity of the brightness of the structured light diffracted by the display screen 10, which is beneficial to improve the accuracy of the acquired depth image.
请参阅图1、图4、图5、图8及图39,在某些实施方式中,当结构光投射器21和结构光摄像头22均设置在显示屏10的背面所在一侧,且显示屏10开设有通槽14,结构光摄像头22的入光面对准通槽14时,步骤014包括:Please refer to FIG. 1, FIG. 4, FIG. 5, FIG. 8 and FIG. 39. In some embodiments, when the structured light projector 21 and the structured light camera 22 are both disposed on the back side of the display screen 10, and the display screen 10 is provided with a through slot 14, and when the light incident surface of the structured light camera 22 is aligned with the through slot 14, step 014 includes:
0141:控制结构光摄像头22接收出射时经显示区11衍射并被目标物体反射后直接入射的结构光以得到散斑图像,光学元件214用于补偿显示屏10衍射的结构光的亮度的均匀性,散斑图像中包括多个测量斑点,多个测量斑点包括激光经过光学元件214扩散再由显示屏10一次衍射并被目标物体反射形成的第一测量斑点;0141: Control the structured light camera 22 to receive the structured light directly diffracted by the display area 11 and reflected by the target object when being emitted to obtain a speckle image, and the optical element 214 is used to compensate the uniformity of the brightness of the structured light diffracted by the display screen 10 , The speckle image includes a plurality of measurement spots, and the plurality of measurement spots includes a first measurement spot formed by laser light diffused through the optical element 214 and then diffracted by the display screen 10 once and reflected by the target object;
图像获取方法还包括:The image acquisition method also includes:
091:在标定参考图像时,控制结构光摄像头22接收出射时经显示区11衍射并被标定物体反射后直接入射的结构光以得到参考图像,光学元件214用于补偿显示屏10衍射的结构光的亮度的均匀性,参考图像包括多个参考斑点,多个参考斑点包括激光经过光学元件214扩散再由显示屏10一次衍射并被标定物体反射形成的第一参考斑点;091: When the reference image is calibrated, the structured light camera 22 is controlled to receive the structured light diffracted by the display area 11 and reflected directly by the calibrated object when it is emitted to obtain the reference image, and the optical element 214 is used to compensate the structured light diffracted by the display screen 10 The uniformity of the brightness, the reference image includes a plurality of reference spots, and the plurality of reference spots includes a first reference spot formed by laser light diffused through the optical element 214 and then diffracted by the display screen 10 once and reflected by the calibration object;
步骤02包括: Step 02 includes:
0281:计算第一测量斑点相对于第一参考斑点的偏移量;及0281: Calculate the offset of the first measurement spot relative to the first reference spot; and
0282:根据偏移量计算深度数据以获取深度图像。0282: Calculate depth data according to the offset to obtain a depth image.
请再参阅图17,步骤0141和步骤091均可以由控制模块401实现。步骤0281和步骤0282均可以由计算模块402实现。Please refer to FIG. 17 again, both step 0141 and step 091 can be implemented by the control module 401. Both step 0281 and step 0282 can be implemented by the calculation module 402.
请再参阅图1,步骤0141、步骤091、步骤0281和步骤0282均可以由处理器200实现。也即是说,处理器200还可用于控制结构光摄像头22接收出射时经显示区11衍射并被目标物体反射后直接入射的结构光以得到散斑图像,光学元件214用于补偿显示屏10衍射的结构光的亮度的均匀性。处理器200还可用于在标定参考图像时,控制结构光摄像头22接收出射时经显示区11衍射并被标定物体反射后直接入射的结构光以得到参考图像,光学元件214用于补偿显示屏10衍射的结构光的亮度的均匀性。处理器200还可用于计算第一测量斑点相对于第一参考斑点的偏移量、以及根据偏移量计算深度数据以获取深度图像。Please refer to FIG. 1 again. Step 0141, step 091, step 0281, and step 0282 can all be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to receive the structured light diffracted by the display area 11 and reflected directly by the target object when it is emitted to obtain a speckle image, and the optical element 214 is used to compensate the display screen 10 The uniformity of the brightness of the diffracted structured light. The processor 200 can also be used to control the structured light camera 22 to receive the structured light that is diffracted by the display area 11 and reflected directly by the calibration object to obtain the reference image when the reference image is calibrated, and the optical element 214 is used to compensate the display screen 10 The uniformity of the brightness of the diffracted structured light. The processor 200 may also be used to calculate an offset of the first measurement spot relative to the first reference spot, and calculate depth data according to the offset to obtain a depth image.
具体地,当结构光摄像头22设置在显示屏10的背面13所在的一侧,且显示屏10开设有与结构光摄像头22的入光面对准的通槽14时,结构光投射器21的光源211发出的激光依次经过光学元件214和显示屏10的显示区11后形成结构光出射到场景中,结构光会被目标物体反射再穿过通槽14入射以被结构光摄像头22接收。由于光学元件214仅用于补偿显示屏10衍射的结构光的亮度的均匀性,而不会增加测量斑点的数量,且通槽14不具有微观间隙不会对反射回的结构光进行衍射,因此,结构光摄像头22拍摄的散斑图像中仅包括激光经过光学元件214扩散再由显示屏10一次衍射并被目标物体反射形成的第一测量斑点。Specifically, when the structured light camera 22 is disposed on the side of the back surface 13 of the display screen 10, and the display screen 10 is provided with a through slot 14 aligned with the light incident surface of the structured light camera 22, the structured light projector 21 The laser light emitted by the light source 211 sequentially passes through the optical element 214 and the display area 11 of the display screen 10 to form structured light and exit into the scene. The structured light is reflected by the target object and then enters the through slot 14 to be received by the structured light camera 22. Since the optical element 214 is only used to compensate the uniformity of the brightness of the structured light diffracted by the display screen 10 without increasing the number of measurement spots, and the through slot 14 does not have a microscopic gap, it will not diffract the structured light reflected back, so The speckle image captured by the structured light camera 22 includes only the first measurement spot formed by the laser light diffused through the optical element 214 and then diffracted by the display screen 10 once and reflected by the target object.
对应地,参考图像中的参考斑点也应该仅包括激光经过光学元件214扩散再由显示屏10一次衍射并被标定物体反射形成的第一参考斑点,则标定场景应为,设有光学元件214的结构光投射器21、以及结构光摄像头22放置在显示屏10的背面13所在一侧,结构光摄像头22的入光面与显示屏10的通槽14对准。如此,在标定场景下和实际使用场景下,结构光投射器21与结构光摄像头22相对于显示屏10的设置位置是一致的。处理器200控制结构光投射器21的光源211发射激光,激光依次穿过光学元件214和显示屏10后形成结构光投射到与结构光组件20相隔预定距离的标定板处,被标定板反射回的结构光穿过通槽14被结构光摄像头22接收。此时,结构光摄像头22接收的是由光源211发出后经衍射光学元件213扩散再由显示屏10一次衍射并被标定板反射后再经由通槽14直接入射的激光,形成的参考图像中包括的多个参考斑点即为激光经过光学元件214扩散再由显示屏10一次衍射并被标定物体反射形成的第一参考斑点。Correspondingly, the reference spot in the reference image should also include only the first reference spot formed by the laser diffused through the optical element 214 and then diffracted by the display screen 10 once and reflected by the calibration object, then the calibration scene should be the one with the optical element 214 The structured light projector 21 and the structured light camera 22 are placed on the side of the back surface 13 of the display screen 10, and the light incident surface of the structured light camera 22 is aligned with the through slot 14 of the display screen 10. In this way, in the calibration scene and the actual use scene, the installation positions of the structured light projector 21 and the structured light camera 22 relative to the display screen 10 are the same. The processor 200 controls the light source 211 of the structured light projector 21 to emit laser light, and the laser light passes through the optical element 214 and the display screen 10 in turn to form structured light and is projected onto the calibration plate at a predetermined distance from the structured light assembly 20, which is reflected back by the calibration plate The structured light passing through the through slot 14 is received by the structured light camera 22. At this time, the structured light camera 22 receives the laser light emitted by the light source 211, diffused by the diffractive optical element 213, diffracted by the display screen 10 once and reflected by the calibration plate, and then directly incident through the through slot 14, the reference image formed includes The multiple reference spots are the first reference spots formed by the laser light diffusing through the optical element 214 and then diffracted by the display screen 10 once and reflected by the calibration object.
处理器200计算深度图像时直接基于第一测量斑点及参考图像中的第一参考斑点计算深度图像。具体地,处理器200计算第一测量斑点与第一参考斑点之间的偏移量,再根据偏移量计算深度数据,从而得到深度图像。When calculating the depth image, the processor 200 directly calculates the depth image based on the first measurement spot and the first reference spot in the reference image. Specifically, the processor 200 calculates the offset between the first measurement spot and the first reference spot, and then calculates depth data according to the offset, thereby obtaining a depth image.
同样地,请结合图3和图40,在某些实施方式中,当结构光摄像头22设置在显示屏10的背面所在一侧,且显示屏10未开设有通槽14时,步骤014包括:Similarly, referring to FIGS. 3 and 40, in some embodiments, when the structured light camera 22 is disposed on the side of the back of the display screen 10 and the display screen 10 is not provided with a through slot 14, step 014 includes:
0142:控制结构光摄像头22接收出射时经显示区11衍射并被目标物体反射后入射时再经显示区11衍射的结构光以得到散斑图像,光学元件214用于补偿显示屏10衍射的结构光的亮度的均匀性,散斑图像包括多个测量斑点,多个测量斑点包括激光经过光学元件214扩散再由显示屏10一次衍射并被目标物体反射后形成的第一测量斑点和激光经过光学元件214扩散再由显示屏10一次衍射并被目标物体反射后又一次由显示屏10二次衍射形成的第二测量斑点。0142: Control the structured light camera 22 to receive the structured light diffracted by the display area 11 when being emitted and reflected by the target object and then diffracted by the display area 11 when incident to obtain a speckle image, and the optical element 214 is used to compensate the structure of the diffraction of the display screen 10 The uniformity of the brightness of the light, the speckle image includes multiple measurement spots, the multiple measurement spots include the first measurement spot formed by the laser light diffused through the optical element 214 and then diffracted by the display screen 10 once and reflected by the target object, and the laser light passes through the optical The element 214 diffuses a second measurement spot formed by the second diffraction of the display screen 10 after being diffracted once by the display screen 10 and reflected by the target object.
请再参阅图17,步骤0142可以由控制模块401实现。Please refer to FIG. 17 again. Step 0142 can be implemented by the control module 401.
请再参阅图1,步骤0142还可以由处理器200实现。也即是说,处理器200还可用于控制结构光摄像头22接收出射时经显示区11衍射并被目标物体反射后入射时再经显示区11衍射的结构光以得到散斑图像,光学元件214用于补偿显示屏10衍射的结构光的亮度的均匀性。Please refer to FIG. 1 again. Step 0142 can also be implemented by the processor 200. That is to say, the processor 200 can also be used to control the structured light camera 22 to receive the structured light diffracted by the display area 11 when diffracted by the display area 11 after being emitted and reflected by the target object and then diffracted by the display area 11 to obtain a speckle image. The optical element 214 It is used to compensate the uniformity of the brightness of the structured light diffracted by the display screen 10.
具体地,当结构光摄像头22设置在显示屏10的背面13所在的一侧,且显示屏10未开设有通槽14时,结构光投射器21的光源211发出的激光依次经过光学元件214和显示屏10的显示区11后形成结构光出射到场景中,结构光会被目标物体反射再穿过显示屏10入射以被结构光摄像头22接收。由于光学元件214仅用于补偿显示屏10衍射的结构光的亮度的均匀性,而不会增加测量斑点的数量,且显示屏10具有微观间隙会对反射回的结构光进行衍射,因此,结构光摄像头22拍摄的散斑图像中同时包括多个激光经过光学元件214扩散再由显示屏10一次衍射并被目标物体反射形成的第一测量斑点、以及激光经过光学元件214扩散再由显示屏10一次衍射并被目标物体反射后又一次由显示屏10二次衍射形成的第二测量斑点。Specifically, when the structured light camera 22 is disposed on the side where the back 13 of the display screen 10 is located, and the display screen 10 is not provided with a through slot 14, the laser light emitted by the light source 211 of the structured light projector 21 passes through the optical element 214 and After the display area 11 of the display screen 10, structured light is formed and emitted into the scene. The structured light is reflected by the target object and then enters through the display screen 10 to be received by the structured light camera 22. Since the optical element 214 is only used to compensate the uniformity of the brightness of the structured light diffracted by the display screen 10 without increasing the number of measurement spots, and the display screen 10 has a microscopic gap to diffract the structured light reflected back, therefore, the structure The speckle image captured by the optical camera 22 includes a plurality of laser spots diffused by the optical element 214 and then diffracted once by the display screen 10 and reflected by the target object, and the first measurement spot formed by the laser beam diffused by the optical element 214 and then by the display screen 10 The second measurement spot formed by the second diffraction of the display screen 10 after being diffracted once and reflected by the target object.
结构光摄像头22拍摄到散斑图像后,处理器200可以直接根据散斑图像中的第一测量斑点及第二测量斑点与参考图像中的参考斑点来计算深度图像。其中,深度图像的计算方式可以包括下述的两种。After the speckle image is captured by the structured light camera 22, the processor 200 may directly calculate the depth image according to the first measurement spot and the second measurement spot in the speckle image and the reference spot in the reference image. The calculation method of the depth image may include the following two.
请再参阅图40,在一个计算方式中,步骤02包括:Please refer to FIG. 40 again. In a calculation method, step 02 includes:
0283:计算所有测量斑点相对于所有参考斑点的偏移量;及0283: Calculate the offset of all measurement spots relative to all reference spots; and
0284:根据偏移量计算深度数据以获取深度图像。0284: Calculate depth data according to the offset to obtain a depth image.
对应地,图像获取方法还包括:Correspondingly, the image acquisition method also includes:
092:在标定参考图像时,控制结构光摄像头22接收出射时经显示区11衍射并被标定物体反射后入射时再经显示区11衍射的结构光以得到参考图像,光学元件214用于补偿显示屏10衍射的结构光的亮度的均匀性,参考图像包括多个参考斑点,多个参考斑点包括激光经过光学元件214扩散再由显示屏10一次衍射并被标定物体反射后形成的第一参考斑点和激光经过光学元件214扩散再由显示屏10一次衍射并被标定物体反射后又一次由显示屏10二次衍射形成的第二参考斑点。092: When the reference image is calibrated, the structured light camera 22 is controlled to receive the structured light diffracted by the display area 11 when diffracted by the display area 11 after being emitted and reflected by the calibrated object and then diffracted by the display area 11 to obtain the reference image. The uniformity of the brightness of the structured light diffracted by the screen 10, the reference image includes a plurality of reference spots, the plurality of reference spots including the first reference spots formed after the laser light diffuses through the optical element 214 and is diffracted by the display screen 10 once and reflected by the calibration object The second laser beam is diffused by the optical element 214 and then diffracted by the display screen 10 once and reflected by the calibration object, and then is second diffracted by the display screen 10 second diffraction.
请再参阅图17,步骤0283和步骤0284可以由计算模块402实现。步骤092可以由控制模块401实现。Please refer to FIG. 17 again. Step 0283 and step 0284 can be implemented by the calculation module 402. Step 092 can be implemented by the control module 401.
请再参阅图1,步骤0283、步骤0284和步骤092还可以由处理器200实现。也即是说,处理器200还可用于计算所有测量斑点相对于所有参考斑点的偏移量、以及根据偏移量计算深度数据以获取深度图像。处理器200还可用于在标定参考图像时,控制结构光摄像头22接收出射时经显示区11衍射并被标定物体反射后入射时再经显示区11衍射的结构光以得到参考图像,光学元件214用于补偿显示屏10衍射的结构光的亮度的均匀性。Please refer to FIG. 1 again. Step 0283, step 0284, and step 092 may also be implemented by the processor 200. That is to say, the processor 200 can also be used to calculate the offsets of all measurement spots relative to all reference spots, and calculate depth data according to the offsets to obtain depth images. The processor 200 can also be used to control the structured light camera 22 to receive the structured light diffracted by the display area 11 when diffracted by the display area 11 and reflected by the calibrated object and then diffracted by the display area 11 when the reference image is calibrated to obtain the reference image. It is used to compensate the uniformity of the brightness of the structured light diffracted by the display screen 10.
具体地,在标定参考图像的过程中,设有光学元件214的结构光投射器21、以及结构光摄像头22放置在显示屏10的背面13所在一侧,其中,显示屏10未开设通槽14。如此,在标定场景下和实际使用场景下,结构光投射器21与结构光摄像头22相对于显示屏10的设置位置是一致的。处理器200控制结构光投射器21的光源211发射激光,激光依次穿过光学元件214和显示屏10后形成结构光投射到与结构光组件20相隔预定距离的标定板处,被标定板反射回的结构光穿过显示屏10后被结构光摄像头22接收。此时,结构光摄像头22拍摄的参考图像中同时包括多个第一参考斑点和多个第二参考斑点。其中,第一参考斑点是激光经过光学元件214扩散再由显示屏10一次衍射并被标定物体反射形成的,第二参考斑点是激光经过光学元件214扩散再由显示屏10一次衍射并被标定物体反射后又一次由显示屏10二次衍射形成的。虽然散斑图像中同时包括第一测量斑点和第二测量斑点,参考图像中同时包括第一参考斑点和第二参考斑点。但是在此计算方式中,处理器200并不会对散斑图像中的第一测量斑点和第二测量斑点做区分,也不会对参考图像中的第一参考斑点和第二参考斑点做区分,而是直接基于所有的测量斑点和参考斑点来进行深度图像的计算。具体地,处理器200首先计算所有测量斑点相对于所 有参考斑点的偏移量,再基于多个偏移量计算出多个深度数据,从而得到深度图像。Specifically, in the process of calibrating the reference image, the structured light projector 21 provided with the optical element 214 and the structured light camera 22 are placed on the side of the back surface 13 of the display screen 10, wherein the display screen 10 does not have a through slot 14 . In this way, in the calibration scene and the actual use scene, the installation positions of the structured light projector 21 and the structured light camera 22 relative to the display screen 10 are the same. The processor 200 controls the light source 211 of the structured light projector 21 to emit laser light, and the laser light passes through the optical element 214 and the display screen 10 in turn to form structured light and is projected onto the calibration plate at a predetermined distance from the structured light assembly 20, which is reflected back by the calibration plate After passing through the display screen 10, the structured light is received by the structured light camera 22. At this time, the reference image captured by the structured light camera 22 includes multiple first reference spots and multiple second reference spots at the same time. Among them, the first reference spot is the laser light diffused through the optical element 214 and then diffracted by the display screen 10 and reflected by the calibrated object. The second reference spot is the laser light diffused through the optical element 214 and then diffracted by the display screen 10 and the calibrated object After reflection, it is formed by the second order diffraction of the display screen 10 again. Although the speckle image includes both the first measurement spot and the second measurement spot, the reference image includes both the first reference spot and the second reference spot. However, in this calculation method, the processor 200 does not distinguish between the first measurement spot and the second measurement spot in the speckle image, nor does it distinguish between the first reference spot and the second reference spot in the reference image Instead, the depth image is calculated directly based on all the measurement spots and reference spots. Specifically, the processor 200 first calculates the offsets of all measurement spots relative to all reference spots, and then calculates multiple depth data based on the multiple offsets, thereby obtaining a depth image.
请参阅图41,在另一个计算方式中,步骤02包括:Referring to FIG. 41, in another calculation method, step 02 includes:
0285:计算第一测量斑点相对于第一参考斑点的偏移量、及第二测量斑点相对于第二参考斑点的偏移量;及0285: Calculate the offset of the first measurement spot relative to the first reference spot, and the offset of the second measurement spot relative to the second reference spot; and
0286:根据偏移量计算深度数据以获取深度图像。0286: Calculate depth data according to the offset to obtain a depth image.
对应地,图像获取方法还包括:Correspondingly, the image acquisition method also includes:
091:在标定参考图像时,控制结构光摄像头22接收出射时经显示区11衍射并被标定物体反射后直接入射的结构光以得到参考图像,光学元件214用于补偿显示屏10衍射的结构光的亮度的均匀性,参考图像包括多个参考斑点,多个参考斑点包括激光经过光学元件214扩散再由显示屏10一次衍射并被标定物体反射形成的第一参考斑点;091: When the reference image is calibrated, the structured light camera 22 is controlled to receive the structured light diffracted by the display area 11 and reflected directly by the calibrated object when it is emitted to obtain the reference image, and the optical element 214 is used to compensate the structured light diffracted by the display screen 10 The uniformity of the brightness, the reference image includes a plurality of reference spots, and the plurality of reference spots includes a first reference spot formed by laser light diffused through the optical element 214 and then diffracted by the display screen 10 once and reflected by the calibration object;
092:在标定参考图像时,控制结构光摄像头22接收出射时经显示区11衍射并被标定物体反射后入射时再经显示区11衍射的结构光以得到参考图像,光学元件214用于补偿显示屏10衍射的结构光的亮度的均匀性,参考图像包括多个参考斑点,多个参考斑点包括激光经过光学元件214扩散再由显示屏10一次衍射并被标定物体反射后形成的第一参考斑点和激光经过光学元件214扩散再由显示屏10一次衍射并被标定物体反射后又一次由显示屏10二次衍射形成的第二参考斑点;092: When the reference image is calibrated, the structured light camera 22 is controlled to receive the structured light diffracted by the display area 11 when diffracted by the display area 11 after being emitted and reflected by the calibrated object and then diffracted by the display area 11 to obtain the reference image, and the optical element 214 is used to compensate the display The uniformity of the brightness of the structured light diffracted by the screen 10, the reference image includes a plurality of reference spots, the plurality of reference spots including the first reference spots formed after the laser light diffuses through the optical element 214 and is diffracted by the display screen 10 once and reflected by the calibration object A second reference spot formed by the laser beam diffusing through the optical element 214 and then diffracted by the display screen 10 once and reflected by the calibration object and then again diffracted by the display screen 10;
043:比对第一参考图像与第二参考图像以获取第二参考斑点;043: Compare the first reference image with the second reference image to obtain a second reference spot;
053:计算多个第二参考斑点的亮度的平均值与多个第一参考斑点的亮度的平均值之间的比值并作为预设比值,及计算多个第一参考斑点的亮度的平均值并作为预设亮度;053: Calculate the ratio between the average of the brightness of the multiple second reference spots and the average of the brightness of the multiple first reference spots as the preset ratio, and calculate the average of the brightness of the multiple first reference spots and As the preset brightness;
063:计算每个测量斑点与预设亮度之间的实际比值;及063: Calculate the actual ratio between each measured spot and the preset brightness; and
073:将实际比值大于预设比值的测量斑点归类为第一测量斑点,及将实际比值小于预设比值的测量斑点归类为第二测量斑点。073: Classify the measurement spot whose actual ratio is greater than the preset ratio as the first measurement spot, and classify the measurement spot whose actual ratio is less than the preset ratio as the second measurement spot.
请再参阅图17,步骤0285、步骤0286、步骤43、步骤053、步骤063和步骤073均可以由计算模块402实现。步骤091和步骤092均可以由控制模块401实现。Please refer to FIG. 17 again. Step 0285, step 0286, step 43, step 053, step 063, and step 073 can all be implemented by the calculation module 402. Both step 091 and step 092 can be implemented by the control module 401.
请再参阅图1,步骤0285、步骤0286、步骤091、步骤092和步骤43、步骤053、步骤063和步骤073均可以由处理器200实现。也即是说,处理器200还可用于计算第一测量斑点相对于第一参考斑点的偏移量、及第二测量斑点相对于第二参考斑点的偏移量、以及根据偏移量计算深度数据以获取深度图像。处理器200还可用于在标定参考图像时控制结构光摄像头22接收出射时经显示区11衍射并被标定物体反射后直接入射的结构光以得到参考图像、以及在标定参考图像时,控制结构光摄像头22接收出射时经显示区11衍射并被标定物体反射后入射时再经显示区11衍射的结构光以得到参考图像,其中,光学元件214用于补偿显示屏10衍射的结构光的亮度的均匀性。处理器200还可用于比对第一参考图像与第二参考图像以获取第二参考斑点、计算多个第二参考斑点的亮度的平均值与多个第一参考斑点的亮度的平均值之间的比值并作为预设比值、以及计算多个第一参考斑点的亮度的平均值并作为预设亮度。处理器200还可用于计算每个测量斑点与预设亮度之间的实际比值、将实际比值大于预设比值的测量斑点归类为第一测量斑点、以及将实际比值小于预设比值的测量斑点归类为第二测量斑点。Please refer to FIG. 1 again. Step 0285, step 0286, step 091, step 092, and step 43, step 053, step 063, and step 073 can all be implemented by the processor 200. That is to say, the processor 200 can also be used to calculate the offset of the first measurement spot relative to the first reference spot, and the offset of the second measurement spot relative to the second reference spot, and calculate the depth according to the offset Data to obtain depth images. The processor 200 can also be used to control the structured light camera 22 to receive the structured light directly diffracted by the display area 11 and reflected by the calibration object when the reference image is calibrated to obtain the reference image, and to control the structured light when the reference image is calibrated The camera 22 receives the structured light diffracted by the display area 11 when it is emitted and reflected by the calibration object and then diffracted by the display area 11 when incident to obtain a reference image, wherein the optical element 214 is used to compensate the brightness of the structured light diffracted by the display screen 10 Uniformity. The processor 200 may also be used to compare the first reference image and the second reference image to obtain the second reference spot, and calculate the average value of the brightness of the plurality of second reference spots and the average value of the brightness of the plurality of first reference spots The ratio is used as the preset ratio, and the average value of the brightness of the plurality of first reference spots is calculated and used as the preset brightness. The processor 200 can also be used to calculate the actual ratio between each measurement spot and the preset brightness, classify the measurement spots whose actual ratio is greater than the preset ratio as the first measurement spots, and classify the measurement spots whose actual ratio is less than the preset ratio It is classified as the second measurement spot.
此种计算方式下,处理器200需要标定出第一参考图像和第二参考图像。第一参考图像的标定过程与前述步骤091中将设有光学元件214的结构光投射器21、以及结构光摄像头22放置在显示屏10的背面13所在一侧,且结构光摄像头22的入光面与显示屏10的通槽14对准的场景下的标定过程一致,第二参考图像的标定过程与前述步骤092中将设有光学元件214的结构光投射器21、以及结构光摄像头22放置在显示屏10的背面13所在一侧,且显示屏10未开设通槽14的场景下的标定过程一致,在此不做赘述。In this calculation mode, the processor 200 needs to calibrate the first reference image and the second reference image. The calibration process of the first reference image and the aforementioned step 091 place the structured light projector 21 provided with the optical element 214 and the structured light camera 22 on the side of the back side 13 of the display screen 10, and the structured light camera 22 enters the light The calibration process in the scene where the surface is aligned with the through slot 14 of the display screen 10 is consistent. The calibration process of the second reference image is the same as the step 092 where the structured light projector 21 provided with the optical element 214 and the structured light camera 22 are placed The calibration process is the same on the side where the back surface 13 of the display screen 10 is located, and the display screen 10 does not have the through slot 14, and will not be repeated here.
处理器200标定出第一参考图像和第二参考图像后,处理器200标记出第一参考图像中第一参考斑点的坐标,并根据第一参考斑点的坐标在第二参考图像中筛选出第一参考斑点,第二参考图像中剩余的参考斑点即为第二参考斑点,如此,处理器即可在第二参考图像的所有参考斑点中区分出第一参考斑点和第二参考斑点。After the processor 200 calibrates the first reference image and the second reference image, the processor 200 marks the coordinates of the first reference spot in the first reference image, and filters out the second reference image according to the coordinates of the first reference spot One reference spot, and the remaining reference spots in the second reference image are the second reference spots. In this way, the processor can distinguish the first reference spot and the second reference spot from all the reference spots in the second reference image.
由于后续计算深度数据时,散斑图像中的测量斑点也需要进行区分。具体地,可以通过亮度来区分出第一测量斑点和第二测量斑点。可以理解,第一测量斑点是激光经过光学元件214扩散再由显示屏10一次衍射形成的,第二测量斑点是激光经过光学元件214扩散再由显示屏10一次及二次衍射形成的, 形成第二测量斑点的激光被衍射的次数多于形成第一测量斑点的激光被衍射的次数,因此,形成第一测量斑点的激光的能量损耗较小,形成第二测量斑点的激光的能量损耗较大,第二测量斑点的亮度会低于第一测量斑点的亮度。如此,可以基于亮度来区分出第一测量斑点和第二测量斑点。那么,在参考图像标定完毕后还需要进一步标定出用于区分第一测量斑点和第二测量斑点的亮度。也即是说,在处理器200区分出第一参考斑点和第二参考斑点后,处理器200需要计算出第二参考图像中的多个第一参考斑点的亮度的平均值,并计算出第二参考图像中多个第二参考斑点的亮度的平均值。随后,处理器200将多个第一参考斑点的亮度的平均值作为预设亮度,将多个第二参考斑点的亮度的平均值与多个第一参考斑点的亮度的平均值之间的比值作为预设比值。As the depth data is calculated later, the measurement spots in the speckle image also need to be distinguished. Specifically, the first measurement spot and the second measurement spot can be distinguished by brightness. It can be understood that the first measurement spot is formed by the laser diffused through the optical element 214 and then diffracted by the display screen 10 once, and the second measurement spot is formed by the diffused optical element 214 and then formed by the first and second diffraction of the display screen 10, forming the first The second measurement spot laser is diffracted more times than the first measurement spot laser is diffracted. Therefore, the energy loss of the laser forming the first measurement spot is smaller, and the energy loss of the laser forming the second measurement spot is larger The brightness of the second measurement spot will be lower than the brightness of the first measurement spot. In this way, the first measurement spot and the second measurement spot can be distinguished based on the brightness. Then, after the reference image calibration is completed, it is necessary to further calibrate the brightness for distinguishing the first measurement spot from the second measurement spot. That is to say, after the processor 200 distinguishes the first reference spot and the second reference spot, the processor 200 needs to calculate the average value of the brightness of the plurality of first reference spots in the second reference image, and calculate the first The average value of the brightness of multiple second reference spots in the two reference images. Subsequently, the processor 200 takes the average value of the brightness of the plurality of first reference spots as the preset brightness, and takes the ratio between the average value of the brightness of the plurality of second reference spots and the average value of the brightness of the plurality of first reference spots As a preset ratio.
在后续的深度数据计算中,处理器200首先计算出每个测量斑点的亮度。随后,处理器200计算每个测量斑点与预设亮度之间的实际比值,并将实际比值大于或等于预设比值的测量斑点归类为第一测量斑点,将实际比值小于预设比值的测量斑点归类为第二测量斑点,从而区分出第一测量斑点和第二测量斑点。In the subsequent depth data calculation, the processor 200 first calculates the brightness of each measurement spot. Subsequently, the processor 200 calculates the actual ratio between each measurement spot and the preset brightness, and classifies the measurement spots whose actual ratio is greater than or equal to the preset ratio as the first measurement spot, and measures the actual ratio less than the preset ratio The spots are classified as second measurement spots, thereby distinguishing the first measurement spots from the second measurement spots.
处理器200区分出第一测量斑点和第二测量斑点后,由于第二参考图像中的第一参考斑点和第二参考斑点也已经被区分出,则处理器200即可利用散斑图像和第二参考图像计算出深度数据。具体地,处理器200首先计算第一测量斑点相对于第一参考斑点的偏移量、以及第二测量斑点相对于第二参考斑点的偏移量。随后,处理器200基于多个偏移量计算出多个深度数据,多个深度数据即可构成一幅深度图像。After the processor 200 distinguishes the first measurement spot and the second measurement spot, since the first reference spot and the second reference spot in the second reference image have also been distinguished, the processor 200 can use the speckle image and the second measurement spot. Two reference images calculate depth data. Specifically, the processor 200 first calculates the offset of the first measurement spot relative to the first reference spot, and the offset of the second measurement spot relative to the second reference spot. Subsequently, the processor 200 calculates multiple depth data based on multiple offsets, and the multiple depth data can constitute a depth image.
与第一种计算方式相比,第二种计算方式对第一测量斑点和第二测量斑点进行区分,对第一参考斑点和第二参考斑点进行区分,可以基于更为准确的第一测量斑点与第一参考斑点的对应关系、以及第二测量斑点与第二参考斑点的对应关系计算得到更为准确的偏移量,进一步得到较为准确的深度数据,提升获取的深度图像的精度。Compared with the first calculation method, the second calculation method distinguishes between the first measurement spot and the second measurement spot, and distinguishes between the first reference spot and the second reference spot, which can be based on the more accurate first measurement spot The corresponding relationship with the first reference spot and the corresponding relationship between the second measurement spot and the second reference spot are calculated to obtain a more accurate offset, further obtain more accurate depth data, and improve the accuracy of the acquired depth image.
在某些实施方式中,预设亮度和预设比值由场景的环境亮度以及结构光投射器21的发光功率决定。如此,可以提升第一测量斑点和第二测量斑点的区分的准确性。In some embodiments, the preset brightness and the preset ratio are determined by the ambient brightness of the scene and the luminous power of the structured light projector 21. In this way, the accuracy of the distinction between the first measurement spot and the second measurement spot can be improved.
综上,本申请实施方式的图像获取方法中,结构光摄像头22拍摄的散斑图像中的测量斑点是直接借助显示屏10的衍射作用形成的,处理器200可以基于这些测量斑点来计算深度图像。光学元件214补偿显示屏10衍射的结构光的亮度均匀性有利于提升深度图像的获取精度。In summary, in the image acquisition method of the embodiment of the present application, the measurement spots in the speckle image captured by the structured light camera 22 are directly formed by the diffraction effect of the display screen 10, and the processor 200 can calculate the depth image based on these measurement spots . The optical element 214 compensates the brightness uniformity of the structured light diffracted by the display screen 10, which is beneficial to improve the accuracy of acquiring the depth image.
在本说明书的描述中,参考术语“一个实施例”、“一些实施例”、“示例”、“具体示例”、或“一些示例”等的描述意指结合该实施例或示例描述的具体特征、结构、材料或者特点包含于本申请的至少一个实施例或示例中。在本说明书中,对上述术语的示意性表述不必须针对的是相同的实施例或示例。而且,描述的具体特征、结构、材料或者特点可以在任一个或多个实施例或示例中以合适的方式结合。此外,在不相互矛盾的情况下,本领域的技术人员可以将本说明书中描述的不同实施例或示例以及不同实施例或示例的特征进行结合和组合。In the description of this specification, the description referring to the terms "one embodiment", "some embodiments", "examples", "specific examples", or "some examples" means specific features described in conjunction with the embodiment or examples , Structure, material or characteristic is included in at least one embodiment or example of the present application. In this specification, the schematic representation of the above terms does not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in any one or more embodiments or examples. In addition, without contradicting each other, those skilled in the art may combine and combine different embodiments or examples and features of the different embodiments or examples described in this specification.
此外,术语“第一”、“第二”仅用于描述目的,而不能理解为指示或暗示相对重要性或者隐含指明所指示的技术特征的数量。由此,限定有“第一”、“第二”的特征可以明示或者隐含地包括至少一个该特征。在本申请的描述中,“多个”的含义是至少两个,例如两个,三个等,除非另有明确具体的限定。In addition, the terms “first” and “second” are used for description purposes only, and cannot be understood as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, the features defined with "first" and "second" may include at least one of the features either explicitly or implicitly. In the description of this application, the meaning of "plurality" is at least two, such as two, three, etc., unless otherwise specifically limited.
尽管上面已经示出和描述了本申请的实施例,可以理解的是,上述实施例是示例性的,不能理解为对本申请的限制,本领域的普通技术人员在本申请的范围内可以对上述实施例进行变化、修改、替换和变型。Although the embodiments of the present application have been shown and described above, it can be understood that the above-mentioned embodiments are exemplary and cannot be construed as limitations to the present application. Those of ordinary skill in the art can The embodiments are changed, modified, replaced, and modified.

Claims (20)

  1. 一种电子装置,其特征在于,包括:An electronic device, characterized in that it includes:
    显示屏,所述显示屏包括显示区,所述显示区形成有相背的正面及背面,所述正面用于显示影像;及A display screen, the display screen including a display area formed with opposite front and back surfaces, the front surface being used to display images; and
    结构光组件,所述结构光组件包括结构光投射器,所述结构光投射器设置在所述显示屏的所述背面所在的一侧,所述结构光投射器用于发射穿过所述显示区的结构光。A structured light assembly, the structured light assembly includes a structured light projector, the structured light projector is disposed on a side of the display screen where the back side is located, and the structured light projector is used to emit through the display area Structured light.
  2. 根据权利要求1所述的电子装置,其特征在于,所述结构光组件还包括结构光摄像头,所述结构光摄像头设置在所述显示屏的所述背面所在的一侧,所述结构光摄像头用于接收穿过所述显示区的被调制后的结构光。The electronic device according to claim 1, wherein the structured light component further comprises a structured light camera, the structured light camera is disposed on a side of the display screen where the back surface is located, and the structured light camera It is used to receive the modulated structured light passing through the display area.
  3. 根据权利要求1所述的电子装置,其特征在于,所述显示屏形成有贯穿所述正面及所述背面的通槽,所述结构光组件还包括结构光摄像头,所述结构光摄像头设置在所述显示屏的所述背面所在的一侧,所述结构光摄像头用于接收穿过所述通槽的被调制后的结构光。The electronic device according to claim 1, wherein the display screen is formed with a through slot penetrating the front surface and the back surface, and the structured light assembly further includes a structured light camera, the structured light camera is disposed at On the side where the back surface of the display screen is located, the structured light camera is used to receive modulated structured light passing through the through slot.
  4. 根据权利要求3所述的电子装置,其特征在于,所述通槽包括形成在所述显示屏的边缘上的缺口;及/或The electronic device according to claim 3, wherein the through slot includes a notch formed on an edge of the display screen; and / or
    所述通槽包括与所述显示屏的边缘间隔的通孔。The through slot includes a through hole spaced from an edge of the display screen.
  5. 根据权利要求4所述的电子装置,其特征在于,所述显示屏的边缘包括上边缘、下边缘、左边缘及右边缘中的任意一个或多个。The electronic device according to claim 4, wherein the edge of the display screen includes any one or more of an upper edge, a lower edge, a left edge, and a right edge.
  6. 根据权利要求3所述的电子装置,其特征在于,所述结构光组件还包括泛光灯,所述泛光灯与所述结构光摄像头与同一个所述通槽对准。The electronic device according to claim 3, wherein the structured light assembly further comprises a floodlight, and the floodlight and the structured light camera are aligned with the same through slot.
  7. 根据权利要求3所述的电子装置,其特征在于,所述电子装置还包括盖板,所述盖板设置在所述显示屏的所述正面所在的一侧,所述盖板的与所述通槽对应的区域上设置有红外透过层。The electronic device according to claim 3, characterized in that the electronic device further comprises a cover plate, the cover plate is disposed on a side of the display screen where the front side is located, and the cover plate and the An infrared transmission layer is provided on the area corresponding to the through slot.
  8. 根据权利要求1所述的电子装置,其特征在于,所述显示屏的与所述结构光投射器对应的区域形成有红外增透膜;及/或The electronic device according to claim 1, wherein an infrared anti-reflection coating is formed in an area of the display screen corresponding to the structured light projector; and / or
    所述显示屏的与所述结构光投射器对应的区域形成有红外透过层。An infrared transmission layer is formed in an area of the display screen corresponding to the structured light projector.
  9. 根据权利要求1所述的电子装置,其特征在于,所述电子装置还包括盖板,所述盖板设置在所述显示屏的正面所在的一侧,所述盖板的与所述结构光投射器对应的区域形成有红外增透膜。The electronic device according to claim 1, characterized in that the electronic device further comprises a cover plate, the cover plate is disposed on a side of the front side of the display screen, and the structure of the cover plate and the light An infrared anti-reflection coating is formed in the area corresponding to the projector.
  10. 根据权利要求9所述的电子装置,其特征在于,所述显示屏形成有贯穿所述正面及所述背面的通槽,所述电子装置还包括可见光摄像头,所述可见光摄像头与所述通槽对准设置,所述盖板上与所述通槽对应的区域形成有可见光增透膜、及/或红外截止膜。The electronic device according to claim 9, wherein the display screen is formed with a through-groove penetrating the front surface and the back surface, the electronic device further includes a visible light camera, the visible light camera and the through groove Alignment is set, and the region corresponding to the through groove on the cover plate is formed with a visible light antireflection film and / or an infrared cutoff film.
  11. 根据权利要求1至9任意一项所述的电子装置,其特征在于,所述结构光组件还包括泛光灯,所述泛光灯设置在所述显示屏的所述背面所在的一侧,所述泛光灯用于发射穿过所述显示区的补充光线。The electronic device according to any one of claims 1 to 9, wherein the structured light assembly further comprises a floodlight, and the floodlight is provided on a side of the display screen where the back surface is located, The floodlight is used to emit supplementary light passing through the display area.
  12. 根据权利要求1或2所述的电子装置,其特征在于,所述显示屏形成有贯穿所述正面及所述背面的通槽,所述结构光组件还包括泛光灯,所述泛光灯设置在所述显示屏的所述背面所在的一侧,所述泛光灯用于发射穿过所述通槽的补充光线。The electronic device according to claim 1 or 2, wherein the display screen is formed with a through-groove penetrating through the front surface and the back surface, and the structured light assembly further includes a floodlight, the floodlight Set on the side where the back side of the display screen is located, the floodlight is used to emit supplementary light passing through the through slot.
  13. 根据权利要求1至9任意一项所述的电子装置,其特征在于,所述显示区包括第一子显示区及第二子显示区,所述结构光投射器发射的结构光穿过所述第一子显示区,所述第一子显示区的像素密度小于所述第二子显示区的像素密度。The electronic device according to any one of claims 1 to 9, wherein the display area includes a first sub-display area and a second sub-display area, and the structured light emitted by the structured light projector passes through the In the first sub-display area, the pixel density of the first sub-display area is less than the pixel density of the second sub-display area.
  14. 根据权利要求13所述的电子装置,其特征在于,所述第一子显示区用于显示电子装置的状态图标。The electronic device according to claim 13, wherein the first sub-display area is used to display a status icon of the electronic device.
  15. 根据权利要求13所述的电子装置,其特征在于,所述第一子显示区位于所述显示区的靠近边缘的位置,所述第二子显示区位于所述显示区的中间位置。The electronic device of claim 13, wherein the first sub-display area is located near the edge of the display area, and the second sub-display area is located in the middle of the display area.
  16. 根据权利要求1至9任意一项所述的电子装置,其特征在于,所述显示区包括第一子显示区及第二子显示区,所述结构光投射器发射的结构光穿过所述第一子显示区,所述第一子显示区与所述第二子显示区能够被独立控制并以不同的显示状态显示。The electronic device according to any one of claims 1 to 9, wherein the display area includes a first sub-display area and a second sub-display area, and the structured light emitted by the structured light projector passes through the The first sub-display area, the first sub-display area and the second sub-display area can be independently controlled and displayed in different display states.
  17. 根据权利要求16所述的电子装置,其特征在于,所述不同的显示状态包括点亮或熄灭、以不同的亮度显示和以不同的刷新频率显示中的一种或多种。The electronic device according to claim 16, wherein the different display states include one or more of turning on or off, displaying with different brightness, and displaying with different refresh frequencies.
  18. 根据权利要求16所述的电子装置,其特征在于,所述结构光投射器在发射结构光时,所述第一子显示区熄灭;或The electronic device according to claim 16, wherein when the structured light projector emits structured light, the first sub-display area is extinguished; or
    所述结构光投射器在发射结构光时,调低所述第一子显示区的显示亮度;或When the structured light projector emits structured light, the display brightness of the first sub-display area is reduced; or
    所述结构光投射器在发射结构光时,调节所述第一子显示区的刷新频率以使所述第一子显示区的开启时间与所述结构光投射器的开启时间错开。When the structured light projector emits structured light, the refresh frequency of the first sub-display area is adjusted so that the turn-on time of the first sub-display area is staggered from the turn-on time of the structured light projector.
  19. 根据权利要求16所述的电子装置,其特征在于,所述结构光投射器未启用时,所述第一子显示区和所述第二子显示区均开启,并以相同的刷新频率显示。The electronic device according to claim 16, wherein when the structured light projector is not activated, both the first sub-display area and the second sub-display area are turned on and displayed at the same refresh frequency.
  20. 根据权利要求1至9任意一项所述的电子装置,其特征在于,所述显示屏为液晶显示屏、或Micro LED显示屏、或OLED显示屏。The electronic device according to any one of claims 1 to 9, wherein the display screen is a liquid crystal display screen, or a Micro LED display screen, or an OLED display screen.
PCT/CN2019/102735 2018-10-31 2019-08-27 Electronic device WO2020088063A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201811287335.0A CN109067951A (en) 2018-10-31 2018-10-31 Electronic device
CN201811287335.0 2018-10-31

Publications (1)

Publication Number Publication Date
WO2020088063A1 true WO2020088063A1 (en) 2020-05-07

Family

ID=64789114

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2019/102735 WO2020088063A1 (en) 2018-10-31 2019-08-27 Electronic device

Country Status (2)

Country Link
CN (1) CN109067951A (en)
WO (1) WO2020088063A1 (en)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109067951A (en) * 2018-10-31 2018-12-21 Oppo广东移动通信有限公司 Electronic device
EP3952260A4 (en) * 2019-03-28 2022-05-18 Ningbo Sunny Opotech Co., Ltd. Under-display camera assembly and corresponding terminal device
CN111756879B (en) * 2019-03-28 2022-04-26 宁波舜宇光电信息有限公司 Under-screen camera shooting assembly and corresponding terminal equipment
CN110213559A (en) * 2019-05-24 2019-09-06 深圳市光鉴科技有限公司 Display device and electronic equipment with 3D camera module
CN210112060U (en) * 2019-06-21 2020-02-21 Oppo广东移动通信有限公司 Laser projection module, depth camera and electronic device

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106603772A (en) * 2017-01-26 2017-04-26 广东欧珀移动通信有限公司 Electronic device and image acquisition method
US20170245377A1 (en) * 2016-02-22 2017-08-24 Samsung Electronics Co., Ltd. Electronic device having segmental portion on housing thereof
CN107979663A (en) * 2017-11-22 2018-05-01 广东欧珀移动通信有限公司 Sensor component, display screen component and electronic equipment
CN108364967A (en) * 2017-09-30 2018-08-03 昆山国显光电有限公司 Display screen and display device
CN207946722U (en) * 2017-11-23 2018-10-09 维沃移动通信有限公司 A kind of mobile terminal
CN109067951A (en) * 2018-10-31 2018-12-21 Oppo广东移动通信有限公司 Electronic device

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10762651B2 (en) * 2016-09-30 2020-09-01 Magic Leap, Inc. Real time calibration for time-of-flight depth measurement
CN106843398B (en) * 2017-01-26 2020-08-07 Oppo广东移动通信有限公司 Electronic device
CN107330415A (en) * 2017-07-10 2017-11-07 广东欧珀移动通信有限公司 Electronic installation
CN107920142B (en) * 2017-11-22 2019-10-25 Oppo广东移动通信有限公司 Electronic device
CN107911584A (en) * 2017-11-28 2018-04-13 信利光电股份有限公司 A kind of image capture device and a kind of terminal
CN108055370A (en) * 2017-12-26 2018-05-18 广东欧珀移动通信有限公司 Electronic device

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20170245377A1 (en) * 2016-02-22 2017-08-24 Samsung Electronics Co., Ltd. Electronic device having segmental portion on housing thereof
CN106603772A (en) * 2017-01-26 2017-04-26 广东欧珀移动通信有限公司 Electronic device and image acquisition method
CN108364967A (en) * 2017-09-30 2018-08-03 昆山国显光电有限公司 Display screen and display device
CN107979663A (en) * 2017-11-22 2018-05-01 广东欧珀移动通信有限公司 Sensor component, display screen component and electronic equipment
CN207946722U (en) * 2017-11-23 2018-10-09 维沃移动通信有限公司 A kind of mobile terminal
CN109067951A (en) * 2018-10-31 2018-12-21 Oppo广东移动通信有限公司 Electronic device

Also Published As

Publication number Publication date
CN109067951A (en) 2018-12-21

Similar Documents

Publication Publication Date Title
WO2020088045A1 (en) Image acquisition method, image acquisition apparatus, structured light assembly, and electronic apparatus
WO2020088043A1 (en) Image acquisition method, image acquisition apparatus, structured light assembly and electronic apparatus
WO2020088063A1 (en) Electronic device
WO2020098344A1 (en) Electronic device
WO2020088044A1 (en) Image acquisition method, image acquisition device, structured light assembly and electronic device
CN109167905B (en) Image acquisition method, image acquisition device, structured light assembly and electronic device
CN109167903B (en) Image acquisition method, image acquisition device, structured light assembly and electronic device
CN109348011B (en) Electronic device, control method thereof and control device thereof
CN109327653B (en) Image acquisition method, image acquisition device, structured light assembly and electronic device
CN109327576B (en) Electronic device, control method thereof and control device thereof
WO2020057208A1 (en) Electronic device
CN111200672B (en) Electronic device, control method thereof and control device thereof
CN109804297B (en) Retro-reflective screen, display system and method of displaying image
WO2020098331A1 (en) Electronic device and control method therefor and control device
CN109451107B (en) Electronic device
US11506886B2 (en) Spatial image display touch device
WO2020238491A1 (en) Control method of electronic device and electronic device
CN109218482B (en) Electronic device, control method thereof and control device thereof
CN209962052U (en) Backlight module, display module and electronic equipment
CN109413238B (en) Electronic device, control method thereof and control device thereof
WO2020098330A1 (en) Electronic device, and control method and control device therefor
CN109327578B (en) Electronic device, control method thereof and control device thereof
CN209803512U (en) Backlight module, display module and electronic equipment
CN209803511U (en) Backlight module, display module and electronic equipment
CN109587295B (en) Terminal, terminal control method and terminal control device

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 19878568

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 19878568

Country of ref document: EP

Kind code of ref document: A1