Medical Imaging Interaction Toolkit
2023.04.00
Medical Imaging Interaction Toolkit
|
Go to the documentation of this file.
13 #ifndef mitkPlaneGeometry_h
14 #define mitkPlaneGeometry_h
22 #include <vnl/vnl_cross.h>
26 template <
class TCoordRep,
unsigned int NPo
intDimension>
28 typedef Line<ScalarType, 3>
Line3D;
84 itkFactorylessNewMacro(
Self);
87 virtual void IndexToWorld(
const Point2D &pt_units,
Point2D &pt_mm)
const;
89 virtual void WorldToIndex(
const Point2D &pt_mm,
Point2D &pt_units)
const;
140 virtual void InitializeStandardPlane(
const BaseGeometry *geometry3D,
143 bool frontside =
true,
144 bool rotated =
false,
159 virtual void InitializeStandardPlane(
const BaseGeometry *geometry3D,
162 bool frontside =
true,
163 bool rotated =
false);
183 virtual void InitializeStandardPlane(
ScalarType width,
188 bool frontside =
true,
189 bool rotated =
false,
197 virtual void InitializeStandardPlane(
ScalarType width,
202 bool frontside =
true,
203 bool rotated =
false,
218 virtual void InitializeStandardPlane(
ScalarType width,
236 virtual void InitializeStandardPlane(
ScalarType width,
250 virtual void InitializeStandardPlane(
const Vector3D &rightVector,
262 virtual void InitializeStandardPlane(
const VnlVector &rightVector,
272 virtual void InitializePlane(
const Point3D &origin,
const Vector3D &normal);
290 static bool CheckRotationMatrix(
AffineTransform3D *transform,
double epsilon=1e-6);
310 virtual bool IsAbove(
const Point3D &pt3d_mm,
bool considerBoundingBox =
false)
const;
332 return (pt3d_mm - GetOrigin()) * GetNormal() / len;
350 if (IsParallel(plane))
352 return SignedDistance(plane->
GetOrigin());
385 double Angle(
const Line3D &line)
const;
395 bool IntersectionPoint(
const Line3D &line,
Point3D &intersectionPoint)
const;
407 bool IntersectionPointParam(
const Line3D &line,
double &t)
const;
420 bool IsOnPlane(
const Point3D &point)
const;
426 bool IsOnPlane(
const Line3D &line)
const;
443 itk::LightObject::Pointer InternalClone()
const override;
446 void ExecuteOperation(
Operation *operation)
override;
554 bool HasReferenceGeometry()
const;
556 static std::vector< int > CalculateDominantAxes(mitk::AffineTransform3D::MatrixType::InternalMatrixType& rotation_matrix);
565 void PrintSelf(std::ostream &os, itk::Indent indent)
const override;
584 void CheckBounds(
const BoundsArrayType &bounds)
override;
604 virtual bool operator!=(
const PlaneGeometry *)
const {
return false; };
ScalarType Distance(const Point3D &pt3d_mm) const
Distance of the point from the geometry (bounding-box not considered)
Describes a two-dimensional, rectangular plane.
Base class of all Operation-classes.
const Point3D GetOrigin() const
Get the origin, e.g. the upper-left corner of the plane.
const mitk::BaseGeometry * m_ReferenceGeometry
ScalarType SignedDistanceFromPlane(const PlaneGeometry *plane) const
Signed distance of the plane from another plane (bounding-box not considered)
itk::ScalableAffineTransform< ScalarType, 3 > AffineTransform3D
vnl_vector< ScalarType > VnlVector
DataCollection - Class to facilitate loading/accessing structured data.
ScalarType DistanceFromPlane(const PlaneGeometry *plane) const
Distance of the plane from another plane (bounding-box not considered)
MITKCORE_EXPORT bool operator!=(const InteractionEvent &a, const InteractionEvent &b)
MITKCORE_EXPORT bool operator==(const InteractionEvent &a, const InteractionEvent &b)
BaseGeometry Describes the geometry of a data object.
ScalarType SignedDistanceFromPlane(const Point3D &pt3d_mm) const
Signed distance of the point from the plane (bounding-box not considered)
Line< ScalarType, 3 > Line3D
void PreSetSpacing(const mitk::Vector3D &aSpacing) override
PreSetSpacing.
#define mitkClassMacro(className, SuperClassName)