public class Blob extends Object
| Modifier and Type | Field and Description |
|---|---|
static int |
DRAW_CONVEX_HULL |
static int |
DRAW_HOLES |
static int |
DRAW_LABEL |
static String |
GETAREACONVEXHULL
Method name of getAreaConvexHull (for filtering).
|
static String |
GETAREATOPERIMETERRATIO
Method name of getAreaToPerimeterRatio (for filtering).
|
static String |
GETASPECTRATIO
Method name of getLongSideMBR (for filtering).
|
static String |
GETCIRCULARITY
Method name of getCircularity (for filtering).
|
static String |
GETCONTOURTEMPERATURE
Method name of getContourTemperature (for filtering).
|
static String |
GETCONVEXITY
Method name of getConvexity (for filtering).
|
static String |
GETDIAMETERMAXIMUMINSCRIBEDCIRCLE
Method name of getMaximumInscribedCircle (for filtering).
|
static String |
GETELONGATION
Method name of getElongation (for filtering).
|
static String |
GETENCLOSEDAREA
Method name of getEnclosedArea (for filtering).
|
static String |
GETFERETDIAMETER
Method name of getFeretDiameter (for filtering).
|
static String |
GETFRACTALBOXDIMENSION
Method name of getContourTemperature (for filtering).
|
static String |
GETLONGSIDEMBR
Method name of getLongSideMBR (for filtering).
|
static String |
GETMINFERETDIAMETER
Method name of getMinFeretDiameter (for filtering).
|
static String |
GETNUMBEROFHOLES
Method name of getNumberofHoles (for filtering).
|
static String |
GETORIENTATIONMAJORAXIS |
static String |
GETORIENTATIONMINORAXIS |
static String |
GETPERIMETER
Method name of getPerimeter (for filtering).
|
static String |
GETPERIMETERCONVEXHULL
Method name of getPerimeterConvexHull (for filtering).
|
static String |
GETSHORTSIDEMBR
Method name of getLongSideMBR (for filtering).
|
static String |
GETSOLIDITY
Method name of getSolidity (for filtering).
|
static String |
GETTHINNESRATIO
Method name of getThinnesRatio (for filtering).
|
| Constructor and Description |
|---|
Blob(Polygon outerContour,
int label) |
Blob(Polygon outerContour,
int label,
ij.measure.Calibration cal) |
| Modifier and Type | Method and Description |
|---|---|
static void |
addCustomFeature(CustomBlobFeature feature) |
void |
draw(ij.process.ImageProcessor ip)
Draws the Blob with its holes.
|
void |
draw(ij.process.ImageProcessor ip,
int options)
Draws the Blob with or without its holes.
|
Object |
evaluateCustomFeature(String methodName,
Object... params)
Evaluates the Custom Feature and return its value
|
static ij.ImagePlus |
generateBlobImage(Blob b) |
double |
getAreaConvexHull() |
double |
getAreaToPerimeterRatio()
Area/Perimeter
|
double |
getAspectRatio() |
Point2D |
getCenterOfGravity()
Return the geometric center of gravity of the blob.
|
double |
getCentralMoments(int p,
int q)
Central Moments Definition of "Gorman et. al.
|
double |
getCircularity()
Calculates the circularity of the outer contour: (perimeter*perimeter) / (enclosed area).
|
double |
getContourTemperature()
Calculates the Contour Temperatur.
|
Polygon |
getConvexHull()
Returns the convex hull of the blob.
|
double |
getConvexity() |
double |
getDiamaterMaximumInscribedCircle() |
double |
getEigenvalueMajorAxis()
Calculates Eigenvalue from the major axis using the moments of the boundary
|
double |
getEigenvalueMinorAxis()
Calculates Eigenvalue from the minor axis using the moments of the boundary
|
double |
getElongation()
The Elongation of the Blob based on a fitted ellipse (1 - minor axis / major axis)
|
double |
getEnclosedArea()
Calculates the enclosed are of the outer contour without subsctracting possible holes.
|
double |
getFeretDiameter()
Calculates the feret diameter of the outer contour
|
double |
getFractalBoxDimension() |
double |
getFractalBoxDimension(int[] boxSizes)
Box Dimension of the blob boundary.
|
double |
getFractalDimensionGoodness()
The goodness of the "best fit" line of the fractal box dimension estimation.
|
ArrayList<Polygon> |
getInnerContours()
Return all inner contours (holes) of the blob.
|
int |
getLabel()
Return the label of the blob in the labeled image
|
double |
getLongSideMBR() |
double |
getMinFeretDiameter()
Calculates the min feret diameter of the outer contour
|
Point[] |
getMinimumBoundingRectangle() |
double |
getMoment(int p,
int q)
Region-Based Moments Definition of "Gorman et. al.
|
int |
getNumberofHoles()
The number of inner contours (Holes) of a blob.
|
double |
getOrientationMajorAxis() |
double |
getOrientationMinorAxis() |
Polygon |
getOuterContour()
The outer contour of an object (polygon points are pixel indicies)
|
int[] |
getOuterContourAsChainCode()
Calculates the freeman chain code the outer contour
|
double |
getPerimeter()
Calculates the perimeter of the outer contour using its chain code
|
double |
getPerimeterConvexHull()
Calculates the perimeter of the convex hull
|
double |
getShortSideMBR() |
double |
getSolidity() |
double |
getThinnesRatio()
The Thinnes Ratio of the blob (normed).
|
boolean |
isOnEdge(ij.process.ImageProcessor ip)
Checks if the blob is on the edge of the image.
|
void |
setCalibration(ij.measure.Calibration cal) |
static void |
setDefaultColor(Color defaultColor)
Changes the default blob color.
|
public static final int DRAW_HOLES
public static final int DRAW_CONVEX_HULL
public static final int DRAW_LABEL
public static final String GETFERETDIAMETER
public static final String GETMINFERETDIAMETER
public static final String GETORIENTATIONMAJORAXIS
public static final String GETORIENTATIONMINORAXIS
public static final String GETELONGATION
public static final String GETLONGSIDEMBR
public static final String GETSHORTSIDEMBR
public static final String GETASPECTRATIO
public static final String GETPERIMETER
public static final String GETPERIMETERCONVEXHULL
public static final String GETCONVEXITY
public static final String GETSOLIDITY
public static final String GETENCLOSEDAREA
public static final String GETAREACONVEXHULL
public static final String GETCIRCULARITY
public static final String GETTHINNESRATIO
public static final String GETAREATOPERIMETERRATIO
public static final String GETCONTOURTEMPERATURE
public static final String GETDIAMETERMAXIMUMINSCRIBEDCIRCLE
public static final String GETFRACTALBOXDIMENSION
public static final String GETNUMBEROFHOLES
public Blob(Polygon outerContour, int label)
public Blob(Polygon outerContour, int label, ij.measure.Calibration cal)
outerContour - Contur of the bloblabel - Its unique labelcal - The blob will use the image calibrationpublic void setCalibration(ij.measure.Calibration cal)
public static void addCustomFeature(CustomBlobFeature feature)
public static void setDefaultColor(Color defaultColor)
defaultColor - The default color.public Object evaluateCustomFeature(String methodName, Object... params) throws NoSuchMethodException
Method - name The method name of the method in the feature classparams - the parameters of the method specified by the method nameNoSuchMethodExceptionpublic void draw(ij.process.ImageProcessor ip,
int options)
ip - The ImageProcesser in which the blob has to be drawn.options - Drawing Options are DRAW_HOLES, DRAW_CONVEX_HULL, DRAW_LABEL. Combinations with | are possible.public void draw(ij.process.ImageProcessor ip)
ip - The ImageProcesser in which the blob has to be drawn.public Point2D getCenterOfGravity()
public double getFeretDiameter()
public double getMinFeretDiameter()
public double getMoment(int p,
int q)
q - (order = (p + q))p - (order = (p + q))public double getCentralMoments(int p,
int q)
q - (order = (p + q))p - (order = (p + q))public double getOrientationMajorAxis()
public double getOrientationMinorAxis()
public double getEigenvalueMajorAxis()
public double getEigenvalueMinorAxis()
public double getElongation()
public Point[] getMinimumBoundingRectangle()
public double getLongSideMBR()
public double getShortSideMBR()
public double getAspectRatio()
public Polygon getOuterContour()
public int[] getOuterContourAsChainCode()
public ArrayList<Polygon> getInnerContours()
public int getLabel()
public double getPerimeter()
public double getPerimeterConvexHull()
public double getConvexity()
public boolean isOnEdge(ij.process.ImageProcessor ip)
ip - The imageprocesser which contains the blobpublic double getSolidity()
public Polygon getConvexHull()
public double getEnclosedArea()
public double getAreaConvexHull()
public double getCircularity()
public double getThinnesRatio()
public double getAreaToPerimeterRatio()
public double getContourTemperature()
in Luciano da Fontoura Costa, Roberto Marcondes Cesar,
Jr.Shape Classification and Analysis: Theory and Practice, Second Edition, 2009, CRC Presspublic double getFractalBoxDimension(int[] boxSizes)
boxSizes - ordered array of Box-Sizespublic double getDiamaterMaximumInscribedCircle()
public static ij.ImagePlus generateBlobImage(Blob b)
public double getFractalBoxDimension()
public double getFractalDimensionGoodness()
public int getNumberofHoles()
Copyright © 2015. All rights reserved.