02-Camera and Image Formation-2023
02-Camera and Image Formation-2023
Instructor: Xu Zhao
๏ Pinhole model
❖ Field of view
❖ Lens aberrations
❖ Digital cameras
Camera obscura
James Hays
Camera obscura
"Reinerus Gemma-Frisius,
observed an eclipse of the sun at
Louvain on January 24, 1544,
and later he used this illustration
of the event in his book De Radio
Astronomica et Geometrica,
1545. It is thought to be the first
published illustration of a camera
obscura..."
Hammond, John H., The Camera
Obscura, A Chronicle
http://www.acmi.net.au/AIC/CAMERA_OBSCURA.html
First photograph
Oldest surviving photograph –
Photograph of the rst photograph
Took 8 hours on pewter plate
Pinhole model
Perspective effects
Distant objects are smaller
Kristen Grauman
Parallel lines meet
❖ Parallel lines in the
scene intersect in the
image
❖ Converge in image on
horizon line
Source
own work
Author
User:MikKBDFJKGeMalak Forsyth and Ponce
v/ v
C D
X1 X2 X3 X4 X
a
d X( )
A
X( )
v
d
C
8.6 Vanishing points and vanishing lines 217
v1 v2
l
n
l
n
C
Fig. 8.16. Vanishing line formation. (a) The two sets of parallel lines on the scene plane converge to
the vanishing points v1 and v2 in the image. The line l through v1 and v2 is the vanishing line of the
plane. (b) The vanishing line l of a plane π is obtained by intersecting theHartley & Zisserman
image plane with a plane
through the camera centre C and parallel to π.
Forsyth & Ponce
!
Vertical vanishing
point
(at infinity)
Vanishing
line
Vanishing
Vanishing
point
point
Perspective distortion
x y
(x, y, z) → ( f , f )
z z
Scen point Image coordinates
Source: J. Ponce, S. Seitz



Models
fY/Z
C
p Z
f
x(t ) = x0 + at x'(t) =
fx f (x 0 + at)
=
y (t ) = y0 + bt z z0 + ct
fy f (y 0 + bt)
z (t ) = z0 + ct y'(t) = =
z z0 + ct
Point of observation
1 0 0 0 x x
0 1 0 0 y y x y
z = z
⇒ (f , f )
z z
0 0 1f 0
1 f
Calibration
❖ Camera’s intrinsic and extrinsic parameters needed to calibrate geometry.
Extrinsic: Camera frame World frame
World frame
Intrinsic:
Image coordinates
relative to camera
Pixel
coordinates Camera frame
170
Weak perspective 6 Camera Models
weak
perspective
perspective
C
f d0
❖ Perspective
Fig. 6.8. Perspective vseffects, but not over
weak perspective the scale
projection. of individual
The action of the weakobjects
perspective camera is
equivalent to orthographic projection onto a plane (at Z = d0 ), followed by perspective projection from
❖ Collect
the plane. points between
The difference into a group at about
the perspective and the
weaksame depth,
perspective then
image divide
point dependseach
both on
the distance ∆ of the point X from the plane, and the distance of the point from the principal ray.
point by the depth of its group
❖Adv: easy; Disadv: only approximate
one of two ways, either with x̃0 = 0 or with t̂ = 0̂. Using the second decomposition
of (6.20), the image of the world origin is P∞ (0, 0, 0, 1)T = (x̃T , 1)T . Consequently,
Orthographic projection
Image World
Antonio Torralba
Three camera projections
3D point 2D image point
' fx fy $
Perspective ( x, y , z ) → % , "
& z z #
Weak Perspective ' fx fy $
( x, y, z ) → %% , ""
& z0 z0 #
Orthographic Projection ( x, y , z ) → ( x, y )
Discussions
lager
smaller
Kristen Grauman
Adding a lens
focal point
f
❖ A lens focuses light onto the film
❖ Rays passing through the center are not deviated
❖ All parallel rays converge to one point on a plane
located at the focal length f Slide by Steve Seitz
optical center
focal point
(Center Of Projection)
Thin lens
Thin lens
❖ Rays entering parallel on
one side go through
focus on other, and vice Left focus Right focus
versa.
❖ In ideal case – all rays
from P imaged at P’.
1 1 1
= +
f u v
u v
Slide by A. Efros
Focus and depth of field
❖ Thin lens: scene points
at distinct depths come
in focus at different
image planes.
❖ (Real camera lens
systems have greater
depth of field.)
“circles of confusion”
3d shape / depth
estimates
Angular measure
of portion of 3d
space seen by
the camera
from R. Duraiswami
f
f
Slide by A. Efros
Real lenses
Lens Flaws: Chromatic Aberration
Lens has different refractive indices
for different wavelengths: causes
color fringing
camera
CCD
array optics frame
computer
grabber
Digital images
width
j=1 520
i=1
Think of images as matrices
taken from CCD array.
500
height
Intensity : [0,255]
im[176][201] has value 164 im[194][203] has value 37 Kristen Grauman
Estimate missing
components from
neighboring values
(demosaicing)
Bayer grid
Demosaicing
Demosaicing
Simple interpolation
Simple “edge aware”interpolation
Digital camera artifacts
❖ Noise
❖ low light is where you most notice noise
❖ stuck pixels
❖ In-camera processing
❖ oversharpening can produce halos
❖ Compression
❖ JPEG artifacts, blocking
❖ Blooming
❖ charge overflowing into neighboring pixels
❖ Color artifacts
❖ purple fringing from microlenses
❖ white balance
Historical context
❖ Pinhole model: Mozi (470-390 BCE), Aristotle
(384-322 BCE)
❖ Principles of optics (including lenses):
Alhacen (965-1039 CE)
Alhacen’s notes
❖ Camera obscura: Leonardo da Vinci
(1452-1519), Johann Zahn (1631-1707)
❖ First photo: Joseph Nicephore Niepce (1822)
❖ Daguerréotypes (1839)
❖ Photographic lm (Eastman, 1889)
Niepce, “La Table Servie,” 1822
❖ Cinema (Lumière Brothers, 1895)
❖ Color Photography (Lumière Brothers, 1908)
❖ Television (Baird, Farnsworth, Zworykin, 1920s)
❖ First consumer camera with CCD: Sony
Mavica (1981)
❖ First fully digital camera: Kodak DCS100 CCD chip
(1990)
Slide credit: L. Lazebnik
fi
Summary
❖ Image formation affected by geometry, photometry, and optics.
❖ Projection equations express how world points mapped to 2d
image.
❖ Homogenous coordinates allow linear system for projection
equations.
❖ Lenses make pinhole model practical.
❖ Parameters (focal length, aperture, lens diameter,…) affect
image obtained.