Projective Line - University of Pennsylvania
Transcript of Projective Line - University of Pennsylvania
Celestial Navigation
Earth
Far far away: point at infinity
My location
Projection of the star
57 stars for navigation
Celestial Navigation
Earth
Far far away: point at infinity
Projection of the star
My location
Zenith
57 stars for navigation
Celestial Navigation
Earth
Far far away: point at infinity
Projection of the star
My location
rr
r : radius of earth
: angle between stars
Zenith
Celestial Navigation Far far away: point at infinity
My location
Horizon
Sextant
Earth
Projection of the star
Zenith
Celestial Navigation Far far away: point at infinity
My location
Horizon
Sextant
Earth
Projection of the star
Direction does not change because
the star is infinitly far away.
Zenith
Celestial Navigation Far far away: point at infinity
My location
Horizon
Sextant
Earth
Projection of the star
rr
r : radius of earth
: angle between stars
Orthographic proj.
Zenith
Celestial Navigation Far far away: point at infinity
Horizon
Sextant
Earth
r : radius of earth
: angle between stars
Celestial Navigation Far far away: point at infinity
Horizon
Sextant
Earth
At least two stars are needed.
Celestial Navigation Far far away: point at infinity
Horizon
Earth
At least two stars are needed.
Two points at infinity (vanishing points) tells us about where I am.
Parallel lines in 3D converge to a point in the image.
MLPS-St. Paul International Airport
Indoor point at infinity
3D Parallel Line Projection
Vanishing point
Ground plane
1. Parallel lines in 3D meet at the same vanishing point in image.
2. The 3D ray passing camera center and the vanishing point is parallel to the lines.
Camera plane
Vanishing Point
Vanishing point
1. Parallel lines in 3D meet at the same vanishing point in image.
2. The 3D ray passing camera center and the vanishing point is parallel to the lines.
3. Multiple vanishing points exist.
Ground plane
Camera plane
Keller Hall
Vanishing point
Vanishing point
What can vanishing line tell us about me?
• Horizon
• Camera pitch angle (looking down)
• Camera roll angle (tilted toward right)
Vanishing line for horizon
Celestial Navigation Far far away: point at infinity
Horizon
Earth
At least two stars are needed.
Two points at infinity (vanishing points) tells us about where I am.
Point-Line in Image
A 2D line passing through 2D point (u,v ):
au bv c 0 au bv c 0
( , )uv
Line parameter: (a,b,c)
Point-Line in Image
A 2D line passing through 2D point (u,v ):
au bv c 0 au bv c 0
( , )uv
Line parameter: (a,b,c )
u
a b c v l xT 0
1
where
u
vx
1
a
b
c
land
au bv c 0
Line parameter2D point
=
a
b
c
l2D line:
1
u
vx
Point-Point in ImageA 2D line passing through two 2D points:
1 10 au bv c
1 1( , )u v
1xx2
2 2( , )u v
2 20 au bv c
Point-Point in Image
1 10 au bv c
1 1( , )u v
1xx2
2 2( , )u v
2 20 au bv c
x lT
10 x lT
20
1
1 1
1
x
u
v
2
2 2
1
x
u
v
a
b
c
lwhere
A 2D line passing through two 2D points:
Point-Point in Image
1 10 au bv c
1 1( , )u v
1xx2
2 2( , )u v
2 20 au bv c
x lT
10 x lT
20
1
1 1
1
x
u
v
2
2 2
1
x
u
v
a
b
c
lwhere
A 2D line passing through two 2D points:
xl 0
x
T
1
T
2
2x3
00
A
Point-Point in Image
1 10 au bv c
1 1( , )u v
1xx2
2 2( , )u v
2 20 au bv c
x lT
10 x lT
20
1
1 1
1
x
u
v
2
2 2
1
x
u
v
a
b
c
lwhere
A 2D line passing through two 2D points:
xl 0
x
T
1
T
2
3x2
00
A
null A l x x1 2
=or
Point-Point in Image
(1804,934)(1052,1323)
function GetLineFromTwoPoints
x1 = [1804;934;1];x2 = [1052;1323;1];
l
1 1( , )u v
1xx2
2 2( , )u v
Point-Point in Image
(1804,934)(1052,1323)
function GetLineFromTwoPoints
x1 = [1804;934;1];x2 = [1052;1323;1];
l = Vec2Skew(x1)*x2;
Cross product
a b a b
a b ab
ab a b
a a b
a -a b
-a a b
a b
a b
2 3 3 2
3 1 1 3
1 2 2 1
3 2 1
3 1 2
2 1 3
-
= -
-
0 -
0
0
Cross product with skew-symmetric matrix representation:
function skew = Vec2Skew(v)skew = [0 -v(3) v(2);
v(3) 0 -v(1);-v(2) v(1) 0];
l
1 1( , )u v
1xx2
2 2( , )u v
Point-Point in Image
(1804,934)(1052,1323)
function GetLineFromTwoPoints
x1 = [1804;934;1];x2 = [1052;1323;1];
l = Vec2Skew(x1)*x2;
l =
-389-752
1404124
Cross product
a b a b
a b ab
ab a b
a a b
a -a b
-a a b
a b
a b
2 3 3 2
3 1 1 3
1 2 2 1
3 2 1
3 1 2
2 1 3
-
= -
-
0 -
0
0
Cross product with skew-symmetric matrix representation:
function skew = Vec2Skew(v)skew = [0 -v(3) v(2);
v(3) 0 -v(1);-v(2) v(1) 0];
l
1 1( , )u v
1xx2
2 2( , )u v
Two 2D lines in an image intersect at a 2D point:
Line-Line in Image
1
1 1
1
l
a
b
c
( , )uvx
2
2 2
2
l
a
b
c
1 1 10 au bv c
2 2 20 a u bv c
Two 2D lines in an image intersect at a 2D point:
Line-Line in Image
l xT
10 l xT
20
1
1 1
1
l
a
b
c
( , )uvx
2
2 2
2
l
a
b
c
1 1 10 au bv c
2 2 20 a u bv c
1
x
u
v
1
1 1
1
l
a
b
c
where
2
2 2
2
l
a
b
c
Two 2D lines in an image intersect at a 2D point:
Line-Line in Image
l xT
10 l xT
20
lx 0
l
T
1
T
2
l x x1 2
=
1
1 1
1
l
a
b
c
( , )uvx
2
2 2
2
l
a
b
c
1 1 10 au bv c
2 2 20 a u bv c
1
x
u
v
1
1 1
1
l
a
b
c
where
2
2 2
2
l
a
b
c
2x3
00
A
null A
or
Line-Line in Image
1
1 1
1
l
a
b
c
( , )uvx
2
2 2
2
l
a
b
c
function GetPointFromTwoLines
l1 = [-398;-752;1404124];l2 = [310;-924;303790];x = Vec2Skew(l1)*l2;x = x/x(3)
x =
1779.0925.61
similar to (1804,934)
2D Point and Line Duality
l x x1 2
The intersection between two lines:
x l l1 2
Given any formula, we can switch the
meaning of point and line to get
another formula.
The 2D line joining two points:
2D Point and Line Duality
l x x1 2
The intersection between two lines:
x l l1 2
Given any formula, we can switch the meaning of
point and line to get another formula.
1x
2x
The 2D line joining two points:
T: Transformation-T
2 1 2 1 x Tx l T l
2D Point and Line Duality
l x x1 2
The intersection between two lines:
x l l1 2
Given any formula, we can switch the meaning of
point and line to get another formula.
1x
2x
The 2D line joining two points:
T
T T -1 -T T
1 1 1 1 1 1 2 2 l x l T Tx T l Tx l x
T: Transformation-T
2 1 2 1 x Tx l T l
0
2D Point and Line Duality
l x x1 2
The intersection between two lines:
x l l1 2
Given any formula, we can switch the meaning of
point and line to get another formula.
1x
2x
The 2D line joining two points:
T
T T -1 -T T
1 1 1 1 1 1 2 2 l x l T Tx T l Tx l x
T: Transformation-T
2 1 2 1 x Tx l T l
0
2D Point and Line Duality
l x x1 2
The intersection between two lines:
x l l1 2
Given any formula, we can switch the meaning
of point and line to get another formula.
1x
2x
The 2D line joining two points:
T
T T -1 -T T
1 1 1 1 1 1 2 2 l x l T Tx T l Tx l x
T: Transformation-T
2 1 2 1 x Tx l T l
2D Point and Line Duality
l x x1 2
The intersection between two lines:
x l l1 2
Given any formula, we can switch the meaning of
point and line to get another formula.
2 1
cos sin 0
-sin cos 0
0 0 1
x x
1x
2x
The 2D line joining two points:
T
T T -1 -T T
1 1 1 1 1 1 2 2 l x l T Tx T l Tx l x
T: Transformation
T
2 1 1
cos sin 0 cos sin 0
-sin cos 0 -sin cos 0
0 0 1 0 0 1
l l l
-T
2 1 2 1 x Tx l T l
?
2D Point and Line Duality
l x x1 2
The intersection between two lines:
x l l1 2
Given any formula, we can switch the meaning
of point and line to get another formula.
2 1
cos sin 0
-sin cos 0
0 0 1
x x
1x
2x
The 2D line joining two points:
T
T T -1 -T T
1 1 1 1 1 1 2 2 l x l T Tx T l Tx l x
T: Transformation
T
2 1 1
cos sin 0 cos sin 0
-sin cos 0 -sin cos 0
0 0 1 0 0 1
l l l
-T
2 1 2 1 x Tx l T l
Geometric Interpretation (Point)
CO
1x̂
-1
1 1ˆ x K x
1x̂
2x̂
-1
2 2ˆ x K x
2x̂
-1
2 2ˆ x K x
Normalized coordinate:
-1
1 1ˆ x K x
Geometric Interpretation (Line)
CO
1x̂
-1
1 1ˆ x K x
1x̂
2x̂
-1
2 2ˆ x K x
2x̂
l̂
l̂
-1
2 2ˆ x K x
Normalized coordinate:
-1
1 1ˆ x K x
-T
-1 Tˆ l K l K l due to duality
1ˆ ˆl = x 2
ˆx
where ?
Geometric Interpretation (Line)
CO
1x̂
-1
1 1ˆ x K x
1x̂
2x̂
-1
2 2ˆ x K x
2x̂
l̂
l̂
-1
2 2ˆ x K x
Normalized coordinate:
-1
1 1ˆ x K x
-T
-1 Tˆ l K l K l due to duality
1ˆ ˆl = x 2
ˆx
where
CO
1x̂
2x̂
l̂
-1
1 1ˆ x K x
1x̂
2x̂
-1
2 2ˆ x K x
l̂
Geometric Interpretation (Line)3D planeπ
-1
2 2ˆ x K x
Normalized coordinate:
-1
1 1ˆ x K x
-T
-1 Tˆ l K l K l due to duality
1ˆ ˆl = x 2
ˆx
where
A 2D line in an image defines to a 3D plane
passing the camera center:
l̂ π
CO
1x̂
2x̂
l̂
-1
1 1ˆ x K x
1x̂
2x̂
-1
2 2ˆ x K x
l̂
Geometric Interpretation (Line)3D planeπ
-1
2 2ˆ x K x
Normalized coordinate:
-1
1 1ˆ x K x
-T
-1 Tˆ l K l K l due to duality
1ˆ ˆl = x 2
ˆx
where
A 2D line in an image defines to a 3D plane
passing the camera center:
l̂ π
Plane normal: 1 1ˆ x 2 2
ˆˆ x l
l̂
?
CO
1x̂
2x̂
l̂
-1
1 1ˆ x K x
1x̂
2x̂
-1
2 2ˆ x K x
l̂
Geometric Interpretation (Line)3D planeπ
-1
2 2ˆ x K x
Normalized coordinate:
-1
1 1ˆ x K x
-T
-1 Tˆ l K l K l due to duality
1ˆ ˆl = x 2
ˆx
where
A 2D line in an image defines to a 3D plane
passing the camera center:
l̂ π
Plane normal: 1 1ˆ x 2 2
ˆˆ x l
l̂
CO
1x̂
-1
2 2ˆ x K x
Normalized coordinate:
-1
1 1ˆ x K x
2x̂
l̂
-T
-1 Tˆ l K l K l due to duality
1ˆ ˆl = x 2
ˆx
where
-1
1 1ˆ x K x
1x̂
2x̂
-1
2 2ˆ x K x
l̂
Geometric Interpretation (Line)3D planeπ
A 2D line in an image defines to a 3D plane
passing the camera center:
l̂ π
Plane normal: 1 1ˆ x 2 2
ˆˆ x l
ˆ
0
lπ
ˆ
0
l
l̂
CO
Geometric Interpretation (Line-Line)
l1ˆl2
ˆ
1π
2π
x̂
x̂
2D lines in an image intersect a 2D point corresponding to a 3D ray:
x̂ 1ˆ= l 2
l̂