Torus Class Reference

#include <VisionX/components/pointcloud_processor/EfficientRANSACPrimitiveExtractor/EfficientRANSAC/Torus.h>

Public Types

enum  { RequiredSamples = 4 }
 

Public Member Functions

float AppleCutOffAngle () const
 
const Vec3fAxisDirection () const
 
const Vec3fCenter () const
 
float Distance (const Vec3f &p) const
 
float DistanceAndNormal (const Vec3f &p, Vec3f *n) const
 
bool Fit (const PointCloud &pc, MiscLib::Vector< size_t >::const_iterator begin, MiscLib::Vector< size_t >::const_iterator end)
 
bool Init (bool binary, std::istream *i)
 
bool Init (const MiscLib::Vector< Vec3f > &samples)
 
void Init (FILE *i)
 
void Init (float *array)
 
bool InitAverage (const MiscLib::Vector< Vec3f > &samples)
 
bool IsAppleShaped () const
 
bool LeastSquaresFit (const PointCloud &pc, MiscLib::Vector< size_t >::const_iterator begin, MiscLib::Vector< size_t >::const_iterator end)
 
const float MajorRadius () const
 
const float MinorRadius () const
 
void Normal (const Vec3f &p, Vec3f *n) const
 
void Project (const Vec3f &p, Vec3f *pp) const
 
void Serialize (bool binary, std::ostream *o) const
 
void Serialize (FILE *o) const
 
void Serialize (float *array) const
 
float SignedDistance (const Vec3f &p) const
 
float SignedDistanceAndNormal (const Vec3f &p, Vec3f *n) const
 
void Transform (float scale, const Vec3f &translate)
 

Static Public Member Functions

static size_t SerializedFloatSize ()
 
static size_t SerializedSize ()
 

Detailed Description

Definition at line 18 of file Torus.h.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
Enumerator
RequiredSamples 

Definition at line 21 of file Torus.h.

Member Function Documentation

◆ AppleCutOffAngle()

float AppleCutOffAngle ( ) const
inline

Definition at line 63 of file Torus.h.

+ Here is the caller graph for this function:

◆ AxisDirection()

const Vec3f& AxisDirection ( ) const
inline

Definition at line 38 of file Torus.h.

+ Here is the caller graph for this function:

◆ Center()

const Vec3f& Center ( ) const
inline

Definition at line 34 of file Torus.h.

+ Here is the caller graph for this function:

◆ Distance()

float Distance ( const Vec3f p) const
inline

Definition at line 87 of file Torus.h.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ DistanceAndNormal()

float DistanceAndNormal ( const Vec3f p,
Vec3f n 
) const
inline

Definition at line 141 of file Torus.h.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ Fit()

bool Fit ( const PointCloud pc,
MiscLib::Vector< size_t >::const_iterator  begin,
MiscLib::Vector< size_t >::const_iterator  end 
)
inline

Definition at line 53 of file Torus.h.

◆ Init() [1/4]

bool Init ( bool  binary,
std::istream *  i 
)

Definition at line 320 of file Torus.cpp.

◆ Init() [2/4]

bool Init ( const MiscLib::Vector< Vec3f > &  samples)

Definition at line 64 of file Torus.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ Init() [3/4]

void Init ( FILE *  i)

Definition at line 347 of file Torus.cpp.

◆ Init() [4/4]

void Init ( float array)

Definition at line 359 of file Torus.cpp.

◆ InitAverage()

bool InitAverage ( const MiscLib::Vector< Vec3f > &  samples)

Definition at line 181 of file Torus.cpp.

+ Here is the call graph for this function:

◆ IsAppleShaped()

bool IsAppleShaped ( ) const
inline

Definition at line 59 of file Torus.h.

+ Here is the caller graph for this function:

◆ LeastSquaresFit()

bool LeastSquaresFit ( const PointCloud pc,
MiscLib::Vector< size_t >::const_iterator  begin,
MiscLib::Vector< size_t >::const_iterator  end 
)

Definition at line 539 of file Torus.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ MajorRadius()

const float MajorRadius ( ) const
inline

Definition at line 46 of file Torus.h.

+ Here is the caller graph for this function:

◆ MinorRadius()

const float MinorRadius ( ) const
inline

Definition at line 42 of file Torus.h.

+ Here is the caller graph for this function:

◆ Normal()

void Normal ( const Vec3f p,
Vec3f n 
) const
inline

Definition at line 115 of file Torus.h.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ Project()

void Project ( const Vec3f p,
Vec3f pp 
) const
inline

Definition at line 243 of file Torus.h.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ Serialize() [1/3]

void Serialize ( bool  binary,
std::ostream *  o 
) const

Definition at line 575 of file Torus.cpp.

+ Here is the caller graph for this function:

◆ Serialize() [2/3]

void Serialize ( FILE *  o) const

Definition at line 600 of file Torus.cpp.

◆ Serialize() [3/3]

void Serialize ( float array) const

Definition at line 613 of file Torus.cpp.

◆ SerializedFloatSize()

size_t SerializedFloatSize ( )
static

Definition at line 608 of file Torus.cpp.

◆ SerializedSize()

size_t SerializedSize ( )
static

Definition at line 592 of file Torus.cpp.

+ Here is the caller graph for this function:

◆ SignedDistance()

float SignedDistance ( const Vec3f p) const
inline

Definition at line 178 of file Torus.h.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ SignedDistanceAndNormal()

float SignedDistanceAndNormal ( const Vec3f p,
Vec3f n 
) const
inline

Definition at line 206 of file Torus.h.

+ Here is the call graph for this function:

◆ Transform()

void Transform ( float  scale,
const Vec3f translate 
)

Definition at line 372 of file Torus.cpp.

+ Here is the caller graph for this function:

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