Path: news.mathworks.com!newsfeed-00.mathworks.com!newsfeed2.dallas1.level3.net!news.level3.com!postnews.google.com!x37g2000yqj.googlegroups.com!not-for-mail
From: ImageAnalyst <imageanalyst@mailinator.com>
Newsgroups: comp.soft-sys.matlab
Subject: Re: outer perimeter binary blobs - vectorisation
Date: Tue, 8 Sep 2009 07:03:53 -0700 (PDT)
Organization: http://groups.google.com
Lines: 10
Message-ID: <58f50640-4469-4369-bb09-7dc1cc95b731@x37g2000yqj.googlegroups.com>
References: <3bab9014-5398-4dd4-b6a1-8c4b49e19dac@f33g2000vbm.googlegroups.com> 
	<eb8c9bee-de8e-4a02-affa-8ea268984649@p23g2000vbl.googlegroups.com>
NNTP-Posting-Host: 192.44.136.113
Mime-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1
X-Trace: posting.google.com 1252418633 8302 127.0.0.1 (8 Sep 2009 14:03:53 GMT)
X-Complaints-To: groups-abuse@google.com
NNTP-Posting-Date: Tue, 8 Sep 2009 14:03:53 +0000 (UTC)
Complaints-To: groups-abuse@google.com
Injection-Info: x37g2000yqj.googlegroups.com; posting-host=192.44.136.113; 
	posting-account=0rLUzAkAAABojYSRC64DkTbtiSCX77HH
User-Agent: G2/1.0
X-HTTP-Via: 1.1 bdci2px (NetCache NetApp/6.0.7)
X-HTTP-UserAgent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; .NET 
	CLR 1.1.4322; .NET CLR 2.0.50727; MS-RTC LM 8; .NET CLR 3.0.04506.648; .NET 
	CLR 3.5.21022),gzip(gfe),gzip(gfe)
Xref: news.mathworks.com comp.soft-sys.matlab:568979


Brendan:
Your algorithm gets the enclosing perimeter - pixels that are outside
the blob, not part of the blob.  You can erode the entire image (no
need to loop over individual blobs), and then subtract that from the
original image to get the perimeters.  This way the perimeters will
actually be a part of your blob - the outermost layer of pixels that
are still contained within your blob.  You can race that algorithm
against the built-in bwboundaries() to see which is faster.
Good luck,
ImageAnalyst