public class HoughLines extends Object
Modifier and Type | Class and Description |
---|---|
static class |
HoughLines.HoughLine
Represents a linear line as detected by the hough transform.
|
Modifier and Type | Field and Description |
---|---|
protected float |
centerX |
protected float |
centerY |
protected int |
doubleHeight |
protected int |
height |
protected float[][] |
houghArray |
protected int |
houghHeight |
protected int |
numPoints |
protected int |
width |
Constructor and Description |
---|
HoughLines() |
Modifier and Type | Method and Description |
---|---|
void |
addPoint(int x,
int y,
float value)
Adds a single point to the hough transform.
|
void |
addPoints(ij.process.ImageProcessor image,
boolean threshold,
float minThreshold)
Adds points from an image.
|
float[][] |
getHoughArray() |
Vector<HoughLines.HoughLine> |
getLines(int n) |
Vector<HoughLines.HoughLine> |
getLines(int n,
int threshold)
Once points have been added in some way this method extracts the lines and returns them as a Vector
of HoughLine objects, which can be used to draw on the
|
void |
initialise(int width,
int height)
Initialises the hough array.
|
protected int width
protected int height
protected float[][] houghArray
protected float centerX
protected float centerY
protected int houghHeight
protected int doubleHeight
protected int numPoints
public void initialise(int width, int height)
public void addPoints(ij.process.ImageProcessor image, boolean threshold, float minThreshold)
public void addPoint(int x, int y, float value)
public Vector<HoughLines.HoughLine> getLines(int n)
public float[][] getHoughArray()
public Vector<HoughLines.HoughLine> getLines(int n, int threshold)
threshold
- The percentage threshold above which lines are determined from the hough arrayCopyright © 2020–2022 Leibniz Institute for Natural Product Research and Infection Biology - Hans Knöll Institute (HKI). All rights reserved.