public class Edge extends Object
Modifier and Type | Class and Description |
---|---|
static interface |
Edge.EdgeOrientationFlag |
Modifier and Type | Field and Description |
---|---|
static int |
L_ALL_EDGES
Filters for all edges
|
static int |
L_HORIZONTAL_EDGES
Filters for horizontal edges
|
static int |
L_VERTICAL_EDGES
Filters for vertical edges
|
Constructor and Description |
---|
Edge() |
Modifier and Type | Method and Description |
---|---|
static Pix |
pixSobelEdgeFilter(Pix pixs,
int orientFlag)
Performs a Sobel edge detecting filter.
|
public static final int L_HORIZONTAL_EDGES
public static final int L_VERTICAL_EDGES
public static final int L_ALL_EDGES
public static Pix pixSobelEdgeFilter(Pix pixs, int orientFlag)
To use both the vertical and horizontal filters, set the orientation flag to L_ALL_EDGES; this sums the abs. value of their outputs, clipped to 255.
Notes:
1 4 7
2 5 8
3 6 9
Read the data incrementally across the image and unroll the loop.
pixs
- Source pix (8 bpp; no colormap)orientFlag
- Edge orientation flag (L_HORIZONTAL_EDGES,
L_VERTICAL_EDGES, L_ALL_EDGES)