Main Page   Class Hierarchy   Alphabetical List   Compound List   Compound Members  

prapi::transforms::LinearHough< T, U > Class Template Reference

#include <Hough.h>

Inheritance diagram for prapi::transforms::LinearHough< T, U >:

prapi::ImageTransform< T, U > List of all members.

Detailed Description

template<class T, class U>
class prapi::transforms::LinearHough< T, U >

Linear Hough transform.

Detects lines in images. Lines are paramerized by their slope (degrees, zero at positive x axis, growing couter-clockwise) and distance to the origin (pixels), resulting in a two-dimensional transformation domain. In the transformation domain, columns represent different slopes and rows different distances to the origin. The origin of the domain is at the center of the image. The quantization of the transformation domain is user-specifiable. The linear Hough transform can be though of as an image-to-image transform as it effectively produces an image as output.


Public Methods

 LinearHough (U threshold=0, int maxRadius=180, int maxAngle=180)
 Create an instance of the linear Hough transform.

virtual ~LinearHough ()
util::Matrix< T > getTransformedImage (const util::Matrix< U > &mat) throw (ImageTransformException&)
 Transform an image.

void setMaxRadius (int radius)
 Set the transformed matrix size.

int getMaxRadius () const
 Get the maximum radius.

void setMaxAngle (int angle)
 Set the transformed matrix size.

int getMaxAngle () const
 Get the maximum angle.

void setThreshold (U threshold)
 Set a new threshold for Hough transform.

getThreshold ()
 Get the current threshold.


Constructor & Destructor Documentation

template<class T, class U>
prapi::transforms::LinearHough< T, U >::LinearHough   threshold = 0,
int    maxRadius = 180,
int    maxAngle = 180
[inline]
 

Create an instance of the linear Hough transform.

There are two parameters that need to be initialized. The threshold will be intialized to zero and the size of the transformation result will be intialized to 180x180.

Parameters:
threshold  the value with which the matrix will be thresholded.
maxRadius  the number of rows in the transformed matrix (quantization can be made for this parameter).
maxAngle  the number of columns in the transformed matrix (quantization can be made for this parameter).


Member Function Documentation

template<class T, class U>
void prapi::transforms::LinearHough< T, U >::setMaxAngle int    angle [inline]
 

Set the transformed matrix size.

(Maximum angle in the parametric representation.)

template<class T, class U>
void prapi::transforms::LinearHough< T, U >::setMaxRadius int    radius [inline]
 

Set the transformed matrix size.

(Maximum radius in the parametric representation.)


The documentation for this class was generated from the following file:
Documentation generated on 11.09.2003 with Doxygen.
The documentation is copyrighted material.
Copyright © Topi Mäenpää 2003. All rights reserved.