Lecture 02 Cameras
Lecture 02 Cameras
Lecture
Camera Models
Liangliang Nan
What is an image?
c
2
What is an image?
c
P = f (x, y)
f : R2 Þ R
Pixel
3
What is an image?
c
f(x, y) = 97
f(x, y) = 213
f(x, y) = 0
width 4
What is an image?
c
5
What is an image?
c
“vector-valued” function
6
Today’s agenda
c
• Images
• Camera Models
7
We see the world through our eyes…
c
cornea
(focus light)
lens retina
(captures image)
optic nerves
(transmit image)
pupil
(control amount of
light entering the eye)
8
Machines see the world through cameras…
c
9
Machines see the world through cameras…
c
10
Camera vs. eye
c
• Similarities
– Image focusing (cornea & lens)
– Light adjustment (pupil & aperture)
• Differences (just name a few)
– Lens focus
• Camera: lens moves closer/further from the film
• Eye: lens changes shape to focus
– Sensitivity to light
• Camera: A film is designed to be uniformly sensitive to light
• Eye: retina is not; has greater sensitivity in dark 11
Imaging …
c
12
Camera models
c
13
Pinhole camera model
c
• One-to-one mapping
14
Pinhole camera model
c
2 mm 1mm
0.6mm 0.35 mm
15
Pinhole camera model
c
Aperture
film (camera center)
camera coordinate
system
17
Pinhole camera model
c
camera coordinate
system
𝑋 𝑌
𝑥=𝑓 , y=𝑓
𝑍 𝑍
18
Pinhole camera model
c
camera coordinate 𝑋 𝑥 𝑌 𝑦
system = , =
𝑍 𝑓 𝑍 𝑓
𝑋 𝑌
𝑥=𝑓 , y=𝑓
𝑍 𝑍
Simplest form of perspective projection
19
Pinhole camera model
c
2 mm 1mm
20
Perspective projection model
c
21
Perspective projection model
c
• Lens
– Converges all rays of light of same points to a single point
– Focuses parallel light rays to the focal point
22
Perspective projection model
c
𝑋 𝑌
𝑥=𝛼 , y=𝛽
𝑍 𝑍
24
Perspective projection model
c
26
Perspective projection model
c
27
Perspective projection model
c
28
Perspective projection model
c
29
Normal Pincushion Barrel
Perspective projection model
c
30
Intrinsic parameters
c
(homogeneous coordinates)
𝐩 = 𝐾𝐏, 𝐾=
31
Intrinsic parameters
c
(homogeneous coordinates)
𝛼 −𝛼 cot 𝜃 𝑐𝑥
𝛽
𝐩 = 𝐾𝐏, 𝐾= 0 𝑐𝑦
sin 𝜃
0 0 1
Intrinsic parameter matrix 32
Intrinsic parameters
c
• Internal characteristics
– focal length, skew distortion, and image center.
33
Extrinsic parameters
c
• Camera motion
– World frame may not align with the camera frame
– Camera can move and rotate
camera frame
world frame
34
Extrinsic parameters
c
• Camera motion
– World frame may not align with the camera frame
– Camera can move and rotate
Camera frame
𝐏𝐶 = 𝑅𝑊
𝐶
𝐏𝑊 + 𝐭𝐶𝑊
World frame
1 3 2 4
𝐶
𝐩 = 𝐾(𝑅𝑊 ⋅ 𝐏𝑊 + 𝐭𝐶𝑊 )
Further reading:
R. Szeliski. Computer Vision: Algorithms and Applications. Springer, 2010.
- Camera models: Section 2.1.5
- Lens distortion: Section 2.1.6
37
Next lecture
c
• Camera calibration
38