private void init() { rootNode = new Graphics3DNode(worldName + "RootNode"); }
private void init() { rootNode = new Graphics3DNode(worldName + "RootNode"); }
public static Graphics3DNode addRotatingScalingNode(ArrayList<Runnable> runnables, Graphics3DObject teapotObject) { Graphics3DNode teapotAndSphereNode = new Graphics3DNode("teaPot", Graphics3DNodeType.JOINT); teapotAndSphereNode.setGraphicsObject(teapotObject); RotateAndScaleNodeRunnable rotator = new RotateAndScaleNodeRunnable(teapotAndSphereNode); runnables.add(rotator); return teapotAndSphereNode; }
public static void addJiggle(Graphics3DNode node,Graphics3DAdapter adapter,ArrayList<Runnable> runnables) { // adapter.removeRootNode(node); Graphics3DNode jiggleNode = new Graphics3DNode("jiggle", Graphics3DNodeType.JOINT); jiggleNode.addChild(node); // adapter.addRootNode(jiggleNode); RotateAndScaleNodeRunnable jiggler = new RotateAndScaleNodeRunnable(node); runnables.add(jiggler); } public static void addFirstCamera(Graphics3DAdapter graphics3DAdapter, PanBackAndForthTrackingAndDollyPositionHolder cameraTrackAndDollyVariablesHolder)
public static void addJiggle(Graphics3DNode node,Graphics3DAdapter adapter,ArrayList<Runnable> runnables) { // adapter.removeRootNode(node); Graphics3DNode jiggleNode = new Graphics3DNode("jiggle", Graphics3DNodeType.JOINT); jiggleNode.addChild(node); // adapter.addRootNode(jiggleNode); RotateAndScaleNodeRunnable jiggler = new RotateAndScaleNodeRunnable(node); runnables.add(jiggler); } public static void addFirstCamera(Graphics3DAdapter graphics3DAdapter, PanBackAndForthTrackingAndDollyPositionHolder cameraTrackAndDollyVariablesHolder)
public static Graphics3DNode addRotatingScalingNode(ArrayList<Runnable> runnables, Graphics3DObject teapotObject) { Graphics3DNode teapotAndSphereNode = new Graphics3DNode("teaPot", Graphics3DNodeType.JOINT); teapotAndSphereNode.setGraphicsObject(teapotObject); RotateAndScaleNodeRunnable rotator = new RotateAndScaleNodeRunnable(teapotAndSphereNode); runnables.add(rotator); return teapotAndSphereNode; }
public HeightMap getGroundProfile(GroundProfileObjectFilter groundProfileObjectFilter, int resolution) { ArrayList<Graphics3DNode> nodes = new ArrayList<Graphics3DNode>(); for (Entry<String, Graphics3DObject> visual : visuals.entrySet()) { if (groundProfileObjectFilter.isTerrainObject(visual.getKey())) { Graphics3DNode node = new Graphics3DNode(visual.getKey(), Graphics3DNodeType.GROUND); node.setGraphicsObject(visual.getValue()); nodes.add(node); } } HeightMap groundProfile = new JMEGeneratedHeightMap(nodes, resolution); return groundProfile; }
public HeightMap getGroundProfile(GroundProfileObjectFilter groundProfileObjectFilter, int resolution) { ArrayList<Graphics3DNode> nodes = new ArrayList<Graphics3DNode>(); for (Entry<String, Graphics3DObject> visual : visuals.entrySet()) { if (groundProfileObjectFilter.isTerrainObject(visual.getKey())) { Graphics3DNode node = new Graphics3DNode(visual.getKey(), Graphics3DNodeType.GROUND); node.setGraphicsObject(visual.getValue()); nodes.add(node); } } HeightMap groundProfile = new JMEGeneratedHeightMap(nodes, resolution); return groundProfile; }
private void createRays() { rays = new Graphics3DNode[scansPerSweep]; for (int i = 0; i < scansPerSweep; i++) { Graphics3DObject rayObject = new Graphics3DObject(); rayObject.rotate(Math.PI / 2, Axis.Y); rayObject.addCylinder(1.0, 0.0005, appearance); rays[i] = new Graphics3DNode(lidarName + "ray" + i, Graphics3DNodeType.VISUALIZATION, rayObject); } } }
public void addCoordinateFrame() { Graphics3DObject coordinateFrameObject = new Graphics3DObject(); coordinateFrameObject.addCoordinateSystem(1.0); addChild(new Graphics3DNode("CoordinateFrameNode", coordinateFrameObject)); }
public void addCoordinateFrame() { Graphics3DObject coordinateFrameObject = new Graphics3DObject(); coordinateFrameObject.addCoordinateSystem(1.0); addChild(new Graphics3DNode("CoordinateFrameNode", coordinateFrameObject)); }
public static Graphics3DNode createPointCloud(String name, List<Point3d> worldPoints, double pointRadius, AppearanceDefinition appearance) { // TODO Change to point sprite mesh Graphics3DNode pointCloud = new Graphics3DNode("PointCloud" + name); for (int i = 0; i < worldPoints.size(); i++) { Graphics3DNode worldPointNode = new Graphics3DNode(name + "point" + i, Graphics3DNodeType.VISUALIZATION, new Graphics3DObject(new Sphere3d(pointRadius), appearance)); worldPointNode.translate(worldPoints.get(i).getX(), worldPoints.get(i).getY(), worldPoints.get(i).getZ()); pointCloud.addChild(worldPointNode); } return pointCloud; }
public static Graphics3DNode createPointCloud(String name, List<Point3D> worldPoints, double pointRadius, AppearanceDefinition appearance) { // TODO Change to point sprite mesh Graphics3DNode pointCloud = new Graphics3DNode("PointCloud" + name); for (int i = 0; i < worldPoints.size(); i++) { Graphics3DNode worldPointNode = new Graphics3DNode(name + "point" + i, Graphics3DNodeType.VISUALIZATION, new Graphics3DObject(new Sphere3D(pointRadius), appearance)); worldPointNode.translate(worldPoints.get(i).getX(), worldPoints.get(i).getY(), worldPoints.get(i).getZ()); pointCloud.addChild(worldPointNode); } return pointCloud; }
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; }
private void createPoints() { points = new Graphics3DNode[scansPerSweep]; for (int i = 0; i < scansPerSweep; i++) { points[i] = new Graphics3DNode(lidarName + "point" + i, Graphics3DNodeType.VISUALIZATION, new Graphics3DObject(new Sphere3d(SPHERE_RADIUS), appearance)); } }
private void addLidarNode() { lidarNode = new Graphics3DNode("lidar", new Graphics3DObject()); lidarNode.getGraphics3DObject().addModelFile("models/hokuyo.dae", YoAppearance.Black()); lidarNode.getGraphics3DObject().addCoordinateSystem(1.0); addChild(lidarNode); }
private void addLidarNode() { lidarNode = new Graphics3DNode("lidar", new Graphics3DObject()); lidarNode.getGraphics3DObject().addModelFile("models/hokuyo.dae", YoAppearance.Black()); lidarNode.getGraphics3DObject().addCoordinateSystem(1.0); addChild(lidarNode); }
public GraphicsIDRobot(String name, RigidBodyBasics rootBody, GraphicsObjectsHolder graphicsObjectsHolder, boolean useCollisionMeshes) { super(new Graphics3DNode(name, Graphics3DNodeType.TRANSFORM)); for (JointBasics joint : rootBody.getChildrenJoints()) { GraphicsJoint rootGraphicsJoint = createJoint(joint, Graphics3DNodeType.ROOTJOINT, graphicsObjectsHolder, useCollisionMeshes); getRootNode().addChild(rootGraphicsJoint); addInverseDynamicsJoints(joint.getSuccessor().getChildrenJoints(), rootGraphicsJoint, graphicsObjectsHolder, useCollisionMeshes); } update(); }
Graphics3DNode sphereNode = new Graphics3DNode("sphere", Graphics3DNodeType.JOINT); sphereNode.setGraphicsObject(sphereObject); graphicsAdapter.addRootNode(sphereNode); Graphics3DNode groundNode = new Graphics3DNode("ground", Graphics3DNodeType.JOINT);