| Modifier and Type | Field and Description |
|---|---|
| public double | x
The x coordinate. |
| public double | y
The y coordinate. |
| Access | Constructor and Description |
|---|---|
| public | |
| public | |
| public | |
| public |
| Modifier and Type | Method and Description |
|---|---|
| public static double | Returns: the distance between the two sets of specified coordinates.the X coordinate of the first specified point x1, double the Y coordinate of the first specified point y1, double the X coordinate of the second specified point x2, double the Y coordinate of the second specified point y2)Returns the distance between two points. |
| public double | Returns: the distance between thisVec2d
and a specified point.the X coordinate of the specified point to be measured
against this vx, double Vec2dthe Y coordinate of the specified point to be measured
against this vy)Vec2dReturns the distance from this |
| public double | |
| public static double | Returns: the square of the distance between the two sets of specified coordinates.the X coordinate of the first specified point x1, double the Y coordinate of the first specified point y1, double the X coordinate of the second specified point x2, double the Y coordinate of the second specified point y2)Returns the square of the distance between two points. |
| public double | Returns: the square of the distance between thisVec2d and the specified point.the X coordinate of the specified point to be measured
against this vx, double Vec2dthe Y coordinate of the specified point to be measured
against this vy)Vec2dReturns the square of the distance from this
|
| public double | Returns: the square of the distance between thisVec2d to a specified Vec2d.the specified point to be measured
against this v)Vec2dReturns the square of the distance from this
|
| public boolean | Returns: true if the object to be compared is
an instance of Vec2d and has
the same values; false otherwise.an object to be compared with this obj)Vec2dOverrides java. Determines whether or not two 2D points or vectors are equal. |
| public int | Returns: a hash code for thisVec2d.Overrides java. Returns the hashcode for this |
| public void | |
| public void | |
| public void | |
| public String | Returns: a string representation of thisVec2d.Overrides java. Returns a |
| x | back to summary |
|---|---|
| public double x The x coordinate. | |
| y | back to summary |
|---|---|
| public double y The y coordinate. | |
| Vec2d | back to summary |
|---|---|
| public Vec2d() | |
| Vec2d | back to summary |
|---|---|
| public Vec2d(double x, double y) | |
| Vec2d | back to summary |
|---|---|
| public Vec2d(Vec2d v) | |
| Vec2d | back to summary |
|---|---|
| public Vec2d(Vec2f v) | |
| distance | back to summary |
|---|---|
| public static double distance(double x1, double y1, double x2, double y2) Returns the distance between two points.
| |
| distance | back to summary |
|---|---|
| public double distance(double vx, double vy) Returns the distance from this
| |
| distance | back to summary |
|---|---|
| public double distance(Vec2d v) Returns the distance from this
| |
| distanceSq | back to summary |
|---|---|
| public static double distanceSq(double x1, double y1, double x2, double y2) Returns the square of the distance between two points.
| |
| distanceSq | back to summary |
|---|---|
| public double distanceSq(double vx, double vy) Returns the square of the distance from this
| |
| distanceSq | back to summary |
|---|---|
| public double distanceSq(Vec2d v) Returns the square of the distance from this
| |
| equals | back to summary |
|---|---|
| public boolean equals(Object obj) Overrides java. Determines whether or not two 2D points or vectors are equal.
Two instances of | |
| hashCode | back to summary |
|---|---|
| public int hashCode() Overrides java. Returns the hashcode for this
| |
| set | back to summary |
|---|---|
| public void set(Vec2d v) | |
| set | back to summary |
|---|---|
| public void set(Vec2f v) | |
| set | back to summary |
|---|---|
| public void set(double x, double y) | |
| toString | back to summary |
|---|---|
| public String toString() Overrides java. Returns a | |