Re: Edge detection algorithm
Try scanning all 8 pixels in the vicinity of the current pixel and if you
find that two adjacent pixels are of different colours (i.e. B&W) then you
know that you have found the next edge step you should be looking at.
"Peter Lundh" <firstname.lastname@example.org> wrote in message
> I have a bitmap image of a white (spherical) shape on a black
> background. I would like to create a loop that would find a random
> edge, or contour pixel of the shape, perform a computation and then
> move on to the next edge pixel in a clockwise fashion. 1) How should I
> find the first edge pixel. 2) How should I design the loop so that it
> moves on to the next edge pixel until it reaches the first pixel?
> Many thanks in advance.