Upload
supun-kandaudahewa
View
49
Download
5
Embed Size (px)
Citation preview
Line Detection
Image Processing & Computer Vision Assignment
Contents
Introduction • What is Line Detection
Problem • How are we going to detect Lines• Is it difficult?
Solution • What can we do?
Different Methods • Sobel, Laplacian etc.
Use • What are the uses of detecting lines
Tools Used •VS 2010•EMGU CV
Demo • A demo of the solution I created
Conclusion
Introduction
• What is EDGE/LINE Detection : Edge detection is considered as the most common approach for detecting meaningful discontinuities in the grey- level.
Origin of Edges
Reference: http://www.ics.uci.edu/~majumder/DIP/classes/EdgeDetect.pdf
Problem• How are we going to detect Lines : Here the problem
arises. How are we going to filter lines from other stuff in an image.• First thing first – We should know that lines or
edges can be identified using the discontinuities in the grey- level. • There are different techniques• Sobel Operator for Horizontal Lines.• Sobel Operator for Vertical Lines.• Laplacian Operator.• Laplacian of Gaussian for further smoothing (CV.SMOOTH)• Canny Operator.
SolutionWhat can we do : Use discontinuities in the grey- level.
Different Methods -SobelCalculates first image derivative using Sobel operator. Use the following function to apply the Sobel operator:
Cv.Sobel( const CvArr src, CvArr dst, int xorder, int yorder,
int aperture_size=3 );
Different Methods -SobelParameters:
src – Source image
dst – Destination image
xorder – First Order derivative in x direction
yorder – First Order derivative in y direction
apertureSize – Size of the extended Sobel kernel, must be 1, 3, 5 or 7
The function is called with (xorder=1, yorder=0, aperture_size=3)
|-1 0 1|
|-2 0 2|
|-1 0 1|
Different Methods -Laplacian• The function calculates the Laplacian of the source image by
filtering the image with the following 3X3 aperture:
|-1 -1 -1|| -1 8 -1||-1 -1 -1|
• Use the following function to apply the Laplacian operator:
• Cv.Laplace(const CvArr src, CvArr dst, int apertureSize=3)
Different Methods -LaplacianParameters:• src – Source image• dst – Destination image• apertureSize – Size of the extended laplace kernel
Different Methods – Further Smoothing Laplacian• Use the Cv.Smooth() function to remove the
Gaussian noise.• Apply the cv.smooth() method first.• Then apply the laplacian method.• More enhanced edges.
Uses of Line Detection• Obtaining basic structure.• Navigation/track or lane assistants.• Find vanishing points.• Identifying objects by shape.
Tools Used• Tools used : Microsoft Visual Studio 2010 C#. NET.
EmguCV image processing library.
Integrating Tools• These tools should be integrated with one another to
get the job done.• There are many tutorials on the internet on these
topics.• Configure them properly prior going forward with the
project. It will save your time for sure.
VISIT MY BLOG FOR MORE INFO : supun567.blogspot.com
Demo• Lets see how this works!!!
Conclusion• Boundaries between regions with relatively distinct
graylevels.• By far the most common type of discontinuity in an
image.• Gives acceptable results.
Thank You!!!