Choreonoid  1.8
Classes | Public Types | Public Member Functions | Static Public Member Functions | List of all members
cnoid::StdSceneReader Class Reference

#include <StdSceneReader.h>

Classes

struct  Resource
 

Public Types

enum  AngleUnit { DEGREE, RADIAN }
 
typedef std::function< std::string(const std::string &path, std::ostream &os)> UriSchemeHandler
 

Public Member Functions

 StdSceneReader ()
 
 ~StdSceneReader ()
 
void setMessageSink (std::ostream &os)
 
void setDefaultDivisionNumber (int n)
 
int defaultDivisionNumber () const
 
void setBaseDirectory (const std::string &directory)
 
void setFilePathVariableProcessor (FilePathVariableProcessor *processor)
 
std::string baseDirectory () const
 
stdx::filesystem::path baseDirPath () const
 
void setYAMLReader (YAMLReader *reader)
 
void clear ()
 
void readHeader (Mapping *info)
 
void readHeader (Mapping *info, double formatVersion)
 
void setAngleUnit (AngleUnit unit)
 
bool isDegreeMode () const
 
double toRadian (double angle) const
 
float toRadian (float angle) const
 
bool readAngle (const Mapping *info, const char *key, double &angle) const
 
bool readAngle (const Mapping *info, std::initializer_list< const char * > keys, double &angle) const
 
bool readAngle (const Mapping *info, const char *key, float &angle) const
 
bool readAngle (const Mapping *info, std::initializer_list< const char * > keys, float &angle) const
 
bool readRotation (const Mapping *info, Matrix3 &out_R) const
 
bool readRotation (const Mapping *info, const char *key, Matrix3 &out_R) const
 
bool readRotation (const Mapping *info, std::initializer_list< const char * > keys, Matrix3 &out_R) const
 
bool extractRotation (Mapping *info, Matrix3 &out_R) const
 
bool readTranslation (const Mapping *info, Vector3 &out_p) const
 
bool readTranslation (const Mapping *info, const char *key, Vector3 &out_p) const
 
bool extractTranslation (Mapping *info, Vector3 &out_p) const
 
SgNodereadNode (Mapping *info)
 
SgNodereadNode (Mapping *info, const std::string &type)
 
SgNodereadScene (ValueNode *scene)
 
Resource readResourceNode (Mapping *info)
 
bool readAngle (const Mapping &info, const char *key, double &angle) const
 
bool readAngle (const Mapping &info, const char *key, float &angle) const
 
bool readRotation (const Mapping &info, Matrix3 &out_R) const
 
bool readRotation (const Mapping &info, const char *key, Matrix3 &out_R) const
 
bool extractRotation (Mapping &info, Matrix3 &out_R) const
 
bool readTranslation (const Mapping &info, Vector3 &out_p) const
 
bool readTranslation (const Mapping &info, const char *key, Vector3 &out_p) const
 
bool extractTranslation (Mapping &info, Vector3 &out_p) const
 
SgNodereadNode (Mapping &info)
 
SgNodereadNode (Mapping &info, const std::string &type)
 
Resource readResourceNode (Mapping &info)
 

Static Public Member Functions

static void registerUriSchemeHandler (const std::string &scheme, UriSchemeHandler handler)
 

Member Typedef Documentation

◆ UriSchemeHandler

typedef std::function<std::string(const std::string& path, std::ostream& os)> cnoid::StdSceneReader::UriSchemeHandler

Member Enumeration Documentation

◆ AngleUnit

Enumerator
DEGREE 
RADIAN 

Constructor & Destructor Documentation

◆ StdSceneReader()

StdSceneReader::StdSceneReader ( )

◆ ~StdSceneReader()

StdSceneReader::~StdSceneReader ( )

Member Function Documentation

◆ baseDirectory()

std::string StdSceneReader::baseDirectory ( ) const

◆ baseDirPath()

stdx::filesystem::path StdSceneReader::baseDirPath ( ) const

◆ clear()

void StdSceneReader::clear ( )

◆ defaultDivisionNumber()

int StdSceneReader::defaultDivisionNumber ( ) const

◆ extractRotation() [1/2]

bool StdSceneReader::extractRotation ( Mapping info,
Matrix3 out_R 
) const

◆ extractRotation() [2/2]

bool StdSceneReader::extractRotation ( Mapping info,
Matrix3 out_R 
) const

◆ extractTranslation() [1/2]

bool StdSceneReader::extractTranslation ( Mapping info,
Vector3 out_p 
) const

◆ extractTranslation() [2/2]

bool StdSceneReader::extractTranslation ( Mapping info,
Vector3 out_p 
) const

◆ isDegreeMode()

bool cnoid::StdSceneReader::isDegreeMode ( ) const
inline

◆ readAngle() [1/6]

bool StdSceneReader::readAngle ( const Mapping info,
const char *  key,
double &  angle 
) const

◆ readAngle() [2/6]

bool StdSceneReader::readAngle ( const Mapping info,
const char *  key,
float &  angle 
) const

◆ readAngle() [3/6]

bool StdSceneReader::readAngle ( const Mapping info,
const char *  key,
double &  angle 
) const

◆ readAngle() [4/6]

bool StdSceneReader::readAngle ( const Mapping info,
const char *  key,
float &  angle 
) const

◆ readAngle() [5/6]

bool StdSceneReader::readAngle ( const Mapping info,
std::initializer_list< const char * >  keys,
double &  angle 
) const

◆ readAngle() [6/6]

bool StdSceneReader::readAngle ( const Mapping info,
std::initializer_list< const char * >  keys,
float &  angle 
) const

◆ readHeader() [1/2]

void StdSceneReader::readHeader ( Mapping info)

◆ readHeader() [2/2]

void StdSceneReader::readHeader ( Mapping info,
double  formatVersion 
)

◆ readNode() [1/4]

SgNode * StdSceneReader::readNode ( Mapping info)

◆ readNode() [2/4]

SgNode * StdSceneReader::readNode ( Mapping info,
const std::string &  type 
)

◆ readNode() [3/4]

SgNode * StdSceneReader::readNode ( Mapping info)

◆ readNode() [4/4]

SgNode * StdSceneReader::readNode ( Mapping info,
const std::string &  type 
)

◆ readResourceNode() [1/2]

StdSceneReader::Resource StdSceneReader::readResourceNode ( Mapping info)

◆ readResourceNode() [2/2]

StdSceneReader::Resource StdSceneReader::readResourceNode ( Mapping info)

◆ readRotation() [1/5]

bool cnoid::StdSceneReader::readRotation ( const Mapping info,
const char *  key,
Matrix3 out_R 
) const

◆ readRotation() [2/5]

bool cnoid::StdSceneReader::readRotation ( const Mapping info,
Matrix3 out_R 
) const

◆ readRotation() [3/5]

bool StdSceneReader::readRotation ( const Mapping info,
const char *  key,
Matrix3 out_R 
) const

◆ readRotation() [4/5]

bool StdSceneReader::readRotation ( const Mapping info,
Matrix3 out_R 
) const

◆ readRotation() [5/5]

bool StdSceneReader::readRotation ( const Mapping info,
std::initializer_list< const char * >  keys,
Matrix3 out_R 
) const

◆ readScene()

SgNode * StdSceneReader::readScene ( ValueNode scene)

◆ readTranslation() [1/4]

bool StdSceneReader::readTranslation ( const Mapping info,
const char *  key,
Vector3 out_p 
) const

◆ readTranslation() [2/4]

bool StdSceneReader::readTranslation ( const Mapping info,
Vector3 out_p 
) const

◆ readTranslation() [3/4]

bool StdSceneReader::readTranslation ( const Mapping info,
const char *  key,
Vector3 out_p 
) const

◆ readTranslation() [4/4]

bool StdSceneReader::readTranslation ( const Mapping info,
Vector3 out_p 
) const

◆ registerUriSchemeHandler()

void StdSceneReader::registerUriSchemeHandler ( const std::string &  scheme,
UriSchemeHandler  handler 
)
static

◆ setAngleUnit()

void StdSceneReader::setAngleUnit ( AngleUnit  unit)

◆ setBaseDirectory()

void StdSceneReader::setBaseDirectory ( const std::string &  directory)

◆ setDefaultDivisionNumber()

void StdSceneReader::setDefaultDivisionNumber ( int  n)

◆ setFilePathVariableProcessor()

void StdSceneReader::setFilePathVariableProcessor ( FilePathVariableProcessor processor)

◆ setMessageSink()

void StdSceneReader::setMessageSink ( std::ostream &  os)

◆ setYAMLReader()

void StdSceneReader::setYAMLReader ( YAMLReader reader)

◆ toRadian() [1/2]

double cnoid::StdSceneReader::toRadian ( double  angle) const
inline

◆ toRadian() [2/2]

float cnoid::StdSceneReader::toRadian ( float  angle) const
inline

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