Class VMath
java.lang.Object
|
+--VMath
- public class VMath
- extends java.lang.Object
|
Constructor Summary |
VMath()
|
|
Method Summary |
static double |
angle(int ax,
int ay,
int bx,
int by)
|
static double |
angle(int ax,
int ay,
int bx,
int by,
int cx,
int cy)
|
static double |
crossProductMag(int ax,
int ay,
int bx,
int by)
|
static double |
crossProductMagPolyline(int ax,
int ay,
int bx,
int by,
int cx,
int cy)
|
static double |
distance(double x,
double y,
double ax,
double ay)
|
static double |
distFromLine(int x,
int y,
int ax,
int ay,
int bx,
int by,
boolean segment)
returns Double.POSITIVE_INFINITY if closest point to line is not contained
in line segment |
static boolean |
inRange(double x,
double y,
double ax,
double ay,
double range)
|
static double |
length(double x,
double y)
|
static int[] |
normal(int x,
int y)
|
static double |
square(double x)
|
static void |
unitNormal(int x,
int y,
double[] res)
|
static void |
unitVector(int x,
int y,
double[] res)
|
| Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
VMath
public VMath()
square
public static double square(double x)
length
public static double length(double x,
double y)
inRange
public static boolean inRange(double x,
double y,
double ax,
double ay,
double range)
distance
public static double distance(double x,
double y,
double ax,
double ay)
normal
public static int[] normal(int x,
int y)
unitNormal
public static void unitNormal(int x,
int y,
double[] res)
unitVector
public static void unitVector(int x,
int y,
double[] res)
crossProductMag
public static double crossProductMag(int ax,
int ay,
int bx,
int by)
crossProductMagPolyline
public static double crossProductMagPolyline(int ax,
int ay,
int bx,
int by,
int cx,
int cy)
angle
public static double angle(int ax,
int ay,
int bx,
int by,
int cx,
int cy)
angle
public static double angle(int ax,
int ay,
int bx,
int by)
distFromLine
public static double distFromLine(int x,
int y,
int ax,
int ay,
int bx,
int by,
boolean segment)
- returns Double.POSITIVE_INFINITY if closest point to line is not contained
in line segment