Package boofcv.alg.shapes.polygon
Interface RefinePolygonToGray<T extends ImageGray<T>>
- All Known Implementing Classes:
RefinePolygonToGrayLine
public interface RefinePolygonToGray<T extends ImageGray<T>>
Refines a polygon using the gray scale image. This results in a more accurate fit than just the contour alone
will provide and removes the shift that fitting to contour injects.
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Clears the previously set lens distortionboolean
refine
(Polygon2D_F64 input, Polygon2D_F64 output) Refines the initial polygonvoid
Sets the input imagevoid
setLensDistortion
(int width, int height, @Nullable PixelTransform<Point2D_F32> distToUndist, @Nullable PixelTransform<Point2D_F32> undistToDist) Specifies lens distortion
-
Method Details
-
setImage
Sets the input image -
setLensDistortion
void setLensDistortion(int width, int height, @Nullable @Nullable PixelTransform<Point2D_F32> distToUndist, @Nullable @Nullable PixelTransform<Point2D_F32> undistToDist) Specifies lens distortion -
clearLensDistortion
void clearLensDistortion()Clears the previously set lens distortion -
refine
Refines the initial polygon- Parameters:
input
- 2D polygon version of contour polygonoutput
- Storage for the refined polygon- Returns:
- true if successful or false if it failed
-