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

3-D implicit surface wrapper for generic Surface3 instance. More...

#include <jet/surface_to_implicit3.h>

Inheritance diagram for jet::SurfaceToImplicit3:
jet::ImplicitSurface3 jet::Surface3

Classes

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

Public Member Functions

 SurfaceToImplicit3 (const Surface3Ptr &surface, const Transform3 &transform=Transform3(), bool isNormalFlipped=false)
 Constructs an instance with generic Surface3 instance. More...
 
 SurfaceToImplicit3 (const SurfaceToImplicit3 &other)
 Copy constructor. More...
 
void updateQueryEngine () override
 Updates internal spatial query engine. More...
 
bool isBounded () const override
 Returns true if bounding box can be defined. More...
 
bool isValidGeometry () const override
 Returns true if the surface is a valid geometry. More...
 
Surface3Ptr surface () const
 Returns the raw surface instance. More...
 
- Public Member Functions inherited from jet::ImplicitSurface3
 ImplicitSurface3 (const Transform3 &transform=Transform3(), bool isNormalFlipped=false)
 Default constructor. More...
 
 ImplicitSurface3 (const ImplicitSurface3 &other)
 Copy constructor. More...
 
virtual ~ImplicitSurface3 ()
 Default destructor. More...
 
double signedDistance (const Vector3D &otherPoint) const
 Returns signed distance from the given point otherPoint. 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
 
bool isInside (const Vector3D &otherPoint) const
 

Static Public Member Functions

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

Protected Member Functions

Vector3D closestPointLocal (const Vector3D &otherPoint) const override
 
double closestDistanceLocal (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
 
double signedDistanceLocal (const Vector3D &otherPoint) const override
 
SurfaceRayIntersection3 closestIntersectionLocal (const Ray3D &ray) const override
 Returns the closest intersection point for given ray in local frame. More...
 
bool isInsideLocal (const Vector3D &otherPoint) const override
 

Additional Inherited Members

- Public Attributes inherited from jet::Surface3
Transform3 transform
 Local-to-world transform. More...
 
bool isNormalFlipped = false
 Flips normal when calling Surface3::closestNormal(...). More...
 

Detailed Description

3-D implicit surface wrapper for generic Surface3 instance.

This class represents 3-D implicit surface that converts Surface3 instance to an ImplicitSurface3 object. The conversion is made by evaluating closest point and normal from a given point for the given (explicit) surface. Thus, this conversion won't work for every single surfaces, especially TriangleMesh3. To use TriangleMesh3 as an ImplicitSurface3 instance, please take a look at ImplicitTriangleMesh3. Use this class only for the basic primitives such as Sphere3 or Box3.

Constructor & Destructor Documentation

◆ SurfaceToImplicit3() [1/2]

jet::SurfaceToImplicit3::SurfaceToImplicit3 ( const Surface3Ptr surface,
const Transform3 transform = Transform3(),
bool  isNormalFlipped = false 
)

Constructs an instance with generic Surface3 instance.

◆ SurfaceToImplicit3() [2/2]

jet::SurfaceToImplicit3::SurfaceToImplicit3 ( const SurfaceToImplicit3 other)

Copy constructor.

Member Function Documentation

◆ boundingBoxLocal()

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

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

Implements jet::Surface3.

◆ builder()

static Builder jet::SurfaceToImplicit3::builder ( )
static

Returns builder fox SurfaceToImplicit3.

◆ closestDistanceLocal()

double jet::SurfaceToImplicit3::closestDistanceLocal ( const Vector3D otherPoint) const
overrideprotectedvirtual

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

Reimplemented from jet::ImplicitSurface3.

◆ closestIntersectionLocal()

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

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

Implements jet::Surface3.

◆ closestNormalLocal()

Vector3D jet::SurfaceToImplicit3::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::SurfaceToImplicit3::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::SurfaceToImplicit3::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::SurfaceToImplicit3::isBounded ( ) const
overridevirtual

Returns true if bounding box can be defined.

Reimplemented from jet::Surface3.

◆ isInsideLocal()

bool jet::SurfaceToImplicit3::isInsideLocal ( const Vector3D otherPoint) const
overrideprotectedvirtual

Returns true if otherPoint is inside by given depth the volume defined by the surface in local frame.

Reimplemented from jet::ImplicitSurface3.

◆ isValidGeometry()

bool jet::SurfaceToImplicit3::isValidGeometry ( ) const
overridevirtual

Returns true if the surface is a valid geometry.

Reimplemented from jet::Surface3.

◆ signedDistanceLocal()

double jet::SurfaceToImplicit3::signedDistanceLocal ( const Vector3D otherPoint) const
overrideprotectedvirtual

Returns signed distance from the given point otherPoint in local space.

Implements jet::ImplicitSurface3.

◆ surface()

Surface3Ptr jet::SurfaceToImplicit3::surface ( ) const

Returns the raw surface instance.

◆ updateQueryEngine()

void jet::SurfaceToImplicit3::updateQueryEngine ( )
overridevirtual

Updates internal spatial query engine.

Reimplemented from jet::Surface3.


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