Remove separated objects in an Image C# -
your appreciated. using c# , emgucv image processing
i have tried noise removal, nothing happens. tried image median filter, , works on first image, not work on second image. makes second image blurry , objects larger , more square-like.
i want remove distinct objects(green ones) in image below turn black because separated , not grouped unlike second image below.
image 1:
at same way, want in image below, remove objects -- (the black ones) -- not grouped/(lumped?) remains on image objects grouped/larger in scale?
image 2:
thank you
you may try gaussian blur , apply threshold image.
gaussian blur used effect in graphics software, typically reduce image noise , reduce detail, think matches requirements well.
for 1st image:
cvinvoke.gaussianblur(srcimg, destimg, new size(0, 0), 5);//you may need customize size , sigma depends on different input image.
you get:
then
cvinvoke.threshold(srcimg, destimg, 10, 255, emgu.cv.cvenum.thresholdtype.binary);
you get:
for 2nd image:
cvinvoke.gaussianblur(srcimg, destimg, new size(0, 0), 5);//you may need customize size , sigma depends on different input image.
you get:
then
cvinvoke.threshold(srcimg, destimg, 240, 255, emgu.cv.cvenum.thresholdtype.binary);
you get:
hope help!
Comments
Post a Comment