cse4030 introduction to computer graphics · 2011-12-28 · spaces • computer graphics is...
TRANSCRIPT
![Page 1: CSE4030 Introduction to Computer Graphics · 2011-12-28 · Spaces • Computer graphics is concerned with the representation and manipulation of sets of geometric elements, such](https://reader030.vdocuments.mx/reader030/viewer/2022040917/5e91bdd535bc45791149e5ed/html5/thumbnails/1.jpg)
Introduction to Computer Graphics
Dongguk University
Jeong-Mo Hong
CSE4030
![Page 2: CSE4030 Introduction to Computer Graphics · 2011-12-28 · Spaces • Computer graphics is concerned with the representation and manipulation of sets of geometric elements, such](https://reader030.vdocuments.mx/reader030/viewer/2022040917/5e91bdd535bc45791149e5ed/html5/thumbnails/2.jpg)
Week 3• Mathematics for Computer Graphics
– Scalar, vector, point, matrix, and space
– A review on 2D graphics
![Page 3: CSE4030 Introduction to Computer Graphics · 2011-12-28 · Spaces • Computer graphics is concerned with the representation and manipulation of sets of geometric elements, such](https://reader030.vdocuments.mx/reader030/viewer/2022040917/5e91bdd535bc45791149e5ed/html5/thumbnails/3.jpg)
Spaces• Computer graphics is concerned with the
representation and manipulation of sets of geometric elements, such as points and linesegments.
• The (linear) vector space contains only two types of objects: scalars, such as real numbers, and vectors.
• The affine space adds a third element: the point.
• Euclidean spaces add the concept of distance.
![Page 4: CSE4030 Introduction to Computer Graphics · 2011-12-28 · Spaces • Computer graphics is concerned with the representation and manipulation of sets of geometric elements, such](https://reader030.vdocuments.mx/reader030/viewer/2022040917/5e91bdd535bc45791149e5ed/html5/thumbnails/4.jpg)
Scalars
• Ordinary real numbers and the operations on them are one example of a scalar field.
![Page 5: CSE4030 Introduction to Computer Graphics · 2011-12-28 · Spaces • Computer graphics is concerned with the representation and manipulation of sets of geometric elements, such](https://reader030.vdocuments.mx/reader030/viewer/2022040917/5e91bdd535bc45791149e5ed/html5/thumbnails/5.jpg)
Vector Spaces
• Zero vectoru + 0 = u.
• Additive inverseu + (-u) = 0.
• Distributivityα(u + v) = αu + αv
(α + β)u = αu + βv
![Page 6: CSE4030 Introduction to Computer Graphics · 2011-12-28 · Spaces • Computer graphics is concerned with the representation and manipulation of sets of geometric elements, such](https://reader030.vdocuments.mx/reader030/viewer/2022040917/5e91bdd535bc45791149e5ed/html5/thumbnails/6.jpg)
Geometric Vectors
• Directed line segments
![Page 7: CSE4030 Introduction to Computer Graphics · 2011-12-28 · Spaces • Computer graphics is concerned with the representation and manipulation of sets of geometric elements, such](https://reader030.vdocuments.mx/reader030/viewer/2022040917/5e91bdd535bc45791149e5ed/html5/thumbnails/7.jpg)
Geometric Vectors
• Scalar-vector multiplication
![Page 8: CSE4030 Introduction to Computer Graphics · 2011-12-28 · Spaces • Computer graphics is concerned with the representation and manipulation of sets of geometric elements, such](https://reader030.vdocuments.mx/reader030/viewer/2022040917/5e91bdd535bc45791149e5ed/html5/thumbnails/8.jpg)
Geometric Vectors
• Head-to-tail axiom for vectors
![Page 9: CSE4030 Introduction to Computer Graphics · 2011-12-28 · Spaces • Computer graphics is concerned with the representation and manipulation of sets of geometric elements, such](https://reader030.vdocuments.mx/reader030/viewer/2022040917/5e91bdd535bc45791149e5ed/html5/thumbnails/9.jpg)
N-tuples of scalars
• A vector can be written as a set of scalars
v = (v1, v2, · · ·, vn)
• Vector-vector addition
u + v = (u1, u2, · · ·, un) + (v1, v2, · · ·, vn)
= (u1 + v1, u2 + v2, · · ·, un + vn)
• Scalar-vector multiplication
αv = (αv1, αv2, · · ·, αvn)
![Page 10: CSE4030 Introduction to Computer Graphics · 2011-12-28 · Spaces • Computer graphics is concerned with the representation and manipulation of sets of geometric elements, such](https://reader030.vdocuments.mx/reader030/viewer/2022040917/5e91bdd535bc45791149e5ed/html5/thumbnails/10.jpg)
Linear Combination
• A vector can be formed by a set of other vectors
– Linear independence
– Dimension
– Basis
– Representation
![Page 11: CSE4030 Introduction to Computer Graphics · 2011-12-28 · Spaces • Computer graphics is concerned with the representation and manipulation of sets of geometric elements, such](https://reader030.vdocuments.mx/reader030/viewer/2022040917/5e91bdd535bc45791149e5ed/html5/thumbnails/11.jpg)
Affine Spaces• A vector space lacks any geometric concepts such as
location and distance
• Coordinate system and origin
Identical vectorsCoordinate system. (a) Basis vectors located at the origin. (b) Arbitrary placement of basis vectors.
![Page 12: CSE4030 Introduction to Computer Graphics · 2011-12-28 · Spaces • Computer graphics is concerned with the representation and manipulation of sets of geometric elements, such](https://reader030.vdocuments.mx/reader030/viewer/2022040917/5e91bdd535bc45791149e5ed/html5/thumbnails/12.jpg)
Affine Geometry
• Points and point-point subtraction
• Frame
![Page 13: CSE4030 Introduction to Computer Graphics · 2011-12-28 · Spaces • Computer graphics is concerned with the representation and manipulation of sets of geometric elements, such](https://reader030.vdocuments.mx/reader030/viewer/2022040917/5e91bdd535bc45791149e5ed/html5/thumbnails/13.jpg)
Euclidean Spaces
• Euclidean space contains only vectors and scalars
• The inner (dot) product
u · v = v · u
(αu + βv) · w = αu · w + αv · w
v · v > 0, v ≠ 0
0 · 0 = 0
• The magnitude (length)of a vector
|v| =
• Orthogonality
u · v = 0
vv ⋅
![Page 14: CSE4030 Introduction to Computer Graphics · 2011-12-28 · Spaces • Computer graphics is concerned with the representation and manipulation of sets of geometric elements, such](https://reader030.vdocuments.mx/reader030/viewer/2022040917/5e91bdd535bc45791149e5ed/html5/thumbnails/14.jpg)
Projections
• The concept of projection arises from the problem of finding the shortest distance from a point to a line or plane.
Projection of one vector onto another.
![Page 15: CSE4030 Introduction to Computer Graphics · 2011-12-28 · Spaces • Computer graphics is concerned with the representation and manipulation of sets of geometric elements, such](https://reader030.vdocuments.mx/reader030/viewer/2022040917/5e91bdd535bc45791149e5ed/html5/thumbnails/15.jpg)
Break and Q&A
CSE4030
![Page 16: CSE4030 Introduction to Computer Graphics · 2011-12-28 · Spaces • Computer graphics is concerned with the representation and manipulation of sets of geometric elements, such](https://reader030.vdocuments.mx/reader030/viewer/2022040917/5e91bdd535bc45791149e5ed/html5/thumbnails/16.jpg)
Matrices
• In computer graphics, the major use of matrices is in the representation of changes in coordinate systems and frames.
• Definitions– Matrix
– Dimensions
– Square matrix
– Transpose
– Column matrix, row matrix
![Page 17: CSE4030 Introduction to Computer Graphics · 2011-12-28 · Spaces • Computer graphics is concerned with the representation and manipulation of sets of geometric elements, such](https://reader030.vdocuments.mx/reader030/viewer/2022040917/5e91bdd535bc45791149e5ed/html5/thumbnails/17.jpg)
Matrix Operations
• Scalar-matrix multiplication
αA = [ αaij ].
• Matrix-matrix addition
C = A + B = [ aij + bij ].
• Matrix-matrix multiplication
– Almost never commutative.
C = AB = [ cij ].
![Page 18: CSE4030 Introduction to Computer Graphics · 2011-12-28 · Spaces • Computer graphics is concerned with the representation and manipulation of sets of geometric elements, such](https://reader030.vdocuments.mx/reader030/viewer/2022040917/5e91bdd535bc45791149e5ed/html5/thumbnails/18.jpg)
Row and Column Matrices
• We can represent either a vector or a point in three-dimensional space, with respect to some frame, as the column matrix.
• One standard mode of representing transformations of points is to use a column matrix of two, three, or four dimensions to represent a point (or vector), and a square matrix to represent a transformation of the point (or vector).
• Concatenations
![Page 19: CSE4030 Introduction to Computer Graphics · 2011-12-28 · Spaces • Computer graphics is concerned with the representation and manipulation of sets of geometric elements, such](https://reader030.vdocuments.mx/reader030/viewer/2022040917/5e91bdd535bc45791149e5ed/html5/thumbnails/19.jpg)
Rank
• Inverse
• Nonsingular or singular
q = Ap, p = Bq
p = Bq = BAp = Ip = p
BA = I
• Number of linearly independent rows or columns
A 1−
![Page 20: CSE4030 Introduction to Computer Graphics · 2011-12-28 · Spaces • Computer graphics is concerned with the representation and manipulation of sets of geometric elements, such](https://reader030.vdocuments.mx/reader030/viewer/2022040917/5e91bdd535bc45791149e5ed/html5/thumbnails/20.jpg)
Change of Representation
• Matrix representation of the change between two bases
![Page 21: CSE4030 Introduction to Computer Graphics · 2011-12-28 · Spaces • Computer graphics is concerned with the representation and manipulation of sets of geometric elements, such](https://reader030.vdocuments.mx/reader030/viewer/2022040917/5e91bdd535bc45791149e5ed/html5/thumbnails/21.jpg)
Cross Product
• Given two nonparallel vectors in a three-dimensional space, the cross product gives a third vector that is orthogonal to both.
w = u x v =
−−−
1221
3113
232
βαβαβαβαβαβα 3
![Page 22: CSE4030 Introduction to Computer Graphics · 2011-12-28 · Spaces • Computer graphics is concerned with the representation and manipulation of sets of geometric elements, such](https://reader030.vdocuments.mx/reader030/viewer/2022040917/5e91bdd535bc45791149e5ed/html5/thumbnails/22.jpg)
Week 3• Mathematics for Computer Graphics
– Scalar, vector, point, matrix, and space
– A review on 2D graphics
![Page 23: CSE4030 Introduction to Computer Graphics · 2011-12-28 · Spaces • Computer graphics is concerned with the representation and manipulation of sets of geometric elements, such](https://reader030.vdocuments.mx/reader030/viewer/2022040917/5e91bdd535bc45791149e5ed/html5/thumbnails/23.jpg)
Reading Assignment
• Chapter 4.1~4.5
– Figures 4.13~16
– Figures 4.17~4.20
– Figure 4.23 (Why is it dangerous?)
– Figures 4.24 and 4.25
– Figure 4.26
– Figure 4.30
– Figure 4.31
![Page 24: CSE4030 Introduction to Computer Graphics · 2011-12-28 · Spaces • Computer graphics is concerned with the representation and manipulation of sets of geometric elements, such](https://reader030.vdocuments.mx/reader030/viewer/2022040917/5e91bdd535bc45791149e5ed/html5/thumbnails/24.jpg)
Quiz
CSE4030