3-d euclidean space - vectors

8
1 CS682, Jana Kosecka Rigid Body Motion and Image Formation Jana Kosecka http://cs.gmu.edu/~kosecka/cs682.html CS682, Jana Kosecka 3- D Euclidean Space D Euclidean Space - Vectors Vectors A “free” vector is defined by a pair of points : Coordinates of the vector : CS682, Jana Kosecka 3D Rotation of Points – Euler angles Rotation around the coordinate axes, Rotation around the coordinate axes, counter counter-clockwise: clockwise: = = = 1 0 0 0 cos sin 0 sin cos ) ( cos 0 sin 0 1 0 sin 0 cos ) ( cos sin 0 sin cos 0 0 0 1 ) ( γ γ γ γ γ β β β β β α α α α α z y x R R R P x Y’ Y’ P’ P’ γ X’ X’ y z CS682, Jana Kosecka Rotation Matrices in 3D 3 by 3 matrices 9 parameters – only three degrees of freedom Representations – either three Euler angles or axis and angle represntation Properties of rotation matrices (constraints between the elements)

Upload: others

Post on 12-Sep-2021

4 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: 3-D Euclidean Space - Vectors

1

CS682, Jana Kosecka

Rigid Body Motion and

Image Formation

Jana Koseckahttp://cs.gmu.edu/~kosecka/cs682.html

CS682, Jana Kosecka

33--D Euclidean Space D Euclidean Space -- VectorsVectors

A “free” vector is defined by a pair of points :

Coordinates of the vector :

CS682, Jana Kosecka

3D Rotation of Points – Euler angles

Rotation around the coordinate axes, Rotation around the coordinate axes, countercounter--clockwise:clockwise:

−=

−=

−=

100

0cossin

0sincos

)(

cos0sin

010

sin0cos

)(

cossin0

sincos0

001

)(

γγγγ

γ

ββ

βββ

ααααα

z

y

x

R

R

R

PP

xx

Y’Y’P’P’

γγ

X’X’

yy

zzCS682, Jana Kosecka

Rotation Matrices in 3D

• 3 by 3 matrices• 9 parameters – only three degrees of freedom• Representations – either three Euler angles• or axis and angle represntation

• Properties of rotation matrices (constraints between the elements)

Page 2: 3-D Euclidean Space - Vectors

2

CS682, Jana Kosecka

Rotation Matrices in 3D

• 3 by 3 matrices• 9 parameters – only three degrees of freedom• Representations – either three Euler angles• or axis and angle representation

• Properties of rotation matrices (constraints between the elements)

Columns are orthonormal

CS682, Jana Kosecka

Canonical Coordinates for Rotation

By algebra

By solution to ODE

Property of R

Taking derivative

Skew symmetric matrix property

CS682, Jana Kosecka

3D Rotation (axis & angle)

with

or

Solution to the ODE

CS682, Jana Kosecka

Rotation Matrices

Given

How to compute angle and axis

Page 3: 3-D Euclidean Space - Vectors

3

CS682, Jana Kosecka

3D Translation of Points

Translate by a vector Translate by a vector

PPxxY’Y’

P’P’

x’x’

yyzz

z’z’

tt

CS682, Jana Kosecka

Rigid Body Motion – Homogeneous Coordinates

3-D coordinates are related by:

Homogeneous coordinates:

Homogeneous coordinates are related by:

CS682, Jana Kosecka

Rigid Body Motion – Homogeneous Coordinates

3-D coordinates are related by:

Homogeneous coordinates:

Homogeneous coordinates are related by:

CS682, Jana Kosecka

Properties of Rigid Body Motions

Rigid body motion composition

Rigid body motion inverse

Rigid body motion acting on vectors

Vectors are only affected by rotation – 4th homogeneous coordinate is zero

Page 4: 3-D Euclidean Space - Vectors

4

CS682, Jana Kosecka

Rigid Body Transformation

Coordinates are related by:Camera pose is specified by:

CS682, Jana Kosecka

Rigid Body Motion

• Camera is moving

• Notion of a twist

• Relationship between velocities

CS682, Jana Kosecka

Image Formation – Perspective Projection

“The Scholar of Athens,” Raphael, 1518

CS682, Jana Kosecka

Pinhole Camera Model

Pinhole

Frontalpinhole

Page 5: 3-D Euclidean Space - Vectors

5

CS682, Jana Kosecka

More on homogeneous coordinates

In homogeneous coordinates – thereis a difference between point and vector

In homogenous coordinates – these represent the Same point in 3D

The first coordinates can be obtained from the second by division by W

What if W is zero ? Special point – point at infinity – more later

CS682, Jana Kosecka

Pinhole Camera Model

2-D coordinates

Homogeneous coordinates

CS682, Jana Kosecka

Image Coordinates

pixelcoordinates

Linear transformation

metriccoordinates

CS682, Jana Kosecka

Calibration Matrix and Camera Model

Pinhole camera Pixel coordinates

Calibration matrix(intrinsic parameters)

Projection matrix

Camera model

Page 6: 3-D Euclidean Space - Vectors

6

CS682, Jana Kosecka

Calibration Matrix and Camera Model

Pinhole camera Pixel coordinates

Transformation between camera coordinateSystems and world coordinate system

More compactly

CS682, Jana Kosecka

Radial Distortion

Nonlinear transformation along the radial direction

Distortion correction: make lines straight

CS682, Jana Kosecka

Image of a point

Homogeneous coordinates of a 3-D point

Homogeneous coordinates of its 2-D image

Projection of a 3-D point to an image plane

CS682, Jana Kosecka

Image of a line – homogeneous representation

Homogeneous representation of a 3-D line

Homogeneous representation of its 2-D image

Projection of a 3-D line to an image plane

Page 7: 3-D Euclidean Space - Vectors

7

CS682, Jana Kosecka

Image of a line – 2D representations

Representation of a 3-D line

Projection of a line - line in the image plane

Special cases – parallel to the image plane, perpendicularWhen λ -> ∞ - vanishing points In art – 1-point perspective, 2-point perspective, 3-point perspective

CS682, Jana Kosecka

Visual Illusions

CS682, Jana Kosecka

Vanishing points

Different sets of parallel lines in a plane intersect at vanishing points, vanishing points form a horizon line

CS682, Jana Kosecka

Ames Room Illusions

Page 8: 3-D Euclidean Space - Vectors

8

CS682, Jana Kosecka

More Illusions

Which of the two monsters is bigger ?