28 #include "vtkCommonDataModelModule.h" 60 vtkSetVector3Macro(
Normal,
double);
61 vtkGetVectorMacro(
Normal,
double, 3);
69 vtkSetVector3Macro(Origin,
double);
70 vtkGetVectorMacro(Origin,
double, 3);
78 void Push(
double distance);
86 static void ProjectPoint(
87 const double x[3],
const double origin[3],
const double normal[3],
double xproj[3]);
88 void ProjectPoint(
const double x[3],
double xproj[3]);
96 static void ProjectVector(
97 const double v[3],
const double origin[3],
const double normal[3],
double vproj[3]);
98 void ProjectVector(
const double v[3],
double vproj[3]);
107 static void GeneralizedProjectPoint(
108 const double x[3],
const double origin[3],
const double normal[3],
double xproj[3]);
109 void GeneralizedProjectPoint(
const double x[3],
double xproj[3]);
115 static double Evaluate(
double normal[3],
double origin[3],
double x[3]);
122 static double DistanceToPlane(
double x[3],
double n[3],
double p0[3]);
123 double DistanceToPlane(
double x[3]);
135 static int IntersectWithLine(
136 const double p1[3],
const double p2[3],
double n[3],
double p0[3],
double& t,
double x[3]);
137 int IntersectWithLine(
const double p1[3],
const double p2[3],
double& t,
double x[3]);
151 static int IntersectWithFinitePlane(
double n[3],
double o[3],
double pOrigin[3],
double px[3],
152 double py[3],
double x0[3],
double x1[3]);
153 int IntersectWithFinitePlane(
154 double pOrigin[3],
double px[3],
double py[3],
double x0[3],
double x1[3]);
166 void operator=(
const vtkPlane&) =
delete;
172 return normal[0] * (x[0] - origin[0]) + normal[1] * (x[1] - origin[1]) +
173 normal[2] * (x[2] - origin[2]);
179 #define vtkPlaneAbs(x) ((x) < 0 ? -(x) : (x)) 180 return (
vtkPlaneAbs(n[0] * (x[0] - p0[0]) + n[1] * (x[1] - p0[1]) + n[2] * (x[2] - p0[2])));
abstract interface for implicit functions
virtual double EvaluateFunction(double x[3])=0
Evaluate function at position x-y-z and return value.
static double DistanceToPlane(double x[3], double n[3], double p0[3])
Return the distance of a point x to a plane defined by n(x-p0) = 0.
static double Evaluate(double normal[3], double origin[3], double x[3])
Quick evaluation of plane equation n(x-origin)=0.
virtual void EvaluateGradient(double x[3], double g[3])=0
Evaluate function gradient at position x-y-z and pass back vector.
a simple class to control print indentation
abstract superclass for arrays of numeric data
perform various plane computations
static vtkObject * New()
Create an object with Debug turned off, modified time initialized to zero, and reference counting on...
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.