1. A method for segmenting an object within an image comprising: extracting an edge image containing a first set of pixels from the image; generating a second set of pixels from the first set of pixels using mathematical morphology; and identifying a segment corresponding to the object.