How to travel edge / contour points consecutively?

1 view (last 30 days)
Dear all,
I have a binary image containing several lines. Now I want to get the coordinates of the pixels on each line from one end to the other end consecutively, says, current point and next point are 8-connected. How do I get this order?
I have tried bwconncomp, but it orders points by x coordinate, that's not what I want.
Can anyone help? Thanks very much!

Answers (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!