Go to the documentation of this file.
34 #include "vtkCommonDataModelModule.h"
75 vtkSetVector3Macro(Origin,
double);
76 vtkGetVectorMacro(Origin,
double,3);
84 void Push(
double distance);
92 static void ProjectPoint(
const double x[3],
const double origin[3],
const double normal[3],
102 static void ProjectVector(
const double v[3],
const double origin[3],
const double normal[3],
114 const double normal[3],
double xproj[3]);
122 static double Evaluate(
double normal[3],
double origin[3],
double x[3]);
129 static double DistanceToPlane(
double x[3],
double n[3],
double p0[3]);
143 double p0[3],
double& t,
double x[3]);
159 double pOrigin[3],
double px[3],
double py[3],
160 double x0[3],
double x1[3]);
162 double x0[3],
double x1[3]);
174 void operator=(
const vtkPlane&) =
delete;
179 double origin[3],
double x[3])
181 return normal[0]*(x[0]-origin[0]) + normal[1]*(x[1]-origin[1]) +
182 normal[2]*(x[2]-origin[2]);
188 #define vtkPlaneAbs(x) ((x)<0?-(x):(x))
189 return (
vtkPlaneAbs(n[0]*(x[0]-p0[0]) + n[1]*(x[1]-p0[1]) +
perform various plane computations
void ProjectPoint(const double x[3], double xproj[3])
static double Evaluate(double normal[3], double origin[3], double x[3])
Quick evaluation of plane equation n(x-origin)=0.
double EvaluateFunction(double x[3]) override
Evaluate function at position x-y-z and return value.
virtual double EvaluateFunction(double x[3])=0
Evaluate function at position x-y-z and return value.
abstract superclass for arrays of numeric data
static void ProjectVector(const double v[3], const double origin[3], const double normal[3], double vproj[3])
Project a vector v onto plane defined by origin and normal.
static int IntersectWithFinitePlane(double n[3], double o[3], double pOrigin[3], double px[3], double py[3], double x0[3], double x1[3])
Given two planes, one infinite and one finite, defined by the normal n and point o (infinite plane),...
void EvaluateGradient(double x[3], double g[3]) override
Evaluate function gradient at point x[3].
abstract interface for implicit functions
int IntersectWithFinitePlane(double pOrigin[3], double px[3], double py[3], double x0[3], double x1[3])
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.
void EvaluateFunction(vtkDataArray *input, vtkDataArray *output) override
a simple class to control print indentation
void GeneralizedProjectPoint(const double x[3], double xproj[3])
int IntersectWithLine(const double p1[3], const double p2[3], double &t, double x[3])
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
void ProjectVector(const double v[3], double vproj[3])
static void ProjectPoint(const double x[3], const double origin[3], const double normal[3], double xproj[3])
Project a point x onto plane defined by origin and normal.
double DistanceToPlane(double x[3])
void Push(double distance)
Translate the plane in the direction of the normal by the distance specified.
static int IntersectWithLine(const double p1[3], const double p2[3], double n[3], double p0[3], double &t, double x[3])
Given a line defined by the two points p1,p2; and a plane defined by the normal n and point p0,...
static vtkPlane * New()
Construct plane passing through origin and normal to z-axis.
static void GeneralizedProjectPoint(const double x[3], const double origin[3], const double normal[3], double xproj[3])
Project a point x onto plane defined by origin and normal.