Professional Documents
Culture Documents
Computer Graphics Unit 4
Computer Graphics Unit 4
Computer Graphics Unit 4
UNIT IV
TOPICS COVERED:
Geometric Transformations
Geometric transformations refer to operations that modify the position, size, orientation, or shape of
geometric objects, such as points, lines, curves, or polygons. These transformations preserve certain
properties of the original objects, allowing us to apply familiar reasoning and analysis techniques to
transformed counterparts. We will consider 5 main types of geometric transformations: translations,
rotations, scaling, shearing, and reflections.
1. Translation: A translation moves each point of an object by a fixed distance in a specified direction
parallel to some axis, preserving relative positions between points and overall shape. Mathematically,
it can be represented as a vector addition operation applied to each coordinate component.
2. Rotation: A rotation pivots an object around a given center point through a specific angle measured
in radians or degrees, maintaining distances between points and changing orientations accordingly.
Two primary axes – x-axis and y-axis – are commonly considered, giving rise to rotations about those
respective axes.
3. Scaling: Scaling alters the size of an object by expanding or contracting it along one or more axes
proportionately, keeping shapes intact and preserving parallelism among corresponding lines.
Uniform scaling scales equally along all directions, while non-uniform scaling varies stretching rates
according to chosen axes.
4. Shearing: Also known as skewing, shearing slants an object along one or more axes, distorting
shapes while retaining collinearity between initial and final configurations. Horizontal and vertical
shears are frequently studied, producing rectangular hyperbolas under certain conditions.
TS
BCA414: COMPUTER GRAPHICS 2
UNIT IV
5. Reflection: A reflection flips an object about a designated mirror line or plane, preserving distances
between symmetric points and altering orientations accordingly. Common examples include
horizontal (left-right), vertical (top-bottom), and diagonal (corner-opposite corner) reflections, which
flip objects horizontally, vertically, or diagonally, respectively. Arbitrary oblique reflections also exist,
reflecting objects across user-specified planes.
Translation
TS
BCA414: COMPUTER GRAPHICS 3
UNIT IV
TS
BCA414: COMPUTER GRAPHICS 4
UNIT IV
TS
BCA414: COMPUTER GRAPHICS 5
UNIT IV
TS
BCA414: COMPUTER GRAPHICS 6
UNIT IV
TS
BCA414: COMPUTER GRAPHICS 7
UNIT IV
TS
BCA414: COMPUTER GRAPHICS 8
UNIT IV
TS
BCA414: COMPUTER GRAPHICS 9
UNIT IV
TS
BCA414: COMPUTER GRAPHICS 10
UNIT IV
TS
BCA414: COMPUTER GRAPHICS 11
UNIT IV
TS
BCA414: COMPUTER GRAPHICS 12
UNIT IV
TS
BCA414: COMPUTER GRAPHICS 13
UNIT IV
The rotation of a point, straight line or an entire image on the screen, about a point
other than origin, is achieved by first moving the image until the point of rotation
occupies the origin, then performing rotation, then finally moving the image to its
original position.
The moving of an image from one place to another in a straight line is called a
translation. A translation may be done by adding or subtracting to each point, the
amount, by which picture is required to be shifted.
TS
BCA414: COMPUTER GRAPHICS 14
UNIT IV
TS
BCA414: COMPUTER GRAPHICS 15
UNIT IV
If we want to rotate an object or point about an arbitrary point, first of all, we translate
the point about which we want to rotate to the origin. Then rotate point or object
about the origin, and at the end, we again translate it to the original place. We get
rotation about an arbitrary point.
TS
BCA414: COMPUTER GRAPHICS 16
UNIT IV
Example1: Prove that 2D rotations about the origin are commutative i.e. R1 R2=R2 R1.
TS
BCA414: COMPUTER GRAPHICS 17
UNIT IV
Example2: Rotate a line CD whose endpoints are (3, 4) and (12, 15) about origin
through a 45° anticlockwise direction.
TS
BCA414: COMPUTER GRAPHICS 18
UNIT IV
TS
BCA414: COMPUTER GRAPHICS 19
UNIT IV
TS
BCA414: COMPUTER GRAPHICS 20
UNIT IV
TS
BCA414: COMPUTER GRAPHICS 21
UNIT IV
TS
BCA414: COMPUTER GRAPHICS 22
UNIT IV
Inverse Transformation
These are also called as opposite transformations. If T is a translation matrix than inverse
translation is representing using T-1. The inverse matrix is achieved using the opposite sign.
Questions
1.
2.
TS