@Override public boolean epsilonEquals(ComPositionPacket other, double epsilon) { if(other == null) return false; if(other == this) return true; if (!this.position_.epsilonEquals(other.position_, epsilon)) return false; return true; }
/** * Tests on a per-component basis on the minimum and maximum coordinates if this bounding box is * equal to {@code other} with the tolerance {@code epsilon}. * * @param other the query. Not modified. * @param epsilon the tolerance to use. * @return {@code true} if the two bounding boxes are equal, {@code false} otherwise. */ @Override public boolean epsilonEquals(BoundingBox3D other, double epsilon) { return minPoint.epsilonEquals(other.minPoint, epsilon) && maxPoint.epsilonEquals(other.maxPoint, epsilon); }
@Override public boolean epsilonEquals(BoundingBox3DMessage other, double epsilon) { if(other == null) return false; if(other == this) return true; if (!us.ihmc.idl.IDLTools.epsilonEqualsPrimitive(this.sequence_id_, other.sequence_id_, epsilon)) return false; if (!this.min_point_.epsilonEquals(other.min_point_, epsilon)) return false; if (!this.max_point_.epsilonEquals(other.max_point_, epsilon)) return false; return true; }
public static boolean isGoalNextToLastStep(Point3D desiredPosition, FootstepPlan footstepPlan, double epsilon) { Point3D goalPosition = getEndPosition(footstepPlan); if (goalPosition.epsilonEquals(desiredPosition, epsilon)) return true; else return false; }
public static boolean isPointOnRegion(PlanarRegion region, Point3D point, double epsilon) { Point3D closestPoint = closestPointOnPlane(point, region); return closestPoint.epsilonEquals(point, epsilon); }
public boolean isCloseToFinalPosition() { if (!launched) return false; this.getPosition(currentPosition); return currentPosition.epsilonEquals(finalPosition, collisionDistance); }
@Override public boolean epsilonEquals(PointStamped other, double epsilon) { if(other == null) return false; if(other == this) return true; if (!this.header_.epsilonEquals(other.header_, epsilon)) return false; if (!this.point_.epsilonEquals(other.point_, epsilon)) return false; return true; }
@Override public boolean epsilonEquals(EuclideanWaypoint other, double epsilon) { if (!position.epsilonEquals(other.position, epsilon)) return false; if (!linearVelocity.epsilonEquals(other.linearVelocity, epsilon)) return false; return true; }
@Override public boolean epsilonEquals(QuadrupedGroundPlaneMessage other, double epsilon) { if(other == null) return false; if(other == this) return true; if (!us.ihmc.idl.IDLTools.epsilonEqualsPrimitive(this.sequence_id_, other.sequence_id_, epsilon)) return false; if (!this.region_origin_.epsilonEquals(other.region_origin_, epsilon)) return false; if (!this.region_normal_.epsilonEquals(other.region_normal_, epsilon)) return false; return true; }
@Override public boolean epsilonEquals(WalkOverTerrainGoalPacket other, double epsilon) { if(other == null) return false; if(other == this) return true; if (!us.ihmc.idl.IDLTools.epsilonEqualsPrimitive(this.sequence_id_, other.sequence_id_, epsilon)) return false; if (!this.position_.epsilonEquals(other.position_, epsilon)) return false; if (!this.orientation_.epsilonEquals(other.orientation_, epsilon)) return false; return true; }
@Override public boolean epsilonEquals(UIPositionCheckerPacket other, double epsilon) { if(other == null) return false; if(other == this) return true; if (!us.ihmc.idl.IDLTools.epsilonEqualsPrimitive(this.sequence_id_, other.sequence_id_, epsilon)) return false; if (!this.position_.epsilonEquals(other.position_, epsilon)) return false; if (!this.orientation_.epsilonEquals(other.orientation_, epsilon)) return false; return true; }
@Override public boolean epsilonEquals(VehiclePosePacket other, double epsilon) { if(other == null) return false; if(other == this) return true; if (!us.ihmc.idl.IDLTools.epsilonEqualsPrimitive(this.sequence_id_, other.sequence_id_, epsilon)) return false; if (!this.position_.epsilonEquals(other.position_, epsilon)) return false; if (!this.orientation_.epsilonEquals(other.orientation_, epsilon)) return false; if (!us.ihmc.idl.IDLTools.epsilonEqualsPrimitive(this.index_, other.index_, epsilon)) return false; return true; }
private void transformAndCheck(RigidBodyTransform trans, Point3D expected, Point3D result) { double epsilon = 0.00001; Point3D exp = new Point3D(expected); trans.transform(exp); assertTrue(result.epsilonEquals(exp, epsilon)); }
@Override public boolean epsilonEquals(QuadrupedStepMessage other, double epsilon) { if(other == null) return false; if(other == this) return true; if (!us.ihmc.idl.IDLTools.epsilonEqualsPrimitive(this.sequence_id_, other.sequence_id_, epsilon)) return false; if (!us.ihmc.idl.IDLTools.epsilonEqualsPrimitive(this.robot_quadrant_, other.robot_quadrant_, epsilon)) return false; if (!this.goal_position_.epsilonEquals(other.goal_position_, epsilon)) return false; if (!us.ihmc.idl.IDLTools.epsilonEqualsPrimitive(this.ground_clearance_, other.ground_clearance_, epsilon)) return false; return true; }
@Override public boolean epsilonEquals(EuclideanTrajectoryPointMessage other, double epsilon) { if(other == null) return false; if(other == this) return true; if (!us.ihmc.idl.IDLTools.epsilonEqualsPrimitive(this.sequence_id_, other.sequence_id_, epsilon)) return false; if (!us.ihmc.idl.IDLTools.epsilonEqualsPrimitive(this.time_, other.time_, epsilon)) return false; if (!this.position_.epsilonEquals(other.position_, epsilon)) return false; if (!this.linear_velocity_.epsilonEquals(other.linear_velocity_, epsilon)) return false; return true; }
@Override public boolean epsilonEquals(WallPosePacket other, double epsilon) { if(other == null) return false; if(other == this) return true; if (!us.ihmc.idl.IDLTools.epsilonEqualsPrimitive(this.sequence_id_, other.sequence_id_, epsilon)) return false; if (!us.ihmc.idl.IDLTools.epsilonEqualsPrimitive(this.cutting_radius_, other.cutting_radius_, epsilon)) return false; if (!this.center_position_.epsilonEquals(other.center_position_, epsilon)) return false; if (!this.center_orientation_.epsilonEquals(other.center_orientation_, epsilon)) return false; return true; }
@Override public boolean epsilonEquals(KinematicsToolboxCenterOfMassMessage other, double epsilon) { if(other == null) return false; if(other == this) return true; if (!us.ihmc.idl.IDLTools.epsilonEqualsPrimitive(this.sequence_id_, other.sequence_id_, epsilon)) return false; if (!this.desired_position_in_world_.epsilonEquals(other.desired_position_in_world_, epsilon)) return false; if (!this.selection_matrix_.epsilonEquals(other.selection_matrix_, epsilon)) return false; if (!this.weights_.epsilonEquals(other.weights_, epsilon)) return false; return true; }
@Override public boolean epsilonEquals(KinematicsToolboxConfigurationMessage other, double epsilon) { if(other == null) return false; if(other == this) return true; if (!us.ihmc.idl.IDLTools.epsilonEqualsPrimitive(this.sequence_id_, other.sequence_id_, epsilon)) return false; if (!this.privileged_root_joint_position_.epsilonEquals(other.privileged_root_joint_position_, epsilon)) return false; if (!this.privileged_root_joint_orientation_.epsilonEquals(other.privileged_root_joint_orientation_, epsilon)) return false; if (!us.ihmc.idl.IDLTools.epsilonEqualsIntegerSequence(this.privileged_joint_hash_codes_, other.privileged_joint_hash_codes_, epsilon)) return false; if (!us.ihmc.idl.IDLTools.epsilonEqualsFloatSequence(this.privileged_joint_angles_, other.privileged_joint_angles_, epsilon)) return false; return true; }
@Override public boolean epsilonEquals(LidarScanMessage other, double epsilon) { if(other == null) return false; if(other == this) return true; if (!us.ihmc.idl.IDLTools.epsilonEqualsPrimitive(this.sequence_id_, other.sequence_id_, epsilon)) return false; if (!us.ihmc.idl.IDLTools.epsilonEqualsPrimitive(this.robot_timestamp_, other.robot_timestamp_, epsilon)) return false; if (!this.lidar_position_.epsilonEquals(other.lidar_position_, epsilon)) return false; if (!this.lidar_orientation_.epsilonEquals(other.lidar_orientation_, epsilon)) return false; if (!us.ihmc.idl.IDLTools.epsilonEqualsFloatSequence(this.scan_, other.scan_, epsilon)) return false; return true; }
@Override public boolean epsilonEquals(VideoPacket other, double epsilon) { if(other == null) return false; if(other == this) return true; if (!us.ihmc.idl.IDLTools.epsilonEqualsPrimitive(this.sequence_id_, other.sequence_id_, epsilon)) return false; if (!us.ihmc.idl.IDLTools.epsilonEqualsPrimitive(this.video_source_, other.video_source_, epsilon)) return false; if (!us.ihmc.idl.IDLTools.epsilonEqualsPrimitive(this.timestamp_, other.timestamp_, epsilon)) return false; if (!us.ihmc.idl.IDLTools.epsilonEqualsByteSequence(this.data_, other.data_, epsilon)) return false; if (!this.position_.epsilonEquals(other.position_, epsilon)) return false; if (!this.orientation_.epsilonEquals(other.orientation_, epsilon)) return false; if (!this.intrinsic_parameters_.epsilonEquals(other.intrinsic_parameters_, epsilon)) return false; return true; }