Itasca C++ Interface
Loading...
Searching...
No Matches
iplane.h
Go to the documentation of this file.
1#pragma once
2
9#include "base/src/base.h"
10#include "dim.h"
11
12namespace itascaxd {
13 // NOTE: Might want to add distance checking, etc functions to the interface later.
14 // NOTE: This class IS used!
15
17
30 class IPlane {
31 public:
39
41 virtual const DVect &getOrigin() const=0;
43 virtual const Orientation &getOrientation() const=0;
46 virtual double getDistance(const DVect &v) const=0;
50 virtual IntersectCode getIntersection(const DVect &begin,const DVect &end,DVect *loc=0,double *dist=0) const=0;
52 virtual DVect getClosestPoint(const DVect &v) const=0;
54 virtual void setOrigin(const DVect &v)=0;
56 virtual void setOrientation(const Orientation &o)=0;
57 };
58} // namespace itascaxd
59// EoF
One stop include for all objects defined as part of base interface.
Class for storing an "orientation", or a direction in 2D or 3D space.
Definition orientation.h:99
Interface for the definition of a Plane in 3D space.
Definition iplane.h:30
virtual DVect getClosestPoint(const DVect &v) const =0
Returns the closest point in the plane to v.
virtual const DVect & getOrigin() const =0
Returns the plane origin.
virtual IntersectCode getIntersection(const DVect &begin, const DVect &end, DVect *loc=0, double *dist=0) const =0
virtual const Orientation & getOrientation() const =0
Returns the plane orientation.
virtual void setOrientation(const Orientation &o)=0
Sets the plane orientation.
virtual double getDistance(const DVect &v) const =0
IntersectCode
Possible intersection types.
Definition iplane.h:33
@ icFront
Definition iplane.h:34
@ icBehind
Definition iplane.h:35
@ icIntersect2
Definition iplane.h:37
@ icIntersect1
Definition iplane.h:36
virtual void setOrigin(const DVect &v)=0
Sets the plane origin.
DIM - Provides code portability between 2D and 3D codes.
DVect3 DVect
Vector of doubles, either 2D or 3D.
Definition dim.h:154
Itasca Library standard namespace, specific to 2D or 3D.
Definition icontactmodule.h:4