Structured light encoding and decoding method and system based on concentric circles and spiral phase-shifted stripes
By using the encoding and decoding method of concentric circles and spiral phase shift fringes in structured light encoding, the problems of excessive projection images and lack of angle information in traditional solutions are solved, and efficient and low-cost three-dimensional measurement is achieved, suitable for 360 degrees Measurement scenarios and non-strict coaxial systems.
Patent Information
- Application Number
- CN202410403723.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-04-03
- Publication Date
- 2024-12-17
- Estimated Expiration
- 2044-04-03
AI Technical Summary
In traditional structured light encoding scheme, there are too many projected images, which are inefficient, and some object points are not sensitive to phase shift changes in the 360-degree measurement scenario, and the concentric circle stripes lack angle information, so they cannot be applied to non-strictly coaxial three-dimensional reconstruction systems. .
Using a structured light encoding and decoding method based on concentric circles and spiral phase shift stripes, by projecting two sets of concentric circle stripes and a set of spiral stripes of different frequencies, the camera collects images, calculates the radius phase and angle phase values of the object surface points, and applies The principle of triangulation calculates real depth information, reduces the number of projected frames, increases measurement speed, and is suitable for non-strictly coaxial three-dimensional measurement systems.
It significantly improves the three-dimensional measurement speed, reduces the system cost and structural complexity, solves the problem of object point depth calculation error in 360-degree measurement scenarios, and realizes efficient reconstruction under non-strict coaxial conditions.
Smart Images

Figure CN118129640B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of structured light three-dimensional imaging, and in particular to a structured light encoding and decoding method and system based on concentric circles and spiral phase-shift stripes. Background Art
[0002] At present, the common structured light coding scheme is mainly based on the N-step phase shift method, which performs phase shift coding along the X-axis or Y-axis direction of the projector image coordinate system. In some measurement scenarios, this method has some limitations. For example, in light field three-dimensional imaging, it is necessary to obtain the image coordinate information of an object point under several sub-lenses for matching and reconstruction. Therefore, it is required to obtain the phase information of the spatial point in the X-axis and Y-axis directions in the camera image coordinate system (indirectly determine the position coordinates of the object point in the image coordinate system), and it is necessary to perform phase shift stripe coding along the X-axis and Y-axis directions at the same time. Take the common "four-step phase shift method + dual-frequency heterodyne" coding scheme as an example: 8 coding images are required to obtain the phase information of the spatial point in the X-axis direction. If the phase information in the Y-axis direction is to be obtained, the number of projected coding frames should be doubled, which is inefficient.
[0003] In addition, the phase-shifted stripes along the horizontal or vertical direction in this solution are mainly projected onto the object through the DLP digital light processor (Digital Light Processing), but this structured light imaging system requires the DMD (Digital Micromirror Device) processing chip developed by Texas Instruments, which is costly and has sanctions risks. The DLP circuit itself is complex and occupies space, and the structured light 3D imaging system including DLP is not easy to integrate. If DLP is abandoned and the light source + physical grating solution is considered to generate phase-shifted stripes, the grating needs to be displaced in the horizontal or vertical axis direction, which will be more complex than the DLP structure, and the cost is high and it is more difficult to integrate.
[0004] In the traditional triangulation-based structured light 3D reconstruction system, due to the existence of epipolar constraints, the best reconstruction effect can be obtained when phase shift encoding is performed along the epipolar direction; on the contrary, if phase shift encoding is performed perpendicular to the epipolar direction, the structured light cannot be effectively marked. In some 360-degree measurement scenarios, such as the measurement of a circular cylinder wall, if phase shift encoding is performed along a certain direction, there must be some object points on the cylinder wall whose corresponding epipolar lines are perpendicular or nearly perpendicular to the phase shift encoding direction, resulting in the inability to calculate the depth or a large calculation error.
[0005] Although concentric circle stripes are used in some structured light coding schemes, they lack angle information. If it is necessary to use the radius information change caused by the projector displacement for phase height mapping, the projector and the camera must be strictly coaxial. This is not suitable for non-strictly coaxial three-dimensional reconstruction systems. Summary of the invention
[0006] In view of this, in order to solve the problem of too many projection frames and low efficiency in traditional encoding and decoding schemes based on horizontal and vertical stripes, the purpose of the present invention is to provide a structured light encoding and decoding method and system based on concentric circles and spiral phase-shift stripes, which can be applied to the "light source + physical grating" structured light three-dimensional imaging system. Compared with the solution of using DLP for structured light projection, it not only reduces the cost but also simplifies the system structure; in addition, the present invention also solves the problem that some object points are insensitive to phase shift changes in some 360-degree measurement scenes; and solves the problem that concentric circle stripes can only be used in strictly coaxial three-dimensional measurement systems due to the lack of angle information.
[0007] The present invention is implemented by the following technical solutions:
[0008] In a first aspect, the present invention provides a structured light encoding and decoding method based on concentric circles and spiral phase-shift stripes, the method comprising the following steps:
[0009] Projecting two groups of radially encoded concentric fringe phase shift patterns with different frequencies and a group of radially and circumferentially encoded spiral fringe phase shift patterns onto the object to be tested;
[0010] Using a camera to collect the fringe coding pattern modulated on the surface of the object to be measured;
[0011] By calculating and processing the collected phase shift map, the radius phase and angle phase values corresponding to the surface point of the object to be measured in the camera image coordinate system are obtained;
[0012] The triangulation principle is applied to calculate the true depth information of each object point based on the acquired radius phase and angle phase.
[0013] As a further solution of the present invention, an N-step phase shift method is used for projection onto the object to be measured, and phase shift is performed according to a predetermined number of steps N to obtain N phase shift images, and each group of fringe phase shift patterns includes several phase shift states.
[0014] As a further solution of the present invention, obtaining the radius phase and the angle phase values includes the following steps:
[0015] Dephase the two groups of projected concentric fringe phase shift images of different frequencies to obtain two concentric truncated phase images;
[0016] The dual-frequency heterodyne method is used to perform phase unwrapping processing on the first concentric circle truncated phase according to the phase difference between the two truncated phase images, and a continuous phase covering the entire field of view, namely the radial phase, is obtained;
[0017] Dephase the spiral fringe phase shift image to obtain the truncated phase image of the spiral line;
[0018] The truncated phase image of the spiral line is subtracted from the first truncated phase image of the concentric circle with the same frequency to obtain the continuous phase covering the entire field of view, that is, the angular phase.
[0019] As a further solution of the present invention, using a camera to collect a stripe coding pattern modulated on the surface of the object to be measured is using a camera to collect a reflected light pattern modulated on the surface of the object, wherein the reflected light pattern contains coding information of concentric circle stripes and spiral stripes.
[0020] As a further solution of the present invention, de-phase is performed on two groups of projected concentric fringe phase shift images of different frequencies, including:
[0021] Perform phase calculation on the collected concentric circle fringe phase shift image to obtain the concentric circle radius phase value corresponding to the surface point of the object;
[0022] Perform phase calculation on the collected spiral fringe phase shift image to obtain the spiral angle phase value of the object surface point;
[0023] The three-dimensional position of each object surface point is reconstructed through the concentric circle radius phase value and the spiral angle phase value.
[0024] As a further solution of the present invention, the unfolding of the truncated phase in the structured light encoding and decoding method based on concentric circles and spiral phase-shift stripes includes the following steps:
[0025] Taking the origin of the camera image coordinate system as the starting point, sinusoidal phase shift encoding is performed along the radial direction to generate a phase shift map;
[0026] Apply the classic phase shift solution formula to solve the truncated phase corresponding to each pixel of the camera;
[0027] Unwrap the truncated phase so that the phase distribution covers the entire camera field of view;
[0028] At the same time, sinusoidal phase shift encoding is performed in radial and circumferential directions to generate a spiral phase shift diagram, and the classical phase shift decomposition formula is applied to obtain a truncated phase distribution, which contains both radial and angular phase information;
[0029] Combined with the radius phase information, the angle phase is obtained to mark the position information of all object points in the camera field of view in the image coordinate system, reducing the number of projection frames and improving the speed of three-dimensional measurement.
[0030] As a further solution of the present invention, the truncated phase is unwrapped by using a dual-frequency unwrapping method or a Gray code-assisted unwrapping method.
[0031] As a further solution of the present invention, two groups of radially encoded concentric fringe phase shift patterns with different frequencies and a group of radially and circumferentially encoded spiral fringe phase shift patterns are projected onto the object to be measured, including:
[0032] Projecting a set of radially encoded concentric fringe phase shift patterns onto the object to be measured;
[0033] Projecting a set of spiral fringe phase shift patterns with the same frequency encoded in radial and circumferential directions onto the object to be measured;
[0034] Another set of concentric fringe phase shift patterns of different frequencies is projected onto the object to be tested.
[0035] As a further solution of the present invention, the structured light encoding and decoding method based on concentric circle and spiral phase shift stripes also includes: exchanging the concentric circle stripe phase shift map and the spiral stripe phase shift map, first projecting two sets of spiral stripe phase shift maps with different frequencies, and then projecting a set of concentric circle stripe phase shift maps.
[0036] In a second aspect, the present invention also includes a structured light encoding and decoding system based on concentric circles and spiral phase-shift stripes, comprising:
[0037] The projection module is responsible for projecting two sets of radially encoded concentric fringe phase shift patterns with different frequencies and a set of radially and circumferentially encoded spiral fringe phase shift patterns onto the object to be tested;
[0038] A camera module, including one or more high-resolution cameras, for collecting the fringe coding pattern modulated by the surface of the object to be measured;
[0039] A synchronization control module, used to coordinate the camera and the projection module to perform phase shift and collect a phase shift map;
[0040] The data processing module is used to obtain the radius phase and angle phase values corresponding to the surface points of the object to be measured in the camera image coordinate system by calculating and processing the collected phase shift map; and to calculate the true depth information of each object point based on the obtained radius phase and angle phase by applying the triangulation principle.
[0041] As a further solution of the present invention, the structured light encoding and decoding system based on concentric circles and spiral phase-shift stripes further includes:
[0042] User interface: allows the user to input parameters (such as the number of projection steps N), start the measurement process and view the measurement results. The user interface can be a software interface or include hardware buttons and display screens.
[0043] Power Management Unit: Provides stable power to various components of the system and includes a power adapter and power distribution circuit.
[0044] Calibration module: used to calibrate the system to ensure accuracy, including calibration plates to ensure the geometric relationship between the projection module and the camera module is accurate.
[0045] Peripheral devices: including interfaces (USB, Ethernet) for data transmission, brackets and casing to support stable operation of the system and user operation.
[0046] The present invention also includes a computer device, comprising: at least one processor, and a memory communicatively connected to the at least one processor, wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor executes the structured light encoding and decoding method based on concentric circles and spiral phase-shift stripes.
[0047] The present invention also includes a computer-readable storage medium, wherein the computer-readable storage medium stores computer instructions, and the computer instructions are used to enable the computer to execute the structured light encoding and decoding method based on concentric circles and spiral phase-shift stripes.
[0048] Compared with the prior art, the structured light encoding and decoding method and system based on concentric circles and spiral phase-shift stripes provided by the present invention has the following beneficial effects:
[0049] 1. The present invention is applied to active light field imaging systems to mark the position of the same object point in each microlens sub-view. Compared with the traditional stripe-coded structured light scheme based on the X-axis and Y-axis directions, the number of projected stripes is reduced by 1 / 4, which significantly improves the three-dimensional measurement speed.
[0050] 2. In addition, the present invention does not need to use DLP to generate phase-shift fringes, and is more suitable for implementation in the form of physical grating rotation. Compared with DLP, it not only reduces costs but also simplifies the system structure.
[0051] 3. The present invention uses concentric circles and spiral stripes for encoding, and can obtain radial phase and angular phase information. According to the conversion relationship between the polar coordinate system and the rectangular coordinate system, the radial phase and angular phase can be converted to a rectangular coordinate system in any direction, that is, the phase information along any direction can be obtained. In a 360-degree measurement scenario like a circular cylinder wall, there will be no problem that the polar line is nearly perpendicular to the phase change direction, resulting in the inability to calculate the depth.
[0052] 4. Compared with the structured light coding scheme of concentric circle stripes, the present invention introduces spiral phase-shift stripes with angle information. When performing phase height mapping, it is not necessary to ensure that the projector and the camera are strictly coaxial, and a good reconstruction effect can be obtained under approximately coaxial experimental conditions.
[0053] These and other aspects of the present invention will be more clearly understood in the following description of the embodiments. It should be understood that the above general description and the following detailed description are only exemplary and explanatory and cannot limit the present invention. BRIEF DESCRIPTION OF THE DRAWINGS
[0054] In order to more clearly illustrate the technical solutions in the embodiments of the present invention or related technologies, the following briefly introduces the drawings required for use in the exemplary embodiments or related technical descriptions. The drawings are used to provide a further understanding of the present invention and constitute a part of the specification. Together with the embodiments of the present invention, they are used to explain the present invention and do not constitute a limitation to the present invention. In the drawings:
[0055] Figure 1 The figure is a flow chart of a structured light encoding and decoding method based on concentric circles and spiral phase-shift stripes according to an embodiment of the present invention.
[0056] Figure 2 The present invention is a flowchart of obtaining the radial phase and the angular phase in the structured light encoding and decoding method based on concentric circles and spiral phase-shift stripes according to an embodiment of the present invention.
[0057] Figure 3 It is a schematic diagram of generating a phase shift image using a four-step phase shift method in a structured light encoding and decoding method based on concentric circles and spiral phase shift stripes according to an embodiment of the present invention.
[0058] Figure 4 Schematic diagram of phase distribution and radial phase trend in a structured light encoding and decoding method based on concentric circles and spiral phase-shift stripes according to an embodiment of the present invention.
[0059] Figure 5 This is a spiral sinusoidal fringe pattern with different phase shifts generated in the structured light encoding and decoding method based on concentric circles and spiral phase-shifted fringes in an embodiment of the present invention.
[0060] Figure 6 Schematic diagram of angular phase distribution in a structured light encoding and decoding method based on concentric circles and spiral phase-shift stripes according to an embodiment of the present invention.
[0061] Figure 7 4 is a structural principle diagram of a coaxial monocular structured light three-dimensional measurement system based on phase-height mapping in an embodiment of the present invention.
[0062] Figure 8 It is a structural diagram of a physical grating projection device in a structured light encoding and decoding method based on concentric circles and spiral phase-shift stripes according to an embodiment of the present invention.
[0063] Fig. 9 It is a schematic diagram of rotating concentric circles and spiral physical gratings to generate phase-shifted fringes in the structured light encoding and decoding method based on concentric circles and spiral phase-shifted fringes according to an embodiment of the present invention. DETAILED DESCRIPTION
[0064] In order to make the purpose, technical solution and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention.
[0065] In some of the processes described in the specification and claims of the present invention and the above-mentioned figures, multiple operations that appear in a specific order are included, but it should be clearly understood that these operations may not be executed in the order in which they appear in this article or executed in parallel. The serial numbers of the operations, such as 101, 102, etc., are only used to distinguish different operations, and the serial numbers themselves do not represent any execution order. In addition, these processes may include more or fewer operations, and these operations may be executed in sequence or in parallel. It should be noted that the descriptions of "first", "second", etc. in this article are used to distinguish different messages, devices, modules, etc., do not represent the order of precedence, and do not limit the "first" and "second" to be different types.
[0066] The following will be combined with the drawings in the exemplary embodiments of the present invention to clearly and completely describe the technical solutions in the exemplary embodiments of the present invention. Obviously, the exemplary embodiments described are only part of the embodiments of the present invention, not all of them. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present invention.
[0067] The present invention provides a structured light encoding and decoding method and system based on concentric circles and spiral phase-shift stripes, which can solve the problem of too many projection frames and low efficiency in traditional encoding and decoding solutions based on horizontal and vertical stripes; the present invention is applied to a structured light three-dimensional imaging system of "light source + physical grating", which reduces the cost and simplifies the system structure compared to the solution of using DLP for structured light projection; in addition, the present invention also solves the problem that some object points are insensitive to phase shift changes in some 360-degree measurement scenes; and solves the problem that concentric circle stripes can only be used in strictly coaxial three-dimensional measurement systems due to the lack of angle information.
[0068] The technical solution of the present invention is further described below in conjunction with specific embodiments:
[0069] See also Figure 1 As shown, Figure 1 A flow chart of a structured light encoding and decoding method based on concentric circles and spiral phase-shift stripes provided by the present invention. A structured light encoding and decoding method based on concentric circles and spiral phase-shift stripes provided in one embodiment of the present invention comprises the following steps:
[0070] Step S10, projecting two groups of radially encoded concentric fringe phase shift patterns with different frequencies and a group of radially and circumferentially encoded spiral fringe phase shift patterns onto the object to be measured.
[0071] In this embodiment, two groups of radially encoded concentric fringe phase shift patterns with different frequencies and a group of radially and circumferentially encoded spiral fringe phase shift patterns are projected onto the object to be measured, including:
[0072] Projecting a set of radially encoded concentric fringe phase shift patterns onto the object to be measured;
[0073] Projecting a set of spiral fringe phase shift patterns with the same frequency encoded in radial and circumferential directions onto the object to be measured;
[0074] Another set of concentric fringe phase shift patterns of different frequencies is projected onto the object to be tested.
[0075] The N-step phase shift method is used for projection onto the object to be measured, and phase shift is performed according to a predetermined number of steps N to obtain N phase shift images, and each set of fringe phase shift patterns includes a number of phase shift states.
[0076] Step S20, using a camera to collect the fringe coding pattern modulated on the surface of the object to be measured;
[0077] Step S30, obtaining the radius phase and angle phase values corresponding to the surface point of the object to be measured in the camera image coordinate system by calculating and processing the collected phase shift map;
[0078] Step S40: Apply the triangulation principle to calculate the true depth information of each object point according to the acquired radius phase and angle phase.
[0079] In the above steps, obtaining the radius phase and the angle phase values includes the following steps:
[0080] Step S301, performing phase deconvolution on two groups of projected concentric fringe phase shift images of different frequencies to obtain two concentric truncated phase images;
[0081] Step S302: using a dual-frequency heterodyne method, according to the phase difference between the two truncated phase images, performing phase unwrapping processing on the first concentric circle truncated phase to obtain a continuous phase covering the entire field of view, that is, a radial phase;
[0082] Step S303, dephase the spiral fringe phase shift image to obtain a truncated phase image of the spiral line;
[0083] Step S304: performing difference processing on the truncated phase image of the spiral line and the first truncated phase image of the concentric circles with the same frequency to obtain a continuous phase covering the entire field of view, that is, an angular phase.
[0084] Among them, using a camera to collect the stripe coding pattern modulated on the surface of the object to be measured is using a camera to collect the reflected light pattern modulated on the surface of the object, and the reflected light pattern contains coding information of concentric circle stripes and spiral stripes.
[0085] In this embodiment, dephasing is performed on two groups of projected concentric fringe phase shift patterns of different frequencies, including:
[0086] Perform phase calculation on the collected concentric circle fringe phase shift image to obtain the concentric circle radius phase value corresponding to the surface point of the object;
[0087] Perform phase calculation on the collected spiral fringe phase shift image to obtain the spiral angle phase value of the object surface point;
[0088] The three-dimensional position of each object surface point is reconstructed through the concentric circle radius phase value and the spiral angle phase value.
[0089] Taking the dual-frequency heterodyne method as an example, the unwrapping of the truncated phase in the structured light encoding and decoding method based on concentric circles and spiral phase-shifted stripes includes the following steps:
[0090] (1) Starting from the origin of the camera image coordinate system, sinusoidal phase shift encoding is performed along the radial direction to generate a phase shift map. Figure 3 As shown in FIG. 1 , a schematic diagram of a phase shift diagram generated by a four-step phase shift method is shown, which represents a concentric circular sinusoidal fringe image along the radial phase shift, where: Figure 3 (a), (b), (c), and (d) are the phase shift fringe diagrams with phase shift steps of 1 / 2π, π, 3 / 2π, and 2π in the four-step phase shift method. Figure 3 Among a~d Phase shift value of an image They are: ; ; ; .
[0091] (2) Apply the classical phase shift decomposition formula to solve the truncated phase corresponding to each pixel of the camera .
[0092] (3) Unwrapping the truncated phase so that the phase distribution covers the entire camera field of view. The unwrapping of the truncated phase is performed by using a dual-frequency unwrapping method or a Gray code-assisted unwrapping method.
[0093] In this step, the phase distribution of the fully expanded phase distribution diagram and the phase trend along the radial direction are as follows: Figure 4 As shown, Figure 4(a) shows the continuous phase diagram of concentric sinusoidal stripes along the radial direction, and (b) shows the phase distribution diagram on a straight line drawn from the edge to the center in a. At this time, each object point in the camera image coordinate system has a unique radial phase value. If the angular phase value of each object point is calculated at this time, an object point in space can be uniquely marked.
[0094] (4) Sinusoidal phase shift encoding is performed in the radial and circumferential directions simultaneously to generate a spiral phase shift diagram. The classical phase shift decomposition formula is applied to obtain a truncated phase distribution that contains both radial and angular phase information.
[0095] In this step, similar to the encoding method of concentric circle stripes in the above text, sinusoidal phase shift encoding is performed with the origin of the camera image coordinate system as the starting point. The difference is that for each pixel point, the phase main value The angle information is also added, and the generated spiral phase shift diagram is as follows Figure 5 As shown, Figure 5 (a), (b), (c), and (d) are spiral sinusoidal fringe patterns with different phase shifts.
[0096] Consistent with the previous method of obtaining truncated phase images from concentric circular stripes, the truncated phase distribution of spiral stripes can be obtained.
[0097] In the truncated phase distribution, the radius and angular phase information of each object point are included at the same time. Combined with the radius phase information obtained above, the angular phase of 0 to 2π can be obtained, and this angular phase can cover the entire field of view of the camera. The angular phase distribution is as follows: Figure 6 shown.
[0098] Therefore, based on the solved radial phase map and angular phase map, the position information of all object points in the camera field of view in the image coordinate system can be marked. Compared with the traditional coding scheme of projecting horizontal and vertical stripes, the number of projected frames is reduced by 1 / 4.
[0099] In some embodiments, the structured light encoding and decoding method based on concentric circle and spiral phase-shift stripes also includes: exchanging the concentric circle stripe phase-shift map and the spiral stripe phase-shift map, first projecting two sets of spiral stripe phase-shift maps with different frequencies, and then projecting a set of concentric circle stripe phase-shift maps, and the effect achieved is exactly the same as described above.
[0100] In summary, the present invention is applied to an active light field imaging system to mark the position of the same object point in each microlens sub-view. Compared with the traditional stripe-coded structured light scheme based on the X-axis and Y-axis directions, the number of projected stripes is reduced by 1 / 4, which significantly improves the three-dimensional measurement speed.
[0101] In addition, the present invention does not use DLP to generate phase-shift fringes, and is more suitable for physical grating rotation. Compared with DLP, it not only reduces the cost but also simplifies the system structure. Figure 8 As shown, a physical grating rotation is used to replace DLP digital projection to obtain a phase shift map. The physical grating projection device includes a physical light source, a collimating light homogenization component, a rotatable multi-color physical grating, and a projection lens group. The physical grating projection device generates a phase shift pattern by rotating the light source and the multi-color physical grating to replace the DLP projection to generate the phase shift map.
[0102] See also Fig. 9 As shown, the method for constructing a multi-color physical grating of a physical grating projection device includes the following steps: concentric circles are all stored in the same color channel, and the center grating is divided into several parts according to the phase shift steps and stripe period adopted; the spiral can be stored separately in another color channel.
[0103] like Fig. 9 The figure shows an example of the phase shift diagram of concentric circles and spiral stripes produced by multi-color physical grating. It is assumed that the phase deconvolution of concentric circles adopts the four-step phase shift method and the dual-frequency heterodyne method, and the phase deconvolution of spiral stripes adopts the eight-step phase shift method, where: Fig. 9 As shown in the left figure, eight circular center fringes with different periods and different phase shift steps are evenly placed in the channel of the circular grating (such as the red channel); Fig. 9 The right figure shows that spiral stripes are placed in the channel of the circular grating (such as the green channel); after each projection and acquisition of the color stripe pattern, the physical grating rotates counterclockwise Projection acquisition. A total of 8 acquisitions were made, and the grating rotated exactly once, so 8 color images were obtained. The color images were decomposed according to the color channels to obtain 8 groups of red stripes and green stripes. The red stripes were spliced according to the predetermined area numbers to obtain 8 concentric circle phase shift images. The green stripes did not require any operation, and they corresponded to spiral stripes with different phase shift steps.
[0104] In the present invention, concentric circles and spiral stripes are used for encoding, and radial phase and angular phase information can be obtained. According to the conversion relationship between the polar coordinate system and the rectangular coordinate system, the radial phase and angular phase can be converted to a rectangular coordinate system in any direction, that is, the phase information along any direction can be obtained. In a 360-degree measurement scenario like a circular cylinder wall, the problem of being unable to calculate the depth due to the polar line being nearly perpendicular to the phase change direction will not occur.
[0105] Compared with the structured light coding scheme of concentric circle stripes, the present invention introduces spiral phase-shift stripes with angle information. When performing phase height mapping, it is not necessary to ensure that the projector and the camera are strictly coaxial, and good reconstruction effects can be obtained under approximately coaxial experimental conditions.
[0106] See also Figure 7 As shown, Figure 7 This is a schematic diagram of a coaxial monocular structured light 3D measurement system based on phase-height mapping. The purpose of the coaxial system is to avoid the problem that traditional triangulation cannot be fully reconstructed in one go due to occlusion when measuring scenes such as the inner wall of a pipe.
[0107] Previously, there were two main structured light solutions for this system: projecting horizontal and vertical phase-shifted stripes, and projecting concentric phase-shifted stripes. For the former, due to the existence of epipolar constraints, the more the epipolar line corresponding to the object point deviates from the phase-shifted encoding direction, the worse the reconstruction accuracy; for the latter, due to the lack of angle information constraints in the concentric phase, if the system cannot be strictly coaxial, the reconstruction effect is very poor. The new encoding and decoding solution based on concentric circles and spiral stripes can perfectly solve these problems.
[0108] It should be understood that, although described in a certain order, these steps are not necessarily performed in sequence in the above order. Unless there is clear explanation in this article, the execution of these steps does not have strict order restriction, and these steps can be performed in other orders. Moreover, a part of the steps of the present embodiment may include a plurality of steps or a plurality of stages, and these steps or stages are not necessarily performed at the same time, but can be performed at different times, and the execution order of these steps or stages is not necessarily performed in sequence, but can be performed in turn or alternately with at least a part of the steps or stages in other steps or other steps.
[0109] In one embodiment, the present invention provides a structured light encoding and decoding system based on concentric circles and spiral phase-shift stripes, which is used to execute the structured light encoding and decoding method based on concentric circles and spiral phase-shift stripes, and the system includes:
[0110] The projection module is responsible for projecting two sets of radially encoded concentric fringe phase shift patterns with different frequencies and a set of radially and circumferentially encoded spiral fringe phase shift patterns onto the object to be tested;
[0111] A camera module, including one or more high-resolution cameras, for collecting the fringe coding pattern modulated by the surface of the object to be measured;
[0112] A synchronization control module, used to coordinate the camera and the projection module to perform phase shift and collect a phase shift map;
[0113] The data processing module is used to obtain the radius phase and angle phase values corresponding to the surface points of the object to be measured in the camera image coordinate system by calculating and processing the collected phase shift map; and calculate the true depth information of each object point based on the obtained radius phase and angle phase by applying the triangulation principle;
[0114] User interface: allows the user to input parameters, start the measurement process and view the measurement results; Power management unit: provides stable power to various components of the system and includes power adapter and power distribution circuit.
[0115] Calibration module: used to calibrate the system to ensure that the geometric relationship between the projection module and the camera module is accurate;
[0116] Peripheral equipment: includes interfaces, brackets and housings for data transmission.
[0117] The structured light encoding and decoding system based on concentric circle and spiral phase-shift stripes of the present invention utilizes concentric circle and spiral phase-shift stripes to perform three-dimensional measurement and reconstruction of objects, and combines concentric circle stripes and spiral stripe phase-shift patterns to capture the precise three-dimensional shape of the object to be measured, providing an efficient and accurate three-dimensional measurement tool for industrial inspection, cultural heritage recording, medical imaging and other fields.
[0118] In this embodiment, the structured light encoding and decoding system based on concentric circles and spiral phase-shift stripes adopts the steps of a structured light encoding and decoding method based on concentric circles and spiral phase-shift stripes as mentioned above during execution. Therefore, the operation process of the structured light encoding and decoding system based on concentric circles and spiral phase-shift stripes will not be introduced in detail in this embodiment.
[0119] In one embodiment, a computer device is also provided in an embodiment of the present invention, comprising at least one processor and a memory communicatively connected to the at least one processor, wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor performs the steps of the structured light encoding and decoding method based on concentric circles and spiral phase-shift stripes.
[0120] In one embodiment, the present invention further provides a computer-readable storage medium storing computer instructions, wherein the computer instructions are used to enable the computer to execute the steps of the structured light encoding and decoding method based on concentric circles and spiral phase-shift stripes.
[0121] A person skilled in the art can understand that all or part of the processes in the above-mentioned embodiments can be realized by instructing the relevant hardware through a computer program represented by computer instructions, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application can include at least one of non-volatile and volatile memory.
[0122] Non-volatile memory may include read-only memory, magnetic tape, floppy disk, flash memory or optical storage, etc. Volatile memory may include random access memory or external cache memory. As an illustration and not limitation, RAM may be in various forms, such as static random access memory or dynamic random access memory, etc.
[0123] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention should be included in the protection scope of the present invention.
Claims
1. A structured light encoding and decoding method based on concentric circles and spiral phase-shifted stripes, characterized in that: The method comprises the following steps: Projecting two groups of radially encoded concentric fringe phase shift patterns with different frequencies and a group of radially and circumferentially encoded spiral fringe phase shift patterns onto the object to be tested; Using a camera to collect the fringe coding pattern modulated on the surface of the object to be measured; By calculating and processing the collected phase shift map, the radius phase and angle phase values corresponding to the surface point of the object to be measured in the camera image coordinate system are obtained; The triangulation principle is applied to calculate the true depth information of each object point based on the acquired radius phase and angle phase.
2. The structured light encoding and decoding method based on concentric circles and spiral phase-shifted stripes according to claim 1, characterized in that: The N-step phase shift method is used for projection onto the object to be measured, and phase shift is performed according to a predetermined number of steps N to obtain N phase shift images, and each set of fringe phase shift patterns includes several phase shift states.
3. The structured light encoding and decoding method based on concentric circles and spiral phase-shifted stripes as claimed in claim 2, characterized in that: Obtaining the radius phase and angle phase values includes the following steps: Dephase the two groups of projected concentric fringe phase shift images of different frequencies to obtain two concentric truncated phase images; The dual-frequency heterodyne method is used to perform phase unwrapping processing on the first concentric circle truncated phase according to the phase difference between the two truncated phase images, and a continuous phase covering the entire field of view, namely the radial phase, is obtained. Dephase the spiral fringe phase shift image to obtain the truncated phase image of the spiral line; The truncated phase image of the spiral line is subtracted from the first truncated phase image of the concentric circle with the same frequency to obtain the continuous phase covering the entire field of view, that is, the angular phase.
4. The structured light encoding and decoding method based on concentric circles and spiral phase-shifted stripes as claimed in claim 3, characterized in that: Using a camera to collect the modulated stripe coding pattern on the surface of the object to be measured is to use a camera to collect the modulated reflected light pattern on the surface of the object, wherein the reflected light pattern contains coding information of concentric circle stripes and spiral stripes.
5. The structured light encoding and decoding method based on concentric circles and spiral phase-shifted stripes as claimed in claim 3, characterized in that: The unfolding of the truncated phase in the structured light encoding and decoding method based on concentric circles and spiral phase-shift stripes includes the following steps: Taking the origin of the camera image coordinate system as the starting point, sinusoidal phase shift encoding is performed along the radial direction to generate a phase shift map; Apply the classic phase shift solution formula to solve the truncated phase corresponding to each pixel of the camera; Unwrap the truncated phase so that the phase distribution covers the entire camera field of view; At the same time, sinusoidal phase shift encoding is performed in radial and circumferential directions to generate a spiral phase shift diagram, and the classical phase shift decomposition formula is applied to obtain a truncated phase distribution, which contains both radial and angular phase information; Combined with the radius phase information, the angle phase is obtained to mark the position information of all object points in the camera field of view in the image coordinate system.
6. The structured light encoding and decoding method based on concentric circles and spiral phase-shifted stripes as claimed in claim 5, characterized in that: The truncated phase is unwrapped using a dual-frequency unwrapping method or a Gray code-assisted unwrapping method.
7. The structured light encoding and decoding method based on concentric circles and spiral phase-shifted stripes according to claim 1, characterized in that: Two sets of radially encoded concentric fringe phase shift patterns with different frequencies and a set of radially and circumferentially encoded spiral fringe phase shift patterns are projected onto the object to be tested, including: Projecting a set of radially encoded concentric fringe phase shift patterns onto the object to be measured; Projecting a set of spiral fringe phase shift patterns with the same frequency encoded in radial and circumferential directions onto the object to be measured; Another set of concentric fringe phase shift patterns of different frequencies is projected onto the object to be tested.
8. The structured light encoding and decoding method based on concentric circles and spiral phase-shifted stripes according to claim 7, characterized in that: The structured light encoding and decoding method based on concentric circle and spiral phase shift stripes also includes: exchanging the concentric circle fringe phase shift map and the spiral fringe phase shift map, first projecting two groups of spiral fringe phase shift maps with different frequencies, and then projecting a group of concentric circle fringe phase shift maps.
9. A structured light encoding and decoding system based on concentric circles and spiral phase-shifted stripes, characterized in that: Used to execute the structured light encoding and decoding method based on concentric circles and spiral phase-shift stripes as described in any one of claims 1 to 8, the structured light encoding and decoding system based on concentric circles and spiral phase-shift stripes comprises: The projection module is responsible for projecting two sets of radially encoded concentric fringe phase shift patterns with different frequencies and a set of radially and circumferentially encoded spiral fringe phase shift patterns onto the object to be tested; A camera module, including one or more high-resolution cameras, for collecting the fringe coding pattern modulated by the surface of the object to be measured; A synchronization control module, used to coordinate the camera and the projection module to perform phase shift and collect a phase shift map; The data processing module is used to obtain the radius phase and angle phase values corresponding to the surface points of the object to be measured in the camera image coordinate system by calculating and processing the collected phase shift map; and to calculate the true depth information of each object point based on the obtained radius phase and angle phase by applying the triangulation principle.
10. The structured light encoding and decoding system based on concentric circles and spiral phase-shift stripes as claimed in claim 9, characterized in that: Also includes: User interface: allows the user to input parameters, start the measurement process and view the measurement results; Power management unit: provides stable power to various components of the system and includes power adapter and power distribution circuit; Calibration module: used to calibrate the system to ensure that the geometric relationship between the projection module and the camera module is accurate; Peripheral equipment: includes interfaces, brackets and housings for data transmission.
Citation Information
Patent Citations
Depth measurement and edge extraction method based on single all-dielectric metasurface
CN116777970A
Super-structure lens three-dimensional microscopic imaging system and method based on double-helix point spread function
CN117631244A
