Jet  v1.3.3
Classes | Public Member Functions | Static Public Member Functions | Public Attributes | Protected Member Functions | List of all members
jet::Plane3 Class Referencefinal

3-D plane geometry. More...

#include <jet/plane3.h>

Inheritance diagram for jet::Plane3:
jet::Surface3

Classes

class  Builder
 Front-end to create Plane3 objects step by step. More...
 

Public Member Functions

 Plane3 (const Transform3 &transform=Transform3(), bool isNormalFlipped=false)
 Constructs a plane that crosses (0, 0, 0) with surface normal (0, 1, 0). More...
 
 Plane3 (const Vector3D &normal, const Vector3D &point, const Transform3 &transform=Transform3(), bool isNormalFlipped=false)
 Constructs a plane that cross point with surface normal normal. More...
 
 Plane3 (const Vector3D &point0, const Vector3D &point1, const Vector3D &point2, const Transform3 &transform=Transform3(), bool isNormalFlipped=false)
 
 Plane3 (const Plane3 &other)
 Copy constructor. More...
 
bool isBounded () const override
 Returns true if bounding box can be defined. More...
 
- Public Member Functions inherited from jet::Surface3
 Surface3 (const Transform3 &transform=Transform3(), bool isNormalFlipped=false)
 Constructs a surface with normal direction. More...
 
 Surface3 (const Surface3 &other)
 Copy constructor. More...
 
virtual ~Surface3 ()
 Default destructor. More...
 
Vector3D closestPoint (const Vector3D &otherPoint) const
 
BoundingBox3D boundingBox () const
 Returns the bounding box of this surface object. More...
 
bool intersects (const Ray3D &ray) const
 Returns true if the given ray intersects with this surface object. More...
 
double closestDistance (const Vector3D &otherPoint) const
 
SurfaceRayIntersection3 closestIntersection (const Ray3D &ray) const
 Returns the closest intersection point for given ray. More...
 
Vector3D closestNormal (const Vector3D &otherPoint) const
 
virtual void updateQueryEngine ()
 Updates internal spatial query engine. More...
 
virtual bool isValidGeometry () const
 Returns true if the surface is a valid geometry. More...
 
bool isInside (const Vector3D &otherPoint) const
 

Static Public Member Functions

static Builder builder ()
 Returns builder fox Plane3. More...
 

Public Attributes

Vector3D normal = Vector3D(0, 1, 0)
 Plane normal. More...
 
Vector3D point
 Point that lies on the plane. More...
 
- Public Attributes inherited from jet::Surface3
Transform3 transform
 Local-to-world transform. More...
 
bool isNormalFlipped = false
 Flips normal when calling Surface3::closestNormal(...). More...
 

Protected Member Functions

Vector3D closestPointLocal (const Vector3D &otherPoint) const override
 
bool intersectsLocal (const Ray3D &ray) const override
 
BoundingBox3D boundingBoxLocal () const override
 Returns the bounding box of this surface object in local frame. More...
 
Vector3D closestNormalLocal (const Vector3D &otherPoint) const override
 
SurfaceRayIntersection3 closestIntersectionLocal (const Ray3D &ray) const override
 Returns the closest intersection point for given ray in local frame. More...
 
- Protected Member Functions inherited from jet::Surface3
virtual double closestDistanceLocal (const Vector3D &otherPoint) const
 
virtual bool isInsideLocal (const Vector3D &otherPoint) const
 

Detailed Description

3-D plane geometry.

This class represents 3-D plane geometry which extends Surface3 by overriding surface-related queries.

Constructor & Destructor Documentation

◆ Plane3() [1/4]

jet::Plane3::Plane3 ( const Transform3 transform = Transform3(),
bool  isNormalFlipped = false 
)

Constructs a plane that crosses (0, 0, 0) with surface normal (0, 1, 0).

◆ Plane3() [2/4]

jet::Plane3::Plane3 ( const Vector3D normal,
const Vector3D point,
const Transform3 transform = Transform3(),
bool  isNormalFlipped = false 
)

Constructs a plane that cross point with surface normal normal.

◆ Plane3() [3/4]

jet::Plane3::Plane3 ( const Vector3D point0,
const Vector3D point1,
const Vector3D point2,
const Transform3 transform = Transform3(),
bool  isNormalFlipped = false 
)

Constructs a plane with three points on the surface. The normal will be set using the counter clockwise direction.

◆ Plane3() [4/4]

jet::Plane3::Plane3 ( const Plane3 other)

Copy constructor.

Member Function Documentation

◆ boundingBoxLocal()

BoundingBox3D jet::Plane3::boundingBoxLocal ( ) const
overrideprotectedvirtual

Returns the bounding box of this surface object in local frame.

Implements jet::Surface3.

◆ builder()

static Builder jet::Plane3::builder ( )
static

Returns builder fox Plane3.

◆ closestIntersectionLocal()

SurfaceRayIntersection3 jet::Plane3::closestIntersectionLocal ( const Ray3D ray) const
overrideprotectedvirtual

Returns the closest intersection point for given ray in local frame.

Implements jet::Surface3.

◆ closestNormalLocal()

Vector3D jet::Plane3::closestNormalLocal ( const Vector3D otherPoint) const
overrideprotectedvirtual

Returns the normal to the closest point on the surface from the given point otherPoint in local frame.

Implements jet::Surface3.

◆ closestPointLocal()

Vector3D jet::Plane3::closestPointLocal ( const Vector3D otherPoint) const
overrideprotectedvirtual

Returns the closest point from the given point otherPoint to the surface in local frame.

Implements jet::Surface3.

◆ intersectsLocal()

bool jet::Plane3::intersectsLocal ( const Ray3D ray) const
overrideprotectedvirtual

Returns true if the given ray intersects with this surface object in local frame.

Reimplemented from jet::Surface3.

◆ isBounded()

bool jet::Plane3::isBounded ( ) const
overridevirtual

Returns true if bounding box can be defined.

Reimplemented from jet::Surface3.

Member Data Documentation

◆ normal

Vector3D jet::Plane3::normal = Vector3D(0, 1, 0)

Plane normal.

◆ point

Vector3D jet::Plane3::point

Point that lies on the plane.


The documentation for this class was generated from the following file: