JunkBox_Win_Lib 1.5.3
Loading...
Searching...
No Matches
CBaseFrameTool Class Reference

#include <NiJointsTool.h>

Inheritance diagram for CBaseFrameTool:
Collaboration diagram for CBaseFrameTool:

Public Member Functions

 CBaseFrameTool (void)
 
virtual ~CBaseFrameTool (void)
 
virtual unsigned int getFramesNumber (void)
 
virtual int getJointsNumber (void)
 
virtual NiFrameData * getFramesData (void)
 
virtual NiJointData * getJointsData (int frmnum, int fps)
 
virtual int getPlayBackTime (void)
 
virtual int getPlayBackFPS (void)
 
virtual BOOL readFile (FILE *fp)
 
virtual BOOL writeFile (FILE *fp)
 

Protected Member Functions

void init_data (void)
 
void free_data (void)
 
void clear_data (void)
 
void clearJointsData (int jnum)
 
void clearVectorData (int jnum)
 

Protected Attributes

unsigned int frames_num
 
int joints_num
 
int start_time
 
int stop_time
 
int exec_time
 
NiFrameData * framesData
 
NiJointData * jointsData
 
Vector< double > * posVect
 
Quaternion< double > * rotQuat
 

Detailed Description

Definition at line 279 of file NiJointsTool.h.

Constructor & Destructor Documentation

◆ CBaseFrameTool()

CBaseFrameTool ( void )

Definition at line 1078 of file NiJointsTool.cpp.

1079{
1080 init_data();
1081}

References CBaseFrameTool::init_data().

Here is the call graph for this function:

◆ ~CBaseFrameTool()

~CBaseFrameTool ( void )
virtual

Definition at line 1085 of file NiJointsTool.cpp.

1086{
1087 DEBUG_INFO("DESTRUCTOR: CBaseFrameTool\n");
1088
1089 free_data();
1090}

References CBaseFrameTool::free_data().

Here is the call graph for this function:

Member Function Documentation

◆ clear_data()

void clear_data ( void )
protected

◆ clearJointsData()

void clearJointsData ( int jnum)
protected

Definition at line 1140 of file NiJointsTool.cpp.

1141{
1142 if (jointsData!=NULL) {
1143 for (int j=0; j<jnum; j++) {
1144 jointsData[j].index = -1;
1145 jointsData[j].joint = -1;
1146 jointsData[j].vect.init(-1.0);
1147 jointsData[j].quat.init(-1.0);
1148 }
1149 }
1150}
NiJointData * jointsData
Quaternion< double > quat
Vector< double > vect

References NiJointData::index, NiJointData::joint, CBaseFrameTool::jointsData, NiJointData::quat, and NiJointData::vect.

Referenced by CNiBVHTool::getJointsData(), CNiJTextTool::getJointsData(), CNiVMDTool::getJointsData(), CNiBVHTool::readFile(), CNiJTextTool::readFile(), and CNiVMDTool::readFile().

Here is the caller graph for this function:

◆ clearVectorData()

void clearVectorData ( int jnum)
protected

Definition at line 1154 of file NiJointsTool.cpp.

1155{
1156 if (posVect!=NULL && rotQuat!=NULL) {
1157 for (int j=0; j<jnum; j++) {
1158 posVect[j].init(-1.0);
1159 rotQuat[j].init(-1.0);
1160 }
1161 }
1162}
Vector< double > * posVect
Quaternion< double > * rotQuat

References CBaseFrameTool::posVect, and CBaseFrameTool::rotQuat.

Referenced by CNiVMDTool::calcJointRotation(), CNiJTextTool::readFile(), and CNiVMDTool::readFile().

Here is the caller graph for this function:

◆ free_data()

void free_data ( void )
protected

Definition at line 1094 of file NiJointsTool.cpp.

1095{
1097 if (jointsData!=NULL) ::free(jointsData);
1098
1099 if (posVect!=NULL) ::free(posVect);
1100 if (rotQuat!=NULL) ::free(rotQuat);
1101
1102 framesData = NULL;
1103 jointsData = NULL;
1104
1105 posVect = NULL;
1106 rotQuat = NULL;
1107
1108 clear_data();
1109}
NiFrameData * framesData
void freeFramesData(NiFrameData *frmdata, int frm_num)

References CBaseFrameTool::clear_data(), CBaseFrameTool::frames_num, CBaseFrameTool::framesData, jbxwl::freeFramesData(), CBaseFrameTool::jointsData, CBaseFrameTool::posVect, and CBaseFrameTool::rotQuat.

Referenced by CNiBVHTool::clear_data(), CNiVMDTool::clear_data(), CNiJTextTool::free_data(), and CBaseFrameTool::~CBaseFrameTool().

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

◆ getFramesData()

virtual NiFrameData * getFramesData ( void )
inlinevirtual

Reimplemented in CNiVMDTool.

Definition at line 289 of file NiJointsTool.h.

289{ return framesData;}

References CBaseFrameTool::framesData.

Referenced by CNiFileTool::readBVHFile(), and CNiFileTool::readJTextFile().

Here is the caller graph for this function:

◆ getFramesNumber()

virtual unsigned int getFramesNumber ( void )
inlinevirtual

Reimplemented in CNiVMDTool.

Definition at line 286 of file NiJointsTool.h.

286{ return frames_num;}

References CBaseFrameTool::frames_num.

Referenced by CNiFileTool::readBVHFile(), CNiFileTool::readJTextFile(), and CNiFileTool::writeBVHFile().

Here is the caller graph for this function:

◆ getJointsData()

virtual NiJointData * getJointsData ( int frmnum,
int fps )
inlinevirtual

Reimplemented in CNiBVHTool, CNiJTextTool, and CNiVMDTool.

Definition at line 290 of file NiJointsTool.h.

290{ return jointsData;}

References CBaseFrameTool::jointsData.

Referenced by CNiFileTool::getJointsDataSeq(), and CNiFileTool::writeBVHFile().

Here is the caller graph for this function:

◆ getJointsNumber()

virtual int getJointsNumber ( void )
inlinevirtual

Definition at line 287 of file NiJointsTool.h.

287{ return joints_num;}

References CBaseFrameTool::joints_num.

Referenced by CNiFileTool::writeBVHFile().

Here is the caller graph for this function:

◆ getPlayBackFPS()

virtual int getPlayBackFPS ( void )
inlinevirtual

Reimplemented in CNiBVHTool.

Definition at line 293 of file NiJointsTool.h.

293{ return 30;}

Referenced by CNiFileTool::readJTextFile(), and CNiFileTool::readVMDFile().

Here is the caller graph for this function:

◆ getPlayBackTime()

virtual int getPlayBackTime ( void )
inlinevirtual

Definition at line 292 of file NiJointsTool.h.

292{ return exec_time;}

References CBaseFrameTool::exec_time.

Referenced by CNiFileTool::writeBVHFile().

Here is the caller graph for this function:

◆ init_data()

void init_data ( void )
protected

Definition at line 1125 of file NiJointsTool.cpp.

1126{
1127 framesData = NULL;
1128 jointsData = NULL;
1129
1130 posVect = NULL;
1131 rotQuat = NULL;
1132
1133 clear_data();
1134}

References CBaseFrameTool::clear_data(), CBaseFrameTool::framesData, CBaseFrameTool::jointsData, CBaseFrameTool::posVect, and CBaseFrameTool::rotQuat.

Referenced by CBaseFrameTool::CBaseFrameTool().

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

◆ readFile()

virtual BOOL readFile ( FILE * fp)
inlinevirtual

Reimplemented in CNiBVHTool, CNiJTextTool, and CNiVMDTool.

Definition at line 295 of file NiJointsTool.h.

295{ return FALSE;}

◆ writeFile()

virtual BOOL writeFile ( FILE * fp)
inlinevirtual

Reimplemented in CNiBVHTool.

Definition at line 296 of file NiJointsTool.h.

296{ return FALSE;}

Member Data Documentation

◆ exec_time

◆ frames_num

◆ framesData

◆ joints_num

◆ jointsData

◆ posVect

◆ rotQuat

◆ start_time

◆ stop_time

int stop_time
protected

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