|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.generation5.vision.HoughTransformOp
org.generation5.vision.LineHoughTransformOp
This class implements a Line Hough transform. It is heavily based on code written by Timothy Sharman for the excellent HIPR2 resource site (http://homepages.inf.ed.ac.uk/rbf/HIPR2/hipr_top.htm).
| Field Summary | |
protected long[][] |
houghAccumulator
The accumulator. |
protected java.awt.Color |
lineColor
The line colour used for the superimposed image (default WHITE). |
protected int |
localPeakNeighbourhood
The local peak neighbourhood. |
protected long |
maxAccValue
The maximum accumulator value. |
protected double |
thetaStep
The theta step. |
| Constructor Summary | |
LineHoughTransformOp()
Creates a new instance of LineHoughTransformOp |
|
| Method Summary | |
java.awt.image.BufferedImage |
getAccumulatorImage()
Returns the accumulator as an image. |
java.awt.Color |
getLineColor()
Get the line colour used. |
int |
getLocalPeakNeighbourhood()
Get the local peak neighbourhood. |
protected long |
getMaximum()
Get the maximum value in the accumulator. |
java.awt.image.BufferedImage |
getSuperimposed(java.awt.image.BufferedImage img,
double threshold)
Returns the superimposed image. |
static void |
main(java.lang.String[] args)
Simple test function. |
void |
run(java.awt.image.BufferedImage img)
Runs the line Hough Transform. |
void |
setLineColor(java.awt.Color lc)
Set the line colour used for the superimposed image. |
void |
setLocalPeakNeighbourhood(int lpn)
Set the local peak neighbourhood. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
protected long[][] houghAccumulator
protected long maxAccValue
protected int localPeakNeighbourhood
protected double thetaStep
protected java.awt.Color lineColor
| Constructor Detail |
public LineHoughTransformOp()
| Method Detail |
public void setLineColor(java.awt.Color lc)
lc - the new line colour.public java.awt.Color getLineColor()
public void setLocalPeakNeighbourhood(int lpn)
lpn - the new local peak neighbourhood.public int getLocalPeakNeighbourhood()
protected long getMaximum()
public java.awt.image.BufferedImage getAccumulatorImage()
getAccumulatorImage in class HoughTransformOppublic void run(java.awt.image.BufferedImage img)
run in class HoughTransformOpimg - input image.
public java.awt.image.BufferedImage getSuperimposed(java.awt.image.BufferedImage img,
double threshold)
getSuperimposed in class HoughTransformOpimg - the input image.threshold - the accumulator threshold.
public static void main(java.lang.String[] args)
args - the command line arguments
|
This documentation is part of the Generation5 JDK.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||