Package net.algart.matrices.scanning
Enum Class Boundary2DSimpleMeasurer.ObjectParameter
java.lang.Object
java.lang.Enum<Boundary2DSimpleMeasurer.ObjectParameter>
net.algart.matrices.scanning.Boundary2DSimpleMeasurer.ObjectParameter
- All Implemented Interfaces:
Serializable
,Comparable<Boundary2DSimpleMeasurer.ObjectParameter>
,Constable
- Enclosing class:
Boundary2DSimpleMeasurer
public static enum Boundary2DSimpleMeasurer.ObjectParameter
extends Enum<Boundary2DSimpleMeasurer.ObjectParameter>
The class describing what parameters of the connected object boundary should be measured by
Boundary2DSimpleMeasurer
class.
This class is immutable and thread-safe: there are no ways to modify settings of the created instance.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantDescriptionInstructsBoundary2DSimpleMeasurer
to measure the oriented area inside the contour, following along the scanned boundary.InstructsBoundary2DSimpleMeasurer
to find the centroid (center of mass) of the figure, lying inside the contour, following along the scanned boundary.InstructsBoundary2DSimpleMeasurer
to measure the maximums and minimums of x, y, x+y,x−y values while scanning the boundary, where x and y are coordinates of all points at the contour, following along the scanned boundary.InstructsBoundary2DSimpleMeasurer
to measure the perimeter of the object: the length of the contour, following along the scanned boundary. -
Method Summary
Modifier and TypeMethodDescriptionReturns the enum constant of this class with the specified name.values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
AREA
InstructsBoundary2DSimpleMeasurer
to measure the oriented area inside the contour, following along the scanned boundary. See definition of the "boundary" term in comments toBoundary2DScanner
class and the list of possible contour types inContourLineType
class.- See Also:
-
PERIMETER
InstructsBoundary2DSimpleMeasurer
to measure the perimeter of the object: the length of the contour, following along the scanned boundary. See definition of the "boundary" term in comments toBoundary2DScanner
class and the list of possible contour types inContourLineType
class.- See Also:
-
COORD_RANGES
InstructsBoundary2DSimpleMeasurer
to measure the maximums and minimums of x, y, x+y,x−y values while scanning the boundary, where x and y are coordinates of all points at the contour, following along the scanned boundary. See definition of the "boundary" term in comments toBoundary2DScanner
class and the list of possible contour types inContourLineType
class. -
CENTROID
InstructsBoundary2DSimpleMeasurer
to find the centroid (center of mass) of the figure, lying inside the contour, following along the scanned boundary. See definition of the "boundary" term in comments toBoundary2DScanner
class and the list of possible contour types inContourLineType
class.Note that the centroid may be undefined for some styles of contours, if the area of the figure inside the contour is zero. For example, it is possible for "thin" 1-pixel "lines" in a case of
ContourLineType.PIXEL_CENTERS_POLYLINE
. In this case,Boundary2DSimpleMeasurer.centroidX()
andBoundary2DSimpleMeasurer.centroidY()
methods return Double.NaN.
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum class has no constant with the specified nameNullPointerException
- if the argument is null
-