Depth Image Acquisition Method, Device, Computer Equipment, Storage Medium and Product

By performing light detection and time period analysis on the terminal's image acquisition period, the available unit time is determined, which solves the problem of the depth image acquisition equipment interfering with each other in the same area, and improves the acquisition efficiency and accuracy.

CN116523992BActive Publication Date: 2025-08-01TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202210067142.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-01-20
Publication Date
2025-08-01
Estimated Expiration
2042-01-20

AI Technical Summary

Technical Problem

Existing depth image acquisition devices will interfere with each other when working in the same area at the same time, resulting in a decrease in acquisition accuracy and efficiency.

Method used

By performing light detection on the image acquisition period of the terminal, determining whether the current period is occupied, and performing light detection for the time period within the target period, determining the available unit time, and periodically performing the depth image acquisition operation.

Benefits of technology

It realizes the use of multiple depth image acquisition devices without interfering with each other in the same area, improving the acquisition efficiency and accuracy.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116523992B_ABST
    Figure CN116523992B_ABST
Patent Text Reader

Abstract

Embodiments of the present application disclose a depth image acquisition method, apparatus, computer device, storage medium, and product. Embodiments of the present application can determine the current image acquisition period of a terminal, where the image acquisition period includes a plurality of unit times. Optical detection is performed within the current image acquisition period to obtain the optical detection result of the image acquisition period. According to the optical detection result of the image acquisition period, optical detection is performed for a time period within a target image acquisition period to obtain the optical detection result of the time period. The target image acquisition period is an image acquisition period after the current image acquisition period, and the time period consists of at least one unit time. According to the optical detection result of the time period, a target unit time for the terminal to acquire a depth image is determined from the target image acquisition period. According to the target unit time and the image acquisition period, a depth image acquisition operation is periodically executed. This solution can improve the acquisition efficiency and accuracy of depth images.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of computer technology, and in particular, to a method and device for collecting depth images, a computer device, a storage medium, and a product. Background Art

[0002] A depth image refers to an image in which the distance (depth) from an image collector to each point in a scene is used as a pixel value, which directly reflects the geometric shape of the visible surface of a scene.

[0003] In the process of researching and practicing related technologies, the inventors of this application found that since the acquisition of depth images is based on an optical design of transmission and reception, when multiple depth image acquisition devices work simultaneously in the same area, there will be mutual interference between different depth image acquisition devices, resulting in the need to improve both the acquisition accuracy and efficiency of depth images. Summary of the Invention

[0004] Embodiments of this application provide a method and device for collecting depth images, a computer device, a storage medium, and a product, which can improve the acquisition efficiency and accuracy of depth images.

[0005] Embodiments of this application provide a method for collecting depth images, including:

[0006] Determine the current image acquisition cycle of the terminal, where the image acquisition cycle includes several unit times;

[0007] Perform optical detection within the current image acquisition cycle to obtain the optical detection result of the image acquisition cycle;

[0008] According to the optical detection result of the image acquisition cycle, perform optical detection on the time period within the target image acquisition cycle to obtain the optical detection result of the time period, where the target image acquisition cycle is the image acquisition cycle after the current image acquisition cycle, and the time period consists of at least one unit time;

[0009] According to the optical detection result of the time period, determine the target unit time for the terminal to collect depth images from the target image acquisition cycle;

[0010] Periodically perform depth image acquisition operations according to the target unit time and the image acquisition cycle.

[0011] Correspondingly, embodiments of this application also provide a depth image acquisition device, including:

[0012] A first determination unit, configured to determine the current image acquisition cycle of the terminal, where the image acquisition cycle includes several unit times;

[0013] A first detection unit, configured to perform optical detection during the current image acquisition period to obtain an optical detection result of the image acquisition period;

[0014] A second detection unit, configured to perform optical detection on a time period within a target image acquisition period according to the optical detection result of the image acquisition period, to obtain an optical detection result of the time period, where the target image acquisition period is an image acquisition period after the current image acquisition period, and the time period consists of at least one unit time;

[0015] A second determination unit, configured to determine a target unit time for the terminal to acquire a depth image from the target image acquisition period according to the optical detection result of the time period;

[0016] An acquisition unit, configured to periodically perform a depth image acquisition operation according to the target unit time and the image acquisition period.

[0017] In one embodiment, the second detection unit includes:

[0018] A first determination subunit, configured to determine a target image acquisition period from image acquisition periods after the current image acquisition period according to the optical detection result of the image acquisition period;

[0019] A division subunit, configured to divide the target image acquisition period into at least one time period, where the time period consists of at least one unit time;

[0020] A first detection subunit, configured to perform optical detection on the time period to obtain an optical detection result of the time period.

[0021] In one embodiment, the second determination unit includes:

[0022] A second determination subunit, configured to determine an idle time interval from the time periods within the target image acquisition period according to the optical detection result of the time period, where the idle time interval is a time interval in the time period where no light is detected, and the time interval consists of at least one unit time;

[0023] A first selection subunit, configured to select a target idle time interval for the terminal to acquire a depth image from the idle time interval;

[0024] A third determination subunit, configured to determine a target unit time for the terminal to acquire a depth image from the target idle time interval.

[0025] In one embodiment, the second determination subunit is configured to:

[0026] When the light detection result during the time period is that light is detected, perform time division on the time period in the target image acquisition cycle from at least one division dimension to obtain divided time intervals; perform light detection on the time intervals to obtain the light detection results of the time intervals; determine idle time intervals from the time intervals according to the light detection results of the time intervals.

[0027] In one embodiment, the second determination subunit is configured to:

[0028] When the light detection result during the time period is that no light is detected, determine the time period as an idle time period, and select an idle time interval from the idle time period.

[0029] In one embodiment, the third determination subunit is configured to:

[0030] When the light detection result of the image acquisition cycle is that light is detected, select a candidate unit time for the terminal to acquire a depth image from the target idle time intervals; perform light detection on the candidate unit time to obtain the light detection result of the candidate unit time; determine the target unit time for the terminal to acquire a depth image from the target idle time intervals within the target image acquisition cycle according to the light detection result of the candidate unit time.

[0031] In one embodiment, the third determination subunit is specifically configured to:

[0032] Perform light detection on the candidate unit time at least once to obtain the light detection results of each time of the candidate unit time; determine the light detection result of the candidate unit time according to the light detection results of each time of the candidate unit time.

[0033] In one embodiment, the third determination subunit is configured to:

[0034] When the light detection result of the image acquisition cycle is that no light is detected, select the target unit time for the terminal to acquire a depth image from the target idle time intervals.

[0035] In one embodiment, the terminal includes a light receiving module; the first detection unit includes:

[0036] A second detection subunit, configured to trigger the light receiving module to perform light detection during the current image acquisition cycle to obtain the light detection result of the light receiving module;

[0037] A fourth determination subunit, configured to determine the light detection result of the image acquisition cycle of the terminal according to the light detection result of the light receiving module.

[0038] In one embodiment, the terminal further includes a data reading module; the fourth determining subunit is configured to:

[0039] Read the light detection result of the light receiving module through the data reading module; and determine the light detection result of the image acquisition period of the terminal according to the read result.

[0040] Correspondingly, an embodiment of the present application further provides a storage medium, on which a computer program is stored, wherein when the computer program is executed by a processor, the steps of the depth image acquisition method shown in the embodiment of the present application are implemented.

[0041] Correspondingly, an embodiment of the present application further provides a computer device, including a memory, a processor, and a computer program stored on the memory and executable on the processor, wherein when the processor executes the computer program, the steps of the depth image acquisition method shown in the embodiment of the present application are implemented.

[0042] Correspondingly, an embodiment of the present application further provides a computer program product, including a computer program / instructions, wherein when the computer program / instructions are executed by a processor, the steps of the depth image acquisition method shown in the embodiment of the present application are implemented.

[0043] The embodiment of the present application can determine the current image acquisition period of the terminal, where the image acquisition period includes a plurality of unit times; perform light detection within the current image acquisition period to obtain the light detection result of the image acquisition period; according to the light detection result of the image acquisition period, perform light detection on the time period within the target image acquisition period to obtain the light detection result of the time period, where the target image acquisition period is the image acquisition period after the current image acquisition period, and the time period consists of at least one unit time; according to the light detection result of the time period, determine the target unit time for the terminal to acquire the depth image from the target image acquisition period; and periodically execute the depth image acquisition operation according to the target unit time and the image acquisition period.

[0044] The depth image acquisition method proposed by this solution can be applied to various depth image acquisition devices for depth image acquisition of the same area, and can effectively solve the accuracy and efficiency of multi-device depth image acquisition of the same area. Specifically, this solution performs optical detection on the current image acquisition cycle of the terminal to obtain the optical detection result of the image acquisition cycle. In this way, it can be determined whether the current image acquisition cycle is occupied by other devices, that is, whether the current image acquisition cycle is available for this terminal. Further, the terminal can perform optical detection on the time period within the target image acquisition cycle according to the optical detection result of the image acquisition cycle, and obtain the optical detection result of the time period. In this way, the terminal can determine the available time period within the target image acquisition cycle. Further, the terminal can determine the target unit time from the target image acquisition cycle according to the optical detection result of the time period, that is, determine the unit time available for the terminal to perform depth image acquisition. After determining the target unit time, the terminal can apply for using the target unit time according to the target unit time and the image acquisition cycle, and periodically perform the depth image acquisition operation.

[0045] Therefore, by applying the depth image acquisition method proposed by this solution, when multiple depth image acquisition devices perform depth image acquisition for the same local area, multiple depth image acquisition devices can be segmented and used at staggered times in the time domain, so as to realize the common use of multiple depth image acquisition devices in the same area without interference, thereby improving the acquisition efficiency and accuracy of depth images. Brief Description of the Drawings

[0046] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following will briefly introduce the drawings required for description in the embodiments. Obviously, the following drawings are only some embodiments of the present application. For those skilled in the art, without creative efforts, other drawings can be obtained according to these drawings.

[0047] Figure 1 It is a schematic diagram of the scenario of the depth image acquisition method provided by the embodiment of the present application;

[0048] Figure 2 It is another schematic diagram of the scenario of the depth image acquisition method provided by the embodiment of the present application;

[0049] Figure 3 It is a flowchart of the depth image acquisition method provided by the embodiment of the present application;

[0050] Figure 4 It is a schematic diagram of the definition of the unit time of the depth image acquisition method provided by the embodiment of the present application;

[0051] Figure 5It is a schematic diagram of light detection for the depth image acquisition method provided by an embodiment of the present application;

[0052] Figure 6 It is another schematic diagram of light detection for the depth image acquisition method provided by an embodiment of the present application;

[0053] Figure 7 It is another schematic diagram of light detection for the depth image acquisition method provided by an embodiment of the present application;

[0054] Figure 8 It is another schematic diagram of light detection for the depth image acquisition method provided by an embodiment of the present application;

[0055] Figure 9 It is another schematic diagram of light detection for the depth image acquisition method provided by an embodiment of the present application;

[0056] Figure 10 It is another schematic diagram of light detection for the depth image acquisition method provided by an embodiment of the present application;

[0057] Figure 11 It is a schematic diagram of depth image acquisition for the depth image acquisition method provided by an embodiment of the present application;

[0058] Figure 12 It is another schematic flow diagram for the depth image acquisition method provided by an embodiment of the present application;

[0059] Figure 13 It is another schematic flow diagram for the depth image acquisition method provided by an embodiment of the present application;

[0060] Figure 14 It is another schematic flow diagram for the depth image acquisition method provided by an embodiment of the present application;

[0061] Figure 15 It is a schematic structural diagram of the depth image acquisition device provided by an embodiment of the present application;

[0062] Figure 16 It is another schematic structural diagram of the depth image acquisition device provided by an embodiment of the present application;

[0063] Figure 17 It is another schematic structural diagram of the depth image acquisition device provided by an embodiment of the present application;

[0064] Figure 18 It is another schematic structural diagram of the depth image acquisition device provided by an embodiment of the present application;

[0065] Figure 19 It is a schematic structural diagram of the computer device provided by an embodiment of the present application. Detailed implementation manners

[0066] The following will be combined with the drawings in the embodiments of this application to clearly and completely describe the technical solutions in the embodiments of this application. Obviously, the embodiments described are only part of the embodiments of this application, not all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by those skilled in the art without making creative efforts are within the scope of protection of this application.

[0067] The embodiments of the present application provide a depth image acquisition method, device, computer equipment, storage medium and product. Specifically, the embodiments of the present application provide a depth image acquisition device suitable for computer equipment. Among them, the computer equipment can be a terminal or server and other equipment. Specifically, the terminal can be a smart phone, a tablet computer, a laptop computer, a desktop computer, a smart speaker, a smart watch, a facial recognition device, a facial payment device, an augmented reality (AR) device, etc., but is not limited to this. The server can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, CDN, and big data and artificial intelligence platforms. In actual applications, the terminal and the server can be directly or indirectly connected via wired or wireless communication, and this application does not limit this.

[0068] The embodiment of the present application will take a depth image acquisition device as an example to introduce the depth image acquisition method.

[0069] There are many ways to acquire a depth image. For example, a depth map can be obtained based on speckle structured light. Specifically, an infrared sensor can collect speckle structured light infrared light, and a depth unit can analyze the speckle to obtain a depth map. In 3D computer graphics and computer vision, a depth map is an image or image channel that contains information about the distance between the surface of the scene object and the viewpoint. Each pixel in the depth map represents the vertical distance between the depth camera plane and the plane of the photographed object, usually represented by 16 bits in millimeters. In facial payment, depth maps can be used for liveness detection and auxiliary comparison recognition.

[0070] Speckle structured light is a dotted light array arranged in a certain structure pattern projected by an infrared speckle projector. A speckle structured light imaging system can be composed of an infrared laser projector and an infrared sensor. For example, see Figure 1 These dot-matrix lights are projected onto the surface of the object. After imaging by the infrared sensor, the 3D coordinate information of the object's surface can be restored according to the principle of triangulation, thereby obtaining a depth map.

[0071] Since the speckle structured light depth map is based on the optical design of emission and reception, when multiple depth cameras work simultaneously in the same area, they will interfere with each other. For example, scenarios where multiple depth maps are used in the same area can include: scenarios where face-scanning devices are placed densely, scenarios where multiple AR devices play interactive games, and so on.

[0072] Therefore, for scenarios where multiple depth maps are used in the same area, the depth image acquisition method described in this application can be applied to efficiently acquire depth images and avoid the problem of interference between different depth image acquisition systems.

[0073] Specifically, referring to Figure 2 , in Figure 2 In the application scenario shown, there can be multiple terminals waiting to acquire depth images of the user. Taking the terminal shown in 10 as an example, specifically, terminal 10 can determine the current image acquisition cycle of the terminal, where the image acquisition cycle includes several unit times; perform optical detection during the current image acquisition cycle to obtain the optical detection result of the image acquisition cycle; according to the optical detection result of the image acquisition cycle, perform optical detection on the time period within the target image acquisition cycle to obtain the optical detection result of the time period, where the target image acquisition cycle is the image acquisition cycle after the current image acquisition cycle, and the time period consists of at least one unit time; according to the optical detection result of the time period, determine the target unit time for terminal 10 to acquire the depth image from the target image acquisition cycle; in this way, terminal 10 can periodically execute the depth image acquisition operation according to the target unit time and the image acquisition cycle.

[0074] The following will be described in detail respectively. It should be noted that the description order of the following embodiments does not limit the preferred order of the embodiments.

[0075] A depth image acquisition method provided by an embodiment of this application can be executed by a terminal or jointly executed by a server and a terminal; in the embodiment of this application, the depth image acquisition method is taken as an example to be executed by a terminal. Specifically, the terminal can be a smart phone, a tablet computer, a notebook computer, a desktop computer, a smart speaker, a smart watch, a face recognition device, a face payment device, an AR device, etc., but is not limited thereto. In practical applications, the terminal and the server can be directly or indirectly connected through wired or wireless communication methods, and this application does not make any restrictions here.

[0076] In the embodiment of this application, this method can be executed by a depth image acquisition device integrated in the terminal. As Figure 3 described, the specific process of this depth image acquisition method can be as follows:

[0077] 101. Determine a current image acquisition cycle of a terminal, where the image acquisition cycle includes a number of unit times.

[0078] The image acquisition cycle refers to the period during which a terminal acquires depth images. Specifically, if a set of events or phenomena repeats in the same order, the time or space interval between them is called a cycle. For example, the image acquisition cycle can be 1 second (s), 100 milliseconds (ms), and so on.

[0079] The unit time in the image acquisition cycle refers to the time required to complete the depth image acquisition operation in the image acquisition cycle. For example, the unit time in the image acquisition cycle can be 1ms; for another example, the unit time in the image acquisition cycle can be 2ms; and so on.

[0080] As an example, the image acquisition cycle of the terminal can be specifically 1s, and the unit time in the image acquisition cycle can be specifically 1ms. Therefore, in actual applications, each 1s is an image acquisition cycle, and each image acquisition cycle can have 1000 unit times. The terminal can determine the unit time when the terminal performs depth image acquisition from the image acquisition cycle. For example, if it is determined that the terminal uses the first unit time in the image acquisition cycle as the time period for the terminal to acquire depth images, the terminal can use the first unit time in each image acquisition cycle to acquire depth images, that is, the terminal can acquire depth images in the first 1ms of each 1s.

[0081] In the present application, there are multiple ways to determine the current image acquisition cycle of a terminal. For example, the image acquisition cycle of the terminal and the unit time in the image acquisition cycle can be set in advance. In this way, the terminal can determine the current image acquisition cycle and the unit time in the image acquisition cycle. For another example, the terminal can receive data sent by a server or other terminal, and the data specifically indicates the current image acquisition cycle of the terminal. Therefore, the terminal can determine the current image acquisition cycle and the unit time in the image acquisition cycle by parsing the data.

[0082] In actual applications, before determining the current image acquisition cycle of the terminal, the image acquisition cycle of the image and the unit time of the terminal in the image acquisition cycle may be set first.

[0083] As an example, depth images can be acquired based on speckle structured light, and the emission time of the speckle structured light laser can be defined as 1 ms. The depth image acquisition system based on speckle structured light can be a system with an emission structure. Among them, the emitter can be a laser capable of emitting speckle structured light with a wavelength of 94 nanometers, and this laser can be driven by a current-driven IC; the receiver can be an infrared sensor equipped with a 94-nanometer wavelength filter. For example, when the emission time is defined as 1 ms, specifically, the current-driven IC can drive the speckle structured light laser to work at the rated current for 1 ms, so that the emitter can emit speckle structured light within this 1 ms. At the same moment, the infrared sensor equipped with a 94-nanometer wavelength infrared light filter is exposed for 1 ms, that is, the receiver is exposed. In this way, the unit time in the image acquisition cycle can be defined as 1 ms. Refer to Figure 4 , Figure 4 where the emitter emits speckle structured light within 0 to 1 ms, and at the same time, within this 1 ms, the receiver is also exposed, Figure 4 and the exposure result in specifically indicates that the corresponding infrared image has speckle laser points. In practical applications, the exposure result can also include indicating that the corresponding infrared image does not have speckle laser points. In addition, the image acquisition cycle can be set as needed. For example, the image acquisition cycle can be set to 1 s, and the unit time therein can be set to 1 ms.

[0084] In an embodiment, it can be as shown in Figure 13 301 in , the emission time of the speckle structured light laser is defined as 1 ms, and the image acquisition cycle is defined as 1 s. In this way, it can be determined that the current image acquisition cycle of the terminal is 1 s, where this image acquisition cycle includes several unit times, and each unit time can specifically be 1 ms.

[0085] 102. Perform optical detection within the current image acquisition cycle to obtain the optical detection result of the image acquisition cycle.

[0086] Among them, optical detection is used to detect whether the current time domain has been occupied. Specifically, it can be determined whether the current time domain has been occupied by other devices for depth image acquisition through optical detection. Therefore, in this application, by performing optical detection within the current image acquisition cycle of the terminal, it can be determined whether the current image acquisition cycle has been used by other devices.

[0087] There can be multiple ways to perform optical detection. Since the acquisition of depth images can be achieved based on the emission and reception of light, for example, based on the emission and reception of speckle structured light. Therefore, it is possible to only perform optical reception in the current time domain and determine the optical detection result of the current time domain based on the reception result. For example, the terminal can include an optical reception module. In this case, the terminal can trigger the optical reception module to perform optical reception in the current time domain, for example, in the current image acquisition cycle, to determine the optical detection result of the current time domain based on the reception result. Specifically, the step "perform optical detection within the current image acquisition cycle to obtain the optical detection result of the image acquisition cycle" can include:

[0088] Trigger the optical reception module to perform optical detection within the current image acquisition cycle to obtain the optical detection result of the optical reception module;

[0089] Determine the optical detection result of the terminal's image acquisition cycle based on the optical detection result of the optical reception module.

[0090] Among them, the optical reception module refers to a module that can detect the light required for acquiring depth images. For example, the optical reception module can receive the light required for acquiring depth images through a filter. For instance, if the filter can transmit infrared light with a wavelength of 94 nanometers, then correspondingly, the optical reception module can receive the signal of infrared light with a wavelength of 94 nanometers.

[0091] For example, depth image acquisition can be based on speckle structured light. Specifically, the depth image acquisition system based on speckle structured light can be a system with an emission structure. Among them, the optical reception module can specifically be a receiver integrated in the depth image acquisition system. For example, the receiver can specifically be an infrared sensor equipped with a filter with a wavelength of 94 nanometers.

[0092] Therefore, performing optical detection within the current image acquisition cycle can be achieved by triggering the optical reception module to perform optical detection within the current image acquisition cycle. Specifically, the optical receiver can be triggered to perform exposure within the current image acquisition cycle, and the optical detection result of the terminal's image acquisition cycle can be determined based on the exposure result of the optical receiver within the current image acquisition cycle. For example, if the optical detection result of the optical reception module is that light is detected, such as detecting speckle structured light, it can be determined that the optical detection result of the current image acquisition cycle is that this image acquisition cycle has been occupied by other devices; otherwise, if the optical detection result of the optical reception module is that no light is detected, such as not detecting speckle structured light, it can be determined that the optical detection result of the current image acquisition cycle is that this image acquisition cycle has not been occupied by other devices.

[0093] As an example, light detection can be performed on astigmatic structured light, the image acquisition period is 1 s, and the light receiving module is specifically integrated into the terminal in the form of a receiver. For example, taking the form of an infrared sensor integrated into the terminal as an example. Specifically, the infrared camera in the terminal can be equipped with an infrared light filter with a wavelength of 94 nm. That is to say, this filter can only transmit infrared light with a wavelength of 94 nm and will refract all other wavelength light rays. Therefore, the infrared camera will only receive the signal of infrared light with a wavelength of 94 nm. When performing light detection during the current image acquisition period, refer to Figure 5 , the infrared camera can be used to detect for 1 s first, that is, the infrared camera is exposed for 1 s. If the exposure result indicates that there are no speckle laser points, it is determined that the current time domain is not occupied, that is, the current image acquisition period is not occupied by other devices; otherwise, refer to Figure 6 , if the exposure result indicates that there are speckle laser points, it is determined that the current time domain has been occupied, that is, the current image acquisition period has been occupied by other devices.

[0094] In one embodiment, a data reading module can be integrated into the terminal to read the light detection result of the light receiver. For example, to read the exposure result of the infrared camera to determine the light detection result of the image acquisition period of the terminal. Specifically, the step of "determining the light detection result of the image acquisition period of the terminal according to the light detection result of the light receiving module" can include:

[0095] Read the light detection result of the light receiving module through the data reading module;

[0096] Determine the light detection result of the image acquisition period of the terminal according to the reading result.

[0097] Among them, the data reading module is a module for reading the light detection result of the light receiving module. For example, the data reading module can generate an image frame as the reading result according to the light detection result of the light receiving module; another example is that the data reading module can generate result data indicating the light detection result as the reading result according to the light detection result of the light receiving module; and so on.

[0098] In one embodiment, taking the light detection of astigmatic structured light and an image acquisition period of 1 s as an example, specifically, after the light receiving module performs light detection within the current image acquisition period, for example, after the infrared camera is exposed for 1 s, the data reading module can read the exposure data of the infrared camera and output an infrared image frame, so as to determine the light detection result of the current image acquisition period by analyzing whether there are speckle laser points in this image frame. Specifically, if no speckle laser points are found in this infrared image frame, it means that the current time domain is not being used, that is, the current image acquisition period is not occupied by other devices; otherwise, if speckle laser points are found in this image frame, it means that the current time domain has been used, that is, the current image acquisition period has been occupied by other devices.

[0099] In another embodiment, taking the light detection of astigmatic structured light as an example, specifically, after the light receiving module performs light detection within the current image acquisition period, the data reading module can read the light detection result of the light receiving module and generate result data indicating the light detection result as the reading result. For example, if the result data indicates that the light receiving module detects astigmatic structured light within this image acquisition period, it can be determined that the current image acquisition period has been occupied by other devices; otherwise, if the result data indicates that the light receiving module does not detect astigmatic structured light within this image acquisition period, it can be determined that the current image acquisition period is not occupied by other devices.

[0100] 103. According to the light detection result of the image acquisition period, perform light detection on the time period within the target image acquisition period to obtain the light detection result of the time period, where the target image acquisition period is the image acquisition period after the current image acquisition period, and the time period consists of at least one unit time.

[0101] Among them, the target image acquisition period refers to the image acquisition period after the current image acquisition period. For example, taking the image acquisition period set to 1 s as an example, see Figure 5 and Figure 6 , if the current image acquisition period in step 102 is the image acquisition period shown from the 0th to the 1st second on the time axis, the target image acquisition period can be the image acquisition period after the first second on the time axis. Therefore, the target image acquisition period can include at least one image acquisition period after the current image acquisition period.

[0102] Among them, a time period with a time length between the unit time and the target image acquisition period can be called a time period within the target image acquisition period. Therefore, this time period consists of at least one unit time. For example, taking the time length of the image acquisition period set to 1 s, the time length of the target image acquisition period to 10 s, and the time length of the unit time within each image acquisition period set to 1 ms as an example, the time period within the target image acquisition period can be a time period located within the target image acquisition period and with any time length between 1 ms and 10 s. For example, the time period within the target image acquisition period can be any image acquisition period within the target image acquisition period, that is, the time length of this time period is specifically 1 s, and this time period consists of 1000 unit times; another example is that the time period within the target image acquisition period can be any unit time within any image acquisition period within the target image acquisition period, that is, the time length of this time period is specifically 1 ms, and this time period consists of one unit time; another example is that the time period within the target image acquisition period can be from the 101st ms to the 200th ms within any image acquisition period within the target image acquisition period, then this time period consists of 100 unit times; another example is that the time period within the target image acquisition period can be from the 101st ms to the 110th ms within any image acquisition period within the target image acquisition period, then this time period consists of 10 unit times; and so on.

[0103] In this application, considering the light detection result of the current image acquisition period of the terminal, it can include that the current image acquisition period has been used by other devices and that the current image acquisition period has not been used by other devices. If the current image acquisition period of the terminal has been used by other devices, it indicates that currently another device occupies the time domain in the image acquisition period. Therefore, this terminal needs to further determine an available time period from the target image acquisition period, and then select a unit time for the terminal to perform depth image acquisition from it; if the current image acquisition period has not been used by other devices, it indicates that currently no other device occupies any time domain in the image acquisition period. Therefore, the terminal can use the target image acquisition period as an available time period and select a unit time for acquiring the depth image from it. Specifically, the step "perform light detection on the time period within the target image acquisition period according to the light detection result of the image acquisition period to obtain the light detection result of the time period" can include:

[0104] Determine the target image acquisition period from the image acquisition periods after the current image acquisition period according to the light detection result of the image acquisition period;

[0105] Divide the target image acquisition period into at least one time period, where the time period consists of at least one unit time;

[0106] Perform optical detection for a time period to obtain the optical detection result of the time period.

[0107] It should be noted that regardless of the length of the time period, the method of performing optical detection for the time period can refer to the method of performing optical detection within the current image acquisition cycle in the foregoing steps, that is, changing the time domain to be detected from the current image acquisition cycle to the time period, and the details will not be elaborated here.

[0108] Similarly, the method of performing optical detection for a unit time can refer to the method of performing optical detection within the current image acquisition cycle in the foregoing steps, that is, changing the time domain to be detected from the current image acquisition cycle to a unit time, and the details will not be elaborated here.

[0109] Specifically, the following will give examples of the steps "Determine the target image acquisition cycle from the image acquisition cycles after the current image acquisition cycle according to the optical detection result of the image acquisition cycle; divide the target image acquisition cycle into at least one time period, where the time period consists of at least one unit time; perform optical detection for the time period to obtain the optical detection result of the time period." according to different optical detection results of the current image acquisition cycle of the terminal.

[0110] In one embodiment, if the optical detection result of the current image acquisition cycle of the terminal is specifically that the current image acquisition cycle has been used by other devices, for example Figure 6 the situation shown, it means that currently some time in the current image acquisition cycle is occupied by other devices. Therefore, the terminal needs to further determine an available time period from the subsequent image acquisition cycles, and then determine the target unit time for depth image acquisition from it. That is to say, the terminal can determine the target image acquisition cycle from the image acquisition cycles after the current image acquisition cycle, and specifically, the target image acquisition cycle can include: an image acquisition cycle for scanning, an image acquisition cycle for detection, and an image acquisition cycle for acquisition. Among them, the image acquisition cycle for scanning is for the terminal to scan the time period in the image acquisition cycle to determine an available time period, that is, a time period not used by other devices; the image acquisition cycle for detection is for the terminal to select a unit time from the available time periods for detection to determine the target unit time for the terminal to perform depth image scanning; the image acquisition cycle for acquisition is for the terminal to perform depth image acquisition within the target unit time in the image acquisition cycle.

[0111] In another embodiment, if the optical detection result of the current image acquisition cycle of the terminal is specifically that the current image acquisition cycle has not been used by other devices, for example Figure 5In the situation shown, it means that no other device is occupying any time period in the current image acquisition cycle. Therefore, the terminal only needs to further review the subsequent image acquisition cycles to improve the accuracy rate, and then select the target unit time for depth image acquisition from them. That is to say, the terminal can determine the target image acquisition cycle from the image acquisition cycles after the current image acquisition cycle, and specifically, the target image acquisition cycle can include: an image acquisition cycle for detection and an image acquisition cycle for acquisition. Among them, the image acquisition cycle for detection is intended for the terminal to select a unit time from this image acquisition cycle for detection to re-determine that the selected target unit time is not occupied; the image acquisition cycle for acquisition is intended for the terminal to perform depth image acquisition within the target unit time in this image acquisition cycle.

[0112] Further, according to the different light detection results of the current image acquisition cycle of the terminal, the target image acquisition cycle of the terminal can be divided into at least one time period, and this time period is composed of at least one unit time.

[0113] In one embodiment, if the light detection result of the current image acquisition cycle of the terminal is specifically that the current image acquisition cycle has been used by other devices, then the terminal can divide the image acquisition cycle for scanning into at least one time period, where this time period is composed of at least one unit time. As an example, if the image acquisition cycle is specifically 1 s, the unit time is specifically 1 ms, and the current image acquisition cycle of the terminal is Figure 6 the image acquisition cycle from the 0th second to the 1st second shown in it as an example, then the three image acquisition cycles from the 1st second to the 4th second can be used as the image acquisition cycles for scanning, and the image acquisition can be divided. For example, each image acquisition cycle for scanning can be divided with a granularity of 100 ms. In this way, the image acquisition cycle for scanning can be divided into 30 time periods, where the duration of each time period is 100 ms, and each time period includes 100 unit times.

[0114] In another embodiment, if the light detection result of the current image acquisition cycle of the terminal is specifically that the current image acquisition cycle is not used by other devices, then the terminal can divide the image acquisition cycle for detection into at least one time period, where this time period is composed of at least one unit time. As an example, if the image acquisition cycle is specifically 1 s, the unit time is specifically 1 ms, and the current image acquisition cycle of the terminal is Figure 5Taking the image acquisition cycle from the 0th second to the 1st second shown as an example, the image acquisition cycle from the 1st second to the 2nd second can be used as the image acquisition cycle for detection. Moreover, the image acquisition for detection can be divided. For example, the image acquisition cycle for detection can be divided with a granularity of 1 ms. In this way, the image acquisition cycle for detection can be divided into 1000 time segments. Among them, the duration of each time segment is 1 ms, and each time segment includes 1 unit time.

[0115] After dividing the target image acquisition cycle of the terminal into at least one time segment, further light detection can be performed on the time segment, and the light detection result of the time segment can be obtained correspondingly.

[0116] In one embodiment, if the light detection result of the current image acquisition cycle of the terminal is specifically that the current image acquisition cycle has been used by other devices, the terminal can divide the image acquisition cycle for scanning into at least one time segment, where each time segment is composed of at least one unit time. For example, each time segment can be composed of 100 unit times. Since the purpose of this embodiment is to divide the image acquisition cycle for scanning into at least one time segment and then perform light detection on the time segment to scan for available time segments, in this case, there are various ways to perform light detection on the time segment. For example, light detection can be performed on each time segment in the image acquisition cycle; or several time segments in the image acquisition cycle can be selected for light detection, where the selected time segments only need to satisfy the condition of covering different positions in the image acquisition cycle; or light detection can start from the first time segment in the image acquisition cycle until an available time segment (i.e., a time segment not used by other devices) is detected; and so on.

[0117] As an example, taking the image acquisition cycle as 1 s specifically, the unit time as 1 ms specifically, and the current image acquisition cycle of the terminal as Figure 6 the image acquisition cycle from the 0th second to the 1st second shown, taking the image acquisition cycle included from the 1st second to the 4th second as the image acquisition cycle for scanning, and setting the duration of the time segment as 100 ms as an example, several time segments can be selected from the image acquisition cycle for scanning for light detection, and the selected time segments satisfy the condition of covering different positions in the image acquisition cycle. Further, the light detection result of the time segment can be obtained by performing light detection on the selected time segments. For example, considering that there is a timing restriction between the execution order of the receiver and the data reading unit in practical applications, that is, the data reading unit can read relevant data only after the receiver performs light detection, and in some application scenarios, the data reading unit and the receiver cannot work simultaneously. Therefore, referring to Figure 7, the following time periods can be selected as the time periods to be subjected to light detection during the image acquisition period from the 1st second to the 4th second: the first, third, fifth, seventh, and ninth 100 ms within the 1st second to the 2nd second, and the second, fourth, sixth, eighth, and tenth 100 ms within the 2nd second to the 3rd second. In this way, the selected time periods can cover the time periods at different positions in the image acquisition period, that is, cover the first to tenth time periods in the image acquisition period. Further, light detection can be performed on the selected time periods to obtain the light detection results of each time period.

[0118] In another embodiment, if the light detection result of the current image acquisition period of the terminal is specifically that the current image acquisition period is not used by other devices, the terminal can divide the image acquisition period used for detection into at least one time period, where each time period consists of one unit time. Therefore, in this case, there are various ways for the terminal to perform light detection on the time periods. For example, one of the time periods can be randomly selected, that is, one of the unit times is randomly selected, and light detection is performed on this unit time; another example is that several time periods can be randomly selected, that is, several unit times are randomly selected, and light detection is performed on the selected unit times; another example is that light detection can be performed on all the time periods, that is, all unit times.

[0119] As an example, it can be assumed that the image acquisition period is specifically 1 s, the unit time is specifically 1 ms, and the current image acquisition period of the terminal is Figure 5 the image acquisition period from the 0th second to the 1st second shown in, and the image acquisition period from the 1st second to the second is used as the image acquisition period for detection. Taking the duration of the time period as 1 ms as an example, one unit time can be randomly selected from the image acquisition period from the 1st second to the 2nd second as the time period to be subjected to light detection, and the light detection result obtained by performing light detection on this unit time is used as the light detection result of the time period. For example, referring to Figure 8 , one unit time from the 1002 ms to the 1003 ms within the image acquisition period from the 1st second to the 2nd second can be randomly selected as the time period to be detected, and the light detection result obtained by performing light detection on this unit time is used as the light detection result of the time period.

[0120] 104. Determine the target unit time for the terminal to acquire the depth image from the target image acquisition period according to the light detection result of the time period.

[0121] Similar to the light detection results of the image acquisition period, the light detection results of a time period can indicate whether the time period has been occupied by other devices for depth image acquisition. Therefore, in this application, the target unit time can be further selected from the target image acquisition period according to the light detection results of the time period, where the target unit time is the unit time for the terminal to perform depth image acquisition.

[0122] For example, according to the light detection results of the time period, the idle time interval of the terminal can be determined from the target image acquisition period, and then the target unit time for the terminal to acquire the depth image can be determined from the idle time interval. Specifically, the step of "determining the target unit time for the terminal to acquire the depth image from the target image acquisition period according to the light detection results of the time period" may include:

[0123] Determine the idle time interval from the time periods within the target image acquisition period according to the light detection results of the time period, where the idle time interval is the time interval during which no light is detected, and the time interval consists of at least one unit time;

[0124] Select the target idle time interval for the terminal to acquire the depth image from the idle time interval;

[0125] Determine the target unit time for the terminal to acquire the depth image from the target idle time interval.

[0126] Wherein, the time interval consists of at least one unit time, and the idle time interval is the time interval during which no light is detected. Therefore, the idle time interval includes at least one unit time during which no light is detected. For example, the time period not used by other devices can be used as the idle time period, and the time interval with a time length between the unit time and the idle time period can be selected from the idle time period as the idle time interval. Specifically, the time length of the idle time interval can be equal to the time length of the unit time, or the time length of the idle time interval can be equal to the time length of the idle time period.

[0127] It should be noted that the light involved in "detecting light", "not detecting light", "light detection", etc. in this application refers to the light related to depth image acquisition, such as speckle structured light.

[0128] In the present application, the light detection results of a time period may include whether the time period has been used by other devices (in this case, the time period is not the available time period of the terminal, that is, the non-idle time period), and whether the time period has not been used by other devices (in this case, the time period may be the available time period of the terminal, that is, the idle time period). Regardless of the specific light detection results of the time period, if the terminal wants to perform depth image acquisition, it can determine the idle time interval from the image acquisition cycle, and then determine the target unit time for the terminal to acquire the depth image from the idle time interval. Therefore, similar to the light detection results of the image acquisition cycle, the following can be used as an example of the step "determining the idle time interval from the time period within the target image acquisition cycle based on the light detection results of the time period" based on different light detection results of the time period.

[0129] In one embodiment, when the light detection result for a time period in the target image acquisition cycle is no light detection, it indicates that the time period is not used by other devices. Therefore, for the terminal, the time period is an available time period for the terminal, that is, an idle time period. In this case, the terminal can select an idle time interval from all idle time periods. Specifically, the step of "determining an idle time interval from a time period in the target image acquisition cycle based on the light detection result of the time period" may include:

[0130] When the light detection result of the time period is that no light is detected, the time period is determined to be an idle time period, and an idle time interval is selected from the idle time period.

[0131] For example, if the light detection result of the terminal's current image acquisition cycle may be that light is detected, and the light detection result of the time period within the target image acquisition cycle may be that light is not detected, then the time period may be determined as an idle time period, and an idle time interval may be selected from the idle time period. That is, in this case, the length of the idle time interval is the same as the length of the idle time period. There are multiple ways to select an idle time interval from the idle time period. For example, if there is only one idle time period, then the idle time period may be determined as the idle time interval. For another example, if there are at least two idle time periods, then one of them may be selected as the idle time interval through various methods, such as random selection, selection of the first one, selection of the last one, selection according to a preset rule, etc.

[0132] As an example, the image acquisition cycle can be specifically 1s, the unit time can be specifically 1ms, and the current image acquisition cycle of the terminal is Figure 6 The image acquisition period from the 0th second to the 1st second shown in FIG, the image acquisition period from the 1st second to the 4th second included as the image acquisition period for scanning, the time period is set to 100ms, and as shown in FIG. Figure 7As shown, in the image acquisition cycle from the 1st second to the 4th second, the following time periods are selected as the time periods for optical detection: the first, third, fifth, seventh, and ninth 100 ms within the 1st second to the 2nd second, and the second, fourth, sixth, eighth, and tenth 100 ms within the 2nd second to the 3rd second, and the optical detection results of these time periods are specifically as Figure 9 shown as an example.

[0133] From Figure 9 it can be seen that the optical detection results of the following time periods indicate that these time periods are idle time periods: the time period between 1200 ms and 1300 ms, the time period between 1400 ms and 1500 ms, and the time period between 2100 ms and 2200 ms. Therefore, it can be known that in the image acquisition cycle, the 2nd, 3rd, and 5th time periods are idle time periods. Further, one can be selected from the idle time periods as the idle time interval. For example, the time period between 2100 ms and 2200 ms, that is, the second time period in the image acquisition cycle, can be used as the idle time interval.

[0134] For another example, if the optical detection result of the current image acquisition cycle of the terminal is that no light is detected, and the optical detection results of the time periods within the target image acquisition cycle are also that no light is detected, then similarly, this time period can be confirmed as an idle time period, and one idle time interval can be selected from the idle time periods. That is to say, in this case, the time length of the idle time interval is the same as the time length of the idle time period. There are various ways to select the idle time interval from the idle time periods. For example, if there is only one idle time period, then this idle time period can be confirmed as the idle time interval; for another example, if there are at least two idle time periods, then one can be selected from them as the idle time interval in various ways such as random selection, selecting the first one, selecting the last one, and selecting according to a preset rule.

[0135] As an example, it can be assumed that the image acquisition cycle is specifically 1 s, the unit time is specifically 1 ms, and the current image acquisition cycle of the terminal is Figure 5 the image acquisition cycle from the 0th second to the 1st second as shown in Figure 8 and the image acquisition cycle from the 1st second to the 2nd second is used as the image acquisition cycle for detection, and the time length of the time period is set to 1 ms. As shown in Figure 10 a unit time within the 1002 ms to 1003 ms within the image acquisition cycle from the 1st second to the 2nd second is randomly selected as the time period to be detected, and the optical detection result of this time period is as Figure 10It can be known that when the light detection result in the time period from 1002 ms to 1003 ms is that no light is detected, this time period can be determined as an idle time period, and this idle time period can be used as an idle time interval.

[0136] In one embodiment, when the light detection result in a time period of the target image acquisition cycle is that light is detected, it indicates that all time periods in the target image acquisition cycle have been used by other devices. To determine the target unit time available for the terminal to perform depth image acquisition from the image acquisition cycle, it can be implemented by referring to the method of scanning for idle time periods in the target image acquisition cycle when the light detection result in the current image acquisition cycle is that light is detected. That is, the image acquisition cycle can be divided into multiple time intervals with shorter time lengths at a finer granularity to determine the idle time interval therefrom. Specifically, the step of "determining the idle time interval from the time periods within the target image acquisition cycle according to the light detection result of the time period" may include:

[0137] When the light detection result of the time period is that light is detected, perform time division on the time periods in the target image acquisition cycle from at least one division dimension to obtain the divided time intervals;

[0138] Perform light detection on the time intervals to obtain the light detection results of the time intervals;

[0139] Determine the idle time interval from the time intervals according to the light detection results of the time intervals.

[0140] Among them, the division dimension refers to the angle for dividing the time periods in the target image acquisition cycle. For example, if the image acquisition cycle is specifically 1 s, the unit time is specifically 1 ms, and the image acquisition cycle is divided into 10 consecutive time periods with a granularity of 100 ms, then the following can be a division dimension for time division of the time periods in the target image acquisition cycle: The time periods in the target image acquisition cycle can be divided with a granularity of 10 ms. In this way, each image acquisition cycle in the target image acquisition cycle can be divided into 100 consecutive time intervals, where the time length of each time interval is 10 ms. Another example is that the following can be another division dimension for time division of the time periods in the target image acquisition cycle: The time periods in the target image acquisition cycle can be divided with a granularity of 1 ms. In this way, each image acquisition cycle in the target image acquisition cycle can be divided into 1000 consecutive time intervals, where the time length of each time interval is 1 ms.

[0141] Similarly, the method of performing light detection on the time interval can refer to the method of performing light detection on the current image acquisition cycle in the aforementioned steps, that is, the time domain to be detected is changed from the current image acquisition cycle to the time interval, and the details are not repeated here.

[0142] Furthermore, based on the light detection result of the time interval, the time interval in which the light detection result indicates that no light is detected can be determined as an idle time interval.

[0143] As an example, assuming that the image acquisition cycle is 1s, the unit time is 1ms, the time period is 100ms, and the light detection results in each time period of the image acquisition cycle used for scanning in the target image acquisition cycle are all light detections, that is, all 10 100ms periods in the image acquisition cycle are used by other devices, the time period in the image acquisition cycle used for scanning can be first divided at a granularity of 10ms to divide the image scanning cycle into 100 consecutive time intervals, where each time interval is 10ms in length. Furthermore, light detection can be performed on the time intervals after the first division. If the light detection results in each time interval are all light detections, the image scanning cycle can be further divided at a smaller granularity. For example, the image scanning cycle can be divided into 1000 consecutive time intervals at a granularity of 1ms, where each time interval is 1ms in length. Light detection can then be performed on the time intervals after the second division, and idle time intervals can be determined based on the light detection results.

[0144] The above explains and exemplifies the step of "determining an idle time interval from the time period within the target image acquisition cycle based on the light detection results of the time period". The following further explains the step of "selecting the target idle time interval for the terminal to acquire depth images from the idle time interval".

[0145] The target idle time interval refers to an idle time interval from which a target unit time is selected. For example, if the terminal detects multiple idle time intervals, the target idle time interval for the terminal to capture depth images can be selected from the multiple idle time intervals.

[0146] Similar to the method of selecting an idle time interval from an idle time period, there can be multiple ways to select a target idle time interval from an idle time interval. For example, if there is only one idle time interval, the idle time interval can be confirmed as the target idle time interval. For example, if there are at least two idle time intervals, one of them can be selected as the target idle time interval through multiple methods such as random selection, selecting the first one, selecting the last one, and selecting according to preset rules.

[0147] Further, the following can explain the step of "determining the target unit time for the terminal to collect depth images from the target idle time interval".

[0148] In this application, since the light detection result of the current image acquisition cycle of the terminal can include two cases: detected light and undetected light, the following can respectively explain how to determine the target unit time for the terminal to collect depth images from the target idle time interval in these two cases.

[0149] In an embodiment, if the light detection result of the current image acquisition cycle of the terminal is undetected light, then the step of "determining the target unit time for the terminal to collect depth images from the target idle time interval" may include:

[0150] When the light detection result of the image acquisition cycle is undetected light, select the target unit time for the terminal to collect depth images from the target idle time interval.

[0151] Specifically, in this application, if the light detection result of the current image acquisition cycle of the terminal is undetected light, that is, the current image acquisition cycle is not used by other devices. In this case, the time length of the idle time period and the idle time interval are both the time length of the unit time. Therefore, the target unit time for the terminal to collect depth images can be directly selected from the target idle time interval. For example, the target idle time interval can be directly determined as the target unit time.

[0152] As an example, it can be assumed that the image acquisition cycle is specifically 1 s, the unit time is specifically 1 ms, and the current image acquisition cycle of the terminal is Figure 5 the image acquisition cycle from the 0th second to the 1st second as shown in Figure 8 Take the image acquisition cycle from the 1st second to the 2nd second as the image acquisition cycle for detection, set the time length of the time period to 1 ms, as Figure 10 shown, randomly select the unit time from the 1002nd ms to the 1003rd ms in the image acquisition cycle from the 1st second to the 2nd second as the time period to be detected, and the light detection result of this time period is as Figure 10 shown. As can be seen from

[0153] Further, since in this example, there is only one idle time interval in the target image acquisition period, and the time length of this idle time interval is equal to the time length of the unit time, therefore, this idle time interval can be used as the target space-time interval, and further this target idle time interval can be used as the target unit time for the terminal to acquire the depth image. That is to say, in each image acquisition period for detection, the third 1 ms in this image acquisition period is the target unit time for the terminal to acquire the depth image.

[0154] In another embodiment, if the light detection result of the current image acquisition period of the terminal is that light is detected, then the step of "determining the target unit time for the terminal to acquire the depth image from the target idle time interval" may include:

[0155] When the light detection result of the image acquisition period is that light is detected, select candidate unit times for the terminal to acquire the depth image from the target idle time interval;

[0156] Perform light detection on the candidate unit times to obtain the light detection results of the candidate unit times;

[0157] According to the light detection results of the candidate unit times, determine the target unit time for the terminal to acquire the depth image from the target idle time interval within the target image acquisition period.

[0158] Specifically, in this application, if the light detection result of the current image acquisition period of the terminal is that light is detected, that is, this current image acquisition period has been used by other devices, then in this case, referring to the method steps in this application, the target idle time interval can be determined from the target image acquisition period. For example, the target idle time interval can be a time interval with a duration of 100 ms; for another example, the target idle time interval can be a time interval with a duration of 10 ms, and for another example, the target idle time interval can be a time interval with a duration of 1 ms; and so on.

[0159] That is to say, when the light detection result of the current image acquisition period of the terminal is that light is detected, the target idle time interval may include at least one unit time. Therefore, candidate unit times for the terminal to acquire the depth image can be selected from the target idle time interval, and further the target unit time can be determined from the candidate unit times.

[0160] There are various methods to select candidate unit times for the terminal to acquire the depth image from the target idle time interval. For example, all unit times in the target idle time interval can be selected as candidate unit times; for another example, several unit times can be selected as candidate unit times from the unit times in the target idle time interval according to a preset rule; and so on.

[0161] Further, optical detection can be performed on the candidate unit time to obtain the optical detection result of the candidate unit time. For example, optical detection can be performed once on the candidate unit time, and the optical detection result of this optical detection can be used as the optical detection result of the candidate unit time. Another example is that in practical applications, in order to ensure the robustness of the candidate unit time, multiple optical detections can be performed on the candidate unit time during the image acquisition cycle for detection, so as to ensure that the finally selected target unit time has a high probability of being the available unit time of the terminal and to avoid the situation where other devices use the target unit time simultaneously as much as possible. Specifically, the step of "performing optical detection on the candidate unit time to obtain the optical detection result of the candidate unit time" can include:

[0162] Performing at least one optical detection on the candidate unit time to obtain the optical detection results of each time of the candidate unit time;

[0163] Determining the optical detection result of the candidate unit time according to the optical detection results of each time of the candidate unit time.

[0164] Similarly, for the method of performing optical detection on the candidate unit time, reference can be made to the method of performing optical detection within the current image acquisition cycle in the foregoing steps, that is, changing the time domain to be detected from the current image acquisition cycle to the candidate unit time, and details are not elaborated here.

[0165] In practical applications, two optical detections can be performed on the candidate unit time to recheck the robustness of the candidate unit time. The specific time for performing optical detection on the candidate unit time can be selected as needed, and this application does not limit this.

[0166] There are various ways to determine the optical detection result of the candidate unit time according to the optical detection results of each time of the candidate unit time. For example, it can be determined that the final optical detection result of the candidate unit time is no light detected only when the optical detection results of each time of the candidate unit time are all no light detected; another example is that the optical detection results of each time of the candidate unit time can be statistically analyzed, and the final optical detection result of the candidate unit time can be determined in the way of the statistical result, such as the final optical detection result of the candidate unit time is that there is an 80% probability of no light detected; and so on.

[0167] After obtaining the final optical detection result of the candidate unit time, further, according to the optical detection result of the candidate unit time, the target unit time for the terminal to collect the depth image can be determined from the target idle time interval within the target image acquisition cycle. For example, the candidate unit time with the optical detection result of no light detected can be used as the target unit time; another example is that the candidate unit time with the highest probability of light detected in the optical detection result can be used as the target unit time; and so on.

[0168] 105. Periodically perform depth image acquisition operations according to the target unit time and the image acquisition cycle.

[0169] Specifically, the terminal can determine the position of the target unit time in the image acquisition cycle, and in each image acquisition cycle for acquisition, select the unit time at the corresponding position for the depth image acquisition operation, so as to periodically perform the depth image acquisition operation.

[0170] As an example, the image acquisition cycle can be specifically 1 s, the unit time can be specifically 1 ms, and the current image acquisition cycle of the terminal is Figure 5 the image acquisition cycle from the 0th second to the 1st second shown in, take the image acquisition cycle from the 1st second to the 2nd second as the image acquisition cycle for detection, take the image acquisition cycle after the image acquisition cycle for detection as the image acquisition cycle for acquisition, and as Figure 10 shown, if the target unit time is specifically the 3rd 1 ms in the image acquisition cycle, then the terminal can, as Figure 11 shown, select the third 1 ms as the target unit time in the image acquisition cycle from the 2nd second to the 3rd second; select the third 1 ms as the target unit time in the image acquisition cycle from the 3rd second to the 4th second; select the third 1 ms as the target unit time in the image acquisition cycle from the 4th second to the 5th second... until the terminal stops working, and the terminal can trigger the emitter to emit speckle structured light and trigger the receiver to perform exposure within the selected target unit time, so as to periodically perform the depth image acquisition operation.

[0171] As can be seen from the above, in this embodiment, the current image acquisition cycle of the terminal can be determined, where the image acquisition cycle includes several unit times; perform optical detection within the current image acquisition cycle to obtain the optical detection result of the image acquisition cycle; according to the optical detection result of the image acquisition cycle, perform optical detection on the time period within the target image acquisition cycle to obtain the optical detection result of the time period, where the target image acquisition cycle is the image acquisition cycle after the current image acquisition cycle, and the time period consists of at least one unit time; according to the optical detection result of the time period, determine the target unit time for the terminal to acquire the depth image from the target image acquisition cycle; and periodically perform the depth image acquisition operation according to the target unit time and the image acquisition cycle.

[0172] The depth image acquisition method proposed by this solution can be applied to various depth image acquisition devices for depth image acquisition of the same area, and can effectively solve the accuracy and efficiency when multiple devices perform depth image acquisition for the same area. Specifically, this solution performs optical detection on the current image acquisition cycle of the terminal to obtain the optical detection result of the image acquisition cycle. In this way, it can be determined whether the current image acquisition cycle is occupied by other devices, that is, it can be determined whether the current image acquisition cycle is available for this terminal. Further, the terminal can perform optical detection on the time period within the target image acquisition cycle according to the optical detection result of the image acquisition cycle, and obtain the optical detection result of the time period. In this way, the terminal can determine the available time period within the target image acquisition cycle. Further, the terminal can determine the target unit time from the target image acquisition cycle according to the optical detection result of the time period, that is, determine the unit time available for the terminal to perform depth image acquisition. After determining the target unit time, the terminal can apply to use the target unit time according to the target unit time and the image acquisition cycle, and periodically perform the depth image acquisition operation.

[0173] Therefore, by applying the depth image acquisition method proposed by this solution, when multiple depth image acquisition devices perform depth image acquisition for the same local area, the multiple depth image acquisition devices can be segmented and used at different times in the time domain, so as to realize the common use of multiple depth image acquisition devices in the same area without interference, thereby improving the acquisition efficiency and accuracy of depth images.

[0174] According to the method described in the above embodiments, the following will be further described in detail with examples.

[0175] In this embodiment, it will be described by taking the depth image acquisition device integrated in the terminal as an example. The terminal can be a smart phone, a tablet computer, a notebook computer, a desktop computer, a smart speaker, a smart watch, a face recognition device, a face payment device, an AR device, etc., but is not limited thereto. The terminal and the server can be directly or indirectly connected through wired or wireless communication methods, and this application does not make any restrictions here.

[0176] This embodiment can take the terminal as a face payment device as an example. For example, Figure 12 As shown, a depth image acquisition method has the following specific process:

[0177] 201. Determine the current image acquisition cycle of the face payment device, where the image acquisition cycle includes several unit times.

[0178] In one embodiment, refer to Figure 13In step 301, the face payment device can define the emission time of the speckle structured light laser as 1 millisecond. Specifically, the speckle structured light depth map is a system of an emission structure. Among them, the emitter is a speckle structured light laser with a wavelength of 94 nanometers, which is driven by a current-driven IC; the receiver is an infrared pickup equipped with a 94-nanometer wavelength filter. Defining the emission time as 1 millisecond specifically means that the current-driven IC drives the speckle structured light laser to work at the rated current for 1 millisecond. At the same moment, the infrared sensor equipped with a 94-nanometer wavelength infrared light filter is exposed for 1 millisecond. In addition, the current image acquisition cycle of the face payment device can be set to 1 second, where this image acquisition cycle can include 1000 unit times, and each unit time is 1 millisecond.

[0179] 202. The face payment device performs optical detection within the current image acquisition cycle to obtain the optical detection result of the image acquisition cycle.

[0180] In one embodiment, refer to Figure 13 In step 302, each time the face payment device opens the depth map, it can first detect the application time domain. Specifically, it can first use the infrared camera to detect for 1 second, and after detection, it can find out which time domains have been occupied. More specifically, since the infrared camera is equipped with a 94-nanometer wavelength infrared filter and can only transmit infrared light with a wavelength of 94 nanometers, while refracting all other wavelength lights, the infrared camera will only receive the signal of infrared light with a wavelength of 94 nanometers. When detecting the application time domain, first use the infrared camera to detect for 1 second, that is, the infrared camera is exposed for 1 second and outputs one frame. If no speckle laser points are found in this frame of infrared image, it means that no time domain is currently being used. If speckle laser points are found in this frame of infrared image, it means that a time domain is currently being used.

[0181] 203. The face payment device performs optical detection on the time period within the target image acquisition cycle according to the optical detection result of the image acquisition cycle to obtain the optical detection result of the time period, where the target image acquisition cycle is the image acquisition cycle after the current image acquisition cycle, and the time period consists of at least one unit time.

[0182] In one embodiment, refer to Figure 13 In step 303, if no time domain is currently being used, any 1 millisecond time domain within 1 second can be randomly used for detection. Specifically, the infrared camera can select a random 1 millisecond within 1 second for exposure, the exposure time is 1 millisecond, and one frame of infrared image is output. If there are no speckle infrared laser points on this infrared image, the detection is successful.

[0183] In another embodiment, refer to Figure 13In step 304, if a time domain is already in use, a time domain that is staggered from the currently used time domain can be applied for. Specifically, for this case, reference can be made to Figure 14 for the implementation of the steps.

[0184] Among them, referring to Figure 14 it can be known from step 401 that first, it is possible to scan which time domains have been applied for. Specifically, 10 groups of infrared frames of 100 milliseconds can be taken with an infrared camera first. Among them, the infrared sensors of the infrared camera are all globally exposed, that is, the time to obtain one frame is: exposure time + frame reading time. Set the pixel clock so that the frame reading time is less than 100 milliseconds. In this way, with 100 milliseconds of exposure + a frame reading time less than 100 milliseconds, the time to obtain one infrared image is less than 200 ms. The scanning is completed within 2 seconds through two sets of shootings. Specifically: 5 infrared images are obtained at the 200th, 400th, 600th, 800th, and 1000th milliseconds of the first second, 4 infrared images are obtained at the 300th, 500th, 700th, and 900th milliseconds of the second second, and 1 infrared image is obtained at the 100th millisecond of the third second. Through the 10 infrared images completed within 3 seconds, it is possible to find which 100-millisecond time domains already have used time domains and which 100-millisecond time domains have not been used. If an unused 100-millisecond time domain is found, the sub-time domain within this 100 milliseconds is the time domain that can be newly applied for with a stagger. If all 10 100-millisecond time domains are in use, a scan with a granularity of 10 milliseconds needs to be carried out again. If all 10-millisecond time domains are in use, a scan with a granularity of 1 millisecond needs to be carried out. The scanning method can refer to the scanning method at 100 milliseconds.

[0185] 204. The face payment device determines the target unit time for the face payment device to collect depth images from the target image acquisition cycle according to the light detection result of the time period.

[0186] In one embodiment, referring to Figure 13 steps 302 to 303, if no time domain is in use currently and a random 1 millisecond time domain within 1 second is used for successful detection, then according to the position of this 1 millisecond in the current image acquisition cycle, the unit time at the corresponding position in the target image acquisition cycle can be selected as the target unit time for the face payment device to collect depth images.

[0187] In another embodiment, referring to Figure 14As can be seen from step 402, it's possible to apply for a new time domain by staggering the already used time domain. Specifically, after finding a time domain that can be staggered and applied for in step 401, you can apply for this time domain. The specific application process is to first turn on the infrared camera and perform a 1-millisecond exposure detection on this time domain. If the infrared image generated by this 1-millisecond exposure contains speckle laser points, the detection fails, and another staggered time domain detected in step 401 is selected for a new application. If the infrared image generated by this 1-millisecond exposure does not contain speckle laser points, this 1-millisecond time domain can be used to simultaneously drive the speckle structured light laser for 1 millisecond during the next frame of infrared exposure using the power supply IC. This process is repeated twice, with both the infrared camera and the speckle structured light laser using this time domain, for two frames each time. In the first frame, the laser is off, and the infrared camera does not detect the speckle laser points. In the second frame, the laser is on, and the infrared camera detects the speckle laser points. If both times meet expectations, the application is successful, and this 1-millisecond time unit is determined as the target unit time for the facial payment device to capture depth images.

[0188] 205. The facial payment device periodically performs a depth image acquisition operation according to the target unit time and the image acquisition period.

[0189] In one embodiment, reference Figure 13 In step 303, if no time domain is currently in use and detection is successful using a random 1-millisecond time domain within 1 second, this 1-millisecond time domain can be used. Specifically, the infrared camera performs a 1-millisecond exposure, while the power driver IC drives the speckle laser for 1 millisecond. From then on, the device locks the time domain and enters the working state.

[0190] In another embodiment, reference Figure 14 As can be seen in step 403, once the time domain is successfully requested, the facial payment device can enter the depth camera operating state. Both the infrared camera and the speckle structured light infrared camera operate within this successfully requested time domain until they cease operation and exit. If interference from other depth cameras is detected during this process, it is ignored, and the protocol adapts from the newly added camera to the already active camera.

[0191] As can be seen from the above, the depth image acquisition method proposed in the embodiments of the present application can be applied to various depth image acquisition devices for acquiring depth images of the same area, and can effectively solve the accuracy and efficiency when multiple devices acquire depth images of the same area. Specifically, the solution obtains the optical detection result of the image acquisition cycle by performing optical detection on the current image acquisition cycle of the terminal. In this way, it can be determined whether the current image acquisition cycle is occupied by other devices, that is, it can be determined whether the current image acquisition cycle is available for this terminal. Further, the terminal can perform optical detection on the time period within the target image acquisition cycle according to the optical detection result of the image acquisition cycle, and obtain the optical detection result of the time period. In this way, the terminal can determine the available time period within the target image acquisition cycle. Further, the terminal can determine the target unit time from the target image acquisition cycle according to the optical detection result of the time period, that is, determine the unit time available for the terminal to acquire depth images. After determining the target unit time, the terminal can apply to use the target unit time according to the target unit time and the image acquisition cycle, and periodically perform the depth image acquisition operation.

[0192] Therefore, by applying the depth image acquisition method proposed in this solution, when multiple depth image acquisition devices acquire depth images of the same local area, the multiple depth image acquisition devices can be segmented and used at different times in the time domain, so as to realize the common use of multiple depth image acquisition devices in the same area without interference, thereby improving the acquisition efficiency and accuracy of depth images.

[0193] To better implement the above method, correspondingly, the embodiments of the present application also provide a depth image acquisition device, where the depth image acquisition device can be integrated in a terminal. The terminal can be a smart phone, a tablet computer, a notebook computer, a desktop computer, a smart speaker, a smart watch, a vehicle-mounted computer, a face recognition device, a face payment device, etc., but is not limited thereto.

[0194] For example, as Figure 15 shown, the depth image acquisition device may include a first determination unit 501, a first detection unit 502, a second detection unit 503, a second determination unit 504, and an acquisition unit 505, as follows:

[0195] The first determination unit 501 can be used to determine the current image acquisition cycle of the terminal, where the image acquisition cycle includes several unit times;

[0196] The first detection unit 502 can be used to perform optical detection within the current image acquisition cycle to obtain the optical detection result of the image acquisition cycle;

[0197] The second detection unit 503 can be used to perform light detection for a time period within a target image acquisition period according to the light detection result of the image acquisition period, so as to obtain the light detection result of the time period, where the target image acquisition period is an image acquisition period after the current image acquisition period, and the time period consists of at least one unit time;

[0198] The second determination unit 504 can be used to determine the target unit time for the terminal to acquire a depth image from the target image acquisition period according to the light detection result of the time period;

[0199] The acquisition unit 505 can be used to periodically perform a depth image acquisition operation according to the target unit time and the image acquisition period.

[0200] In one embodiment, referring to Figure 16 , the second detection unit 503 may include:

[0201] The first determination subunit 5031 can be used to determine a target image acquisition period from the image acquisition periods after the current image acquisition period according to the light detection result of the image acquisition period;

[0202] The division subunit 5032 can be used to divide the target image acquisition period into at least one time period, where the time period consists of at least one unit time;

[0203] The first detection subunit 5033 can be used to perform light detection for the time period to obtain the light detection result of the time period.

[0204] In one embodiment, referring to Figure 17 , the second determination unit 504 may include:

[0205] The second determination subunit 5041 can be used to determine an idle time interval from the time periods within the target image acquisition period according to the light detection result of the time period, where the idle time interval is a time interval in the time period where no light is detected, and the time interval consists of at least one unit time;

[0206] The first selection subunit 5042 can be used to select the target idle time interval for the terminal to acquire a depth image from the idle time interval;

[0207] The third determination subunit 5043 can be used to determine the target unit time for the terminal to acquire a depth image from the target idle time interval.

[0208] In one embodiment, the second determination subunit 5041 can be used to:

[0209] When the light detection result of the time period is that light is detected, the time period in the target image acquisition period is divided in terms of time from at least one division dimension to obtain divided time intervals; light detection is performed on the time intervals to obtain the light detection results of the time intervals; and idle time intervals are determined from the time intervals according to the light detection results of the time intervals.

[0210] In an embodiment, the second determination subunit 5041 may be configured to:

[0211] When the light detection result of the time period is that no light is detected, determine the time period as an idle time period, and select an idle time interval from the idle time period.

[0212] In an embodiment, the third determination subunit 5043 may be configured to:

[0213] When the light detection result of the image acquisition period is that light is detected, select a candidate unit time for the terminal to acquire a depth image from the target idle time interval; perform light detection on the candidate unit time to obtain the light detection result of the candidate unit time; and determine the target unit time for the terminal to acquire a depth image from the target idle time interval within the target image acquisition period according to the light detection result of the candidate unit time.

[0214] In an embodiment, the third determination subunit 5043 may be specifically configured to:

[0215] Perform light detection on the candidate unit time at least once to obtain the light detection results of each time of the candidate unit time; and determine the light detection result of the candidate unit time according to the light detection results of each time of the candidate unit time.

[0216] In an embodiment, the third determination subunit 5043 may be configured to:

[0217] When the light detection result of the image acquisition period is that no light is detected, select the target unit time for the terminal to acquire a depth image from the target idle time interval.

[0218] In an embodiment, with reference to Figure 18 , the terminal includes a light receiving module; the first detection unit 502 may include:

[0219] The second detection subunit 5021 may be configured to trigger the light receiving module to perform light detection within the current image acquisition period to obtain the light detection result of the light receiving module;

[0220] The fourth determination subunit 5022 can be used to determine the light detection result of the image acquisition period of the terminal according to the light detection result of the light receiving module.

[0221] In an embodiment, the terminal further includes a data reading module; the fourth determination subunit 5022 can be used to:

[0222] Read the light detection result of the light receiving module through the data reading module; determine the light detection result of the image acquisition period of the terminal according to the reading result.

[0223] In specific implementation, each of the above units can be implemented as an independent entity, or can be arbitrarily combined and implemented as the same or several entities. For the specific implementation of each of the above units, reference can be made to the foregoing method embodiments, which will not be elaborated herein.

[0224] As can be seen from the above, in the depth image acquisition device of this embodiment, the first determination unit 501 determines the current image acquisition period of the terminal, where the image acquisition period includes several unit times; the first detection unit 502 performs light detection within the current image acquisition period to obtain the light detection result of the image acquisition period; the second detection unit 503 performs light detection on the time period within the target image acquisition period according to the light detection result of the image acquisition period to obtain the light detection result of the time period, where the target image acquisition period is the image acquisition period after the current image acquisition period, and the time period consists of at least one unit time; the second determination unit 504 determines the target unit time for the terminal to acquire the depth image from the target image acquisition period according to the light detection result of the time period; the acquisition unit 505 periodically performs the depth image acquisition operation according to the target unit time and the image acquisition period.

[0225] The depth image acquisition method proposed by this solution can be applied to various depth image acquisition devices for depth image acquisition of the same area, and can effectively solve the accuracy and efficiency when multiple devices perform depth image acquisition of the same area. Specifically, this solution performs optical detection on the current image acquisition cycle of the terminal to obtain the optical detection result of the image acquisition cycle. In this way, it can be determined whether the current image acquisition cycle is occupied by other devices, that is, it can be determined whether the current image acquisition cycle is available for this terminal. Further, the terminal can perform optical detection on the time period within the target image acquisition cycle according to the optical detection result of the image acquisition cycle, and obtain the optical detection result of the time period. In this way, the terminal can determine the available time period within the target image acquisition cycle. Further, the terminal can determine the target unit time from the target image acquisition cycle according to the optical detection result of the time period, that is, determine the unit time available for the terminal to perform depth image acquisition. After determining the target unit time, the terminal can apply for using the target unit time according to the target unit time and the image acquisition cycle, and periodically perform the depth image acquisition operation.

[0226] Therefore, by applying the depth image acquisition method proposed by this solution, when multiple depth image acquisition devices perform depth image acquisition of the same local area, the multiple depth image acquisition devices can be segmented and used at staggered times in the time domain, so as to realize the common use of multiple depth image acquisition devices in the same area without interference, thereby improving the acquisition efficiency and accuracy of depth images.

[0227] In addition, an embodiment of the present application further provides a computer device, and this computer device can be a device such as a terminal. The terminal can be a smart phone, a tablet computer, a notebook computer, a desktop computer, a smart speaker, a smart watch, a vehicle-mounted computer, etc., but is not limited thereto. As Figure 19 shown, it shows a schematic structural diagram of the computer device involved in the embodiment of the present application. Specifically:

[0228] This computer device may include a memory 601 with one or more computer-readable storage media, an input unit 602, a processor 603 including one or more processing cores, and a power supply 604 and other components. Those skilled in the art can understand that Figure 19 the structural diagram of the computer device shown in does not constitute a limitation on the computer device, and may include more or fewer components than Figure 19 shown, or combine some components, or arrange different components. Among them:

[0229] The memory 601 can be used to store software programs and modules. The processor 603 executes various functional applications and data processing by running the software programs and modules stored in the memory 601. The memory 601 mainly includes a program storage area and a data storage area. Among them, the program storage area can store an operating system, application programs required for at least one function (such as a sound playback function, an image playback function, etc.); the data storage area can store data created according to the use of the computer device (such as audio data, phone book, etc.). In addition, the memory 601 can include high-speed random access memory and can also include non-volatile memory, such as at least one magnetic disk storage device, a flash memory device, or other volatile solid-state storage devices. Correspondingly, the memory 601 can also include a memory controller to provide access to the memory 601 by the processor 603 and the input unit 602.

[0230] The input unit 602 can be used to receive input digital or character information, and generate keyboard, mouse, joystick, optical or trackball signal inputs related to user settings and function controls. Specifically, in a specific embodiment, the input unit 602 can include a touch-sensitive surface and other input devices. The touch-sensitive surface, also known as a touch display screen or a touchpad, can collect touch operations of the user on or near it (such as operations of the user using a finger, a stylus, or any suitable object or accessory on or near the touch-sensitive surface), and drive the corresponding connection device according to a pre-set program. Optionally, the touch-sensitive surface can include two parts: a touch detection device and a touch controller. Among them, the touch detection device detects the touch orientation of the user, detects the signal brought by the touch operation, and transmits the signal to the touch controller; the touch controller receives the touch information from the touch detection device, converts it into contact coordinates, and then sends it to the processor 603, and can receive and execute commands sent by the processor 603. In addition, various types such as resistive, capacitive, infrared, and surface acoustic wave can be used to implement the touch-sensitive surface. In addition to the touch-sensitive surface, the input unit 602 can also include other input devices. Specifically, the other input devices can include, but are not limited to, one or more of a physical keyboard, function keys (such as volume control keys, switch keys, etc.), a trackball, a mouse, a joystick, etc.

[0231] The processor 603 is the control center of the computer device, connecting various parts of the entire mobile phone through various interfaces and circuits. By running or executing software programs and / or modules stored in the memory 601, and by invoking the data stored in the memory 601, it performs various functions of the computer device and processes data. Optionally, the processor 603 may include one or more processing cores; preferably, the processor 603 may integrate an application processor and a modem processor. Among them, the application processor mainly processes the operating system, user interface, application programs, etc., and the modem processor mainly processes wireless communication. It can be understood that the above-mentioned modem processor may not be integrated into the processor 603 either.

[0232] The computer device also includes a power supply 604 (such as a battery) for supplying power to each component. Preferably, the power supply can be logically connected to the processor 603 through a power management system, so as to implement functions such as management of charging, discharging, and power consumption management through the power management system. The power supply 604 may also include any components such as one or more DC or AC power supplies, a recharge system, a power failure detection circuit, a power converter or inverter, and a power status indicator.

[0233] Although not shown, the computer device may also include a camera, a Bluetooth module, etc., which will not be elaborated here. Specifically, in this embodiment, the processor 603 in the computer device will load the executable files corresponding to the processes of one or more application programs into the memory 601 according to the following instructions, and the processor 603 will run the application programs stored in the memory 601 to achieve various functions as follows:

[0234] Determine the current image acquisition cycle of the terminal, where the image acquisition cycle includes several unit times; perform optical detection within the current image acquisition cycle to obtain the optical detection result of the image acquisition cycle; according to the optical detection result of the image acquisition cycle, perform optical detection on the time period within the target image acquisition cycle to obtain the optical detection result of the time period, where the target image acquisition cycle is the image acquisition cycle after the current image acquisition cycle, and the time period consists of at least one unit time; according to the optical detection result of the time period, determine the target unit time for the terminal to acquire a depth image from the target image acquisition cycle; and perform depth image acquisition operations periodically according to the target unit time and the image acquisition cycle.

[0235] For the specific implementation of each of the above operations, reference can be made to the previous embodiments, which will not be elaborated here.

[0236] As can be seen from the above, the computer device in this embodiment obtains the optical detection result of the current image acquisition cycle through optical detection of the current image acquisition cycle. In this way, it can be determined whether the current image acquisition cycle is occupied by other devices, that is, it can be determined whether the current image acquisition cycle is available for this computer device. Further, the computer device can perform optical detection on the time period within the target image acquisition cycle according to the optical detection result of the image acquisition cycle, and obtain the optical detection result of the time period. In this way, the computer device can determine the available time period within the target image acquisition cycle. Further, the computer device can determine the target unit time from the target image acquisition cycle according to the optical detection result of the time period, that is, determine the unit time available for the terminal to perform depth image acquisition. After determining the target unit time, the computer device can apply for using the target unit time according to the target unit time and the image acquisition cycle, and periodically perform depth image acquisition operations.

[0237] Therefore, by applying the depth image acquisition method proposed in this solution, when multiple depth image acquisition devices perform depth image acquisition for the same local area, the multiple depth image acquisition devices can be segmented and used at different times in the time domain, so as to realize the common use of multiple depth image acquisition devices in the same area without interference, thereby improving the acquisition efficiency and accuracy of depth images.

[0238] Those of ordinary skill in the art can understand that all or part of the steps in the various methods of the above embodiments can be completed by instructions, or by controlling relevant hardware through instructions. The instructions can be stored in a computer-readable storage medium and loaded and executed by a processor.

[0239] For this reason, an embodiment of the present application provides a storage medium, which stores multiple instructions that can be loaded by a processor to execute the steps in any of the depth image acquisition methods provided by the embodiments of the present application. For example, the instructions can perform the following steps: [[ID=!1]]

[0240] Determine the current image acquisition cycle of the terminal, where the image acquisition cycle includes several unit times; perform optical detection within the current image acquisition cycle to obtain the optical detection result of the image acquisition cycle; according to the optical detection result of the image acquisition cycle, perform optical detection on the time period within the target image acquisition cycle to obtain the optical detection result of the time period, where the target image acquisition cycle is the image acquisition cycle after the current image acquisition cycle, and the time period consists of at least one unit time; determine the target unit time for the terminal to acquire depth images from the target image acquisition cycle according to the optical detection result of the time period; and periodically perform depth image acquisition operations according to the target unit time and the image acquisition cycle.

[0241] For the specific implementation of each of the above operations, reference may be made to the foregoing embodiments and will not be elaborated herein.

[0242] Among them, the storage medium may include: read-only memory (ROM, Read Only Memory), random access memory (RAM, Random Access Memory), magnetic disk or optical disc, etc.

[0243] Since the instructions stored in the storage medium can execute the steps in any of the depth image acquisition methods provided in the embodiments of the present application, the beneficial effects achievable by any of the depth image acquisition methods provided in the embodiments of the present application can be realized. For details, refer to the foregoing embodiments and will not be elaborated herein.

[0244] According to one aspect of the present application, there is provided a computer program product or a computer program. The computer program product or the computer program includes computer instructions, and the computer instructions are stored in a computer-readable storage medium. A processor of a computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes the methods provided in the various alternative implementations in the above-mentioned depth image acquisition aspect.

[0245] The above has introduced in detail a depth image acquisition method, device, computer device, storage medium and product provided by the embodiments of the present application. Specific examples are used in this article to elaborate on the principle and implementation manner of the present application. The description of the above embodiments is only used to help understand the method and its core idea of the present application; at the same time, for those skilled in the art, according to the idea of the present application, there will be changes in the specific implementation manner and application scope. In summary, the content of this specification should not be construed as a limitation to the present application.

Claims

1. A depth image acquisition method, characterized in that, Applied to a terminal, the method includes: Determine the current image acquisition period of the terminal, where the image acquisition period includes a plurality of unit times; Perform light detection within the current image acquisition period to obtain the light detection result of the image acquisition period; According to the light detection result of the image acquisition period, perform light detection on a time period within a target image acquisition period to obtain the light detection result of the time period, where the target image acquisition period is an image acquisition period after the current image acquisition period, and the time period consists of at least one unit time; According to the light detection result of the time period, determine the target unit time for the terminal to acquire a depth image from the target image acquisition period, including: according to the light detection result of the time period, determine an idle time interval from the time periods within the target image acquisition period, where the idle time interval is a time interval in the time period where no light is detected, and the time interval consists of at least one unit time; select the target idle time interval for the terminal to acquire a depth image from the idle time interval; determine the target unit time for the terminal to acquire a depth image from the target idle time interval; Periodically execute the depth image acquisition operation according to the target unit time and the image acquisition period.

2. The depth image acquisition method according to claim 1, characterized in that According to the light detection result of the image acquisition period, perform light detection on a time period within a target image acquisition period to obtain the light detection result of the time period, including: According to the light detection result of the image acquisition period, determine the target image acquisition period from the image acquisition periods after the current image acquisition period; Divide the target image acquisition period into at least one time period, where the time period consists of at least one unit time; Perform light detection on the time period to obtain the light detection result of the time period.

3. The depth image acquisition method according to claim 1, wherein According to the light detection result of the time period, determine the idle time interval from the time periods within the target image acquisition period, including: When the light detection result of the time period is that light is detected, perform time division on the time periods in the target image acquisition period from at least one division dimension to obtain the divided time intervals; Perform light detection on the time intervals to obtain the light detection results of the time intervals; According to the light detection results of the time intervals, determine the idle time interval from the time intervals.

4. The depth image acquisition method according to claim 1, characterized in that, According to the light detection result of the time period, determine the idle time interval from the time periods within the target image acquisition period, including: When the light detection result of the time period is that no light is detected, determine the time period as an idle time period, and select the idle time interval from the idle time period.

5. The depth image acquisition method according to claim 1, wherein Determine the target unit time for the terminal to acquire a depth image from the target idle time interval, including: When the light detection result of the image acquisition period is that light is detected, select the candidate unit time for the terminal to acquire a depth image from the target idle time interval; Perform light detection on the candidate unit time to obtain the light detection result of the candidate unit time; Determine the target unit time for the terminal to collect a depth image from the target idle time interval within the target image acquisition period according to the light detection result of the candidate unit time.

6. The depth image acquisition method according to claim 5, wherein, Perform light detection on the candidate unit time to obtain the light detection result of the candidate unit time, including: Perform at least one light detection on the candidate unit time to obtain the light detection results of each time of the candidate unit time; Determine the light detection result of the candidate unit time according to the light detection results of each time of the candidate unit time.

7. The depth image acquisition method according to claim 1, wherein Determine the target unit time for the terminal to collect a depth image from the target idle time interval, including: When no light is detected in the light detection result of the image acquisition period, select the target unit time for the terminal to collect a depth image from the target idle time interval.

8. The depth image acquisition method according to claim 1, wherein The terminal includes a light receiving module; Perform light detection during the current image acquisition period to obtain the light detection result of the image acquisition period, including: Trigger the light receiving module to perform light detection during the current image acquisition period to obtain the light detection result of the light receiving module; Determine the light detection result of the image acquisition period of the terminal according to the light detection result of the light receiving module.

9. The depth image acquisition method according to claim 8, wherein, The terminal further includes a data reading module; Determine the light detection result of the image acquisition period of the terminal according to the light detection result of the light receiving module, including: Read the light detection result of the light receiving module through the data reading module; Determine the light detection result of the image acquisition period of the terminal according to the reading result.

10. A depth image acquisition device, characterized in that, Including: A first determination unit, configured to determine the current image acquisition period of the terminal, where the image acquisition period includes a plurality of unit times; A first detection unit, configured to perform light detection during the current image acquisition period to obtain the light detection result of the image acquisition period; A second detection unit, configured to perform light detection on a time period within the target image acquisition period according to the light detection result of the image acquisition period to obtain the light detection result of the time period, where the target image acquisition period is the image acquisition period after the current image acquisition period, and the time period consists of at least one unit time; A second determination unit, configured to determine the target unit time for the terminal to collect a depth image from the target image acquisition period according to the light detection result of the time period, including: determining an idle time interval from the time period within the target image acquisition period according to the light detection result of the time period, where the idle time interval is a time interval in the time period where no light is detected, and the time interval consists of at least one unit time; selecting the target idle time interval for the terminal to collect a depth image from the idle time interval; determining the target unit time for the terminal to collect a depth image from the target idle time interval; An acquisition unit, configured to periodically execute a depth image acquisition operation according to the target unit time and the image acquisition period.

11. A computer device, characterized in that, It includes a memory and a processor; the memory stores an application program, and the processor is used to run the application program in the memory to perform the operations in the depth image acquisition method according to any one of claims 1 to 9.

12. A computer-readable storage medium, characterized in that, The storage medium stores multiple instructions, and the instructions are suitable for being loaded by a processor to execute the steps in the depth image acquisition method according to any one of claims 1 to 9.

13. A computer program product comprising a computer program / instructions, characterized in that, When the computer program / instructions are executed by a processor, the steps in the depth image acquisition method according to any one of claims 1 to 9 are implemented.

Citation Information

Patent Citations

  • Depth camera control method and device, terminal and readable storage medium

    CN110072044A