Package us.ihmc.graphics3DAdapter.graphics

Examples of us.ihmc.graphics3DAdapter.graphics.Graphics3DObject.rotate()


      Link xPendulumArmGimbalLink = new Link("xPendulumArmGimbalLink");
      xPendulumArmGimbalLink.setMassAndRadiiOfGyration(0.05, 0.02, 0.02, 0.02);
      xPendulumArmGimbalLink.setComOffset(-ARM_LENGTH/2.0, 0.0, 0.0);
      Graphics3DObject xPendulumArmGimbalLinkGraphics = new Graphics3DObject();
      xPendulumArmGimbalLinkGraphics.addSphere(0.04, YoAppearance.Red());
      xPendulumArmGimbalLinkGraphics.rotate(-Math.PI/2.0, Axis.Y);
      xPendulumArmGimbalLinkGraphics.addCylinder(ARM_LENGTH, ARM_RADIUS, YoAppearance.Pink());
     
      // Pen:
      xPendulumArmGimbalLinkGraphics.identity();
      xPendulumArmGimbalLinkGraphics.translate(-ARM_LENGTH, 0.0, -PEN_HEIGHT);
View Full Code Here


      Link yPendulumArmGimbalLink = new Link("yPendulumArmGimbalLink");
      yPendulumArmGimbalLink.setMassAndRadiiOfGyration(0.05, 0.02, 0.02, 0.02);
      yPendulumArmGimbalLink.setComOffset(0.0, -ARM_LENGTH/2.0, 0.0);
      Graphics3DObject yPendulumArmGimbalLinkGraphics = new Graphics3DObject();
      yPendulumArmGimbalLinkGraphics.addSphere(0.04, YoAppearance.Red());
      yPendulumArmGimbalLinkGraphics.rotate(Math.PI/2.0, Axis.X);
      yPendulumArmGimbalLinkGraphics.addCylinder(ARM_LENGTH, ARM_RADIUS, YoAppearance.Pink());
      yPendulumArmGimbalLink.setLinkGraphics(yPendulumArmGimbalLinkGraphics);
      return yPendulumArmGimbalLink;
   }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.