本文整理了Java中us.ihmc.commonWalkingControlModules.bipedSupportPolygons.YoPlaneContactState.setFullyConstrained()
方法的一些代码示例,展示了YoPlaneContactState.setFullyConstrained()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。YoPlaneContactState.setFullyConstrained()
方法的具体详情如下:
包路径:us.ihmc.commonWalkingControlModules.bipedSupportPolygons.YoPlaneContactState
类名称:YoPlaneContactState
方法名:setFullyConstrained
暂无
代码示例来源:origin: us.ihmc/CommonWalkingControlModules
public void setPlaneContactStateFullyConstrained(ContactablePlaneBody contactableBody)
{
YoPlaneContactState yoPlaneContactState = yoPlaneContactStates.get(contactableBody);
yoPlaneContactState.setFullyConstrained();
}
代码示例来源:origin: us.ihmc/CommonWalkingControlModules
public void setPlaneContactStateFullyConstrained(ContactablePlaneBody contactableBody, double coefficientOfFriction, FrameVector normalContactVector)
{
YoPlaneContactState yoPlaneContactState = yoPlaneContactStates.get(contactableBody);
yoPlaneContactState.setFullyConstrained();
yoPlaneContactState.setCoefficientOfFriction(coefficientOfFriction);
yoPlaneContactState.setContactNormalVector(normalContactVector);
}
代码示例来源:origin: us.ihmc/ihmc-common-walking-control-modules-test
private void updateContactState(int currentStepCount, double percentageOfPhase)
{
if (inDoubleSupport.getBooleanValue())
{
for (RobotSide side : RobotSide.values)
contactStates.get(side).setFullyConstrained();
}
else
{
RobotSide swingSide = footstepList.get(currentStepCount).getRobotSide();
contactStates.get(swingSide).clear();
contactStates.get(swingSide.getOppositeSide()).setFullyConstrained();
if (currentStepCount > 0)
{
swingFootPose.set(footstepList.get(currentStepCount - 1).getFootstepPose());
}
else
{
swingFootPose.set(initialPose);
swingFootPose.appendTranslation(0.0, swingSide.negateIfRightSide(stepWidth / 2.0), 0.0);
}
FramePose3D endOfSwing = footstepList.get(currentStepCount).getFootstepPose();
swingFootPose.interpolate(endOfSwing, percentageOfPhase);
FootSpoof foot = feet.get(swingSide);
foot.setSoleFrame(swingFootPose);
}
bipedSupportPolygons.updateUsingContactStates(contactStates);
}
代码示例来源:origin: us.ihmc/ihmc-common-walking-control-modules-test
double coefficientOfFriction = contactableFoot.getCoefficientOfFriction();
YoPlaneContactState yoPlaneContactState = new YoPlaneContactState(sidePrefix + "Foot", foot, soleFrame, contactFramePoints, coefficientOfFriction, parentRegistry);
yoPlaneContactState.setFullyConstrained();
contactStates.put(robotSide, yoPlaneContactState);
代码示例来源:origin: us.ihmc/ihmc-common-walking-control-modules-test
@Before
public void setUp()
{
parentRegistry = new YoVariableRegistry("parentRegistryTEST");
for (RobotSide robotSide : RobotSide.values)
{
String sidePrefix = robotSide.getCamelCaseNameForStartOfExpression();
double xToAnkle = 0.0;
double yToAnkle = 0.0;
double zToAnkle = 0.0;
List<Point2D> contactPointsInSoleFrame = new ArrayList<>();
contactPointsInSoleFrame.add(new Point2D(footLengthForControl / 2.0, toeWidthForControl / 2.0));
contactPointsInSoleFrame.add(new Point2D(footLengthForControl / 2.0, -toeWidthForControl / 2.0));
contactPointsInSoleFrame.add(new Point2D(-footLengthForControl / 2.0, -footWidthForControl / 2.0));
contactPointsInSoleFrame.add(new Point2D(-footLengthForControl / 2.0, footWidthForControl / 2.0));
FootSpoof contactableFoot = new FootSpoof(sidePrefix + "Foot", xToAnkle, yToAnkle, zToAnkle, contactPointsInSoleFrame, 0.0);
FramePose3D startingPose = new FramePose3D();
startingPose.setToZero(worldFrame);
startingPose.setY(robotSide.negateIfRightSide(0.20));
contactableFoot.setSoleFrame(startingPose);
contactableFeet.put(robotSide, contactableFoot);
RigidBodyBasics foot = contactableFoot.getRigidBody();
ReferenceFrame soleFrame = contactableFoot.getSoleFrame();
List<FramePoint2D> contactFramePoints = contactableFoot.getContactPoints2d();
double coefficientOfFriction = contactableFoot.getCoefficientOfFriction();
YoPlaneContactState yoPlaneContactState = new YoPlaneContactState(sidePrefix + "Foot", foot, soleFrame, contactFramePoints, coefficientOfFriction, parentRegistry);
yoPlaneContactState.setFullyConstrained();
contactStates.put(robotSide, yoPlaneContactState);
}
}
代码示例来源:origin: us.ihmc/ihmc-common-walking-control-modules-test
YoPlaneContactState yoPlaneContactState = new YoPlaneContactState(sidePrefix + "Foot", foot, soleFrame, contactFramePoints, coefficientOfFriction,
registry);
yoPlaneContactState.setFullyConstrained();
contactStates.put(robotSide, yoPlaneContactState);
代码示例来源:origin: us.ihmc/ihmc-common-walking-control-modules-test
YoPlaneContactState yoPlaneContactState = new YoPlaneContactState(side.getCamelCaseName(), foot.getRigidBody(), foot.getSoleFrame(),
foot.getContactPoints2d(), foot.getCoefficientOfFriction(), testRegistry);
yoPlaneContactState.setFullyConstrained();
contactStates.put(side, yoPlaneContactState);
代码示例来源:origin: us.ihmc/ihmc-common-walking-control-modules-test
contactStates.get(side).setFullyConstrained();
bipedSupportPolygons.updateUsingContactStates(contactStates);
代码示例来源:origin: us.ihmc/ihmc-common-walking-control-modules-test
contactStates.get(side).setFullyConstrained();
bipedSupportPolygons.updateUsingContactStates(contactStates);
代码示例来源:origin: us.ihmc/ihmc-common-walking-control-modules-test
private BipedSupportPolygons setupBipedSupportPolygons(SideDependentList<FootSpoof> contactableFeet, YoVariableRegistry registry)
{
SideDependentList<ReferenceFrame> ankleZUpFrames = new SideDependentList<>();
SideDependentList<YoPlaneContactState> contactStates = new SideDependentList<>();
for (RobotSide robotSide : RobotSide.values)
{
FootSpoof contactableFoot = contactableFeet.get(robotSide);
ReferenceFrame ankleFrame = contactableFoot.getFrameAfterParentJoint();
ankleFrames.put(robotSide, ankleFrame);
ankleZUpFrames.put(robotSide, new ZUpFrame(worldFrame, ankleFrame, robotSide.getCamelCaseNameForStartOfExpression() + "ZUp"));
String sidePrefix = robotSide.getCamelCaseNameForStartOfExpression();
RigidBodyBasics foot = contactableFoot.getRigidBody();
ReferenceFrame soleFrame = contactableFoot.getSoleFrame();
List<FramePoint2D> contactFramePoints = contactableFoot.getContactPoints2d();
double coefficientOfFriction = contactableFoot.getCoefficientOfFriction();
YoPlaneContactState yoPlaneContactState = new YoPlaneContactState(sidePrefix + "Foot", foot, soleFrame, contactFramePoints, coefficientOfFriction, registry);
yoPlaneContactState.setFullyConstrained();
contactStates.put(robotSide, yoPlaneContactState);
}
ReferenceFrame midFeetZUpFrame = new MidFrameZUpFrame("midFeetZupFrame", worldFrame, ankleZUpFrames.get(RobotSide.LEFT), ankleZUpFrames.get(RobotSide.RIGHT));
midFeetZUpFrame.update();
BipedSupportPolygons bipedSupportPolygons = new BipedSupportPolygons(midFeetZUpFrame, ankleZUpFrames, registry, null);
bipedSupportPolygons.updateUsingContactStates(contactStates);
return bipedSupportPolygons;
}
代码示例来源:origin: us.ihmc/ihmc-common-walking-control-modules-test
private BipedSupportPolygons setupBipedSupportPolygons(SideDependentList<FootSpoof> contactableFeet, YoVariableRegistry registry)
{
SideDependentList<ReferenceFrame> ankleZUpFrames = new SideDependentList<>();
SideDependentList<YoPlaneContactState> contactStates = new SideDependentList<>();
for (RobotSide robotSide : RobotSide.values)
{
FootSpoof contactableFoot = contactableFeet.get(robotSide);
ReferenceFrame ankleFrame = contactableFoot.getFrameAfterParentJoint();
ankleFrames.put(robotSide, ankleFrame);
ankleZUpFrames.put(robotSide, new ZUpFrame(worldFrame, ankleFrame, robotSide.getCamelCaseNameForStartOfExpression() + "ZUp"));
String sidePrefix = robotSide.getCamelCaseNameForStartOfExpression();
RigidBodyBasics foot = contactableFoot.getRigidBody();
ReferenceFrame soleFrame = contactableFoot.getSoleFrame();
List<FramePoint2D> contactFramePoints = contactableFoot.getContactPoints2d();
double coefficientOfFriction = contactableFoot.getCoefficientOfFriction();
YoPlaneContactState yoPlaneContactState = new YoPlaneContactState(sidePrefix + "Foot", foot, soleFrame, contactFramePoints, coefficientOfFriction, registry);
yoPlaneContactState.setFullyConstrained();
contactStates.put(robotSide, yoPlaneContactState);
}
ReferenceFrame midFeetZUpFrame = new MidFrameZUpFrame("midFeetZupFrame", worldFrame, ankleZUpFrames.get(RobotSide.LEFT), ankleZUpFrames.get(RobotSide.RIGHT));
midFeetZUpFrame.update();
BipedSupportPolygons bipedSupportPolygons = new BipedSupportPolygons(midFeetZUpFrame, ankleZUpFrames, registry, null);
bipedSupportPolygons.updateUsingContactStates(contactStates);
return bipedSupportPolygons;
}
代码示例来源:origin: us.ihmc/ihmc-common-walking-control-modules-test
YoPlaneContactState contactState = new YoPlaneContactState(footName + "ContactState", foot.getRigidBody(), foot.getSoleFrame(),
foot.getContactPoints2d(), foot.getCoefficientOfFriction(), registry);
contactState.setFullyConstrained();
this.contactStates.put(side, contactState);
内容来源于网络,如有侵权,请联系作者删除!