Image Processing
Image Processing
Chapter 11:
chain code
Gonzalez and Richard E.
Object Boundary
boundary vertices
(resampling)
4-directional 8-directional
chain code chain code
Partitioned boundary
Object boundary
Step 1. Mark pixels for deletion if the following conditions are true.
a) 2 N ( p1 ) 6
(Apply to all border pixels) p9 p2 p3
b) T(p1) =1
p p p 0 p8 p1 p4
c) 2 4 6
p7 p6 p5
d) p4 p6 p8 0
Step 2. Delete marked pixels and go to Step 3.
Step 3. Mark pixels for deletion if the following conditions are true.
a) 2 N ( p1 ) 6
(Apply to all border pixels)
b) T(p1) =1
c) p2 p4 p8 0
d) p2 p6 p8 0
Step 4. Delete marked pixels and repeat Step 1 until no change
occurs.
Example: Skeletons Obtained from the Thinning Alg.
Skeleton
2. Shape number
3. Fourier descriptor
4. Statistical moments
Shape Number
Shape number of the boundary definition: 1
the first difference of smallest magnitude
The order n of the shape number: 2 0
the number of digits in the sequence
3
Chain code:
000030032232221211
First difference:
300031033013003130