[Insight-users] how to extract boundarys from binary image?

Yu Long yulong202 at 263.net
Sat Jul 10 20:31:39 EDT 2004


Hi, Luis Ibanez,
    Thanks for your help. 
    Finding that there is no solution for extracting contours in itk,I have already turned to  use an VTK filter(vtkLinkEdgels). After testing the example "canny.tcl" in VTK, I found it can fulfill my job. I am now rewriting the canny.tcl in C++ and I will combine the VTK code with my itk code. This methods is not elegant, since It is rather complicated by involving VTK and the codes do much extra works unneeded. I just take this as an opportunity to learn VTK. 
  
regards

YU Long
----- Original Message ----- 
From: "Luis Ibanez" <luis.ibanez at kitware.com>
To: "Yu Long" <yulong202 at 263.net>
Cc: "salah" <salah at gris.uni-tuebingen.de>; <insight-users at itk.org>
Sent: Sunday, July 11, 2004 5:27 AM
Subject: Re: [Insight-users] how to extract boundarys from binary image?


> 
> Hi Yu,
> 
> There are currently no filters in ITK for extracting
> contours from images, at least not countour represented
> as a sequence of points or as a path.
> 
> It is relatively simply to implement such a filter by
> writing a state machine with 8 inputs. The output of the
> state machine is usually a chain code. You can use the
> class
> 
> http://www.itk.org/Insight/Doxygen/html/classitk_1_1ChainCodePath.html
> 
> in order to store / represent the resulting contour.
> 
> Please let us know if you need help implementing such algorithm,
> we will be happy to assist you in doing so, and of course will
> encourage you to contribute the filter back to ITK.
> 
> 
> Regards,
> 
> 
>    Luis
> 
> 
> ----------------
> Yu Long wrote:
> 
> >     Thanks for your reply.I will try your method.I still have two questions.
> >   1 Can your method produce */one/* */pixel width/* boundary?
> >   2 Is there any filter used to trace the boundary pixels one by one? So 
> > that I can convert the boundary pixels to contour points.
> >  
> > 
> >     ----- Original Message -----
> >     *From:* salah <mailto:salah at gris.uni-tuebingen.de>
> >     *To:* Yu Long <mailto:yulong202 at 263.net>
> >     *Sent:* Thursday, July 08, 2004 5:37 PM
> >     *Subject:* AW: [Insight-users] how to extract boundarys from binary
> >     image?
> > 
> >     If you want to produce a binary image containing on the boundary, I
> >     would suggest:
> >     1- let your binary image be   "A"
> >     2- erode the image "A" by itk erosion filter, name the result "B"
> >      
> >     The boundary image is A - B
> >      
> >     best wishes,
> >     Zein
> >      
> >      
> > 
> >         -----Ursprüngliche Nachricht-----
> >         *Von:* Yu Long [mailto:yulong202 at 263.net]
> >         *Gesendet:* Thursday, July 08, 2004 11:33 AM
> >         *An:* insight-users at itk.org
> >         *Betreff:* [Insight-users] how to extract boundarys from binary
> >         image?
> > 
> > 
> >             I have now written a program to convert a RGB image into a
> >         binary image using itk. A sample binary image is attached with
> >         this email.
> >             My question is how to extract the boundary from the binary
> >         image with itk? Is there any filter or algorithm than can
> >         extract boundarys from binary image in itk?
> >          
> >          
> >          
> >          
> >         HuaZhong Univ. of Sci. & Tech, China
> >         email: yulong202 at 263.net <mailto:yulong202 at 263.net>
> > 
> > 
> > ------------------------------------------------------------------------
> > 
> > _______________________________________________
> > Insight-users mailing list
> > Insight-users at itk.org
> > http://www.itk.org/mailman/listinfo/insight-users
> 
> 
> 
> _______________________________________________
> Insight-users mailing list
> Insight-users at itk.org
> http://www.itk.org/mailman/listinfo/insight-users
> 
> 


More information about the Insight-users mailing list