Cameras & Projections - PowerPoint PPT Presentation

cameras projections n.
Download
Skip this Video
Loading SlideShow in 5 Seconds..
Cameras & Projections PowerPoint Presentation
Download Presentation
Cameras & Projections

play fullscreen
1 / 112
Cameras & Projections
192 Views
Download Presentation
jacoba
Download Presentation

Cameras & Projections

- - - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - - -
Presentation Transcript

  1. Cameras & Projections Dan Witzner Hansen

  2. Outline • Previously??? • Projections • Pinhole cameras

  3. Computer vision vs Computer graphics

  4. Picture Plane Objects in World Space What Are Projections? • Our 3-D scenes are all specified in 3-D world coordinates • To display these we need to generate a 2-D image - project objects onto a picture plane • So how do we figure out these projections?

  5. Taxonomy of Projections

  6. Types Of Projections • There are two broad classes of projections: • Parallel: Typically used for architectural and engineering drawings • Perspective: Realistic looking and used in computer graphics / Computer vision Parallel Projection Perspective Projection

  7. Examples of Parallel Projections Orthographic Projection Isometric Projection

  8. Isometric Projections • Isometric projections have been used in computer games from the very early days of the industry up to today Q*Bert Sim City Virtual Magic Kingdom

  9. Perspective Projections Perspective projections are much more realistic than parallel projections

  10. 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

  11. Pinhole camera Pinhole camera is a simple model to approximate imaging process, perspective projection. Virtual image pinhole If we treat pinhole as a point, only one ray from any given point can enter the camera. Fig from Forsyth and Ponce

  12. Camera obscura Jetty at Margate England, 1898. An attraction in the late 19th century Around 1870s http://brightbytes.com/cosite/collection2.html Adapted from R. Duraiswami

  13. Camera obscura at home http://room-camera-obscura.blogspot.com/ Sketch from http://www.funsci.com/fun3_en/sky/sky.htm

  14. Digital cameras • Film  sensor array • Often an array of charged coupled devices • Each CCD is light sensitive diode that converts photons (light energy) to electrons camera CCD array frame grabber optics computer

  15. Lenses • A lens focuses parallel rays onto a single focal point • focal point at a distance f beyond the plane of the lens • f is a function of the shape and index of refraction of the lens • Aperture of diameter D restricts the range of rays • aperture may be on either side of the lens • Lenses are typically spherical (easier to produce) F focal point optical center (Center Of Projection)

  16. Adding a lens • A lens focuses light onto the film • There is a specific distance at which objects are “in focus”

  17. Pinhole vs. lens

  18. Thin lenses • Thin lens equation: • Any object point satisfying this equation is in focus • Thin lens applet: http://www.phy.ntnu.edu.tw/java/Lens/lens_e.html (by Fu-Kwun Hwang )

  19. “circle of confusion” Adding a lens • A lens focuses light onto the film • There is a specific distance at which objects are “in focus” • other points project to a “circle of confusion” in the image • Changing the shape of the lens changes this distance

  20. Pinhole size / aperture How does the size of the aperture affect the image we’d get? Larger Smaller

  21. Lens and defocus Image of a point light source Lens’ aperture Camera sensor Lens Point spread function Focal plane

  22. Lens and defocus Image of a defocused point light source Lens’ aperture Camera sensor Object Lens Point spread function Focal plane

  23. Lens and defocus Image of a defocused point light source Lens’ aperture Camera sensor Object Lens Point spread function Focal plane

  24. Lens and defocus Image of a defocused point light source Lens’ aperture Camera sensor Object Lens Point spread function Focal plane

  25. Lens and defocus Image of a defocused point light source Lens’ aperture Camera sensor Object Lens Point spread function Focal plane

  26. Focus and depth of field • Depth of field: distance between image planes where blur is tolerable Shapiro and Stockman

  27. Depth of field • Changing the aperture size affects depth of field • A smaller aperture increases the range in which the object is approximately in focus • Pinhole -> infinity f / 5.6 f / 32 Flower images from Wikipedia http://en.wikipedia.org/wiki/Depth_of_field

  28. Focus and depth of field Image credit: cambridgeincolour.com

  29. Is depth of field a blur? • Depth of field is NOT a convolution of the image • The circle of confusion varies with depth • There are interesting occlusion effects From Macro Photography

  30. Depth from focus Images from same point of view, different camera parameters 3d shape / depth estimates [figs from H. Jin and P. Favaro, 2002]

  31. Modeling Projections

  32. Perspective effects

  33. Perspective and art • Use of correct perspective projection indicated in 1st century B.C. frescoes • Skill resurfaces in Renaissance: artists develop systematic methods to determine perspective projection (around 1480-1515) Raphael Durer, 1525

  34. Modeling projection

  35. Perspective effects • Far away objects appear smaller Forsyth and Ponce

  36. Perspective effects • Parallel lines in the scene intersect in the image • Converge in image on horizon line Image plane (virtual) pinhole Scene

  37. (x,y,1) image plane The projective plane • Why do we need homogeneous coordinates? • represent points at infinity, homographies, perspective projection, multi-view relationships • What is the geometric intuition? • a point in the image is a ray in projective space -y (sx,sy,s) (0,0,0) x -z • Each point(x,y) on the plane is represented by a ray(sx,sy,s) • all points on the ray are equivalent: (x, y, 1)  (sx, sy, s)

  38. A line is a plane of rays through origin • all rays (x,y,z) satisfying: ax + by + cz = 0 l p • A line is also represented as a homogeneous 3-vector l Projective lines What does a line in the image correspond to in projective space?

  39. vanishing point v Vanishing points image plane camera center C line on ground plane • Vanishing point • projection of a point at infinity

  40. l1 p l l2 Point and line duality • A line l is a homogeneous 3-vector • It is  to every point (ray) p on the line: lp=0 p2 p1 • What is the line l spanned by rays p1 and p2 ? • lis  to p1 and p2 l= p1p2 • l is the plane normal • What is the intersection of two lines l1 and l2 ? • p is  to l1 and l2  p = l1l2

  41. line on ground plane Vanishing points • Properties • Any two parallel lines have the same vanishing point v • The ray from C through v is parallel to the lines • An image may have more than one vanishing point • in fact every pixel is a potential vanishing point image plane vanishing point v camera center C line on ground plane

  42. Ideal points and line at infinity 1 • Intersection of parallel lines l = (a, b, c) and l’ = (a, b, c’) are parallel lxl’ = (c’ – c)( b, -a, 0)T Ignoring scale, it is a point ( b, -a, 0)T with inhomogeneous coordinates (b/0, -a/0)T

  43. (a,b,0) -y -z image plane x • Ideal line • l  (a, b, 0) – parallel to image plane Ideal points and lines -y (sx,sy,0) x -z image plane • Corresponds to a line in the image (finite coordinates) • goes through image origin (principle point) • Ideal point (“point at infinity”) • p  (x, y, 0) – parallel to image plane • It has infinite image coordinates

  44. Ideal points and line at infinity 2 • The points with last coordinate x3 = 0 are known as ideal points, or points at infinity. Note that this set lies on a single line , the line at infinity linf =( 0, 0, 1)T as ( 0,0,1) (x1 , x2 , 0) = 0 A line l=( a, b, c)T intersect the line at infinity in the ideal point ( b, -a, 0)T (b, -a) T represent the line’s direction

  45. Ideal Points and the Homography

  46. Overview transformations Concurrency, collinearity, order of contact (intersection, tangency, inflection, etc.), cross ratio Projective 8dof Parallellism, ratio of areas, ratio of lengths on parallel lines (e.g midpoints), linear combinations of vectors (centroids). The line at infinity l∞ Affine 6dof Ratios of lengths, angles. The circular points I,J Similarity 4dof Euclidean 3dof lengths, areas.

  47. Invariants

  48. Affine rectification

  49. Affine rectification via the vanishing line

  50. Equal distance ratios on a line to determine the point at infinity