public class CannyEdge extends FunctionAggregator
| Modifier and Type | Field and Description |
|---|---|
boolean |
accurate |
IFunction |
function |
int |
height |
Kernel |
kernelH |
Kernel |
kernelV |
int |
layers |
boolean |
thinEdges |
float |
thresholdEnd |
float |
thresholdStart |
int |
width |
| Constructor and Description |
|---|
CannyEdge(IExplicitFunction function,
Kernel kernelH,
Kernel kernelV,
boolean accurate,
float thresholdStart,
float thresholdEnd,
boolean thinEdges) |
CannyEdge(IFunction function,
Kernel kernelH,
Kernel kernelV,
boolean accurate,
float thresholdStart,
float thresholdEnd,
boolean thinEdges,
int width,
int height,
int layers)
Edge detection using gradient
References: https://en.wikipedia.org/wiki/Canny_edge_detector |
| Modifier and Type | Method and Description |
|---|---|
protected IFunction |
createAggregate() |
static IFunction |
gradient(IExplicitFunction function,
boolean accurate,
float thresholdStart,
float thresholdEnd,
boolean thinEdges) |
static IFunction |
gradient(IFunction function,
int width,
int height,
int layers,
boolean accurate,
float thresholdStart,
float thresholdEnd,
boolean thinEdges) |
static IFunction |
sobel(IExplicitFunction function,
boolean accurate,
float thresholdStart,
float thresholdEnd,
boolean thinEdges) |
static IFunction |
sobel(IFunction function,
int width,
int height,
int layers,
boolean accurate,
float thresholdStart,
float thresholdEnd,
boolean thinEdges) |
get, get2D, getDerivative, getDerivative2Dpublic final IFunction function
public final Kernel kernelH
public final Kernel kernelV
public final boolean accurate
public final float thresholdStart
public final float thresholdEnd
public final boolean thinEdges
public final int width
public final int height
public final int layers
public CannyEdge(IExplicitFunction function, Kernel kernelH, Kernel kernelV, boolean accurate, float thresholdStart, float thresholdEnd, boolean thinEdges)
public CannyEdge(IFunction function, Kernel kernelH, Kernel kernelV, boolean accurate, float thresholdStart, float thresholdEnd, boolean thinEdges, int width, int height, int layers)
accurate - edge magnitude using sqrt(dx²+dy²) if accurate, or abs(dx)+abs(dy).thresholdStart - thresholdEnd - if < 1, applies hysteresis thresholdingthinEdges - Non-maximum Suppressionprotected IFunction createAggregate()
createAggregate in class FunctionAggregatorpublic static IFunction sobel(IExplicitFunction function, boolean accurate, float thresholdStart, float thresholdEnd, boolean thinEdges)
#cannyEdge(IExplicitFunction, IExplicitFunction, boolean, float, float, boolean)public static IFunction sobel(IFunction function, int width, int height, int layers, boolean accurate, float thresholdStart, float thresholdEnd, boolean thinEdges)
#cannyEdge(IExplicitFunction, IExplicitFunction, boolean, float, float, boolean)public static IFunction gradient(IExplicitFunction function, boolean accurate, float thresholdStart, float thresholdEnd, boolean thinEdges)
#cannyEdge(IExplicitFunction, IExplicitFunction, boolean, float, float, boolean)Bonzai Engine 1.4.1-20200831 - A Java OpenGL engine and tools for Windows/Mac/Linux/Android
Copyright © 2007-2019 Jérôme Jouvie bonzaiengine.com contact@bonzaiengine.com