多自由度机械臂模拟-吊绳伸缩

吊绳伸缩

int numChild = groupRope->getNumChildren();
groupRope->removeChildren(0, numChild);

for (int k = 0; k<num; k++)
{
    osg::ref_ptr<osg::Geode> rope1 = CreateCylinder(0, 0, startPosition, 0.1f);
    hookNode = rope1;
    groupRope->addChild(rope1.get());
    startPosition++;
}

 

posted @ 2019-08-29 18:33  西北逍遥  阅读(374)  评论(0编辑  收藏  举报