private void addSupportBaseControlGraphics(YoGraphicsListRegistry yoGraphicsListRegistry) { addSupportBaseGraphics(yoGraphicsListRegistry,baseControlPoints,baseControlPointsList,baseControlLinesList,"baseControl",YoAppearance.Green()); }
private void addSupportBaseControlGraphics(YoGraphicsListRegistry yoGraphicsListRegistry) { addSupportBaseGraphics(yoGraphicsListRegistry,baseControlPoints,baseControlPointsList,baseControlLinesList,"baseControl",YoAppearance.Green()); }
public static Graphics3DObject createSphereObject(double radius) { Graphics3DObject sphere = new Graphics3DObject(); sphere.addSphere(radius, YoAppearance.Green()); return sphere; }
public static Graphics3DObject createSphereObject(double radius) { Graphics3DObject sphere = new Graphics3DObject(); sphere.addSphere(radius, YoAppearance.Green()); return sphere; }
public static Graphics3DObject createSphereObject(double radius) { Graphics3DObject sphere = new Graphics3DObject(); sphere.addSphere(radius, YoAppearance.Green()); return sphere; }
public static Graphics3DObject createSphereObject(double radius) { Graphics3DObject sphere = new Graphics3DObject(); sphere.addSphere(radius, YoAppearance.Green()); return sphere; }
private CombinedTerrainObject3D setupWallSlightlyInFront(String name) { CombinedTerrainObject3D combinedTerrainObject = new CombinedTerrainObject3D(name); double xStart = 0.6; AppearanceDefinition appearance = YoAppearance.Green(); appearance.setTransparency(0.25); combinedTerrainObject.addBox(xStart, wallMinY, xStart + 0.1, wallMaxY, 0.5, 1.8, appearance); return combinedTerrainObject; }
private void addIntertialEllipsoidsToVisualizer(FloatingRootJointRobot valkyrieRobot) { ArrayList<Joint> joints = new ArrayList<>(); joints.add(valkyrieRobot.getRootJoint()); HashSet<Link> links = getAllLinks(joints, new HashSet<Link>()); for (Link l : links) { AppearanceDefinition appearance = YoAppearance.Green(); appearance.setTransparency(0.6); l.addEllipsoidFromMassProperties(appearance); l.addCoordinateSystemToCOM(0.5); // l.addBoxFromMassProperties(appearance); } }
private CombinedTerrainObject3D setupStepInFront(String name, double stepHeight) { CombinedTerrainObject3D combinedTerrainObject = new CombinedTerrainObject3D(name); double xStart = 0.3; double stepWidth = 0.5; AppearanceDefinition appearance = YoAppearance.Green(); appearance.setTransparency(0.25); combinedTerrainObject.addBox(xStart, -stepWidth/2.0, xStart + stepWidth, stepWidth/2.0, 0.0, stepHeight, appearance); return combinedTerrainObject; }
private CombinedTerrainObject3D setupWall(String name) { CombinedTerrainObject3D combinedTerrainObject = new CombinedTerrainObject3D(name); double xStart = wallDistance; double wallMinY = -1000; double wallMaxY = 1000; double wallZStart = -1000; double wallZEnd = 1000; AppearanceDefinition appearance = YoAppearance.Green(); appearance.setTransparency(0.25); combinedTerrainObject.addBox(xStart, wallMinY, xStart + 0.1, wallMaxY, wallZStart, wallZEnd, appearance); return combinedTerrainObject; }
public void createVisualizerForConstantCMPs(YoGraphicsList yoGraphicsList, ArtifactList artifactList) { for (int i = 0; i < entryCMPs.size(); i++) { YoGraphicPosition entryCMPViz = new YoGraphicPosition("Entry CMP" + i, entryCMPsInWorldFrameReadOnly.get(i), CMP_POINT_SIZE, YoAppearance.Green(), GraphicType.SOLID_BALL); yoGraphicsList.add(entryCMPViz); artifactList.add(entryCMPViz.createArtifact()); } for (int i = 0; i < exitCMPs.size(); i++) { YoGraphicPosition exitCMPViz = new YoGraphicPosition("Exit CMP" + i, exitCMPsInWorldFrameReadOnly.get(i), CMP_POINT_SIZE, YoAppearance.Green(), GraphicType.BALL); yoGraphicsList.add(exitCMPViz); artifactList.add(exitCMPViz.createArtifact()); } }
public PlanarRegionBaseOfCliffAvoider(YoVariableRegistry parentRegistry, YoGraphicsListRegistry yoGraphicsListRegistry) { parentRegistry.addChild(registry); if (yoGraphicsListRegistry == null) { visualize = false; } if (visualize) { beforeAdjustmentPosition = new YoGraphicPosition("beforeAdjustmentPosition", "", registry, 0.02, YoAppearance.Red()); afterAdjustmentPosition = new YoGraphicPosition("afterAdjustmentPosition", "", registry, 0.02, YoAppearance.Green()); yoGraphicsListRegistry.registerYoGraphic(getClass().getSimpleName(), beforeAdjustmentPosition); yoGraphicsListRegistry.registerYoGraphic(getClass().getSimpleName(), afterAdjustmentPosition); } else { beforeAdjustmentPosition = null; afterAdjustmentPosition = null; } }
public static Graphics3DNode setupStaticBox(Graphics3DAdapter graphics3DAdapter) { Graphics3DNode box = new Graphics3DNode("box", Graphics3DNodeType.JOINT); Graphics3DObject boxGraphics = new Graphics3DObject(); boxGraphics.addCube(1.0, 1.0, 1.0, YoAppearance.Green()); box.setGraphicsObject(boxGraphics); graphics3DAdapter.addRootNode(box); return box; }
public static Graphics3DNode setupStaticBox(Graphics3DAdapter graphics3DAdapter) { Graphics3DNode box = new Graphics3DNode("box", Graphics3DNodeType.JOINT); Graphics3DObject boxGraphics = new Graphics3DObject(); boxGraphics.addCube(1.0, 1.0, 1.0, YoAppearance.Green()); box.setGraphicsObject(boxGraphics); graphics3DAdapter.addRootNode(box); return box; }
public static AppearanceDefinition[] getStandardRoyGBivRainbow() { AppearanceDefinition[] rainbow = new AppearanceDefinition[] { YoAppearance.Red(), YoAppearance.OrangeRed(), YoAppearance.Yellow(), YoAppearance.Green(), YoAppearance.Blue(), YoAppearance.Indigo(), YoAppearance.Purple()}; return rainbow; }
public static AppearanceDefinition[] getStandardRoyGBivRainbow() { AppearanceDefinition[] rainbow = new AppearanceDefinition[] { YoAppearance.Red(), YoAppearance.OrangeRed(), YoAppearance.Yellow(), YoAppearance.Green(), YoAppearance.Blue(), YoAppearance.Indigo(), YoAppearance.Purple()}; return rainbow; }
private static Link thigh() { AppearanceDefinition thighApp = YoAppearance.Green(); Link ret = new Link("thigh"); ret.setMass(THIGH_MASS); // 2.35); ret.setMomentOfInertia(0.0437, 0.0437, 0.0054); ret.setComOffset(0.0, 0.0, -THIGH_LENGTH / 2.0); Graphics3DObject linkGraphics = new Graphics3DObject(); linkGraphics.addCylinder(THIGH_LENGTH, THIGH_RAD, thighApp); ret.setLinkGraphics(linkGraphics); return ret; }
private void addSupportBaseGraphics(YoGraphicsListRegistry yoGraphicsListRegistry,YoFramePoint3D[] basePoints, ArrayList<YoGraphic> basePointsList, ArrayList<YoGraphic> linesList, String namePrefix,AppearanceDefinition appearance) { AppearanceDefinition[] colors = { YoAppearance.Red(), YoAppearance.Green(), YoAppearance.Blue(), YoAppearance.Yellow() }; YoGraphicsList yoGraphicsList = new YoGraphicsList(namePrefix + "Points"); for (int i = 0; i < basePoints.length; i++) { YoGraphicPosition baseControlPointViz = new YoGraphicPosition(namePrefix + "Point" + i, basePoints[i], 0.01, colors[i]); yoGraphicsList.add(baseControlPointViz); basePointsList.add(baseControlPointViz); for (int j = i + 1; j < basePoints.length; j++) { YoGraphicLineSegment yoGraphicLineSegment = new YoGraphicLineSegment(namePrefix + "SupportLine", basePoints[i], basePoints[j], 1.0, appearance, false); yoGraphicsList.add(yoGraphicLineSegment); linesList.add(yoGraphicLineSegment); } } if (yoGraphicsListRegistry != null) yoGraphicsListRegistry.registerYoGraphicsList(yoGraphicsList); yoGraphicsList.hideYoGraphics(); }
private void addSupportBaseGraphics(YoGraphicsListRegistry yoGraphicsListRegistry,YoFramePoint[] basePoints, ArrayList<YoGraphic> basePointsList, ArrayList<YoGraphic> linesList, String namePrefix,AppearanceDefinition appearance) { AppearanceDefinition[] colors = { YoAppearance.Red(), YoAppearance.Green(), YoAppearance.Blue(), YoAppearance.Yellow() }; YoGraphicsList yoGraphicsList = new YoGraphicsList(namePrefix + "Points"); for (int i = 0; i < basePoints.length; i++) { YoGraphicPosition baseControlPointViz = new YoGraphicPosition(namePrefix + "Point" + i, basePoints[i], 0.01, colors[i]); yoGraphicsList.add(baseControlPointViz); basePointsList.add(baseControlPointViz); for (int j = i + 1; j < basePoints.length; j++) { YoGraphicLineSegment dynamicGraphicLineSegment = new YoGraphicLineSegment(namePrefix + "SupportLine", basePoints[i], basePoints[j], 1.0, appearance, false); yoGraphicsList.add(dynamicGraphicLineSegment); linesList.add(dynamicGraphicLineSegment); } } if (yoGraphicsListRegistry != null) yoGraphicsListRegistry.registerYoGraphicsList(yoGraphicsList); yoGraphicsList.hideYoGraphics(); }
sphereObject.addCoordinateSystem(1.0); sphereObject.translate(translation); sphereObject.addSphere(0.5, YoAppearance.Green());