Choreonoid  1.5
Classes | Public Types | Public Member Functions | List of all members
cnoid::MeshGenerator Class Reference

#include <MeshGenerator.h>

Classes

struct  Extrusion
 

Public Types

typedef std::vector< Vector2, Eigen::aligned_allocator< Vector2 > > Vector2Array
 
typedef std::vector< Vector3, Eigen::aligned_allocator< Vector3 > > Vector3Array
 
typedef std::vector< AngleAxis, Eigen::aligned_allocator< AngleAxis > > AngleAxisArray
 

Public Member Functions

 MeshGenerator ()
 
 MeshGenerator (const MeshGenerator &org)
 
 ~MeshGenerator ()
 
void setDivisionNumber (int n)
 
int divisionNumber () const
 
void enableNormalGeneration (bool on)
 
bool isNormalGenerationEnabled () const
 
SgMesh * generateBox (Vector3 size)
 
SgMesh * generateSphere (double radius)
 
SgMesh * generateCylinder (double radius, double height, bool bottom=true, bool top=true, bool side=true)
 
SgMesh * generateCone (double radius, double height, bool bottom=true, bool side=true)
 
SgMesh * generateDisc (double radius, double innerRadius)
 
SgMesh * generateArrow (double length, double width, double coneLengthRatio=0.1, double coneWidthRatio=2.5)
 
SgMesh * generateTorus (double radius, double crossSectionRadius)
 
SgMesh * generateExtrusion (const Extrusion &extrusion)
 
SgLineSet * generateExtrusionLineSet (const Extrusion &extrusion, SgMesh *mesh)
 

Member Typedef Documentation

◆ AngleAxisArray

typedef std::vector<AngleAxis, Eigen::aligned_allocator<AngleAxis> > cnoid::MeshGenerator::AngleAxisArray

◆ Vector2Array

typedef std::vector<Vector2, Eigen::aligned_allocator<Vector2> > cnoid::MeshGenerator::Vector2Array

◆ Vector3Array

typedef std::vector<Vector3, Eigen::aligned_allocator<Vector3> > cnoid::MeshGenerator::Vector3Array

Constructor & Destructor Documentation

◆ MeshGenerator() [1/2]

MeshGenerator::MeshGenerator ( )

◆ MeshGenerator() [2/2]

cnoid::MeshGenerator::MeshGenerator ( const MeshGenerator &  org)

◆ ~MeshGenerator()

MeshGenerator::~MeshGenerator ( )

Member Function Documentation

◆ divisionNumber()

int MeshGenerator::divisionNumber ( ) const

◆ enableNormalGeneration()

void MeshGenerator::enableNormalGeneration ( bool  on)

◆ generateArrow()

SgMesh * MeshGenerator::generateArrow ( double  length,
double  width,
double  coneLengthRatio = 0.1,
double  coneWidthRatio = 2.5 
)

◆ generateBox()

SgMesh * MeshGenerator::generateBox ( Vector3  size)

◆ generateCone()

SgMesh * MeshGenerator::generateCone ( double  radius,
double  height,
bool  bottom = true,
bool  side = true 
)

◆ generateCylinder()

SgMesh * MeshGenerator::generateCylinder ( double  radius,
double  height,
bool  bottom = true,
bool  top = true,
bool  side = true 
)

◆ generateDisc()

SgMesh * MeshGenerator::generateDisc ( double  radius,
double  innerRadius 
)

◆ generateExtrusion()

SgMesh * MeshGenerator::generateExtrusion ( const Extrusion &  extrusion)

◆ generateExtrusionLineSet()

SgLineSet * MeshGenerator::generateExtrusionLineSet ( const Extrusion &  extrusion,
SgMesh *  mesh 
)

◆ generateSphere()

SgMesh * MeshGenerator::generateSphere ( double  radius)
Todo:
set normals directly without using the following function

◆ generateTorus()

SgMesh * MeshGenerator::generateTorus ( double  radius,
double  crossSectionRadius 
)

◆ isNormalGenerationEnabled()

bool MeshGenerator::isNormalGenerationEnabled ( ) const

◆ setDivisionNumber()

void MeshGenerator::setDivisionNumber ( int  n)

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