Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
OpenCV Android Programming By Example

You're reading from   OpenCV Android Programming By Example Leverage OpenCV to develop vision-aware and intelligent Android applications.

Arrow left icon
Product type Paperback
Published in Dec 2015
Publisher
ISBN-13 9781783550593
Length 202 pages
Edition 1st Edition
Languages
Tools
Arrow right icon
Toc

Detecting shapes

So, we have seen how to detect edges; however, this process is a pixel-by-pixel process answering the question of whether this pixel is an edge or not. Moving forward, in shape analysis, we would need more concrete information than just the edge test; we will need a better representation.

For example, if we have a picture of a box and we did the edge detection, we will end up with thousands and thousands of edge pixels; however, if we tried to fit a line to these edge pixels, we get a rectangle, which is a more symbolic and useful representation.

Understanding the Hough line transform

There are many ways to fit a line through a number of points, and Hough transform is considered an under constrained method, where we use only one point to find all the possible lines that can go through this point and we use another point to find all the lines that can go through it too, and we keep doing this for all the points that we have.

We end up with a voting system where each point is...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image