13 #ifndef mitkPlanarPolygon_h
14 #define mitkPlanarPolygon_h
32 itkFactorylessNewMacro(Self);
39 itkBooleanMacro(Closed);
80 void PrintSelf(std::ostream &os, itk::Indent indent)
const override;
Implementation of PlanarFigure representing a polygon with two or more control points.
void PrintSelf(std::ostream &os, itk::Indent indent) const override
const unsigned int FEATURE_ID_AREA
std::vector< mitk::Point2D > CheckForLineIntersection(const Point2D &p1, const Point2D &p2) const
bool CheckForLineIntersection(const mitk::Point2D &p1, const mitk::Point2D &p2, const mitk::Point2D &p3, const mitk::Point2D &p4, Point2D &intersection) const
void GenerateHelperPolyLine(double mmPerDisplayUnit, unsigned int displayHeight) override
Generates the poly-lines that should be drawn the same size regardless of zoom.
bool Equals(const mitk::PlanarFigure &other) const override
Compare two PlanarFigure objects Note: all subclasses have to implement the method on their own.
const unsigned int FEATURE_ID_CIRCUMFERENCE
virtual void SetClosed(bool closed)
Set whether the polygon should be closed between first and last control point or not.
bool CheckForLineIntersection(const mitk::Point2D &p1, const mitk::Point2D &p2, const mitk::Point2D &p3, const mitk::Point2D &p4) const
void EvaluateFeaturesInternal() override
Calculates feature quantities of the planar figure.
unsigned int GetMaximumNumberOfControlPoints() const override
Polygon maximum number of control points is principally not limited.
unsigned int GetMinimumNumberOfControlPoints() const override
Place figure in its minimal configuration (a point at least) onto the given 2D geometry.
mitkClassMacro(PlanarPolygon, PlanarFigure)
void GeneratePolyLine() override
Generates the poly-line representation of the planar figure.
Find image slices visible on a given plane.