Path: news.mathworks.com!not-for-mail
From: <HIDDEN>
Newsgroups: comp.soft-sys.matlab
Subject: Re: extracting a line from an image using hough transform
Date: Wed, 18 Feb 2009 09:57:01 +0000 (UTC)
Organization: STFC Rutherford Appleton Laboratory
Lines: 18
Message-ID: <gngm1d$1nj$1@fred.mathworks.com>
References: <gndn21$3lm$1@fred.mathworks.com> <gne6oi$qe7$1@fred.mathworks.com> <gngj5h$ncf$1@fred.mathworks.com>
Reply-To: <HIDDEN>
NNTP-Posting-Host: webapp-02-blr.mathworks.com
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit
X-Trace: fred.mathworks.com 1234951021 1779 172.30.248.37 (18 Feb 2009 09:57:01 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Wed, 18 Feb 2009 09:57:01 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 968489
Xref: news.mathworks.com comp.soft-sys.matlab:519083


"Anil Kumar Reddy " <g_anilkumarreddy@yahoo.co.in> wrote in message <gngj5h$ncf$1@fred.mathworks.com>...
> "Image Analyst" <imageanalyst@mailinator.com> wrote in message <gne6oi$qe7$1@fred.mathworks.com>...
> > Anil Kumar Reddy :
> > Detect or display?  Or both?  Which is it?
> i want to detect and display the line.the line i need to detect is a horizontal line. how can it be done?
>    thank you

If you know that your line is horizontal, do you actually have to go to the extent of using the Hough transform, which takes a lot of computational horse power? 

You might find that you can get your result by simply doing a sum in the row direction. Any truely horizontal line will provide a large peak in the sum vector, which will provide information regarding its length (via the peak amplitude), its width (via the width of the peak) and its position (via the position of the peak).

It is a limited form of the Radon Transform.
help sum
help radon

Hope that helps 

Dave Robinson