VisuTwin Canvas
C++ 3D Engine — Metal Backend
Loading...
Searching...
No Matches
visutwin::canvas::Plane Class Reference

#include <core/shape/plane.h>

Public Member Functions

Plane clone () const
Planecopy (const Plane &src)
float distance () const
bool intersectsLine (const Vector3 &start, const Vector3 &end, Vector3 *point=nullptr) const
bool intersectsRay (const Ray &ray, Vector3 *point=nullptr) const
const Vector3normal () const
Planenormalize ()
 Plane ()
 Plane (const Vector3 &normal, float distance)
Planeset (float nx, float ny, float nz, float d)
void setDistance (float distance)
PlanesetFromPointNormal (const Vector3 &point, const Vector3 &normal)
void setNormal (const Vector3 &normal)

Detailed Description

Definition at line 10 of file plane.h.

Constructor & Destructor Documentation

◆ Plane() [1/2]

visutwin::canvas::Plane::Plane ( )

Definition at line 10 of file plane.cpp.

Referenced by clone(), copy(), normalize(), set(), and setFromPointNormal().

◆ Plane() [2/2]

visutwin::canvas::Plane::Plane ( const Vector3 & normal,
float distance )

Definition at line 14 of file plane.cpp.

References distance(), and normal().

Member Function Documentation

◆ clone()

Plane visutwin::canvas::Plane::clone ( ) const
nodiscard

Definition at line 25 of file plane.cpp.

References Plane().

◆ copy()

Plane & visutwin::canvas::Plane::copy ( const Plane & src)

Definition at line 18 of file plane.cpp.

References Plane().

◆ distance()

float visutwin::canvas::Plane::distance ( ) const
inline

Definition at line 18 of file plane.h.

Referenced by Plane(), and setDistance().

◆ intersectsLine()

bool visutwin::canvas::Plane::intersectsLine ( const Vector3 & start,
const Vector3 & end,
Vector3 * point = nullptr ) const

Definition at line 30 of file plane.cpp.

◆ intersectsRay()

bool visutwin::canvas::Plane::intersectsRay ( const Ray & ray,
Vector3 * point = nullptr ) const

◆ normal()

const Vector3 & visutwin::canvas::Plane::normal ( ) const
inline

Definition at line 16 of file plane.h.

Referenced by Plane(), setFromPointNormal(), and setNormal().

◆ normalize()

Plane & visutwin::canvas::Plane::normalize ( )

Definition at line 56 of file plane.cpp.

References Plane().

◆ set()

Plane & visutwin::canvas::Plane::set ( float nx,
float ny,
float nz,
float d )

Definition at line 64 of file plane.cpp.

References Plane().

◆ setDistance()

void visutwin::canvas::Plane::setDistance ( float distance)
inline

Definition at line 19 of file plane.h.

References distance().

◆ setFromPointNormal()

Plane & visutwin::canvas::Plane::setFromPointNormal ( const Vector3 & point,
const Vector3 & normal )

Definition at line 71 of file plane.cpp.

References normal(), and Plane().

◆ setNormal()

void visutwin::canvas::Plane::setNormal ( const Vector3 & normal)
inline

Definition at line 17 of file plane.h.

References normal().


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