Lecture 5
Lecture 5
(a) (b)
Zooming
(a) Replication of a single pixel vale
(b) Interpolation – considering neighboring values
Image Scaling
Scale matrices are
diagonal matrices
Image Rotation
An image can be rotated by a user specified angle about a
specified point.
+ve values -> clockwise rotation
-ve -> opposite
Rotation about the origin can be given as
REPEAT
1. Transform (x1,y1) to (x2,y2) using the rotation
transformation.
2. Obtain a grey-level value for (x2,y2) using Bi-linear
Interpolation.
3. Assign grey-level value of (x2,y2) to (x1,y1)
UNTIL All pixels are processed
(Note : (x1,y1) is in the output (corrected) image and (x2,y2) is in
the input (distorted) image)
Rotational matrices are
orthogonal
But wise versa ???
Image Reflection
Reflection produces a mirror image like image about an
axis of reflection.
Reflection about x-axis
x2= x1
y2= -y1
Reflection about an axis oriented in any arbitrary direction
, and passing through (x0,y0).
x2 = x1 + 2 * * (-sin ())
y2 = y1 + 2 * * (cos ())
Where = (x1-x2) * sin () – (y1-y0) * cos ().
Shearing
`
X-direction shear
Shearing
`
Y-direction shear
Shearing
Exercise:
Express shearing operations in matrix form.
If x-direction shearing is followed by a y-direction shearing
What is the combined (composite) transformation matrix?
• The most important applications of geometric
transformation is image registration
• It will align images taken in different modalities
• Useful in
– Medicine
– Entertainment
Basic Transformations.
• Translation.
• P’ = T +P
• Scale
• P’ = S. P
• Rotation
• P’ = R. P