Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the...

43
Visual Imaging in the Electronic Age Perspective Transformations Lecture # 3 August 30, 2016 Prof. Donald P. Greenberg

Transcript of Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the...

Page 1: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

Visual Imaging in the

Electronic Age

Perspective Transformations

Lecture # 3

August 30, 2016

Prof. Donald P. Greenberg

Page 2: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

• We have seen how a pinhole camera

(or camera obscura) works

• We have also seen Brunelleschi’s

experiment with his perspective panels

• Both are obviously two dimensional

and exist on a planar (flat) surface

Page 3: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

Perspective Depth

• We now know how to mathematically (and

geometrically) construct the perspective image.

(e.g., xs, ys)

• But how do we find the third dimension (zs)?

Page 4: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo
Page 5: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

How a Camera Lens Works

• Rays which pass through the focal point are bent

to leave the lens perpendicular to its principal

axis.

Page 6: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

® Donald P. Greenberg - Cornell Program of Computer Graphics

Page 7: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

® Donald P. Greenberg - Cornell Program of Computer Graphics

Page 8: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

Railroad Tracks in Perspective

elevation

Page 9: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

How a Camera Lens Works

• Rays which pass through the focal point are bent

to leave the lens perpendicular to its principal

axis.

• Rays which are perpendicular to the principal

axis of the lens are bent through the focal point.

Page 10: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

How a Camera Lens Works

f

P(xe, ye, ze)

P(xp, yp, zp)

-zp - 2f

Ze

Xe

Ye

A

A

B

B

f

-yp

Page 11: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

e

ep

e

ep

z

x

f

x

z

y

f

y

,Using triangles A and A':

fz

y

f

y

p

pe

2

Using triangles B and B':

e

ep

e

ep

z

yfy

z

xfx ,

How a Camera Lens Works

Page 12: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

f

fz

y

y

z

f

y

y p

e

p

ee

p 2 ,

We know that:

e

p

e

p

z

ffz

z

f

f

fz 2

2 ,2

e

pz

ffz

2

2

How a Camera Lens Works

Page 13: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

How a Camera Lens Works

Page 14: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

Camera

Film

Plane

Page 15: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

Camera

Film

Plane

Page 16: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo
Page 17: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

® Donald P. Greenberg - Cornell Program of Computer Graphics

http://upload.wikimedia.org/wikipedia/en/5/5f/DoF-sym.png

Page 18: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

Perspective Projections in

Computer Graphics

Eye coordinate systemPlan or elevation view

Page 19: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

Object Space

(One point

perspective)

Page 20: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

Image Space

(One point

perspective)

Page 21: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

Object Space

(Two point

perspective)

Page 22: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

Image Space

(Two point

perspective)

Page 23: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

Object Space

(Three point

perspective)

Page 24: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

Image Space

(Three point

perspective)

Page 25: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

3D Perspective Image

(x & y coordinates in virtual image

space)

e

e

pz

xfx

e

e

pz

yfy

e

e

pz

xx constant

e

e

pz

yy constant

Page 26: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

e

pz

ffz

2

2

e

pz

z1

21constantconstant

3D Perspective Image

(z depth coordinate in virtual image

space)

Page 27: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

Equivalent Distorted Geometries

in Virtual Image Space

Page 28: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

® Donald P. Greenberg - Cornell Program of Computer Graphics

Mapping a Viewing Frustum

to a Standard Viewbox

11

ze = DXe

Frustum of vision Screen coordinate system

Ze

Ye

ze = F

Xs

Ys Zs

1

Page 29: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

Viewing Frustum - User Parameters

Location and Orientation (vectors):

Eye location of eye point

At a point along view direction vector

Up a vector defining the Y axis on the hither plane

Shape (scalars):

fov field of view angle

aspect view plane aspect ratio

hither perpendicular distance to hither plane

yon perpendicular distance to yon plane

At

Up

Eye

aspect =

width / height

hitheryon

fov

Page 30: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

Uses of Perspective in Enlarging

Architectural Space (3D)

Page 31: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

Palazzo Spada

Borromini

Page 32: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

Imss,Firenze 2004 - 3 Scenografia prospettica

Page 33: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

Imss,Firenze 2004 - 3 Scenografia prospettica

Page 34: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

Imss,Firenze 2004 - 3 Scenografia prospettica

Page 35: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

Imss,Firenze 2004 - 3 Scenografia prospettica

Page 36: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

Imss,Firenze 2004 - 3 Scenografia prospettica

Page 37: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

Imss,Firenze 2004 - 3 Scenografia prospettica

Page 38: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

Imss,Firenze 2004 - 3 Scenografia prospettica

Page 39: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

Borromini

Palazzo Spada

Page 40: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

Borromini

Palazzo Spada

Page 41: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

Video - Palazzo Spada Video(spada.wmv)

Page 42: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

® Donald P. Greenberg - Cornell Program of Computer Graphics

Probe Demo

Page 43: Visual Imaging in the Electronic Age - Cornell Program of ... · PDF fileVisual Imaging in the Electronic Age Perspective Transformations ... f x z y f y , Using ... Borromini Palazzo

® Donald P. Greenberg - Cornell Program of Computer Graphics

End. . .