MOIRÉ PATTERNS FROM A CCD CAMERA
Are They Annoying Artifacts or Can They be Useful?
Tong Tu and Wooi-Boon Goh
School of Computer Engineering, Nanyang Technological University, Singapore 639798, Singapore
Keywords: Moiré pattern analysis, Image-based metrology, Surface reconstruction.
Abstract: When repetitive high frequency patterns appear in the view of a charge-coupled device (CCD) camera,
annoying low frequency Moiré patterns are often observed. This paper demonstrates that such Moiré pattern
can useful in measuring surface deformation and displacement. What is required, in our case, is that the
surface in question is textured with appropriately aligned black and white line gratings and this surface is
imaged using a grey scaled CCD camera. The characteristics of the observed Moiré patterns are described
along with a spatial domain model-fitting algorithm that is able to extract a dense camera-to-surface
displacement measures. The experimental results discuss the reconstruction of planar incline and curved
surfaces using only a coarse 33 lines per inch line grating patterns printed from a 600 dpi printer.
1 INTRODUCTION
Moiré patterns are the results of the interference
fringes produced by superimposing two sets of
repetitive gratings. These patterns are used in
metrology for tasks such as strain measurements,
vibration analysis and the 3D surface reconstruction
(Kafri, 1990), (Walker, 2004), (Creath, 2007). Moiré
images are normally obtained using a camera to
capture the patterns generated by superimposing two
alternating opaque-transparent Ronchi gratings
(Khan, 2001) or two projected light patterns.
In this work, the imaging device itself plays the
role of one of the grating with its regular 2D
repetitive arrangement of charged-coupled cell
arrays. This camera is then used to observe another
grating. The interaction between the two ‘gratings’
results in the formation of Moiré patterns, which can
be simply captured by the CCD camera itself. This
imaging device-based approach of using Moiré
fringes for surface displacement measurement was
suggested by (Chang, 2003), where they
demonstrated how wavelet transform (WT) could be
used to extract the pitch of the Moiré fringes for
micro-range measurement. A micro-pitch grating of
300 lines per inch (lpi) was employed as the
specimen grating so that the pitch dimensions of the
grating is close to that of the CCD cell spacing. This
situation produces Moiré fringe patterns (see Fig. 2)
that do not suffer annoying artufacts, making it
relatively easy to extract the peak-to-peak fringe
pitch. Unfortunately, peak-to-peak pitch values are
only useful in providing distance measurements of
flat surfaces perpendicular to the imaging plane.
Their approach cannot be readily used to generate a
dense varying depth map of the surface.
We propose using specimen grating with
relatively larger pitch ( 33 lpi), which can be easily
printed with a 600 dpi laser printer. Unfortunately,
such coarse pitch result in Moiré patterns that
contain high frequency artifacts (see Fig. 3b), which
embeds the desired Moiré fringe waveform. We
discuss some property resulting from employing the
CCD array as a reference grating that allows these
artifacts to be easily removed. We also present a
spatial domain model-fitting algorithm for
measuring the instantaneous pitch width of the
Moiré fringes, thus allowing the reconstruction of
dense depth profiles.
2 THE MOIRÉ PATTERNS
2.1 Near Similar Pitch Gratings
Let the pitch width of the reference and specimen
gratings be p
r
and p
s
respectively. In Fig. 1(a), we
have a situation where the pitch of p
s
> p
r
, but only
slightly. As a result, lower frequency Moiré fringes
(light) with period p
m
results due to the repeated and
51
Tu T. and Goh W. (2009).
MOIRÉ PATTERNS FROM A CCD CAMERA - Are They Annoying Artifacts or Can They be Useful? .
In Proceedings of the Fourth International Conference on Computer Vision Theory and Applications, pages 51-58
DOI: 10.5220/0001807700510058
Copyright
c
SciTePress
regular maximum overlap of the two sets of dark
lines. Dark fringes are observed in zones of
minimum overlap. Assuming no relative rotation
between the two line gratings, the Moiré fringe
pitch, p
m
is given by the well known equation [6]
||
sr
sr
m
pp
pp
p
×
=
(1)
Reference line grating
p
r
p
s
Moiré frin
g
e
p
itch,
p
m
Specimen line grating
(a)
1 2
3 4
p
s
’= p
r
+ p
s
Moiré fringe pitch, p
m
rrs
ppp <
p
r
(b)
rrs
ppp >
p
r
p
s
1
2
3
4
Figure 1: Resulting pitch for the Moiré fringes generated
when the specimen grating pitch is (a) only slightly larger
than the reference grating pitch and (b) much larger than
the reference grating pitch. Notice the Moiré fringe pitch
is made up of k = 3 specimen grating pitches in both cases.
Assume the reference line grating is now
replaced by a regular-pitched CCD imaging cells.
Fig. 2a shows the resulting 1-D image intensity
profile. Notice that the extracted period p
m
of the
Moiré fringe pattern can be easily obtained as there
are no specimen line grating artifacts, as observed
with the 300 lpi line gratings used in (Chang, 2003).
(b)
Specimen grating
(
a
)
2
4
6
8
1
0
1
2
1
4
Moiré fringe pattern
Image Intensity
CCD cells
p
s
P
m
p
r
Equi-spaced CCD cells
2 4 6 8 1
0
1
2
1
4
Moiré fringe pattern
Image Intensity
CCD cells
P
m
p
r
p
s
p
r
= 40, p
s
=46 p
r
= 40, p
s
=48
Figure 2: Moiré fringe patterns obtained when using point
spread integration of the specimen grating intensity falling
on regularly-spaced CCD cells. The image intensity
profile obtained when the CCD pitch (reference grating)
and the specimen line grating pitch are (a) p
r
= 40,
p
s
= 46 and (b) p
r
= 40, p
s
= 48 spatial units respectively.
As given in eqn. (1), the further p
r
is from p
s
, the narrower
is the Moiré fringe pitch p
m
.
2.2 Larger Pitch Gratings
What happens when the pitch of the specimen
grating, p
s
is much larger than that of the reference
grating, p
r
, as shown in Fig. 1b? We now derive a
new expression for the Moiré fringe pitch, p
m
for
the situation shown in Fig. 1b where
rrs
ppp >
since the fringe pitch expression given in eqn. (1) is
only valid for the situations shown in Fig. 1a, where
rrs
ppp <
. In order to make use of eqn. (1), we
need to subtract the largest integer multiple of the
reference pitch p
r
from the large specimen line
grating pitch p
s
. The remaining pitch value after
subtraction, given by
s
p
ˆ
is less than p
r
and can
therefore be substituted into eqn. (1) to compute the
Moiré fringe pitch p
m
. In Fig. 1b, we illustrate an
example where this remaining pitch
s
p
ˆ
is similar to
the specimen grating pitch p
s
in Fig. 1a. As shown in
Fig. 1a, if the width of the Moiré fringe pitch p
m
is
made up of k × p
s
width (example in Fig 1 has k =
3), then the fringe pitch p
m
of the wide specimen
grating will also be given by k × p
s
. From eqn. (1),
the number of specimen line grating, p
s
making up
the Moiré fringe pitch width, p
m
is given by
sr
r
s
m
pp
p
p
p
k
==
(2)
If p
s
′>>p
r
, we need to find the maximum number
of integer multiples of p
r
within p
s
given by
=
r
s
p
p
m
'
(3)
where ⎣⎦ is a flooring function. The remaining
pitch
s
p
)
after removing multiples of p
r
is given by
rss
mppp = '
ˆ
],0[
r
p
(4)
The number of specimen line grating pitch width
contained within the Moiré fringe pitch can be
obtained by substituting (4) into (2), and is given by
sr
r
pp
p
k
ˆ
=
(5)
We can now compute the Moiré fringe pitch, p
m
for the large specimen line grating with pitch p
s
from eqns. (4) and (5) and this is given by
')1(
'
ˆ
'
''
sr
sr
sr
sr
sm
ppm
pp
pp
pp
pkp
+
=
=×
=
(6)
From this general expression of the Moiré fringe
pitch, we can observe that the presence of the (1+m)
VISAPP 2009 - International Conference on Computer Vision Theory and Applications
52
factor ensures that the absolute value of the
denominator of both eqns. (1) and (6) will not
exceed 1. This means the increase in specimen
grating pitch p
s
will produce a fringe pitch p
m
that
is equally magnified, as shown in Fig. 3b.
2.3 Removing Grating Artifacts
5 10 15 20 25 30 35 40
(b)
Specimen line gratings
(
a
)
Moiré frin
g
e pattern
Image Intensity
CCD cells
p
m
p
r
Moiré fringe pattern
CCD cells
p
m
p
r
=40, p
s
=48
p
r
=40, p
s
=88
5 10
15
20 25 30 35 40
....................
p
r
Equi-spaced CCD cells
p
s
p
s
Figure 3: 1D Moiré fringe patterns obtained with specimen
line gratings of different pitch widths. In both cases, the
reference grating p
r
= 40. Specimen line grating pitch in
(a) p
s
= 48 and in (b) p
s
= 88, (i.e. m = 1). In both cases,
the remaining pitch widths
8
ˆ
=
s
p
.
The resulting Moiré pattern produced when m >1
(see Fig. 3b) contains high frequency artifacts from
the specimen line grating, which, makes automatic
fringe pitch estimation difficult.
5 10 15 20 25 30 35 40
0
0.2
0.4
0.6
0.8
1
2 4 6 8 10 12 14 16 18 20
0
0.2
0.4
0.6
0.8
1
Ima
g
e Intensit
y
After sub-sampling every other even pixel intensity value
Ima
g
e Intensit
y
Full resolution Moiré pattern
11 pixels
11 pixels
Figure 4: Removing line grating artifacts by sub-sampling.
Notice the pitch width (i.e. 11 pixels) of the Moiré fringe
remains unchanged after sub-sampling.
Since the reference grating pitch p
r
is the pitch of
the CCD cell and therefore the pixel width, we can
quickly remove these high frequency artifacts by
sub-sampling the Moiré pattern waveform as shown
in Fig. 4. For situations where m =1, down-sampling
is done by selecting every other pixel in the original
N × N sized image to form new image of size
N/2×N/2. It is unimportant whether the even or the
odd pixels are removed as this only results in a
phase shift. When the value of (1+m) in eqn. (6) is
3, we can obtain an artifact-free waveform by sub-
sampling every other 3
rd
pixel. When (1+m) is 4, we
sub-sample every other 4
th
pixel and so on.
Given that the true pitch of the specimen grating
is given by S. If we assume a thin lens (pin-hole)
camera model and the distance of the surface of the
specimen to the centre of projection given by d is
relatively larger than the focal length of the camera
given by f, the specimen grating pitch p
s
can be
approximated by
d
fS
p
s
='
(7)
Putting (7) into (6) and rearranging, we get
+
+
=
rm
ppm
fS
d
1
'
1
)1(
(8)
Given that f, S, and p
r
are constants, the distance d
from the camera has an inversely proportional
relation to the measure Moiré fringe pitch, p
m
.
2.4 CCD Cell Summation Model
The observed Moiré pattern is formed from the
accumulation of individual CCD cell summation of
the specimen line grating intensities. But how would
the intensity summation model influence the shape
of the resulting Moiré waveform? We obtained
simulation results for three hypothetical summation
models (see Fig. 5), namely impulse, Gaussian and
uniform. Fig. 6 shows the resulting 1D Moiré pattern
waveform for each of the summation models. Notice
that the shape of the waveform is dependent on the
CCD integration function but the fundamental
frequency, which is related to the Moiré fringe pitch
width, remains unchanged.
0
5
10 15 20 25 30 35 40
0
0.1
0.2
0.3
0.4
0.5
0.6
0.7
0.8
0.9
1
Gaussian
Impulse
Unit
Figure 5: Three different intensity summation models for
the hypothetical CCD cell.
From eqn. (8), the pitch period of the sub-
sampled Moiré waveform provides a reciprocal
description of the surface displacement d from the
camera. As such, the instantaneous frequency (i.e.
reciprocal of pitch) of the fundamental sinusoid of
the waveforms shown in Fig. 6 will allow us to
reconstruct a dense surface depth profile along a
MOIRÉ PATTERNS FROM A CCD CAMERA - Are They Annoying Artifacts or Can They be Useful?
53
selected 1D cross-section of the Moiré image. This
is achieved independently of the assumed CCD cell
summation model. We next describe an algorithm to
extract the instantaneous frequency of a 1D sub-
sampled Moiré pattern waveform.
(a)
(b)
5 10 15 20 25 30
(c)
Gaussian
Impulse
Uniform
Figure 6: The resulting Moiré waveform using (a)
Gaussian point spread, (b) impulse and (c) uniform CCD
cell intensity summation model.
3 EXTRACTING DEPTH
Fig. 7(c) shows the sub-sampled waveform obtained
from a 1D cross-section of a Moiré pattern image
obtained for a curved line grating surface. The
varying intensity could be due to shadows or uneven
ambient lighting during imaging.
200 400 600
0
50
100
150
200
250
image intensity
pixel
position
0 20 40 60 80 100 120 140 160
0
50
100
150
200
250
Down-sampled waveform, s(n)
Moiré pattern image
Waveform at cross section
Sub-sample every
other 4
th
pixel
pixel position (n)
image intensity
(a)
(b)
(c)
Figure 7: (a) Moiré pattern image of a curved line gating
surface acquired under uneven lighting condition. (b) The
full resolution intensity profile along the dotted (red)
cross-section. (c) The waveform with the line grating
artifact removed by sub-sampling every other 4
th
pixel in
the original 1D cross section of the Moiré pattern image.
Notice that the sub-sampled waveform s(n) in
Fig. 7(c) can be viewed as a multi-component time-
varying amplitude and frequency modulated (AM-
FM) signal that is riding on a time-varying bias. In
order, to extract the varying pitch period of the
signal, we need to extract the instantaneous
frequency of the fundamental sinusoid taking into
account the varying bias and amplitude of the signal.
We modelled the fundamental AM-FM sinusoid by
modifying the least-squares truncated power series
approximation (L-STPSA) model approach of (Goh
2007) with an additional time-varying bias. Firstly,
the sub-sampled waveform s(n) is converted to a
positive-negative going zero-mean signal x(n) using
=
=
N
k
ks
N
nsnx
1
)(
1
)()(
(9)
3.1 The L-STPSA AM-FM Model
An AM-FM sinusoidal signal
~
()xn
with a varying
bias given by v(n) can be represented by
)()](cos[)()(
~
nvnnwnAnx
c
+
+
=
θ
(10)
where w
c
is a fixed carrier frequency with
varying amplitude A(n). The instantaneous
frequency f(n) is the derivative of the varying phase
θ
(n) and is given by
π
θ
2
])([
)(
dnndw
nf
c
+
=
(11)
The signal x(n) can be expanded to its in-phase
and quadrature sinusoidal components given by
(
)
(
)
[
]
(
)()
[]
)(sincos)(
~
nvnnwnbnnwnanx
cc
++++=
θθ
(12)
where a(n) and b(n) are given by
))(cos()()( nnAna
θ
=
and
))(sin()()( nnAnb
θ
=
(13)
If we assume the functions that describe the
varying amplitude A(n) and phase
θ
(n) are analytic,
then such functions can be approximated by a power
series. As an example, cos x is given by the series
...!6!4!21cos
642
++= xxxx
(14)
We can now model the components of
~
()xn
and
the varying bias v(n) as general truncated power
series of orders P and R respectively, given by
=
=
P
k
k
k
anna
0
)(
,
=
=
P
k
k
k
bnnb
0
)(
,
=
=
R
j
j
j
vnnv
0
)(
(15)
The modelling process starts by assuming there
are no phase variations (i.e.
θ
(n) = 0). Then, given a
signal x(n) of sample length N, the modelled signal
~
()xn
in eqn. (10) can be estimated by minimising the
mean squared-error
ε
in (16) with respect to the
(P+1) pairs of amplitude coefficients, the (R+1) bias
coefficients and predetermined carrier frequency w
c
.
2
1
)}()(
~
{ nxnx
N
n
=
=
ε
(16)
VISAPP 2009 - International Conference on Computer Vision Theory and Applications
54
Here, the coefficients estimation in (Goh, 1998)
is extended with a further (R+1) equations to solve
for the varying bias v(n). Since the varying phase is
estimated iteratively, it is not important what the
predetermine carrier frequency w
c
is as long as it is a
frequency component present in the waveform. We
chose w
c
by picking the frequency corresponding to
the highest peak frequency in the power spectrum of
the waveform x(n). (Goh, 2007) showed that the
current estimate of the varying phase is given
()
() ()
() ()
+
+
=
)(sin)()(cos)(
)(sin)()(cos)(
arctan
ˆ
nnbnna
nnannb
n
θθ
θθ
θ
(17)
From eqn. (15), both a(n) and b(n) can be
estimated from the (P +1) a
k
and b
k
coefficients
using the L-STPSA model of order P. With initial
values of
θ
(n) = 0, we make an initial estimate of the
varying phase
()
$
θ
n
using eqn. (17). The phase is
then unwrapped by tracking the 2π jumps in its
values and then parameterised using another L-
STPSA model of order Q given by
()
=
=
Q
k
k
k
ncn
0
θ
(18)
The smooth L-STPSA reconstructed phase
function
θ
(n) in (18) is then substituted back into the
AM-FM signal model in (12) to obtain another new
estimate of a(n) and b(n), which in turn is
substituted, along with
θ
(n), into (17) to compute a
new estimate of the varying phase
(
)
$
θ
n
. This
iterative parameter-substitution process is repeated
until the waveform model in the M th iteration
deviates little from that estimated in the (M+1)th
iteration. Fig. 8 shows the progressive sinusoidal
signal estimation. For the waveform shown in Fig.
7(c), reasonable convergence occurred after the 6
th
iteration, with P = 12, Q =5, R =3 and w
c
= 0.393.
pixel position (n)
zero mean intensity
(a)
(b)
0 20 40 60 80 100 120 140 160
-50
0
50
100
150
0 20 40 60 80 100 120 140 160
-50
0
50
100
150
pixel position (n)
zero mean intensity
Iteration #1
Iteration #6
reconstructed sinusoid
original signal
varying intensity bias
Figure 8: (a) The estimated L-STPSA AM-FM sinusoid of
the fundamental frequency at (a) iteration #1 and (b) at
stable full signal reconstruction at iteration #6. The
original waveform and estimated varying bias is shown in
dotted (red) and dashed lines (black) respectively.
Once a stable AM-FM sinusoid has been
iteratively estimated, the varying phase
θ
(n) from
(18) can yield an instantaneous frequency as given
in (11). Since we are interested in the varying pitch
period of the Moiré pattern, we can relate the
varying phase
θ
(n) in (18) to the reciprocal of the
Moiré pattern pitch width p
m
in (8) using the
instantaneous frequency given in (11)
π
θθ
2
)1()(
)(
)('
1
+
==
nnw
nf
np
c
m
(19)
The derivative of the varying phase in (11) is
approximated using backward difference. Fig. 9
shows a 1D depth profile of the line grating surface
shown in Fig. 7(a), obtained from the plot of 1/p
m
(n)
in (19) using the fundamental sinusoid’s estimated
phase changes shown in Fig. 8(b).
0 20 40 60 80 100 120 140 160
pixel position (n)
p
m
1
camera distance, d
Figure 9: The cross-sectional profile of the distance
between surface and camera computed from the
instantaneous frequency estimate of the recovered L-
STPSA sinusoidal signal in Fig. 8(b).
4 EXPERIMENTAL RESULTS
4.1 Experimental System Setup
The experimental setup used is shown in Fig. 10. It
consists of a CCD camera mounted on a crank-
based height-adjustable stand, a personal computer
(PC) and A4-sized white paper with uniform black-
white line gratings printed from a 600dpi laser
printer. The camera is the Dragon Fly Express
monochrome model (PointGrey, 2008) from Point
Grey Research Inc., with a C-mount lens of focal
length 25mm. The resolution of the captured image
is 640 × 480 pixels.
Paper with line grating patterns
d
Personal
computer
Height-adjustable
camera stand
CCD camera
1D cross section
(perpendicular to
line gratings)
Figure 10: The basic experimental setup.
MOIRÉ PATTERNS FROM A CCD CAMERA - Are They Annoying Artifacts or Can They be Useful?
55
The distance, d from the camera imaging plane to
the line grating surface is proportional to the inverse
of Moiré fringe pitch width, 1/p
m
and this width is
related to the instantaneous frequency of the Moiré
waveform as shown in (19). In other words, the 1D
distance profile along the cross section shown in Fig.
10 can be generalized to
bnkfb
np
knd
m
+=+×= )(
)('
1
)(
(20)
where k and b are unknown system constants.
The instantaneous frequency f(n) given in (19) is
computed from the extracted L-STPSA fundamental
sinusoid of the 1D Moiré pattern waveform.
The first experiment verifies that the distance
from the camera, d is proportional to the extracted
instantaneous frequencies, f of the fundamental
sinusoid of the 1D Moiré pattern waveform. The L-
STPSA model parameter values of P =5, R =3 and
Q = 2, as given in eqns. (15) and (18) was used. By
setting Q = 2, we are adopting a constant phase
model as we do not expect the frequency of the
Moiré pattern to change over the 1D cross section
since the distance, d to the surface is much larger
that the focal length, f of the camera lens.
Fig. 11 shows the results obtained for the d
distances from 70.0cm to 75.0cm, in steps of 0.5cm.
At this distance and with the printed line grating
pitch used, the value of m in (3) is 3 and artifact-free
1D Moiré waveform is obtained by sampling every
other 4
th
pixel of the original resolution waveform.
Notice that the results obtained in Fig. 11 confirm
the proportional relationship given in (20).
measured data
best linear fit
0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1
70
70.5
71
71.5
72
72.5
73
73.5
74
74.5
75
distance to camera,
d
instantaneous fre
q
uenc
y
,
f
Plot of distance versus instantaneous frequency
Figure 11: A plot to show the relationship between the
distance, d between the line grating surface and the CCD
camera and the estimated instantaneous frequency, f of the
Moiré pattern waveform.
4.2 1D Incline Planar Surfaces
This experiment demonstrates the use of the AM-
FM modelling property of the L-STPSA technique
to estimate the changing instantaneous frequency of
the Moiré pattern waveform across the 1D cross
section. By using an incline line grating surface, the
distance to the camera would vary linearly from one
end of the 1D cross section (see Fig. 12) to the other.
θ
d
CCD
camera
(a)
(b)
Line
grating
Image acquired
Figure 12: (a) Experimental setup for the incline planar
surface analysis. (b) The acquired image with the dashed
line (blue) indicating the 1D profile used in the analysis.
Fig. 13(a) shows the Moiré pattern waveform
obtained for a planar incline of about 10 degrees.
Fig. 13(b) shows the corresponding frequency-
varying fundamental sinusoid estimated using the L-
STPSA model parameters of
P =5, R =3 and Q =5.
The linearly changing chirp-like instantaneous
frequency fundamental sinusoid can be seen in the
Moiré waveform shown in Fig. 13(b).
pixel position (n)
zero mean intensity
(a)
(b)
zero mean intensity
20 40 60 80 100 120
-50
0
50
20 40 60 80 100 120
-50
0
50
reconstructed fundamental sinusoid
Original Moiré waveform
pixel position (n)
Moiré waveform
amplitude envelope
varying intensity bias
Figure 13: (a) The Moiré pattern waveform obtained from
an incline line grating. Also shown is the estimated
amplitude envelope for the fundamental sinusoid and the
varying bias. (b) The extracted fundamental sinusoid of
the Moiré waveform using the L-STPSA modelling
technique. Shown in dotted line (red) is the error residue
between the estimated sinusoid and the original signal in.
Fig. 14 shows the plot of the instantaneous
frequency of the fundamental sinusoid in Fig. 13(b).
Observe that the extracted instantaneous frequency
varies closely to that of an incline, as we would
expect from the proportional relationship between
distance,
d and instantaneous frequency, f in (20).
VISAPP 2009 - International Conference on Computer Vision Theory and Applications
56
20 40 60 80 100 120
0.05
0.06
0.07
0.08
0.09
0.1
0.11
pixel position (n)
instantaneous frequency, f
frequency, f
best incline fit
Figure 14: The incline observed in the instantaneous
frequency, f is plotted against a best fit incline.
4.3 2D Incline Planar Surfaces
Next, we imaged a line grating surface that is
inclined in both the x and y directions (see Fig. 15).
We reconstructed a dense surface depth map by
stitching together the all perpendicular 1D cross
sections across the image. Fig. 16 shows the
resulting dense 2D depth map reconstructed by
analysing a series of 1D cross sections.
h
1
h
3
h
2
CCD
camera
multiple 1D
cross sections
Figure 15: The 2D incline surface experimental setup. The
heights h
1
=64.5 mm, h
2
=37mm, and h
3
=33mm.
Figure 16: Reconstructed 2D surface of the incline plane.
4.4 Impact of Uneven Lighting
Conditions
We studied the effects of ambient lighting variations
on the accuracy of the extracted depth using the
proposed CCD Moiré waveform analysis technique.
Fig. 17 shows the setup used in which a curved A4-
sized paper with evenly spaced vertical line gratings
was imaged twice. Firstly, under normal lighting
conditions and secondly, with portions of the line
grating surface covered by shadows.
(a)
CCD camera
Curved surface with
line gratings
(b)
CCD camera
Light
source
Light source
Shadows
added
Occluder
Figure 17: Experimental setup for testing effects of
lighting variations. (a) Normal light source and (b)
Shadows cast on surface due to partially occluded light
source.
Fig. 18 shows the two waveforms obtained after
sub-sampling the intensity value of every other 4
th
pixel of a 1D cross section. The fundamental
sinusoidal waveforms along with their respective
instantaneous frequencies were extracted for both
waveforms using
P =10, Q =5 and R =3. The
carrier frequencies used in Fig. 18(a) and 18(b) were
w
c
= 0.668 and w
c
= 0.628 respectively.
The resulting 1D depth profiles of the surface
cross section under different lighting conditions
were plotted together as shown in Fig. 19. Hardly
any noticeable variations in depth profiles were
observed. This shows that the proposed technique
for measuring the depth profile of a line grating
surface is robust to lighting variations. The ability of
the L-STPSA technique to simultaneously extract
the varying instantaneous frequency and amplitude
modulation envelopes in a waveform allows us to
handle changes in the Moiré pattern intensity, which
does not fundamentally change the pitch of the
Moiré fringes.
pixel position (n)
zero mean intensity
(a)
(b)
pixel position (n)
zero mean intensity
20 40 60 80 100 120 140 160
-100
-50
0
50
100
20 40 60 80 100 120 140 160
-100
-50
0
50
100
Normal lighting
With shadows
Moiré waveform
Estimated AM
varying intensity bias
Figure 18: The 1D intensity profiles of the sub-sampled
zero-mean Moiré pattern waveforms obtained under (a)
normal lighting condition and (b) with shadows. Notice
the shadows resulted in uneven intensity attenuation. The
estimated amplitude modulation envelopes of the
MOIRÉ PATTERNS FROM A CCD CAMERA - Are They Annoying Artifacts or Can They be Useful?
57
fundamental sinusoids are shown dotted (red) and the
varying biases are shown in dashed lines (black).
pixel position (n)
Camera distance, d
0 20 40 60 80 100 120 140 160
1D depth profiles
Normal lighting
With shadows
Figure 19: The plot of the two estimated 1D depth profiles
of Moire pattern waveforms in Figure 19(a) and 19(b).
The two overlapping profiles are almost identical despite
the significant variation in the intensity profile.
5 CONCLUSIONS
We introduced a method of measuring dense 2D
surface depth maps using the Moiré patterns
captured from a CCD camera. This uniform CCD
cell array is exploited in the generation of the Moiré
patterns, making this approach simpler and less
expensive than the use of Ronchi gratings. A novel
sub-sampling technique was introduced to remove
artifacts that resulted from adopting a more
convenient and inexpensive setup in which larger
specimen line grating pitch width were be employed.
A spatial domain parametric technique was
proposed for extracting the instantaneous frequency
of the Moiré pattern waveform and we showed that
this frequency parameter is proportional to the
surface-camera distance and can therefore be used to
analyse the relative depth variation of the line
grating surface. We also showed that the depth
profiles estimated from the observed Moiré pattern
are independent of the intensity variations over the
line grating pattern, which makes such measurement
techniques easy to deploy under conditions that
consistent and uniform lighting cannot be assured.
REFERENCES
Kafri, O., Glatt, I., 1990, The Physics of Moiré Metrology,
John Wiley & Sons.
Khan, A. S., Wang X., 2001, Strain Measurements and
Stress Analysis, Prentice Hall, New Jersey.
Walker, C.A. (Ed), 2004, Handbook of Moiré
Measurement, Institute of Physics Publishing, Bristol.
Creath, K., Schmit, J., Wyant, J.C., 2007, Optical
Metrology of Diffuse Surfaces. In Optical Shop
Testing, Malacara, D. (Ed.), John Wiley & Sons,
Hoboken, New Jersey, 3
rd
edition, pp. 756-807.
Chang, R. S., Sheu, J.Y., Lin C.H., Liu H.C., 2003,
Analysis of CCD Moiré Pattern for Micro-range
measurements using the Wavelet Transform. Optics
and Laser Technology (35) pp. 43-47.
Amidror, I., 2000, The Theory of the Moiré Phenomenon,
Kluwer Academic Publishers, Dordrecht, The
Netherlands.
Goh, W. B., 2007, Noise Robust AM-FM Demodulation
using Least-Squares Truncated Power Series
Approximation. In ICICS’07, 6
th
Intl. Conf. on
Information, Communications and Signal Processing.
Goh, W. B., Chan, K.Y., 1998, Amplitude Modulated
Sinusoidal Modeling using Least-square Infinite Series
Approximation with Applications to Timbre Analysis.
In ICASSP’98, IEEE Intl. Conf. of Acoustics, Speech
and Signal Processing, (6), pp. 3561-3564.
Point Grey Research Inc., 2008, Dragonfly Express,
http://www.ptgrey.com/products/dx/dx.pdf
VISAPP 2009 - International Conference on Computer Vision Theory and Applications
58