Perspective projection

Slides:



Advertisements
Similar presentations
Image formation. Image Formation Vision infers world properties form images. How do images depend on these properties? Two key elements –Geometry –Radiometry.
Advertisements

C280, Computer Vision Prof. Trevor Darrell Lecture 2: Image Formation.
The Camera : Computational Photography Alexei Efros, CMU, Fall 2006.
CSE 473/573 Computer Vision and Image Processing (CVIP) Ifeoma Nwogu Lecture 4 – Image formation(part I)
CS 691 Computational Photography Instructor: Gianfranco Doretto 3D to 2D Projections.
Computer Vision CS 776 Spring 2014 Cameras & Photogrammetry 1 Prof. Alex Berg (Slide credits to many folks on individual slides)
Paris town hall.
The Camera CS194: Image Manipulation & Computational Photography Alexei Efros, UC Berkeley, Fall 2014.
Cameras. Overview The pinhole projection model Qualitative properties Perspective projection matrix Cameras with lenses Depth of focus Field of view Lens.
Single-view metrology
Modeling Light : Rendering and Image Processing Alexei Efros.
Announcements. Projection Today’s Readings Nalwa 2.1.
Lecture 5: Projection CS6670: Computer Vision Noah Snavely.
Announcements Mailing list (you should have received messages) Project 1 additional test sequences online Talk today on “Lightfield photography” by Ren.
CS485/685 Computer Vision Prof. George Bebis
Computer Vision - A Modern Approach
CSCE641: Computer Graphics Image Formation Jinxiang Chai.
Announcements Mailing list Project 1 test the turnin procedure *this week* (make sure it works) vote on best artifacts in next week’s class Project 2 groups.
Lecture 13: Projection, Part 2
Lecture 12: Projection CS4670: Computer Vision Noah Snavely “The School of Athens,” Raphael.
Lecture 6: Image Warping and Projection CS6670: Computer Vision Noah Snavely.
CS223b, Jana Kosecka Rigid Body Motion and Image Formation.
Today: The Camera. Overview The pinhole projection model Qualitative properties Perspective projection matrix Cameras with lenses Depth of focus Field.
Single-view Metrology and Camera Calibration Computer Vision Derek Hoiem, University of Illinois 02/26/15 1.
The Camera : Computational Photography Alexei Efros, CMU, Fall 2008.
Cameras, lenses, and calibration
Image formation and cameras
EEM 561 Machine Vision Week 10 :Image Formation and Cameras
Building a Real Camera.
Image formation How are objects in the world captured in an image?
Northeastern University, Fall 2005 CSG242: Computational Photography Ramesh Raskar Mitsubishi Electric Research Labs Northeastern University September.
Single-view metrology
Lecture 14: Projection CS4670 / 5670: Computer Vision Noah Snavely “The School of Athens,” Raphael.
Viewing and Projections
776 Computer Vision Jan-Michael Frahm Fall Camera.
776 Computer Vision Jan-Michael Frahm Spring 2012.
Recap from Wednesday Two strategies for realistic rendering capture real world data synthesize from bottom up Both have existed for 500 years. Both are.
776 Computer Vision Jan-Michael Frahm, Enrique Dunn Spring 2013.
COMPUTER VISION D10K-7C02 CV02: Camera Dr. Setiawan Hadi, M.Sc.CS. Program Studi S-1 Teknik Informatika FMIPA Universitas Padjadjaran.
Single-view Metrology and Camera Calibration Computer Vision Derek Hoiem, University of Illinois 01/25/11 1.
CS559: Computer Graphics Lecture 9: Projection Li Zhang Spring 2008.
Computational Photography Derek Hoiem, University of Illinois
Projection Readings Nalwa 2.1 Szeliski, Ch , 2.1
Jinxiang Chai CSCE 441 Computer Graphics 3-D Viewing 0.
More with Pinhole + Single-view Metrology
Image Formation and Cameras CSE 455 Linda Shapiro 1.
Announcements Project 1 grading session this Thursday 2:30-5pm, Sieg 327 –signup ASAP:signup –10 minute slot to demo your project for a TA »have your program.
Lecture 14: Projection CS4670 / 5670: Computer Vision Noah Snavely “The School of Athens,” Raphael.
Lecture 18: Cameras CS4670 / 5670: Computer Vision KavitaBala Source: S. Lazebnik.
Outline 3D Viewing Required readings: HB 10-1 to 10-10
CSE 185 Introduction to Computer Vision
Single-view metrology
CS5670: Computer Vision Lecture 9: Cameras Noah Snavely
Jan-Michael Frahm Fall 2016
The Camera : Computational Photography
Announcements Project 1 Project 2
CSCE 441 Computer Graphics 3-D Viewing
Announcements Project 1 Project 2 Due Wednesday at 11:59pm
CS 790: Introduction to Computational Vision
Overview Pin-hole model From 3D to 2D Camera projection
CS4670 / 5670: Computer Vision Lecture 12: Cameras Noah Snavely
Lecture 13: Cameras and geometry
Lecturer: Dr. A.H. Abdul Hafez
The Camera : Computational Photography
Announcements Midterm out today Project 1 demos.
Projection Readings Nalwa 2.1.
Credit: CS231a, Stanford, Silvio Savarese
Announcements Midterm out today Project 1 demos.
The Camera.
Presentation transcript:

Perspective projection Albrecht Dürer, Mechanical creation of a perspective image, 1525

Overview of next two lectures The pinhole projection model Qualitative properties Perspective projection matrix Cameras with lenses Depth of focus Field of view Lens aberrations Digital cameras Sensors Color Artifacts

Let’s design a camera Idea 1: put a piece of film in front of an object Do we get a reasonable image? Slide by Steve Seitz

Pinhole camera Add a barrier to block off most of the rays It gets inverted Slide by Steve Seitz

Pinhole camera Captures pencil of rays – all rays through a single point: aperture, center of projection, optical center, focal point, camera center The image is formed on the image plane Slide by Steve Seitz

Camera obscura Basic principle known to Mozi (470-390 BCE), Aristotle (384-322 BCE) Drawing aid for artists: described by Leonardo da Vinci (1452-1519) Gemma Frisius, 1558 Source: A. Efros

Turning a room into a camera obscura From Grand Images Through a Tiny Opening, Photo District News, February 2005 Abelardo Morell, Camera Obscura Image of Manhattan View Looking South in Large Room, 1996 http://www.abelardomorell.net/camera_obscura1.html

Turning a room into a camera obscura A. Torralba and W. Freeman, Accidental Pinhole and Pinspeck Cameras, CVPR 2012

Pinhole cameras everywhere Tree shadow during a solar eclipse photo credit: Nils van der Burg http://www.physicstogo.org/index.cfm Slide by Steve Seitz

Dimensionality reduction: from 3D to 2D 3D world 2D image What properties of the world are preserved? Straight lines, incidence What properties are not preserved? Angles, lengths Slide by A. Efros Figures © Stephen E. Palmer, 2002

Modeling projection x y z f To compute the projection P’ of a scene point P, form the visual ray connecting P to the camera center O and find where it intersects the image plane All scene points that lie on this visual ray have the same projection in the image Are there scene points for which this projection is undefined?

Modeling projection The coordinate system Projection equations f y z x The optical center (O) is at the origin The image plane is parallel to xy-plane or perpendicular to the z-axis, which is the optical axis Projection equations Derived using similar triangles: Source: J. Ponce, S. Seitz

Fronto-parallel planes What happens to the projection of a pattern on a plane parallel to the image plane? All points on that plane are at a fixed depth z The pattern gets scaled by a factor of f / z, but angles and ratios of lengths/areas are preserved

Fronto-parallel planes What happens to the projection of a pattern on a plane parallel to the image plane? All points on that plane are at a fixed depth z The pattern gets scaled by a factor of f / z, but angles and ratios of lengths/areas are preserved Piero della Francesca, Flagellation of Christ, 1455-1460 Jan Vermeer, The Music Lesson, 1662-1665

What about non-fronto-parallel planes? Piero della Francesca, Flagellation of Christ, 1455-1460 Jan Vermeer, The Music Lesson, 1662-1665

Vanishing points All parallel lines converge to a vanishing point Each direction in space is associated with its own vanishing point Exception: directions parallel to the image plane

Constructing the vanishing point of a line image plane vanishing point camera center line in the scene If we have another line in the scene parallel to the first one, it will have the same vanishing point Slide by Steve Seitz

Perspective cues Slide by Steve Seitz

Perspective cues Slide by Steve Seitz

Perspective cues Slide by Steve Seitz

Perspective cues in art Masaccio, Trinity, Santa Maria Novella, Florence, 1425-28 One of the first consistent uses of perspective in Western art

Vanishing lines of planes Is this parachutist higher or lower than the person taking this picture? Lower—he is below the horizon How do we construct the vanishing line of a plane? Image source: S. Seitz

Vanishing lines of planes camera center plane in the scene Horizon: vanishing line of the ground plane All points at the same height as the camera project to the horizon Points higher (resp. lower) than the camera project above (resp. below) the horizon Provides way of comparing height of objects Slide by Steve Seitz

Comparing heights Vanishing Point Slide by Steve Seitz

Measuring height What is the height of the camera? 5.4 5 4 3.3 3 2.8 2 1 2 3 4 5 3.3 Camera height 2.8 What is the height of the camera? Slide by Steve Seitz

Perspective distortion Are the widths of the projected columns equal? The exterior columns are wider This is not an optical illusion, and is not due to lens flaws Phenomenon pointed out by Da Vinci Source: F. Durand

Perspective distortion What is the shape of the projection of a sphere? Image source: F. Durand

Perspective distortion What is the shape of the projection of a sphere?

Perspective distortion: People

Modeling projection Projection equation: f y z x The camera projection scales the apparent height of objects by the inverse of the depth. This results in the well-known effect that objects farther away from the camera look smaller. We don’t care that the image is upside down: we can simply pretend that the image plane is in front of the camera center. Source: J. Ponce, S. Seitz

Homogeneous coordinates Is this a linear transformation? no—division by z is nonlinear Trick: add one more coordinate: homogeneous image coordinates homogeneous scene coordinates Converting from homogeneous coordinates Slide by Steve Seitz

Perspective Projection Matrix Projection is a matrix multiplication using homogeneous coordinates divide by the third coordinate In practice: lots of coordinate transformations… World to camera coord. trans. matrix (4x4) Perspective projection matrix (3x4) Camera to pixel coord. trans. matrix (3x3) = 2D point (3x1) 3D point (4x1)

Orthographic Projection Special case of perspective projection Distance from center of projection to image plane is infinite Also called “parallel projection” Image World Is this a linear function? Slide by Steve Seitz

Orthographic Projection Special case of perspective projection Distance from center of projection to image plane is infinite Also called “parallel projection” Is this a linear function?

Orthographic Projection Special case of perspective projection Distance from center of projection to image plane is infinite Also called “parallel projection” What’s the projection matrix? Image World Is this a linear function? Slide by Steve Seitz