shear & perspective
DESCRIPTION
Shear & Perspective. CS5600 Computer Graphics Rich Riesenfeld Spring 2006 (Sp2014 edits by T. J. Peters). Lecture Set 7. 3D Shear in x -direction. 3D Shear in x -direction. 3D Shears : Clamp a Principal Plane , shear in other 2 DoFs. Shear in x . . then , y :. - PowerPoint PPT PresentationTRANSCRIPT
Shear & Perspective
CS5600 Computer Graphics
Rich RiesenfeldSpring 2006(Sp2014 edits by T. J. Peters)
Lect
ure
Set
7
Spring 2006 Utah School of Computing 2
3D Shear in x -direction
111000
0100
0010
001
)(z
y
ayx
z
y
xa
aShx
Spring 2006 Utah School of Computing 3
3D Shear in x -direction
111000
0100
0010
001
)(z
y
bzx
z
y
xb
bShx
Spring 2006 Utah School of Computing 4
3D Shears: Clamp a Principal Plane, shear in other 2 DoFs
x
z
y
Spring 2006 Utah School of Computing 5
Shear in x . . then,
y :
)1,0(
)0,0(
)1,0(
)0,0(
)1,0(
)0,0()0,1(
)1,0(
)0,0(
)1,1( b
)1,1(
),1( b
12
32
11 0 1
1
12
1 10 1
)0,1(
)1,1(
312 2
( , )
3 52 2
( , )
12
( ,1) 32
( ,1)
x
z
y
111000
0100
0010
001
)(z
y
ayx
z
y
xa
aShx
x
z
y
Spring 2006 Utah School of Computing 7
3D Shear in y -direction
111000
0100
010
0001
)(z
czy
x
z
y
x
ccShy
Spring 2006 Utah School of Computing 8
3D Shear in y -direction
111000
0100
001
0001
)(z
ydx
x
z
y
x
ddShy
x
z
y
x
z
y
111000
0100
001
0001
)(z
ydx
x
z
y
x
ddShy
Spring 2006 Utah School of Computing 10
3D Shear in z-direction
111000
010
0010
0001
)(zex
y
x
z
y
x
eeShz
Spring 2006 Utah School of Computing 11
3D Shear in z
111000
010
0010
0001
)(zex
y
x
z
y
x
eeShz
Spring 2006 Utah School of Computing 12
3D Shear in z
111000
010
0010
0001
)(zfy
y
x
z
y
x
ffShz
Spring 2006 Utah School of Computing 13
Shear Inverse
1
1
1
1
0
0
1
01
1
01
0
0
10
1
10
1
bb
aa
Spring 2006 Utah School of Computing 14
Shear Inverse
1
01
1
01
10
1
10
1
1
1
bb
aa
Spring 2006 Utah School of Computing 15
Double Shear in x and y
ab)(10
1
1
01
1
1
b
aa
b
1
1 ab)(
1
01
10
1
b
a
b
a
( )aShx( )bSh y
( )aShx ( )bSh y
Spring 2006 Utah School of Computing 16
Ex: a = 0.5 and b =1.0
1
1
1 0 1
1 0 1 ( ab)
a a
b b
1
1 ab)(
1
01
10
1
b
a
b
a
( )aShx( )bSh y
( )aShx ( )bSh y
Spring 2006 Utah School of Computing 17
Shear in x . . then,
y :
)1,0(
)0,0(
)1,0(
)0,0(
)1,0(
)0,0()0,1(
)1,0(
)0,0(
)1,1( b
)1,1(
),1( b
12
32
11 0 1
1
12
1 10 1
)0,1(
)1,1(
312 2
( , )
3 52 2
( , )
12
( ,1) 32
( ,1)
Spring 2006 Utah School of Computing 18
)1,0(
)0,0(
)1,0(
)0,0(
)1,0(
)0,0()0,1( )0,1(
)1,0(
)0,0(
(1, 2)
)1,1(
)0,1(
)1,1(
12
( ,1) 32
( ,1)
32
( ,1)
12
( ,1)
(2, 2)
Shear in x . then, y :
12
32
11 0 1
1
12
1 10 1
Spring 2006 Utah School of Computing 19
Shears in x and y do not Commute
)1,0(
)0,0(
1( , )a
Sh in x (a=½) , then Sh y(b=1)
Sh in y (b=1) , then
Sh in x (a=½)
Spring 2006 Utah School of Computing 20
Shear in x then in y)1,0(
)0,0(
)1,0(
)0,0(
)1,0(
)0,0()0,1( )0,1(
),(1 bab
),( 1a
),( 1 aba
),( 11 baba
),( 11 a
)1,0(
)0,0(
)1,1( b
)1,1(
),1( b
Spring 2006 Utah School of Computing 21
Shear in y then in x)1,0(
)0,0(
)1,0(
)0,0(
)1,0(
)0,0()0,1( )0,1(
),(1 b
),( 1a
),( 1 aba
),( 11 abba
),( 11 a
)1,0(
)0,0(
)1,1( b
)1,1(
)0,1(
),1( b
Spring 2006 Utah School of Computing 22
Results Are Different
y then x: x then y:
Spring 2006 Utah School of Computing 23
What is “Perspective?”
• A mechanism for portraying 3D in 2D
• “True Perspective” corresponds to
projection onto a plane
• “True Perspective” corresponds to an
ideal camera image
Spring 2006 Utah School of Computing 24
“True” Perspective in 2Dy
x
(x,y)
p
h
Spring 2006 Utah School of Computing 25
“True” Perspective in 2D
pxpyh
pxy
ph
Spring 2006 Utah School of Computing 26
“True” Perspective in 2Dy
x
(x,y)
p
h
Spring 2006 Utah School of Computing 27
“True” Perspective in 2D
pxpyh
pxy
ph
Spring 2006 Utah School of Computing 28
“True” Perspective in 2D
1
1
1
1 0 0
0 1 0
0 1 1 xp p
pyx p
pxx p
x pp
px
x p
py
x p
x x
y y
x
y
Spring 2006 Utah School of Computing 29
Geometry Same for Eye at Originy
x
(x,y)
p
h
Screen Plane
Spring 2006 Utah School of Computing 30
Values below 0?y
x
(x,y)
p
h
Spring 2006 Utah School of Computing 31
“True” Perspective in 2Dy
p
Spring 2006 Utah School of Computing 32
“True” Perspective in 2Dy
p
p
p
p
p
p
p
p
Spring 2006 Utah School of Computing 33
“True” Perspective in 2Dy
p
Spring 2006 Utah School of Computing 34
Viewing Frustum
Spring 2006 Utah School of Computing 35
What happens for large p?”
1 0 0
0 1 0
0 1
1
1
1 0 0
0 1 0
1 0 1 1
lim 0
0p
p
x x
y y
p
Spring 2006 Utah School of Computing 36
Projection Becomes Orthogonal: “Right Thing Happens”
x
(x,y)
h=y
p
The End
(Modified) Transformations II
Lect
ure
Set
7x