MCPcopy Create free account
hub / github.com/MITK/MITK / IntersectionPointParam

Method IntersectionPointParam

Modules/Core/src/DataManagement/mitkPlaneGeometry.cpp:675–692  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

673 }
674
675 bool PlaneGeometry::IntersectionPointParam(const Line3D &line, double &t) const
676 {
677 Vector3D planeNormal = this->GetNormal();
678
679 Vector3D lineDirection = line.GetDirection();
680
681 t = planeNormal * lineDirection;
682
683 if (fabs(t) < eps)
684 {
685 return false;
686 }
687
688 Vector3D diff;
689 diff = this->GetOrigin() - line.GetPoint();
690 t = (planeNormal * diff) / t;
691 return true;
692 }
693
694 bool PlaneGeometry::IsParallel(const PlaneGeometry *plane) const
695 {

Callers 2

CreateVtkCrosshairMethod · 0.80

Calls 3

GetNormalMethod · 0.95
GetOriginMethod · 0.45
GetPointMethod · 0.45

Tested by

no test coverage detected