FCL  0.6.0
Flexible Collision Library
fcl::RSS< S_ > Class Template Reference

A class for rectangle sphere-swept bounding volume. More...

#include <RSS.h>

Public Types

using S = S_
 

Public Member Functions

 RSS ()
 Constructor.
 
bool overlap (const RSS< S > &other) const
 Check collision between two RSS.
 
bool overlap (const RSS< S > &other, RSS< S > &overlap_part) const
 Check collision between two RSS and return the overlap part. For RSS, we return nothing, as the overlap part of two RSSs usually is not a RSS.
 
bool contain (const Vector3< S > &p) const
 Check whether the RSS contains a point. More...
 
RSS< S > & operator+= (const Vector3< S > &p)
 A simple way to merge the RSS and a point, not compact. More...
 
RSS< S > & operator+= (const RSS< S > &other)
 Merge the RSS and another RSS.
 
RSS< S > operator+ (const RSS< S > &other) const
 Return the merged RSS of current RSS and the other one.
 
width () const
 Width of the RSS.
 
height () const
 Height of the RSS.
 
depth () const
 Depth of the RSS.
 
volume () const
 Volume of the RSS.
 
size () const
 Size of the RSS (used in BV_Splitter to order two RSSs)
 
const Vector3< S > center () const
 The RSS center.
 
distance (const RSS< S > &other, Vector3< S > *P=nullptr, Vector3< S > *Q=nullptr) const
 the distance between two RSS; P and Q, if not nullptr, return the nearest points
 

Public Attributes

Matrix3< S > axis
 Orientation of RSS. The axes of the rotation matrix are the principle directions of the box. We assume that the first column corresponds to the axis with the longest box edge, second column corresponds to the shorter one and the third coulumn corresponds to the shortest one.
 
Vector3< S > To
 Origin of the rectangle in RSS.
 
l [2]
 Side lengths of rectangle.
 
r
 Radius of sphere summed with rectangle to form RSS.
 

Detailed Description

template<typename S_>
class fcl::RSS< S_ >

A class for rectangle sphere-swept bounding volume.

Member Function Documentation

template<typename S >
bool fcl::RSS< S >::contain ( const Vector3< S > &  p) const

Check whether the RSS contains a point.

projection is within the rectangle

template<typename S >
RSS< S > & fcl::RSS< S >::operator+= ( const Vector3< S > &  p)

A simple way to merge the RSS and a point, not compact.

Todo:
This function may have some bug.

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