Geometric Image TransformationsAlgebraic Groups● Euclidean● Affine● Projective● Bovine● Lecture 7 Slide 1 6.837 Fall '00Lecture 7 --- 6.837 Fall '00http://graphics.lcs.mit.edu/classes/6.837/F00/Lecture07/Slide01.html [10/3/2000 1:10:48 PM]Two-Dimensional Geometric TransformsGeometric transforms are functions that map points from one place to anotherGeometric transformscan be applyed todrawing primitives(lines, conics, triangles)● pixel coordinates of an image (or sprites)● We'll begin with simple transforms and generalize them.Lecture 7 Slide 2 6.837 Fall '00Lecture 7 --- 6.837 Fall '00http://graphics.lcs.mit.edu/classes/6.837/F00/Lecture07/Slide02.html [10/3/2000 1:10:54 PM]TranslationsTranslations are a simple family of two-dimensional transforms. Translations were at theheart of our Sprite implementations in Project #1.Translations have the following formx' = x + txy' = y + tyFor every translation there exists an inverse function which undoes the translation. In ourcase the inverse looks like:x = x' - txy = y' - tyThere also exists a special translation, called the identity, that leaves every point unchanged.x' = x + 0y' = y + 0Lecture 7 Slide 3 6.837 Fall '00Lecture 7 --- 6.837 Fall '00http://graphics.lcs.mit.edu/classes/6.837/F00/Lecture07/Slide03.html [10/3/2000 1:10:55 PM]Groups and CompositionFor Translations:There exists an inverse mapping for each function1. There exists an identity mapping2. These properties might seem trivial at first glance, but they are actually veryimportant, because when these conditions are shown for any class offunctions it can be proven that such a class is closed under composition (i.e.any series of translations can be composed to a single translation). Inmathematical parlance this the same as saying that translations form analgebraic group.Lecture 7 Slide 4 6.837 Fall '00Lecture 7 --- 6.837 Fall '00http://graphics.lcs.mit.edu/classes/6.837/F00/Lecture07/Slide04.html [10/3/2000 1:10:56 PM]RotationsAnother group of 2-transforms are the rotations about the origin.Lecture 7 Slide 5 6.837 Fall '00Lecture 7 --- 6.837 Fall '00http://graphics.lcs.mit.edu/classes/6.837/F00/Lecture07/Slide05.html [10/3/2000 1:10:58 PM]Euclidean TransformsThe union of translations and rotation functions defines the Euclidean SetProperties of Euclidean Transformations:They preserve distances● They preserve angles● How do you represent these functions?Lecture 7 Slide 6 6.837 Fall '00Lecture 7 --- 6.837 Fall '00http://graphics.lcs.mit.edu/classes/6.837/F00/Lecture07/Slide06.html [10/3/2000 1:10:59 PM]Problems with this FormMust consider Translation and Rotation separately● Computing the inverse transform involves multiple steps● Order matters between the R and T partsThese problem can be remedied by considering our 2 dimensional image plane as a 2Dsubspace within 3D.● Lecture 7 Slide 7 6.837 Fall '00Lecture 7 --- 6.837 Fall '00http://graphics.lcs.mit.edu/classes/6.837/F00/Lecture07/Slide07.html [10/3/2000 1:11:01 PM]Choose a SubspaceWe can use any planar subspace as long as it does not contain the originWLOG assume the our 2D space of points lies on the 3D plane z = 1Now we can express all Euclidean Transforms in matrix form:This gives us a three parameter group of Transformations.Lecture 7 Slide 8 6.837 Fall '00Lecture 7 --- 6.837 Fall '00http://graphics.lcs.mit.edu/classes/6.837/F00/Lecture07/Slide08.html [10/3/2000 1:11:03 PM]Playing with Euclidean TransformsIn what order are the translation and rotation performed?● Will this family of transforms always generate points on our choosen3-D plane?Why?● Lecture 7 Slide 9 6.837 Fall '00Lecture 7 --- 6.837 Fall '00http://graphics.lcs.mit.edu/classes/6.837/F00/Lecture07/Slide09.html [10/3/2000 1:11:04 PM]Similitude TransformsWe can define a 4-parameter superset of Euclidean Transforms with additional capabilitiesProperties of Similtudes:Distance between any 2 pointsare changed by a fixed ratio● Angles are preserved● Maintains "similar" shape(similar triangles, circles map to circles, etc)● Lecture 7 Slide 10 6.837 Fall '00Lecture 7 --- 6.837 Fall '00http://graphics.lcs.mit.edu/classes/6.837/F00/Lecture07/Slide10.html [10/3/2000 1:11:06 PM]Playing with Similitude TransformsAdds reflections● Scales in x and y must be the same. Why?● Order?● Will this family of transforms always generate points on our choosen3-D plane?Why?● Lecture 7 Slide 11 6.837 Fall '00Lecture 7 --- 6.837 Fall '00http://graphics.lcs.mit.edu/classes/6.837/F00/Lecture07/Slide11.html [10/3/2000 1:11:07 PM]Affine TransformationsA 6-parameter group of transformsLecture 7 Slide 12 6.837 Fall '00Lecture 7 --- 6.837 Fall '00http://graphics.lcs.mit.edu/classes/6.837/F00/Lecture07/Slide12.html [10/3/2000 1:11:08 PM]Affine PropertiesTo the right is a simple illustration of how wecan map our parameters into a four arbitrarynumbersProperties of Affine Transforms:They perserve our selected plane(sometimes called the Affine plane)● They preserve parallel lines● Lecture 7 Slide 13 6.837 Fall '00Lecture 7 --- 6.837 Fall '00http://graphics.lcs.mit.edu/classes/6.837/F00/Lecture07/Slide13.html [10/3/2000 1:11:10 PM]Playing with Affine Transformsσx scales the x-dimension● σy scales the y-dimension● σxy is often called the skew parameter● Lecture 7 Slide 14 6.837 Fall '00Lecture 7 --- 6.837 Fall '00http://graphics.lcs.mit.edu/classes/6.837/F00/Lecture07/Slide14.html [10/3/2000 1:11:11 PM]Determining Affine TransformsThe coordinates of three corresponding points uniquely determine and Affine TransformIf we know where we would like at least three points to map to, we can solve for an Affinetransform that will give this mapping.Lecture 7 Slide 15 6.837 Fall '00Lecture 7 --- 6.837 Fall '00http://graphics.lcs.mit.edu/classes/6.837/F00/Lecture07/Slide15.html [10/3/2000 1:11:12 PM]Solution MethodWe've used this technique severaltimes now. We set up 6 linearequations in terms of our 6unknown values. In this case, weknow the coordinates before andafter the mapping, and we wish tosolve for the entries in our Affinetransform matrix.This gives the following solution:Lecture 7 Slide 16 6.837 Fall '00Lecture 7 --- 6.837 Fall '00http://graphics.lcs.mit.edu/classes/6.837/F00/Lecture07/Slide16.html [10/3/2000 1:11:14 PM]Projective TransformationsThe most general linear transformation that we can apply to 2-D pointsThere is something
View Full Document