Example #1
0
void RrtGuiWindow::sliderSolution( int pos )
{
	if (!solution)
		return;
	Saba::CSpacePathPtr s = solution;
	if (UI.radioButtonSolutionOpti->isChecked() && solutionOptimized)
		s = solutionOptimized;
	float p = (float)pos/1000.0f;
	Eigen::VectorXf iPos;
	s->interpolate(p,iPos);
	robot->setJointValues(rns,iPos);
	redraw();
}
Example #2
0
void IKRRTWindow::sliderSolution(int pos)
{
    if (!solution)
    {
        return;
    }

    Saba::CSpacePathPtr s = solution;

    if (solutionOptimized)
    {
        s = solutionOptimized;
    }

    float p = (float)pos / 1000.0f;
    Eigen::VectorXf iPos;
    s->interpolate(p, iPos);
    robot->setJointValues(rns, iPos);

    redraw();
    //saveScreenshot();
}