Sie sind auf Seite 1von 30

Digital Image Processing

Lecture 7: Basic Transformations














Presented by:
Dr. Umer IJAZ








09 Sept 2014
Table of Contents
1. General Concepts
2. Translation
3. Scaling
4. Rotation
5. Concatenation
General Concepts
Basic Idea
In many imaging systems, the acquired images
are subject to geometric distortion.
Applying some basic transformation to a
uniformly distorted image can correct for a range
of perspective distortions by transforming the
measurements from the ideal coordinates to
those actually used.
For example, this is useful in satellite imaging
where geometrically correct ground maps are
desired.
2D Geometric Transforms
An affine transformation is an important class of
linear 2-D geometric transformations which maps
variables (e.g. pixel intensity values located at
position in an input image) into new variables
(e.g. in an output image) by applying a linear
combination of basic operations.
Two dimensional geometric transforms are used to
rotate, shear, translate or zoom ( scale) on whole
images or sometimes on parts of them.
Example of the basic 2D
transformation
Remarks
These operations are very common in
computer graphics.
Any linear operation can be written in matrix
form and using homogeneous coordinates.
We will consider the following basic
transformations in a 3D cartesian coordinate
system.
Translation
Translation
Suppose that the task is to translate a point
with coordinates (X,Y,Z) to a new location by
using displacements (X o ,Y o ,Z o ).
The translation is easily accomplished by using
the equations:
X * = X + X o
Y * = Y + Y o
Z * = Z + Z o

Translation
The three equations may be expressed in
matrix form by writing:

Translation
To be able to concatenate several
transformations, the use of square matrices
simplifies the notational representation of this
process. With this in mind, the above
equation can be written as follow:

Translation
This will create a unified matrix representation
of v * = Tv. Where T is a 4 x 4 transformation
matrix, v is the column vector containing the
original coordinates, and v * is a column
vector whose components are the
transformed coordinates. With this notation,
matrix T for translation is:

Example of Translation
Scaling
Scaling
The scale operator performs a geometric
transformation which can be used to shrink or
zoom the size of an image (or part of an
image).
Scaling
Image reduction and zooming are the two
image scaling operations.
Image reduction, commonly known
as subsampling, is performed by replacement
(of a group of pixel values by one arbitrarily
chosen pixel value from within this group) or
by interpolating between pixel values in a
local neighborhoods.
Scaling
Image zooming is achieved by pixel replication
or by interpolation
The subsampling, for example, can be
performed by :
(a) Replacement with upper left pixel.
(b) Interpolation using the mean value.

Scaling
Scaling
Scaling by factors Sx , Sy , and Sz along the X, Y,
and Z axes is given by the transformation
matrix


Example of Scaling
Rotation
Rotation
The transformations used for 3-D rotation are
inherently more complex.
The simplest form of these transformations is
for rotation of a point about the coordinate
axes.

Rotation
Rotation of a point about the Z coordinate axis
by an angle is achieved by using the
transformation:

Rotation
Rotation of a point about the X coordinate axis
by an angle a is performed by using the
transformation:

Rotation
Finally, rotation of a point about the Y axis by
an angel B is achieved by using the
transformation:

Example of Rotation
Concatenation
Concatenation
The application of several transformations can
be represented by a single 4 x 4
transformation matrix.
For example, translation, scaling, and rotation
about the Z axis of a point v is given by:


Where A is the 4 x 4 matrix A = ST.

Concatenation
Matrices after concatenation generally do not
commute, so the order of application is
important.
Thank you

Das könnte Ihnen auch gefallen