/** * Called after each render. */ private void update() { if (debugCoordinates) { System.out.println("Machine coordinates: " + this.machineCoord.toString()); System.out.println("Work coordinates: " + this.workCoord.toString()); System.out.println("-----------------"); } /* // Increases the cutoff number each frame to show the tool path. count++; if (increasing) currentCommandNumber+=10; else currentCommandNumber-=10; if (this.currentCommandNumber > this.lastCommandNumber) increasing = false; else if (this.currentCommandNumber <= 0) increasing = true; */ }
System.out.println("Center = " + center.toString()); System.out.println("Num Line Segments :" + gcodeLineList.size());
public void writeFootstepAndPointsToFile(FootstepDataMessage footstep, List<Point3d> points) { System.out.println("Printing Footstep and Points to file: " + outputFile.getName()); index++; try { FileWriter writer = new FileWriter(outputFile, true); writer.write("Footstep " + index + "\n" + footstep + "\n"); for (Point3d point3d : points) { writer.write(point3d.toString() + "\n"); } writer.close(); } catch (IOException e) { e.printStackTrace(); } } }
@Override public List<Point3d> applyPolynomial( List<Point3d> srcPts ) throws TransformationException { if ( srcPts == null || srcPts.size() == 0 ) { return srcPts; } List<Point3d> result = new ArrayList<Point3d>( srcPts.size() ); for ( Point3d p : srcPts ) { Point2D r = leastSquarePolynomial.mapDestPoint( new Point2D.Double( p.x, p.y ) ); if ( r != null ) { result.add( new Point3d( r.getX(), r.getY(), p.z ) ); } else { throw new TransformationException( Messages.getMessage( "CRS_POLYNOMIAL_TRANSFORM_ERROR", p.toString() ) ); } } return result; }
public String toString() { String ret = ""; FrameOrientation frameOrientation = new FrameOrientation(ReferenceFrame.getWorldFrame(), this.orientation); double[] ypr = frameOrientation.getYawPitchRoll(); ret = location.toString(); ret += ", YawPitchRoll = " + Arrays.toString(ypr) + "\n"; return ret; }
bufferedWriter.write(point.toString() + System.lineSeparator());
public String toString() { String ret = ""; FrameOrientation frameOrientation = new FrameOrientation(ReferenceFrame.getWorldFrame(), this.orientation); double[] ypr = frameOrientation.getYawPitchRoll(); ret = location.toString(); ret += ", YawPitchRoll = " + Arrays.toString(ypr) + "\n"; ret += "Predicted Contact Points: "; if (predictedContactPoints != null) { ret += "size = " + predictedContactPoints.size() + "\n"; } else { ret += "null"; } return ret; }
public String toString() { String ret = ""; FrameOrientation frameOrientation = new FrameOrientation(ReferenceFrame.getWorldFrame(), this.orientation); double[] ypr = frameOrientation.getYawPitchRoll(); ret = location.toString(); ret += ", YawPitchRoll = " + Arrays.toString(ypr) + "\n"; ret += "Predicted Contact Points: "; if (predictedContactPoints != null) { ret += "size = " + predictedContactPoints.size() + "\n"; } else { ret += "null"; } ret += trajectoryType.name() + "\n"; if(trajectoryWaypoints != null) { ret += "waypoints = " + trajectoryWaypoints.length + "\n"; } else { ret += "no waypoints" + "\n"; } return ret; }
public String toString() { String startingFootstep = ""; int numberOfSteps = this.size(); if (numberOfSteps > 0) { startingFootstep = this.get(0).getLocation().toString(); Quat4d quat4d = this.get(0).getOrientation(); FrameOrientation frameOrientation = new FrameOrientation(ReferenceFrame.getWorldFrame(), quat4d); startingFootstep = startingFootstep + ", ypr= " + Arrays.toString(frameOrientation.getYawPitchRoll()); } if (this.size() == 1) { RobotSide footSide = footstepDataList.get(0).getRobotSide(); String side = "Right Step"; if (footSide.getSideNameFirstLetter().equals("L")) side = "Left Step"; return (side); } else { return ("Starting Footstep: " + startingFootstep + "\n\tExecution Mode: " + this.executionMode + "\n\tTransfer Time: " + defaultTransferTime + "\n\tSwing Time: " + defaultSwingTime + "\n\tSize: " + this.size() + " Footsteps"); } }