本文整理汇总了C++中Skeleton::draw方法的典型用法代码示例。如果您正苦于以下问题:C++ Skeleton::draw方法的具体用法?C++ Skeleton::draw怎么用?C++ Skeleton::draw使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Skeleton
的用法示例。
在下文中一共展示了Skeleton::draw方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: Draw
void SpinningCube::Draw() {
//glMatrixMode(GL_MODELVIEW);
//glLoadMatrixf(WorldMtx);
//glutWireCube(Size);
/*
Joint test = Joint("Test");
test.setPose(Vector3(45, 45, 0));
test.setTranslation(Vector3(0, 0, 0));
test.setScale(Vector3(1, 1, 1), Vector3(0, 0, 0));
test.calculate();
Joint test1 = Joint("Test2");
test1.setDOFX(0);
test1.setDOFY(0);
test1.setDOFZ(0);
test1.setTranslation(Vector3(0, 1.5, 0));
test1.setScale(Vector3(1, 1, 1), Vector3(0, 0, 0));
test1.calculate();
test.addChild(test1);
Joint *test2 = test1.getParent();
test.draw(WorldMtx.IDENTITY);*/
Skeleton test = Skeleton();
test.Load("test.skel");
test.calculate(WorldMtx.IDENTITY);
test.draw();
}
示例2: draw
void MyWindow::draw()
{
Skeleton* model = mMainMotion.getSkel();
// validate the frame index
int nFrames = mMainMotion.getNumFrames();
int fr = mFrame;
if (fr >= nFrames) fr = nFrames-1;
// update and draw the motion
model->setPose(mMainMotion.getPoseAtFrame(fr));
model->draw(mRI);
Skeleton* model2 = mCompareMotion.getSkel();
if (fr >= mCompareMotion.getNumFrames())
fr = mCompareMotion.getNumFrames() - 1;
model2->setPose(mCompareMotion.getPoseAtFrame(fr));
model2->draw(mRI);
if(mShowMarker) model->drawMarkers(mRI);
if(mShowProgress) yui::drawProgressBar(fr,mMaxFrame);
// display the frame count in 2D text
char buff[64];
sprintf(buff,"%d/%d",mFrame,mMaxFrame);
string frame(buff);
glDisable(GL_LIGHTING);
glColor3f(0.0,0.0,0.0);
yui::drawStringOnScreen(0.02f,0.02f,frame);
glEnable(GL_LIGHTING);
}