1 Introduction

Fringe projection profilometry (FPP) is widely used in 3D shape measurement for its non-contacting operation, full-field acquisition, fast data processing and high resolution. It has found various applications in diverse fields: online measurement, quality control, reverse engineering, relic restoration, and product design [13].

The main methods utilized to measure complex surface are dual-frequency FPP [4], multi-frequency FPP [5], Gray code plus phase-shifting method [6], and so on. Gray code plus phase-shifting method determines the codeword from image intensity rather its phase. However, the codeword is less robust for measuring high contrast surface and limited to 2m (here, m is the number of Gray code patterns). Wang et al. proposed a novel absolute phase recovery technique with phase coding [7]. It not only produces more codewords but also receives more robust measurement result for different fringes image brightness. Based on the former foundation, Zheng proposed a method that projected two sets of phase coding fringes to address the difficulty in judging the fringe order [8]. Chen added a corrected method to make the phase-unwrapping algorithm more stable [9].

Many methods had been proposed to solve the period broadening of sinusoidal fringe. Sansoni et al. calibrated a whole-field optical profilometer and evaluated the measurement performance of system [10]. Chen and Wang et al. determined the relationship between the fringe period of the projection plane and that of the reference plane. The authors also obtained the phase on the reference plane through the least-squares method [1113]. Rajoub et al. presented a new model to measure object shape using non-collimated fringe-pattern projection [14]. Zhang and Fu et al. proposed a novel uneven fringe projection technique to obtain evenly spaced fringe in the measurement volume. The technique simplified the relationship between the measured phase and the depth of object [1517]. Feng et al. proposed a method to generate a fringe image of periodic consistency by homography relationship without considering the complex projection angle deflection or the projection lens distortion model [18].

However, the period broaden problem of phase coding fringe still remains a challenge. Period correction method of phase coding fringe is proposed. The rest of the paper is organized as follows. Section 2 describes the principles of the proposed method. Section 3 presents the experiments and results. Section 4 provides the conclusion.

2 Principle

2.1 Measurement system

The measurement system based on triangulation is shown in Fig. 1. Point E and C are the optical center of the digital light processing (DLP) and the charge-coupled-device (CCD) camera, respectively. They have the same distance which is noted as l 0 from the reference plane. d is the distance between the entrance pupil of the CCD camera and the exit pupil of the projector. The optical axis of the projector and that of the CCD camera intersect at origin point O. The fringe is projected onto the measured object. The deformed fringe pattern is captured by the CCD camera. The height of the measured object can be expressed as follows: [19]

$$h = \frac{{l_{0} \Delta \varphi }}{{2\pi f_{0} d + \Delta \varphi }}.$$
(1)

Here, f 0 is the spatial frequency of the sinusoidal fringe pattern on the reference plane. Δφ is the phase difference between the corresponding point on the object and reference plane. The parameters l 0, d and f 0 are obtained by calibration. The verticality and parallel of the system are calibrated by the method of Ref. [20].

Fig. 1
figure 1

Measurement system

2.2 Flowchart of the proposed corrected method

The corrected method that combines the phase coding fringe with sinusoidal fringe is proposed in this paper. It can be roughly explained using the flowchart below:

First, the non-uniform sinusoidal fringes (shown in Sect. 2.3) and the non-uniform phase coding fringes (shown in Sect. 2.4) are successively projected by DLP. Then, the corrected uniform fringe patterns are obtained on the reference and captured by CCD camera. The wrapped phase and the fringe order are achieved by sinusoidal fringes and phase coding fringes, respectively. Finally, the unwrapped phase can be retrieved. Figure 2 shows the flowchart of the proposed corrected method.

Fig. 2
figure 2

Flowchart of the proposed corrected method

2.3 The generated principle of non-uniform sinusoidal fringe

The model of corrected method is exploited and shown in Fig. 3. X is the axis of the reference plane. X′ is the x axis of the virtual reference plane perpendicular to the optical axis of the projector. X″ is the x axis of the projector plane.

Fig. 3
figure 3

Model of corrected method

In the ref. [17], the phase of sinusoidal fringe based on the four-step phase-shifting method has the period correction function:

$$\phi (x^{\prime \prime } ,y) = \frac{{2\pi \cdot f_{o} \cdot (l_{o}^{2} + d^{2} ) \cdot M \cdot x^{\prime \prime } }}{{l_{o} \cdot \sqrt {l_{o}^{2} + d^{2} } - M \cdot x^{\prime \prime } \cdot d}}\; + \;\frac{\pi \cdot N}{2},\;\;\;N\; = \;0,\;1,\;2,\;3.$$
(2)

Here, M is magnification and N is the N-th phase shift.

The corrected sinusoidal fringe can be coded by the phase \(\phi (x^{\prime \prime } ,y)\) and its intensity on the camera is as follows:

$$I_{N} (x,y)\; = \;a(x,y)\; + \;b(x,y)\cos [\phi (x^{n} ,y)],\;\;N\; = \;0,\;1,\;2,\;3.$$
(3)

Here, \(a\left( {x,y} \right)\) is the average intensity and \(b\left( {x,y} \right)\) is the intensity modulation.

From these four intensity patterns, the phase function can be computed as:

$$\varphi (x,y) = \arctan \left[ {\frac{{I_{3} - I_{1} }}{{I_{2} - I_{0} }}} \right] .$$
(4)

The phase values are wrapped into the range \(\left( { - \pi ,\pi } \right)\), phase unwrapping must be carried out to retrieve the unwrapping phase.

2.4 The generated principle of non-uniform phase coding fringe

The non-uniform phase coding fringe is generated according to the rule of non-uniform sinusoidal fringe. The following rounds state the generating principle:

Round 1: generate four non-uniform sinusoidal fringe patterns in the computer according to Sect. 2.3.

Here, 16 periods non-uniform sinusoidal fringe is simulated as an example. The pattern with 0° phase shift is shown in Fig. 4.

Fig. 4
figure 4

Non-uniform sinusoidal fringe with 00 phase shift

Round 2: obtain the non-uniform wrapped phase using Eq. (4).

It is important to note that the non-uniform wrapped phase is obtained by above simulated non-uniform sinusoidal fringe. The blue line represents the non-uniform wrapped phase in Fig. 5.

Fig. 5
figure 5

Non-uniform wrapped phase and fringe order

Round 3: count the period number of non-uniform wrapped phase and mark it as fringe order \(k\left( {x,y} \right)\),which is shown by green line.

Here, we mark the first fringe order as \(k\left( {x,y} \right) = 0\) and the following increase successively, as shown in Fig. 5.

Round 4: convert the fringe order into coding phase \(\varphi (x,y)\):

$$\varphi (x,y) = - 3.14 + 2 \times 3.14 \cdot \frac{k(x,y)}{\hbox{max} (k(x,y))} .$$
(5)

Here, max(·) is the maximal value of \(k\left( {x,y} \right)\). The coding phase \(\varphi (x,y)\) ranging from −3.14 to 3.14 is shown in Fig. 6.

Fig. 6
figure 6

Distribution of the coding phase

Round 5: implant the coding phase into phase coding fringe based on four-step phase shifting.

$$I{_{N}}^{\prime } (x,y) = [0.5 + 0.5 \cdot \cos (\varphi (x,y) + \frac{N \cdot \pi }{2})] \cdot 255\begin{array}{*{20}c} {} & , & {N = 0,1,2,3} \\ \end{array} .$$
(6)

At last, the non-uniform phase coding fringe is generated, and the fringe with 0° phase shift is shown in Fig. 7.

Fig. 7
figure 7

Non-uniform phase coding fringe with 00 phase shift

3 Experiments and results

The FPP measurement system consists of three parts: a Samsung DLP projector with the resolution of 1024 × 768, a black and white CCD camera (DH-HV 135 1UC) with focal length of 12.5 mm, and a 2.8 GHZ dual-core computer. The period of the sinusoidal fringe is the same as that of the phase coding fringe, and its period number is 32. d is 44.003 ± 0.025 cm, and l 0 is 156.002 ± 0.032 cm. Figure 8 is the image of the experiment setup.

Fig. 8
figure 8

Image of the experiment setup

3.1 The measurement experiment of a standard board

A standard board (900 mm × 24.5 mm × 24.5 mm) was measured by the corrected and the uncorrected fringes to verify the effectiveness of the proposed method. Figure 9 shows above-mentioned fringe patterns with 00 phase shift on the standard board. The 3D shape is reconstructed, respectively, as shown in Fig. 10. The measured height using corrected fringe is almost the same, as shown in Fig. 10a. However, the measured height using uncorrected fringe is gradually varied, as shown in Fig. 10b. Meanwhile, Fig. 11 shows the 33-th row of the measured height. Figure 11a shows that the measured height with correction fluctuates near actual height. Figure 11b depicts that the measured height without correction has a monotonically declining trend overall.

Fig. 9
figure 9

Fringe patterns with 0° phase shift on the standard board: a with correction b without correction

Fig. 10
figure 10

The 3D shape of the standard board: a with correction b without correction

Fig. 11
figure 11

The 33-th row of the standard board: a with correction b without correction

Compared with the standard height, the measured error is presented in Fig. 12. The height error in Fig. 12b is almost ten times than that in Fig. 12a. The experimental results illustrate that the proposed method plays a positive role to overcome the fringe broaden.

Fig. 12
figure 12

The height error of the standard board: a with correction b without correction

3.2 The measurement experiment of a foam holder

A foam holder (700 mm × 400 mm × 20 mm) with complex larger surface was measured to demonstrate the reliability of the proposed method. Figure 13 is the corrected fringe patterns with 90° phase shift on the foam holder.

Fig. 13
figure 13

Corrected fringe patterns with 90° phase shift on the foam holder: a sinusoidal fringe b phase coding fringe

Figure 14a and b is the unwrapped phase on the reference plane and the foam holder, respectively. Then, the unwrapped phase difference can be obtained. At last, 3D shape is obtained by Eq. (1), which is exhibited in Fig. 15. Compared with the 3D shape measured by a CMM (coordinate measuring machine), the RMS (root mean square) error of the proposed method is 0.15 mm.

Fig. 14
figure 14

The unwrapped phase: a on the reference plane b on the foam holder

Fig. 15
figure 15

The retrieved 3D shape result

3.3 The measurement experiment of standard gauge block

Five standard gauge blocks with different heights were measured by the proposed method to further verify the measurement accuracy. The measured area is about 800 mm × 800 mm. Figure 16a and b shows the five standard gauge blocks modulated by sinusoidal fringe and phase coding fringe, respectively. Figure 17 shows the 3D shape of the five standard gauge blocks obtained using the proposed method. Table 1 lists the absolute error and RMS error for each standard gauge block. It can be seen that the maximum absolute error is 0.081 mm and the maximum RMS error is 0.073 mm. The quantitative analysis shows the accuracy of the proposed method.

Fig. 16
figure 16

Five standard gauge blocks modulated by corrected fringes: a sinusoidal fringe b phase coding fringe

Fig. 17
figure 17

The 3D shape of five standard gauge blocks

Table 1 Experimental results on standard gauge blocks (unit: mm)

4 Conclusion

The proposed method can solve the broadening of phase coding fringe and improve the measurement accuracy. Therefore, the method based on the corrected phase coding fringe and the corrected sinusoidal fringe can measure the larger object with complex surface. Especially,it can measure surface with different contrasts [7]. Furthermore, the period corrected method can be easily transplanted to other coding fringes, such as Binary coding fringe or Gray coding fringe.