gpt4 book ai didi

us.ihmc.yoVariables.variable.YoFramePoseUsingYawPitchRoll.setToNaN()方法的使用及代码示例

转载 作者:知者 更新时间:2024-03-16 07:38:40 27 4
gpt4 key购买 nike

本文整理了Java中us.ihmc.yoVariables.variable.YoFramePoseUsingYawPitchRoll.setToNaN()方法的一些代码示例,展示了YoFramePoseUsingYawPitchRoll.setToNaN()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。YoFramePoseUsingYawPitchRoll.setToNaN()方法的具体详情如下:
包路径:us.ihmc.yoVariables.variable.YoFramePoseUsingYawPitchRoll
类名称:YoFramePoseUsingYawPitchRoll
方法名:setToNaN

YoFramePoseUsingYawPitchRoll.setToNaN介绍

暂无

代码示例

代码示例来源:origin: us.ihmc/ihmc-common-walking-control-modules-test

private void updateNextFootsteps(int stepIndex)
{
 int numberOfStepToUpdate =
    (numberOfFootstepsForTest - stepIndex) < numberOfFootstepsToConsider ? (numberOfFootstepsForTest - stepIndex) : numberOfFootstepsToConsider;
 int nextStepIndex;
 for (nextStepIndex = 0; nextStepIndex < numberOfStepToUpdate; nextStepIndex++)
 {
   nextFootstepPoses.get(nextStepIndex).set(footstepList.get(stepIndex + nextStepIndex).getFootstepPose());
 }
 for (; nextStepIndex < numberOfFootstepsToConsider; nextStepIndex++)
 {
   nextFootstepPoses.get(nextStepIndex).setToNaN();
 }
}

代码示例来源:origin: us.ihmc/ihmc-footstep-planning-test

private void createCandidateFootstep(String name, int index, YoVariableRegistry registry, YoGraphicsListRegistry yoGraphicsListRegistry)
{
 YoFramePoseUsingYawPitchRoll footstepYoFramePose = new YoFramePoseUsingYawPitchRoll(name + index + "FramePose", ReferenceFrame.getWorldFrame(), registry);
 footstepYoFramePose.setToNaN();
 YoGraphicPolygon footstepYoGraphicPolygon = new YoGraphicPolygon(name + index + "YoGraphicPolygon", footstepYoFramePose,
                                  defaultFootPolygon.getNumberOfVertices(), registry, 1.0, YoAppearance.Red());
 footstepYoGraphicPolygon.updateConvexPolygon2d(defaultFootPolygon);
 candidateFootstepPolygons.put(index, footstepYoGraphicPolygon);
 yoGraphicsListRegistry.registerYoGraphic(getClass().getSimpleName(), footstepYoGraphicPolygon);
}

代码示例来源:origin: us.ihmc/ihmc-common-walking-control-modules-test

private void updateCurrentFootsteps()
{
 for (RobotSide side : RobotSide.values)
 {
   YoFramePoseUsingYawPitchRoll footPose = currentFootLocations.get(side);
   if (contactStates.get(side).inContact())
   {
    footPose.setFromReferenceFrame(feet.get(side).getSoleFrame());
   }
   else
   {
    footPose.setToNaN();
   }
 }
}

代码示例来源:origin: us.ihmc/ihmc-footstep-planning-test

public Controller(YoGraphicsListRegistry graphicsListRegistry)
{
  for (int i = 0; i < numberOfPoints; i++)
  {
   YoFramePoint3D yoPoint = new YoFramePoint3D("Position" + i, ReferenceFrame.getWorldFrame(), registry);
   YoGraphicPosition position = new YoGraphicPosition("Position" + i, yoPoint, 0.02, YoAppearance.Blue());
   points.add(yoPoint);
   graphicsListRegistry.registerYoGraphic("BodyPath", position);
  }
  YoFrameConvexPolygon2D yoDefaultFootPolygon = new YoFrameConvexPolygon2D("DefaultFootPolygon", ReferenceFrame.getWorldFrame(), 4, registry);
  yoDefaultFootPolygon.set(PlannerTools.createDefaultFootPolygon());
  for (RobotSide side : RobotSide.values)
  {
   AppearanceDefinition appearance = side == RobotSide.RIGHT ? YoAppearance.Green() : YoAppearance.Red();
   ArrayList<YoFramePoseUsingYawPitchRoll> poses = new ArrayList<>();
   for (int i = 0; i < stepsPerSide; i++)
   {
     YoFramePoseUsingYawPitchRoll yoFootstepPose = new YoFramePoseUsingYawPitchRoll("footPose" + side.getCamelCaseName() + i, ReferenceFrame.getWorldFrame(), registry);
     YoGraphicPolygon footstepViz = new YoGraphicPolygon("footstep" + side.getCamelCaseName() + i, yoDefaultFootPolygon, yoFootstepPose, 1.0,
                               appearance);
     poses.add(yoFootstepPose);
     yoFootstepPose.setToNaN();
     graphicsListRegistry.registerYoGraphic("viz", footstepViz);
   }
   yoSteps.put(side, poses);
  }
  planner.setTimeout(1.0);
}

代码示例来源:origin: us.ihmc/ihmc-footstep-planning-test

public PolygonSnapperVisualizer(ConvexPolygon2D snappingPolygonShape)
{
 Robot robot = new Robot("Robot");
 scs = new SimulationConstructionSet(robot);
 scs.setDT(0.1, 1);
 polygonToSnap = new YoFrameConvexPolygon2D("polygonToSnap", ReferenceFrame.getWorldFrame(), 4, registry);
 snappedPolygon = new YoFrameConvexPolygon2D("snappedPolygon", ReferenceFrame.getWorldFrame(), 4, registry);
 polygonToSnap.set(snappingPolygonShape);
 snappedPolygon.set(snappingPolygonShape);
 polygonToSnapPose = new YoFramePoseUsingYawPitchRoll("polygonToSnapPose", ReferenceFrame.getWorldFrame(), registry);
 snappedPolygonPose = new YoFramePoseUsingYawPitchRoll("snappedPolygonPose", ReferenceFrame.getWorldFrame(), registry);
 polygonToSnapPose.setToNaN();
 snappedPolygonPose.setToNaN();
 polygonToSnapViz = new YoGraphicPolygon("polygonToSnapViz", polygonToSnap, polygonToSnapPose, 1.0, YoAppearance.Green());
 snappedPolygonViz = new YoGraphicPolygon("snappedPolygonViz", polygonToSnap, snappedPolygonPose, 1.0, YoAppearance.Red());
 polygonToSnapViz.update();
 snappedPolygonViz.update();
 scs.addYoGraphic(polygonToSnapViz);
 scs.addYoGraphic(snappedPolygonViz);
 scs.addYoVariableRegistry(registry);
 scs.setGroundVisible(false);
 scs.startOnAThread();
}

代码示例来源:origin: us.ihmc/ihmc-footstep-planning-test

String sideName = robotSide.getCamelCaseName();
   YoFramePoseUsingYawPitchRoll yoPose = new YoFramePoseUsingYawPitchRoll("footPose" + sideName + i, worldFrame, registry);
   yoPose.setToNaN();
   solePosesForVisualization.get(robotSide).add(yoPose);
   YoGraphicPolygon footstepViz = new YoGraphicPolygon("footstep" + sideName + i, defaultPolygon, yoPose, 1.0, appearance);
startStep.setToNaN();
YoGraphicPolygon stanceViz = new YoGraphicPolygon("startFootPose", defaultPolygon, startStep, 1.0, YoAppearance.Black());
graphicsListRegistry.registerYoGraphic("viz", stanceViz);
 step.setToNaN();
 stepPosesTaken.add(step);
 YoGraphicPolygon polygon = new YoGraphicPolygon("step" + i, defaultPolygon, step, 1.0, YoAppearance.Gray());
 pose.setToNaN();
 visiblePolygons.add(polygon);
 visiblePolygonPoses.add(pose);
   visiblePolygonPoses.get(polygonIdx).setToNaN();
    solePosesForVisualization.get(robotSide).get(hideIdx).setToNaN();

代码示例来源:origin: us.ihmc/ihmc-path-planning-test

pose.setToNaN();
visiblePolygons.add(polygon);
visiblePolygonPoses.add(pose);
  visiblePolygonPoses.get(polygonIdx).setToNaN();

代码示例来源:origin: us.ihmc/ihmc-footstep-planning-test

yoSteps.get(robotSide).get(i).setToNaN();
for (int i = sideCount.intValue(); i < stepsPerSide; i++)
  yoSteps.get(robotSide).get(i).setToNaN();

代码示例来源:origin: us.ihmc/ihmc-footstep-planning-test

snappedPolygonPose.setToNaN();
snappedPolygonViz.update();
return;

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com