As the name says, reduces the images to lines. The result on a natural image is not always pleasant. Try, on a flat bakground paint square contours . Sometimes you can enhance the results with the morphogenetic fuctions. Or by preparing the image by median or by a segmentation followed by segapla (whic dyes each region with the average color in this region). Beware, that takes time.
As one can see, results are unpredictabble with raster images (e.g. scanned from press).
contours case 2001 : Contours(refReg,10, 1); break; //f(61); as the name says, reduces the image to contours ; the result, on a natural image, is not always pleasing. You have a perfect example (over a monochrome backgound) with paint square
contours4 case 2002 : Contours(refReg,20,0); f(61); break; //contours4
contours... case 2003 : Contours(refReg,40,2); f(61); break;
contours3 case 2006 : Contours(refReg, 10, 3); break; //contours3
Sometimes you can get a better result with morphogeometric operations (si below), notably x . Or else prepare the operation with some simplification, for instance median (see below ) or a segmentation followed by segapla (which colors each region in the average color of this region in the original image; beware, this operation takes a lot of time).
Ways to simplify an image prior to segmentation,
automatically as a precondition, with difg
You can thicken the contours with ee, ww, et X Z, and thin ghem with X2 or Z2
The contours are generated as black over white. But you can change the black into another color with bllacktocol
A classical form of technique in image processing.