cse 185 introduction to computer vision cameras. camera models –pinhole perspective projection...

28
CSE 185 Introduction to Computer Vision Cameras

Upload: elaine-mclaughlin

Post on 20-Jan-2016

239 views

Category:

Documents


1 download

TRANSCRIPT

Page 1: CSE 185 Introduction to Computer Vision Cameras. Camera models –Pinhole Perspective Projection –Affine Projection –Spherical Perspective Projection Camera

CSE 185 Introduction to Computer

VisionCameras

Page 2: CSE 185 Introduction to Computer Vision Cameras. Camera models –Pinhole Perspective Projection –Affine Projection –Spherical Perspective Projection Camera

Cameras

• Camera models– Pinhole Perspective Projection– Affine Projection– Spherical Perspective Projection

• Camera with lenses• Sensing• Human eye• Reading: S Chapter 2

Page 3: CSE 185 Introduction to Computer Vision Cameras. Camera models –Pinhole Perspective Projection –Affine Projection –Spherical Perspective Projection Camera

Images are two-dimensional patterns of brightness values.

They are formed by the projection of 3D objects.

Figure from US Navy Manual of Basic Optics and Optical Instruments, prepared by Bureau of Naval Personnel. Reprinted by Dover Publications, Inc., 1969.

Page 4: CSE 185 Introduction to Computer Vision Cameras. Camera models –Pinhole Perspective Projection –Affine Projection –Spherical Perspective Projection Camera

Animal eye: a long time ago.

Pinhole perspective projection: Brunelleschi, XVth Century.Camera obscura: XVIth Century.

Photographic camera:Niepce, 1816.

Figure from US Navy Manual of Basic Optics and Optical Instruments, prepared by Bureau of Naval Personnel. Reprinted by Dover Publications, Inc., 1969.

Page 5: CSE 185 Introduction to Computer Vision Cameras. Camera models –Pinhole Perspective Projection –Affine Projection –Spherical Perspective Projection Camera

Parallel lines: converge on a line formed by the intersection of a plane parallel to π and image plane

L in π that is parallel to image plane has no image at all

A is half the size of BC is half the size of B

Page 6: CSE 185 Introduction to Computer Vision Cameras. Camera models –Pinhole Perspective Projection –Affine Projection –Spherical Perspective Projection Camera

Vanishing point

Page 7: CSE 185 Introduction to Computer Vision Cameras. Camera models –Pinhole Perspective Projection –Affine Projection –Spherical Perspective Projection Camera

Vanishing point

The lines all converge in his right eye, drawing the viewers gaze to this place.

Page 8: CSE 185 Introduction to Computer Vision Cameras. Camera models –Pinhole Perspective Projection –Affine Projection –Spherical Perspective Projection Camera

z

yfy

z

xfx

z

f

y

y

x

x

zf

yy

xx

''

''

'''

'

'

'

NOTE: z is always negative

• C’ :image center• OC’ : optical axis• π’ : image plane is at a positive distance f’ from the pinhole• OP’= λ OP

Pinhole perspective equation

Page 9: CSE 185 Introduction to Computer Vision Cameras. Camera models –Pinhole Perspective Projection –Affine Projection –Spherical Perspective Projection Camera

0

'where

'

'

z

fm

myy

mxx

is the magnification.

When the scene relief (depth) is small compared its distance from thecamera, m can be taken constant weak perspective projection.

frontal-parallel plane π0 defined by z=z0

Weak perspective projection

Page 10: CSE 185 Introduction to Computer Vision Cameras. Camera models –Pinhole Perspective Projection –Affine Projection –Spherical Perspective Projection Camera

yy

xx

'

'When the camera is at a(roughly constant) distancefrom the scene, take m=-1 orthographic projection

Orthographic projection

Page 11: CSE 185 Introduction to Computer Vision Cameras. Camera models –Pinhole Perspective Projection –Affine Projection –Spherical Perspective Projection Camera

Pinhole too big:many directions are averaged, blurring the image

Pinhole too small: diffraction effects blur the image

Generally, pinhole cameras are dark, becausea very small set of raysfrom a particular pointhits the screen

Page 12: CSE 185 Introduction to Computer Vision Cameras. Camera models –Pinhole Perspective Projection –Affine Projection –Spherical Perspective Projection Camera

Snell’s law (akaDescartes’ law)

n1 sin 1 = n2 sin 2

n: index of refraction

reflection

refraction

Lenses

Page 13: CSE 185 Introduction to Computer Vision Cameras. Camera models –Pinhole Perspective Projection –Affine Projection –Spherical Perspective Projection Camera

Snell’s law:

n1 sin 1 = n2 sin 2

Small angles:

n11 = n22

Paraxial (or first-order) optics

Page 14: CSE 185 Introduction to Computer Vision Cameras. Camera models –Pinhole Perspective Projection –Affine Projection –Spherical Perspective Projection Camera

Small angles:

n11 = n22 R

nn

d

n

d

n 12

2

2

1

1

222

111

d

h

R

h

d

h

R

h

Paraxial (or first-order) optics

Page 15: CSE 185 Introduction to Computer Vision Cameras. Camera models –Pinhole Perspective Projection –Affine Projection –Spherical Perspective Projection Camera

)1(2 and

11

'

1 e wher

''

''

n

Rf

fzz

z

yzy

z

xzx

f: focal length F, F’: focal points

Thin Lens

All other rays passing through P are focused on P’

Page 16: CSE 185 Introduction to Computer Vision Cameras. Camera models –Pinhole Perspective Projection –Affine Projection –Spherical Perspective Projection Camera

Depth of field and field of view• Depth of field (field of focus): objects

within certain range of distances are in acceptable focus– Depends on focal length and aperture

• Field of view: portion of scene space that are actually projected onto camera sensors– Not only defined by focal length– But also effective sensor area

Page 17: CSE 185 Introduction to Computer Vision Cameras. Camera models –Pinhole Perspective Projection –Affine Projection –Spherical Perspective Projection Camera

Depth of field

• Changing the aperture size affects depth of field– Increasing f-number (reducing aperture diameter) increases DOF– A smaller aperture increases the range in which the object is

approximately in focus

f / 5.6 (large aperture)

f / 32 (small aperture)

f-number: N=f/Df: focal lengthD: aperture diameter

Page 18: CSE 185 Introduction to Computer Vision Cameras. Camera models –Pinhole Perspective Projection –Affine Projection –Spherical Perspective Projection Camera

Thick lenses

• Simple lenses suffer from several aberrations• First order approximation is not sufficient• Use 3rd order Taylor approximation

Page 19: CSE 185 Introduction to Computer Vision Cameras. Camera models –Pinhole Perspective Projection –Affine Projection –Spherical Perspective Projection Camera

Orthographic (“telecentric”) lenses

http://www.lhup.edu/~dsimanek/3d/telecent.htm

Navitar telecentric zoom lens

Page 20: CSE 185 Introduction to Computer Vision Cameras. Camera models –Pinhole Perspective Projection –Affine Projection –Spherical Perspective Projection Camera

Correcting radial distortion

from Helmut Dersch

Page 21: CSE 185 Introduction to Computer Vision Cameras. Camera models –Pinhole Perspective Projection –Affine Projection –Spherical Perspective Projection Camera

SphericalAberration•rays do not intersect at one point•circle of least confusion

Distortion

ChromaticAberrationrefracted rays of different wavelengths intersect the optical axis at different points

pincushion barrel

Page 22: CSE 185 Introduction to Computer Vision Cameras. Camera models –Pinhole Perspective Projection –Affine Projection –Spherical Perspective Projection Camera

Vignetting

• Aberrations can be minimized by well-chosen shapes and refraction indexes, separated by appropriate stops• However, light rays from object points off-axis are partially blocked by lens configuration vignetting brightness drop in the image periphery

Page 23: CSE 185 Introduction to Computer Vision Cameras. Camera models –Pinhole Perspective Projection –Affine Projection –Spherical Perspective Projection Camera

Helmoltz’s SchematicEye

Corena: transparent highly curved refractive componentPupil: opening at center of iris in response to illumination

The human eye

Page 24: CSE 185 Introduction to Computer Vision Cameras. Camera models –Pinhole Perspective Projection –Affine Projection –Spherical Perspective Projection Camera

Retina: thin, layered membrane with two types of photoreceptors

• rods: very sensitive to light but poor spatial detail• cones: sensitive to spatial details but active at higher light level • generally called receptive field

Cones in the fovea

Rods and cones in the periphery

Retina

Page 25: CSE 185 Introduction to Computer Vision Cameras. Camera models –Pinhole Perspective Projection –Affine Projection –Spherical Perspective Projection Camera

Photographs (Niepce, “La Table Servie,” 1822)

Milestones: Daguerreotypes (1839)Photographic Film (Eastman,1889)Cinema (Lumière Brothers,1895)Color Photography (LumièreBrothers, 1908)Television (Baird, Farnsworth,Zworykin, 1920s)

CCD Devices (1970)

Collection Harlingue-Viollet. .

Page 26: CSE 185 Introduction to Computer Vision Cameras. Camera models –Pinhole Perspective Projection –Affine Projection –Spherical Perspective Projection Camera

360 degree field of view…

• Basic approach– Take a photo of a parabolic mirror with an orthographic lens – Or buy one a lens from a variety of omnicam manufacturers…

• See http://www.cis.upenn.edu/~kostas/omni.html

Page 27: CSE 185 Introduction to Computer Vision Cameras. Camera models –Pinhole Perspective Projection –Affine Projection –Spherical Perspective Projection Camera

Digital camera

• A digital camera replaces film with a sensor array– Each cell in the array is a Charge Coupled Device

• light-sensitive diode that converts photons to electrons• other variants exist: CMOS is becoming more popular• http://electronics.howstuffworks.com/digital-camera.htm

Page 28: CSE 185 Introduction to Computer Vision Cameras. Camera models –Pinhole Perspective Projection –Affine Projection –Spherical Perspective Projection Camera

Image sensing pipeline

Two kinds of sensorCCD: Charge-Coupled DeviceCMOS: Complementary Metal Oxide on Silicon