CS 395/495-26: Spring 2003 IBMR: Week 5 A Back to Chapter 2: 3 -D Projective Geometry Jack Tumblin

Slides:



Advertisements
Similar presentations
Epipolar Geometry.
Advertisements

1 A camera is modeled as a map from a space pt (X,Y,Z) to a pixel (u,v) by ‘homogeneous coordinates’ have been used to ‘treat’ translations ‘multiplicatively’
CS 395/495-26: Spring 2002 IBMR: Week 5B Finish Chapter 2: 3D Projective Geometry + Applications Jack Tumblin
1 Computer Graphics Chapter 8 3D Transformations.
Robot Vision SS 2005 Matthias Rüther 1 ROBOT VISION Lesson 3: Projective Geometry Matthias Rüther Slides courtesy of Marc Pollefeys Department of Computer.
Projective Geometry- 3D
Recovering metric and affine properties from images
Structure from motion.
2D Geometric Transformations
Recovering metric and affine properties from images
Multiple View Geometry Projective Geometry & Transformations of 2D Vladimir Nedović Intelligent Systems Lab Amsterdam (ISLA) Informatics Institute,
1 Basic geometric concepts to understand Affine, Euclidean geometries (inhomogeneous coordinates) projective geometry (homogeneous coordinates) plane at.
The 2D Projective Plane Points and Lines.
Multiple View Geometry Marc Pollefeys University of North Carolina at Chapel Hill Modified by Philippos Mordohai.
Projective 2D & 3D geometry course 2
CS 395/495-25: Spring 2003 IBMR: Week 6B R 3  R 2 and P 3  P 2 The Camera Matrix Jack Tumblin
Epipolar geometry. (i)Correspondence geometry: Given an image point x in the first view, how does this constrain the position of the corresponding point.
Projective geometry Slides from Steve Seitz and Daniel DeMenthon
CS 395/495-26: Spring 2004 IBMR: Projective 2D DLT Jack Tumblin
Projective 3D geometry. Singular Value Decomposition.
CS 395/495-26: Spring 2003 IBMR: Week 4A from Chapter 3: Point Correspondence and Direct Linear Transform (DLT) Jack Tumblin
Multiple View Geometry Marc Pollefeys University of North Carolina at Chapel Hill Modified by Philippos Mordohai.
CS 395/495-26: Spring 2003 IBMR: Week 1B 2-D Projective Geometry Jack Tumblin
Projective Geometry and Camera model Class 2
CS 395/495-25: Spring 2004 IBMR: The Fundamental Matrix The Fundamental Matrix Combines Two Cameras Jack Tumblin
Lecture 15: Single-view modeling CS6670: Computer Vision Noah Snavely.
CS 395/495-26: Spring 2003 IBMR: Week 3 A 2D Projective Geometry: Conics Measure Angles Jack Tumblin
CS 395/495-26: Spring 2003 IBMR: Week 2 B 2-D Projective Geometry Jack Tumblin
CS 395/495-25: Spring 2003 IBMR: Week 8A Chapter 8... Epipolar Geometry: Two Cameras: Jack Tumblin
The Pinhole Camera Model
CS 395/495-25: Spring 2003 IBMR: Week 7A The Camera Matrix Continued... Jack Tumblin
Cameras, lenses, and calibration
Introduction to 3D Graphics Lecture 3: General Camera Model Anthony Steed University College London.
Experimental Mathematics 25 August Linear Equations in 2D Space Recall: A line in the x-y-plane can be represented algebraically by an equation.
COS 397 Computer Graphics Svetla Boytcheva AUBG, Spring 2013.
1 February 24 Matrices 3.2 Matrices; Row reduction Standard form of a set of linear equations: Chapter 3 Linear Algebra Matrix of coefficients: Augmented.
COMP 175: Computer Graphics March 24, 2015
1 Homogeneous Coordinates and Transformation. 2 Line in R 2 General line equation Normalize: Distance to origin (projection along n) n (x,y) For any two.
CS 480/680 Computer Graphics Representation Dr. Frederick C Harris, Jr. Fall 2012.
Homogeneous Coordinates (Projective Space) Let be a point in Euclidean space Change to homogeneous coordinates: Defined up to scale: Can go back to non-homogeneous.
CSE 681 Review: Transformations. CSE 681 Transformations Modeling transformations build complex models by positioning (transforming) simple components.
Chapter 5 General Vector Spaces.
Pole/polar consider projective geometry again we may want to compute the tangents of a curve that pass through a point (e.g., visibility) let C be a conic.
CS559: Computer Graphics Lecture 9: Projection Li Zhang Spring 2008.
University of Palestine Faculty of Applied Engineering and Urban Planning Software Engineering Department Introduction to computer vision Chapter 2: Image.
Announcements Project 3 due Thursday by 11:59pm Demos on Friday; signup on CMS Prelim to be distributed in class Friday, due Wednesday by the beginning.
Geometry 1.2 Linear Measure.
Geometric Algebra 4. Algebraic Foundations and 4D Dr Chris Doran
Multi-linear Systems and Invariant Theory
Projective Geometry Hu Zhan Yi. Entities At Infinity The ordinary space in which we lie is Euclidean space. The parallel lines usually do not intersect.
Affine Geometry.
1 Overview Introduction to projective geometry 1 view geometry (calibration, …) 2-view geometry (stereo, motion, …) 3- and N-view geometry Autocalibration.
Camera Model Calibration
Single-view geometry Odilon Redon, Cyclops, 1914.
Digital Image Processing Additional Material : Imaging Geometry 11 September 2006 Digital Image Processing Additional Material : Imaging Geometry 11 September.
CS559: Computer Graphics Lecture 9: 3D Transformation and Projection Li Zhang Spring 2010 Most slides borrowed from Yungyu ChuangYungyu Chuang.
Lec 26: Fundamental Matrix CS4670 / 5670: Computer Vision Kavita Bala.
Projective geometry ECE 847: Digital Image Processing Stan Birchfield Clemson University.
Projective geometry ECE 847: Digital Image Processing Stan Birchfield
Homogeneous Coordinates (Projective Space)
Two-view geometry Computer Vision Spring 2018, Lecture 10
CS Visual Recognition Projective Geometry Projective Geometry is a mathematical framework describing image formation by perspective camera. Under.
Homogeneous Coordinates and Transformation
Geometric Camera Models
Reconstruction.
Announcements list – let me know if you have NOT been getting mail
IBMR: Week 4B Chapter 3: CS 395/495-26: Spring 2003
컴퓨터 그래픽스를 위한 기하학적 기초 (Line Geometry for Computer Graphics)
컴퓨터 그래픽스를 위한 기하학적 기초 (Line Geometry for Computer Graphics)
The Pinhole Camera Model
Presentation transcript:

CS 395/495-26: Spring 2003 IBMR: Week 5 A Back to Chapter 2: 3 -D Projective Geometry Jack Tumblin

IBMR-Related Seminars 3D Scanning for Cultural Heritage Applications 3D Scanning for Cultural Heritage Applications Holly Rushmeier, IBM TJ Watson 3D Scanning for Cultural Heritage Applications Friday May 16 3:00pm, Rm 381, CS Dept. no title yet... no title yet... Steve Marschner, Cornell University Friday May 23 3:00pm, Rm 381, CS Dept.

3D Homogeneous Coordinates Extend Projective space from 2D to 3D: P 2 :P 2 : –From 2D ‘world space’ (x,y) make –2D homogeneous coordinates (x 1,x 2,x 3 ). –2D projective ‘image space’ (x’,y’) = (x 1 /x 3, x 2 /x 3 ) P 3 :P 3 : –From 3D ‘world space’ (x,y,z) make –3D homogeneous coordinates (x 1,x 2,x 3,x 4 ). –3D projective ‘image space’ (x’,y’,z’) = (x 1 /x 4, x 2 /x 4, x 3 /x 4 )

3D Homogeneous Coordinates –Unifies points and planes –(but lines are messy) –Puts perspective projection into matrix form –No divide-by-zero, points at infinity defined… x y But in P 3, write same point x as: where: (x,y,z) in R 3, write point x as xyzxyz x1x2x3x4x1x2x3x4 x = x 1 / x 4, y = x 2 / x 4, z = x 3 / x 4, x 4 = anything non-zero! (but usually defaults to 1) z

A Very Common Mistaek: P 2 homog. coords: 2D projective map (2D point  3D ray is correct)P 2 homog. coords: 2D projective map (2D point  3D ray is correct) P 3 homog. coords. 3D projective map ( But 3D point  3D ray’ is WRONG!)P 3 homog. coords. 3D projective map ( But 3D point  3D ray’ is WRONG!) x2x2x2x2 x1x1x1x1 x2x2x2x2 x1x1x1x1 x3x3x3x3 (x,y) (x 1, x 2, x 3 ) (x,y,z) (x 1, x 2, x 3, x 4 )

A Very Common Mistaek P 2 homog. coords: 2D projective map (2D point  3D ray)P 2 homog. coords: 2D projective map (2D point  3D ray) P 3 homog. coords. 3D projective map ( 3D point  3D ray’ is WRONG!)P 3 homog. coords. 3D projective map ( 3D point  3D ray’ is WRONG!) x2x2x2x2 x1x1x1x1 x2x2x2x2 x1x1x1x1 x3x3x3x3 (x,y,z) (x,y) (x 1, x 2, x 3 ) (x,y,z) (x 1, x 2, x 3, x 4 ) NO! Don’t confuse 3D ‘z’ with projective x 4 !

P 3 : Point  Plane duality Recall Plane Equations in 3D: Normal vector: (a,b,c) = n Unaffected by scale k, with Min. Distance from plane to origin: d Write in 3D homog. coordinates: Point x and Plane  are duals (lines are not!) ax + by + cz +d = 0 kax + kby + kcz + kd= 0 = 0 x 1 x 2 x 3 x 4 abcdabcd x T.  = 0 ax + by + cz +d = 0 ^

3D Homogeneous Coordinates P 2 homog. coords: 2D projective map (2D point  3D ray)P 2 homog. coords: 2D projective map (2D point  3D ray) P 3 homog. coords. 3D projective map 3D point  4D ‘ray’: --an impossible-to-draw plane in R 4 with normal x1,x2,x3 --its 3D part is a ray through originP 3 homog. coords. 3D projective map 3D point  4D ‘ray’: --an impossible-to-draw plane in R 4 with normal x1,x2,x3 --its 3D part is a ray through origin x2x2x2x2 x1x1x1x1 x2x2x2x2 x1x1x1x1 x3x3x3x3 (x,y,z) (x,y) (x 1, x 2, x 3 ) (x,y,z) (x 1, x 2, x 3, x 4 ) x3x3x3x3 (Approx. as many 2D planes of constant z) (One 2D plane of constant z)

3D Homogeneous Coordinates P 3 homog. coords. 3D projective map 3D point  4D ‘ray’: --Superset of P 2 transformations: --Includes translation, projection from any point x2x2x2x2 x1x1x1x1 x3x3x3x3 (x,y,z) (x,y,z) (x 1, x 2, x 3, x 4 ) (Approx. as many 2D planes of constant z) H (x 1 ’, x 2 ’, x 3 ’, x 4 ’) x2x2x2x2 x1x1x1x1 x3x3x3x3

Find plane  thru points P 1,P 2,P 3 ?Find plane  thru points P 1,P 2,P 3 ? –Easy! Stack points: –Find null space (SVD) –(Rank 2? collinear points!) OR: use 3D cross products:OR: use 3D cross products: Points  Plane Conversions PT1PT1PT2PT2PT3PT3PT1PT1PT2PT2PT3PT3 = 0  p 11 p 12 p 13 p 14 p 21 p 22 p 23 p 24 p 31 p 32 p 33 p 34 1122334411223344 = 0  = (p1 – p3)  (p2-p3) – x3(x1  x2) – x3(x1  x2) (p 1 - p 3 )  (p 2 - p 3 ) -p 3 T · ( p 1  p 2 )  = = = = (scalar)

Plane  can define a 3D coordinate system (find u,v coordinates within plane, w along plane normal) –Because  is equiv. to plane’s normal vector –Find 3  vectors in P3 (null space of [0 0 0  ] ) –assemble them as columns of 4x3 M vector –To get 3D coords of any P 3 point p: M p = x’ –Finds a 2D coords in P 2 plane (of  ): x’ = Points  Planes in P 3 uvw

Lines in P 3 : Awkward Geometrically, Lines are:Geometrically, Lines are: –Intersection of 2 (or more) planes, –An axis or ‘pencil’ of planes, –Linear combo of 2 points, p 1 + A(p 2 -p 1 ) –a 4 DOF entity in P 3 ; a 4-vector won’t do! Symbolically: Three forms of P 3 lines:Symbolically: Three forms of P 3 lines: –‘Span’ : Null Space of matrix W –Plűcker Matrix –Plűcker Line Coordinates

Recall that a point x is on a plane  iffRecall that a point x is on a plane  iff if 2 given points A, B intersect with a ‘pencil’ of planes on a line,if 2 given points A, B intersect with a ‘pencil’ of planes on a line, Define a ‘P3 line’ as that intersection: stack A T, B T to make 2x4 matrix W:Define a ‘P3 line’ as that intersection: stack A T, B T to make 2x4 matrix W: W = If line W contains the plane , then W  = 0If line W contains the plane , then W  = 0 P 3 Lines 1a: ( Point-Point ) Span W a 1 a 2 a 3 a 4 b 1 b 2 b 3 b 4 A B x T.  = 0 T.  = 0 AB

P 3 Lines 1b: ( Plane-Plane ) Span W* Recall that a point x is on a plane  ifRecall that a point x is on a plane  if If 2 given planes P,Q intersect at a ‘pencil’ of points on a line,If 2 given planes P,Q intersect at a ‘pencil’ of points on a line, Define a ‘P3 line’ as that intersection: stack P T, Q T to make 2x4 matrix W*:Define a ‘P3 line’ as that intersection: stack P T, Q T to make 2x4 matrix W*: W* = If line W* contains the point x, then W* x = 0If line W* contains the point x, then W* x = 0 p 1 p 2 p 3 p 4 q 1 q 2 q 3 q 4 x T.  = 0 P Q x T. PQ = 0

P 3 Lines 1:Spans (Point) Span W(Point) Span W –(Found from points A,B) –Used to test plane  : (Plane) Span W*(Plane) Span W* –(Found from planes P,Q) –Used to test point x : P Q A B W T W* = W* W T = 0 2x2 (the 2x2 null matrix) W  = 0 W* x = 0 Useful property:

P 3 Lines 1: ‘Join’ reverses Spans... Join Line W and Point p  Plane Join Line W and Point p  Plane  W  = 0 iff plane  holds line W, and p T  = 0 iff plane  holds point p; stack … Let M = ; solve for  in M  = 0 W  = 0 iff plane  holds line W, and p T  = 0 iff plane  holds point p; stack … Let M = ; solve for  in M  = 0 Join Line W* and Plane   Point pJoin Line W* and Plane   Point p W* p = 0 iff line W* holds point p  p = 0 iff plane  holds point p; stack… W* p = 0 iff line W* holds point p  p = 0 iff plane  holds point p; stack… Let M* = ; solve for p in M* p = 0 W WWpTpTWWpTpT W*

P 3 Lines 2: Plűcker Matrices Line == A 4x4 symmetric matrix, rank 2, 4DOF Line L through known points A, B:Line L through known points A, B: L = A. B T - B. A T = Line L* through known planes P,Q:Line L* through known planes P,Q: L* = P. Q T – QP T a 1 a 2 a 3 a 4 b 1 b 2 b 3 b 4 a1a2a3a4a1a2a3a4a1a2a3a4a1a2a3a4 b1b2b3b4b1b2b3b4b1b2b3b4b1b2b3b4 - P Q A B Two forms:

P 3 Lines 2: Plűcker Matrices Line == A 4x4 symmetric matrix, rank 2, 4DOF Line L through A, B pts: L = A. B T - B. A TLine L through A, B pts: L = A. B T - B. A T Line L* through P,Q planes: L* = P. Q T - QP TLine L* through P,Q planes: L* = P. Q T - QP T L  L* convert? Note that:L  L* convert? Note that: –Skew-symmetric; –L’s has 6 params: or –Note det|L|=0 is written l 12 l 34 + l 13 l 42 +l 14 l 23 = 0 –Simple! Replace l ij with l mn so that {i,j,m,n} = {1,2,3,4} Examples: l 12  l 34,or l 42  l 13 etc.  l 12 l 13 l 14  l 23 l 24  l 34   l 12 l 13 l 14   l 23 l 24    l 34      l 12 l 13 l 14  l 23   l 34  l 42   l 12 l 13 l 14   l 23     l 34  l 42   (to avoid minus signs)

P 3 Lines 2: Plűcker Matrices Join Line L* and Point p  Plane Join Line L* and Point p  Plane  L*. p =  (if point is on the line, then L*. p = 0 ) L*. p =  (if point is on the line, then L*. p = 0 ) Join Line L and Plane   Point p L.  = p L.  = p (if line is in the plane, then L.  =0 ) (if line is in the plane, then L.  =0 )

P 3 Lines 3: Plűcker Line Coords ==Plűcker Matrix has 6 vital elements: –Off-diagonals or –Just make them a 6-vector: and require that det|L| = 0, or:  l 12 l 13 l 14  l 23 l 24  l 34   l 12 l 13 l 14   l 23 l 24    l 34      l 12 l 13 l 14  l 23   l 34  l 42   l 12 l 13 l 14   l 23     l 34  l 42   (to avoid minus signs) L = l 12 l 13 l 14 l 23 l 42 l 34 l 12 l 34 + l 13 l 42 +l 14 l 23 = 0

Projective Transformations Use H for transforms in P 3 : Use H for transforms in P 3 : –Has 15 DOF (4x4 -1) –Superset of the P 2 H matrix: Homework Hint: ProjA show P 2 objects in R 3 ProjA show P 2 objects in R 3 x 1  x,x 2  y,x 3  z; uses  h 11 h 12 h 13 h 21 h 22 h 21 h 31 h 32 h 33 h 11 h 12 0 h 13 h 21 h 22 0 h h 31 h 32 0 h 33 h 11 h 12 h 13 h 14 h 21 h 22 h 23 h 24 h 31 h 32 h 33 h 34 h 41 h 42 h 43 h 44 H = H2 =H2 =H2 =H2 = h 11 h 12 h 13 0 h 21 h 22 h 23 0 h 31 h 32 h

P 3 Transformations Transform a point p or plane  with H:Transform a point p or plane  with H: Lines 1: Transform a span:Lines 1: Transform a span: Lines 2: Transform a Plűcker Matrix:Lines 2: Transform a Plűcker Matrix: p’ = H. p  ’ = H -T.  W’ = H. W W*’ = H -T. W* L’ = H. L. H T L*’ = H -T. L*. H -1

END