Chap 11
Chap 11
We assume
i) we work with binary images with object and background
represented as 1 & 0 respectively.
ii) Images are padded with borders of 0s to eliminate the
possibility of object merging with image border.
Representation
1) Let the starting point b0 be the uppermost, leftmost point in
the image. c0 the west neighbor of b0. Examine 8 neighbors
of b0 starting at c0 & proceed in clockwise direction.
1 1 1 1
1 1
1 1
1 1
1 1 1 1
c0 b0 1 1 1 b 1 1
1 1 1 1
1 1 1 1
1 1 1 1
1 1 1 1 1 1 1 1
Representation
2) Let b = b1 & c = c1
3) Let the 8-neighbors of b, starting at c & proceeding in
clockwise directions be denoted by n1, n2, …..n8. Find first nk
labeled 1.
4) Let b = nk & c = nk-1
b 1 b 1 b 1 1
0
1 1 1 1
1 1 1 1
1 1 1 1
1 1 1 1 1 1 1 1
Representation
5) Repeat step 3 & 4 until b = b0 & next boundary point found is
b1. The sequence of b points found when the algorithm stops
constitutes the set of ordered boundary points.
1 c0 b0 c
1 1 1 1 1 b
1 1 1
1 1 1 1 1 1
1 1 1 1 1 1 1 1 1
Representation
2) Chain codes:
They are used to represent a boundary by a connected sequence
of straight line segments of specified length & direction.
2 0 4 0
3 5 6 7
•
Representation
A boundary code formed as a sequence of such directional
numbers is referred to as a Freeman chain code.
Thinning algorithm:
Region points are assumed to have value 1 & background points
are assumed to have value 0.
Representation
p8 p1 p4
p7 p6 p5
Step 1 flags a con tour point for deletion if the following
conditions are satisfied:
a) 2 ≤ N(p1) ≤ 6
b) T(p1) = 1
c) p2.p4.p6 = 0
d) p4.p6.p8 = 0
p2 + p3 + …… + p8 + p9
where pi is either 0 or 1.
0 0 1
1 p1 0
1 0 1
After step 1 been applied to all border points, those who are
flagged are deleted (changed to 0).
Diameter:
Diameter of a boundary is defined as :
Diam(B) = max [D(pi,pj)]
Where, D – is distance measure &
pi, pj – are points on the boundary
It is the distance between any two
border points on region.
Descript
ors
Major axis: The largest diameter is the major axis
Basic rectangle: The box consisting of major and minor axes with
points intersecting the border forms a basic rectangle.