Projective Geometry Shao-Yi Chien Department of Electrical - - PowerPoint PPT Presentation

projective geometry
SMART_READER_LITE
LIVE PREVIEW

Projective Geometry Shao-Yi Chien Department of Electrical - - PowerPoint PPT Presentation

Projective Geometry Shao-Yi Chien Department of Electrical Engineering National Taiwan University Fall 2019 1 Outline Projective 2D geometry Projective 3D geometry [Slides credit: Marc Pollefeys] 2 Projective 2D Geometry


slide-1
SLIDE 1

Projective Geometry

簡韶逸 Shao-Yi Chien Department of Electrical Engineering National Taiwan University Fall 2019

1

slide-2
SLIDE 2

Outline

  • Projective 2D geometry
  • Projective 3D geometry

2

[Slides credit: Marc Pollefeys]

slide-3
SLIDE 3
  • Points, lines & conics
  • Transformations & invariants
  • 1D projective geometry and

the cross-ratio

Projective 2D Geometry

3

slide-4
SLIDE 4

Homogeneous Coordinates

   c by ax

 

T

a,b,c

, ) ( ) (      k kc y kb x ka

   

T T

a,b,c k a,b,c ~

 Homogeneous representation of lines equivalence class of vectors, any vector is representative  Homogeneous representation of points

   c by ax

 

T

a,b,c  l

 

T

y x, x 

  • n

if and only if

    

l 1 1   x,y, a,b,c x,y,

T

   

, 1 , , ~ 1 , ,  k y x k y x

T T

The point x lies on the line l if and only if xTl=lTx=0 Homogeneous coordinates Inhomogeneous coordinates 

T

y x,

 

T 3 2 1

, , x x x

but only 2DOF The point x=(𝑦1, 𝑦2, 𝑦3)T represent the point (𝑦1/𝑦3, 𝑦2/𝑦3)T in ℝ2

4

slide-5
SLIDE 5

Points and Lines

l' l x  

 Intersections of lines The intersection of two lines and is

l l'

 Line joining two points The line through two points and is

x' x l  

x

x'

Example

1  x 1  y

5

slide-6
SLIDE 6

Ideal Points and the Line at Infinity

 

T

, , l' l a b   

 Intersections of parallel lines

   

T T and

' , , l' , , l c b a c b a  

Example

1  x 2  x

Ideal points

 

T

, ,

2 1 x

x

Line at infinity

 

T

1 , , l 

 

  l

2 2

R P

tangent vector (line’s direction) normal direction

 

a b  ,

 

b a,

Note that in P2 there is no distinction between ideal points and others

6

slide-7
SLIDE 7

A Model for the Projective Plane

exactly one line through two points exaclty one point at intersection of two lines

x3=1

7

slide-8
SLIDE 8

Duality

x l

x l 

T

l x 

T

l' l x   x' x l  

 Duality principle: To any theorem of 2-dimensional projective geometry there corresponds a dual theorem, which may be derived by interchanging the role of points and lines in the original theorem

8

slide-9
SLIDE 9

Conics

Curve described by 2nd-degree equation in the plane

2 2

      f ey dx cy bxy ax

2 3 3 2 3 1 2 2 2 1 2 1

      fx x ex x dx cx x bx ax

3 2 3 1

, x x y x x x  

  • r homogenized

x x  C

T

  • r in matrix form

           f e d e c b d b a 2 / 2 / 2 / 2 / 2 / 2 / C

with

 

f e d c b a : : : : :

5DOF:

symmetric

9

slide-10
SLIDE 10

Five Points Define a Conic

For each point the conic passes through

2 2

      f ey dx cy y bx ax

i i i i i i

  • r

 

, , , , ,

2 2

 c f y x y y x x

i i i i i i

 

T

f e d c b a , , , , ,  c 1 1 1 1 1

5 5 2 5 5 5 2 5 4 4 2 4 4 4 2 4 3 3 2 3 3 3 2 3 2 2 2 2 2 2 2 2 1 1 2 1 1 1 2 1

                 c y x y y x x y x y y x x y x y y x x y x y y x x y x y y x x

stacking constraints yields

10

slide-11
SLIDE 11

Tangent Lines to Conics

The line l tangent to C at point x on C is given by l=Cx

l x C

11

slide-12
SLIDE 12

Dual Conics

l l

* 

C

T

A line tangent to the conic C satisfies Dual conics = line conics = conic envelopes

1 * 

 C C

In general (C full rank):

12

slide-13
SLIDE 13

Projective Transformations

A projectivity is an invertible mapping h from P2 to itself such that three points x1,x2,x3 lie on the same line if and only if h(x1),h(x2),h(x3) do. Definition: A mapping h:P2P2 is a projectivity if and only if there exist a non-singular 3x3 matrix H such that for any point in P2 reprented by a vector x it is true that h(x)=Hx Theorem: Definition: Projective transformation

                              

3 2 1 33 32 31 23 22 21 13 12 11 3 2 1

' ' ' x x x h h h h h h h h h x x x

x x' H 

  • r

8DOF

projectivity=collineation=projective transformation=homography 14

slide-14
SLIDE 14

Mapping between Planes

central projection may be expressed by x’=Hx

(application of theorem)

15

slide-15
SLIDE 15

Removing Projective Distortion

33 32 31 13 12 11 3 1

' ' ' h y h x h h y h x h x x x      

33 32 31 23 22 21 3 2

' ' ' h y h x h h y h x h x x y      

 

13 12 11 33 32 31

' h y h x h h y h x h x     

 

23 22 21 33 32 31

' h y h x h h y h x h y     

select four points in a plane with know coordinates (linear in hij) (2 constraints/point, 8DOF  4 points needed) Remark: no calibration at all necessary

16

slide-16
SLIDE 16

More Examples

17

slide-17
SLIDE 17

Transformation of Lines and Conics

Transformation for lines

l l'

  • T

H 

Transformation for conics

  • 1
  • TCH

H C  '

Transformation for dual conics

T

H HC C

* *

'  x x' H 

For a point transformation

18

slide-18
SLIDE 18

A Hierarchy of Transformations

 Projective linear group  Affine group (last row (0,0,1))  Euclidean group (upper left 2x2 orthogonal)  Oriented Euclidean group (upper left 2x2 det 1) Alternative, characterize transformation in terms of elements

  • r quantities that are preserved or invariant

e.g. Euclidean transformations leave distances unchanged

Similarity Affine Projective

19

slide-19
SLIDE 19

Class I: Isometries

                                1 1 cos sin sin cos 1 ' ' y x t t y x

y x

      1    1   1   

  • rientation preserving:
  • rientation reversing:

x x x'         1 t

T

R H E I R R 

T

special cases: pure rotation, pure translation 3DOF (1 rotation, 2 translation), can be computed from 2 point correspondences Invariants: length, angle, area (Euclidean transform)

20

slide-20
SLIDE 20

Class II: Similarities

                                1 1 cos sin sin cos 1 ' ' y x t s s t s s y x

y x

    x x x'         1 t

T

R H s

S

I R R 

T

4DOF (1 scale, 1 rotation, 2 translation), can be computed from 2 point correspondences Invariants: ratios of length, angle, ratios of areas, parallel lines

21

also know as equi-form (shape preserving)

slide-21
SLIDE 21

Class III: Affine Transformations

                               1 1 1 ' '

22 21 12 11

y x t a a t a a y x

y x

x x x'         1 t

T

A H A

non-isotropic scaling! (2DOF: scale ratio and orientation) 6DOF (2 scale, 2 rotation, 2 translation), can be computed from 3 point correspondences Invariants: parallel lines, ratios of parallel lengths, ratios of areas

     

   DR R R A         

2 1

  D

22

slide-22
SLIDE 22

Class VI: Projective Transformations

Action non-homogeneous over the plane 8DOF (2 scale, 2 rotation, 2 translation, 2 line at infinity) can be computed from 4 point correspondences Invariants: cross-ratio of four points on a line, (ratio of ratio)

x v x x'         v

P T

t A H

 

T 2 1,

v v v 

23

slide-23
SLIDE 23

Action of Affinities and Projectivities

  • n Line at Infinity

                                   

2 2 1 1 2 1 2 1

v x v x v x x x x v A A

T

t

                                  

2 1 2 1

x x x x v A A

T

t

Line at infinity becomes finite, allows to observe vanishing points, horizon Line at infinity stays at infinity, but points move along line

24

slide-24
SLIDE 24

Decomposition of Projective Transformations

                           v v s

P A S T T T T

v t v 1 1 t A I K R H H H H

T

tv   RK A s K

1 det  K

upper-triangular, decomposition unique (if chosen s>0)

           . 1 . 2 . 1 . 2 242 . 8 707 . 2 . 1 586 . 707 . 1 H                                 1 2 1 1 1 1 2 1 5 . 1 . 2 45 cos 2 45 sin 2 . 1 45 sin 2 45 cos 2

   

H

Example:

S: similarity A: Affine P: Projective

25

slide-25
SLIDE 25

Summary of Transformations

          1

22 21 12 11 y x

t a a t a a           1

22 21 12 11 y x

t sr sr t sr sr          

33 32 31 23 22 21 13 12 11

h h h h h h h h h           1

22 21 12 11 y x

t r r t r r

Projective 8dof Affine 6dof Similarity 4dof Euclidean 3dof

Concurrency, collinearity,

  • rder of contact (intersection,

tangency, inflection, etc.), cross ratio Parallellism, ratio of areas, ratio of lengths on parallel lines (e.g midpoints), linear combinations of vectors (centroids). The line at infinity l∞ Ratios of lengths, angles. The circular points I,J lengths, areas.

Invariant Properties

26

slide-26
SLIDE 26

Number of Invariants?

The number of functional invariants is equal to, or greater than, the number of degrees of freedom of the configuration less the number of degrees of freedom of the transformation e.g. configuration of 4 points in general position has 8 dof (2/pt) and so 4 similarity, 2 affinity and zero projective invariants

27

slide-27
SLIDE 27

Projective Geometry of 1D

x ' x

2 2

 H

The cross ratio Invariant under projective transformations

 

T 2 1, x

x

3DOF (2x2-1)

2 

x

 

4 2 3 1 4 3 2 1 4 3 2 1

x , x x , x x , x x , x x , x , x , x  Cross

      

2 2 1 1

det x , x

j i j i j i

x x x x

slide-28
SLIDE 28

Recovering Metric and Affine Properties from Images

  • Parallelism
  • Parallel length ratios
  • Angles
  • Length ratios
slide-29
SLIDE 29

The Line at Infinity

    

                     l 1 1 t l l A A H

T T A

The line at infinity l is a fixed line under a projective transformation H if and only if H is an affinity Note: not fixed pointwise

slide-30
SLIDE 30

Affine Properties from Images

projection rectification

A PA

l l l H H           

3 2 1

1 1

 

, l

3 3 2 1

 

l l l l

T

HP 𝐼𝑄

−T(𝑚1, 𝑚2,𝑚3)T= (0,0,1)T= 𝑚∞

slide-31
SLIDE 31

Affine Rectification

v1 v2 l1 l2 l4 l3 l∞

2 1

v v l  

 2 1 1

l l v  

4 3 2

l l v  

slide-32
SLIDE 32

Distance Ratios

   

b a d d        : c , b : b , a

 

T

, 1 v' H 

     

T T T

1 , , 1 , , 1 , b a a 

c , b , a    H

slide-33
SLIDE 33

The Circular Points

           1 I i             1 J i I 1 1 1 cos sin sin cos I I                                     i se i t s s t s s

i y x S 

    H

The circular points I, J are fixed points under the projective transformation H iff H is a similarity

slide-34
SLIDE 34

The Circular Points

“circular points”

2 3 3 2 3 1 2 2 2 1

     fx x ex x dx x x

2 2 2 1

  x x

l∞

   

T T

, , 1 J , , 1 I i i   

   

T T

, 1 , , , 1 I i  

Algebraically, encodes orthogonal directions

3 

x

slide-35
SLIDE 35

Conic Dual to the Circular Points

T T

JI IJ

*

 

C

          

1 1

*

C

T S S

H C H C

* *   

The dual conic is fixed conic under the projective transformation H iff H is a similarity

* 

C

slide-36
SLIDE 36

Angles

  

2 2 2 1 2 2 2 1 2 2 1 1

cos m m l l m l m l     

 

T 3 2 1

, , l l l l 

 

T 3 2 1

, , m m m m 

Euclidean: Projective:

  

m m l l m l cos

* * *   

 C C C

T T T

 m l

*

C

T

If orthogonal

(This equation is Invariant to projective transform)

slide-37
SLIDE 37

Length Ratios

  sin sin ) , ( ) , (  c a d c b d

cos𝛽 and cos𝛾 can be derived with the equations in the previous page

slide-38
SLIDE 38

Metric Properties from Images

           

         

   

v v v v '

* * * * T T T T T T T T

K K KK H H C H H H H H C H H H H H H C H H H C

A P A P A P S S A P S A P S A P T

U U C           

1 1 '

*

Rectifying transformation from SVD

U H 

slide-39
SLIDE 39

Metric from Affine

 

3 2 1 3 2 1

                       m m m l l l

T

KK

 

, , , ,

2 22 12 11 2 12 2 11 2 2 1 2 2 1 1 1

          

T

k k k k k m l m l m l m l

Suppose an image has been affinely rectified (v=0)

slide-40
SLIDE 40

Metric from Projective

       

c , , , , ,

3 3 2 3 3 2 1 3 3 1 2 2 1 2 2 1 1 1

5 . 5 . 5 .

                      m l m l m l m l m l m l m l m l m l

 

v v v v

3 2 1 3 2 1

                       m m m l l l

T T T T

K K KK

m l

*

C

T

𝐝 = (𝑏, 𝑐, 𝑑, 𝑒, 𝑓, 𝑔)T

slide-41
SLIDE 41

Pole-polar Relationship

The polar line l=Cx of the point x with respect to the conic C intersects the conic in two points. The two lines tangent to C at these points intersect at x

slide-42
SLIDE 42

Projective 3D Geometry

  • Points, lines, planes and quadrics
  • Transformations
  • П∞, ω∞ and Ω ∞
slide-43
SLIDE 43

3D Points

 

T T

1 , , , 1 , , , X

4 3 4 2 4 1

Z Y X X X X X X X          

in R3

 

4 

X

 

T

Z Y X , ,

in P3

X X' H 

(4x4-1=15 dof) projective transformation 3D point

 

T 4 3 2 1

, , , X X X X X 

slide-44
SLIDE 44

Planes

π π π π

4 3 2 1

    Z Y X π π π π

4 4 3 3 2 2 1 1

    X X X X

X π 

T

Dual: points ↔ planes, lines ↔ lines 3D plane

X ~ . n   d

 

T 3 2 1

π , π , π n 

 

T

Z Y X , , X ~ 

1

4 

X d 

4

π

Euclidean representation

n / d

X X' H  π π'

  • T

H  Transformation

slide-45
SLIDE 45

Planes from Points

π X X X

3 2 1

          

T T T 234 1D

X

 

T 123 124 134 234

, , , π D D D D   

                       

det

4 3 4 2 4 1 4 3 3 3 2 3 1 3 2 3 2 2 2 1 2 1 3 1 2 1 1 1

             X X X X X X X X X X X X X X X X π X π X 0, π X π

3 2 1

  

T T T

and from Solve

(solve as right nullspace of )

π

         

T T T 3 2 1

X X X

 

X X X X det

3 2 1

Or implicitly from coplanarity condition

124 3 134 2 234 1

D X D X D X  

123 4 124 3 134 2 234 1

    D X D X D X D X

134 2 234 1

D X D X 

slide-46
SLIDE 46

Points from Planes

X π π π

3 2 1

          

T T T

X π X π 0, X π X

3 2 1

  

T T T

and from Solve

(solve as right nullspace of )

X

         

T T T 3 2 1

π π π

slide-47
SLIDE 47

Points and Planes

  • Projective transformation
  • Parametrized points on a plane

49

x X M  π  M

T

       I p M

 

T

d c b a , , , π 

T

      

   a d a c a b

p

, ,

Representing a plane by its span Under the point transformation 𝒀′ = 𝐼𝒀, a plane transforms as 𝝆′ = 𝐼−𝑈𝝆

x is a 3-vector parameter (a point on the projective plane) M is not unique

slide-48
SLIDE 48

Lines

      

T T

B A W

μB λA

      

T T

Q P W*

μQ λP

2 2 * *

WW W W

 

T T

       1 1 W        1 1 W*

Example: X-axis (4dof) Defined as the join of two points A, B (Dual) Defined as the intersection of two planes P, Q

slide-49
SLIDE 49

Points, Lines and Planes

      

T

X W M

π  M       

T

π W* M X  M W X

*

W

π

slide-50
SLIDE 50

Plücker Matrices

j i j i ij

A B B A l  

T T

BA AB L  

Plücker matrix (4x4 skew-symmetric homogeneous matrix)

  • 1. L has rank 2

2. 4dof 3. generalization of 4.

L independent of choice A and B

5. Transformation

2 4 *

LW

T

y x l  

T

HLH L'

   

                                        1 1 1 1 1 1 L

T

Example: x-axis

slide-51
SLIDE 51

Plücker Matrices

T T

QP PQ L

*

 

Dual Plücker matrix L*

  • 1

TLH

H L

  • '

*  * 12 * 13 * 14 * 23 * 42 * 34 34 42 23 14 13 12

: : : : : : : : : : l l l l l l l l l l l l 

X L π

*

Lπ X 

Correspondence Join and incidence

X L

*

(plane through point and line) (point on line) (intersection point of plane and line) (line in plane)

Lπ 

 

π , L , L

2 1

 

(coplanar lines)

slide-52
SLIDE 52

Quadrics and Dual Quadrics

(Q : 4x4 symmetric matrix)

QX X 

T

1. 9 d.o.f. 2. in general 9 points define quadric 3. det Q=0 ↔ degenerate quadric 4. Polar plane 5. (plane ∩ quadric)=conic 6. transformation

                            

Q

QX π 

QM M C

T

 Mx X : π 

  • 1
  • TQH

H Q' π Q π

*  T

  • 1

*

Q Q 

1. relation to quadric (non-degenerate) 2. transformation

T

H HQ Q'

* * 

Q*: dual quadric, equations on planes

slide-53
SLIDE 53

Quadric Classification

Rank Sign. Diagonal Equation Realization 4 4 (1,1,1,1) X2+ Y2+ Z2+1=0 No real points 2 (1,1,1,-1) X2+ Y2+ Z2=1 Sphere (1,1,-1,-1) X2+ Y2= Z2+1 Hyperboloid (1S) 3 3 (1,1,1,0) X2+ Y2+ Z2=0 Single point 1 (1,1,-1,0) X2+ Y2= Z2 Cone 2 2 (1,1,0,0) X2+ Y2= 0 Single line (1,-1,0,0) X2= Y2 Two planes 1 1 (1,0,0,0) X2=0 Single plane

slide-54
SLIDE 54

Quadric Classification

Projectively equivalent to sphere: Ruled quadrics: hyperboloids

  • f one sheet

hyperboloid of two sheets paraboloid sphere ellipsoid Degenerate ruled quadrics: cone two planes (contain straight line)

slide-55
SLIDE 55

Hierarchy of Transformations

      v

T

v t A

Projective 15dof Affine 12dof Similarity 7dof Euclidean 6dof

Intersection and tangency Parallellism of planes, Volume ratios, centroids, The plane at infinity π∞ The absolute conic Ω∞ Volume

      1 t A

T

      1 t R

T

s       1 t R

T

Invariant Properties

3 for rotation 3 for translation 1 for isotropic scaling 5 for affine scaling

slide-56
SLIDE 56

Screw Decomposition

Any particular translation and rotation is equivalent to a rotation about a screw axis and a translation along the screw axis.

slide-57
SLIDE 57

Screw Decomposition

Any particular translation and rotation is equivalent to a rotation about a screw axis and a translation along the screw axis.

  t t t

//

screw axis // rotation axis

slide-58
SLIDE 58

The Plane at Infinity

    

                         π 1 1 t π π A A H

T T A

The plane at infinity π is a fixed plane under a projective transformation H iff H is an affinity

1. canical position 2. contains directions 3. two planes are parallel  line of intersection in π∞ 4. line // line (or plane)  point of intersection in π∞

 

T

1 , , , π 

 

T

, , , D

3 2 1

X X X 