igeo
Class IRand
java.lang.Object
igeo.IRand
- Direct Known Subclasses:
- IRandom
public class IRand
- extends java.lang.Object
A class to provide random number function.
Constructor Summary |
IRand()
|
Method Summary |
static java.awt.Color |
clr()
|
static java.awt.Color |
clr(float alpha)
|
static java.awt.Color |
clr(int alpha)
|
static double |
get()
|
static double |
get(double max)
|
static double |
get(double min,
double max)
|
static java.awt.Color |
getColor()
|
static java.awt.Color |
getColor(float alpha)
|
static java.awt.Color |
getColor(int alpha)
|
static double |
getDouble()
|
static double |
getDouble(double max)
|
static double |
getDouble(double min,
double max)
|
static float |
getf()
|
static float |
getf(float max)
|
static float |
getf(float min,
float max)
|
static float |
getFloat()
|
static float |
getFloat(float max)
|
static float |
getFloat(float min,
float max)
|
static java.awt.Color |
getGray()
|
static java.awt.Color |
getGray(float alpha)
|
static java.awt.Color |
getGray(int alpha)
|
static java.awt.Color |
getGrayColor()
|
static java.awt.Color |
getGrayColor(float alpha)
|
static java.awt.Color |
getGrayColor(int alpha)
|
static int |
geti()
returns 0 or 1 |
static int |
geti(int max)
|
static int |
geti(int min,
int max)
|
static int |
getInt()
|
static int |
getInt(int max)
|
static int |
getInt(int min,
int max)
|
static int |
getInteger()
|
static int |
getInteger(int max)
|
static int |
getInteger(int min,
int max)
|
static boolean |
getPercent(double percent)
|
static IVec |
getPoint()
|
static IVec |
getPoint(double max)
|
static IVec |
getPoint(double min,
double max)
|
static IVec |
getPoint(double maxx,
double maxy,
double maxz)
|
static IVec |
getPoint(double minx,
double miny,
double minz,
double maxx,
double maxy,
double maxz)
|
static IVec |
getPoint(IVec max)
|
static IVec |
getPoint(IVec min,
IVec max)
|
static java.awt.Color |
gray()
|
static java.awt.Color |
gray(float alpha)
|
static java.awt.Color |
gray(int alpha)
|
static void |
init()
|
static void |
init(long seed)
|
static void |
initByTime()
|
static boolean |
percent(double percent)
|
static IVec |
point()
|
static IVec |
point(double max)
|
static IVec |
point(double min,
double max)
|
static IVec |
point(double maxx,
double maxy,
double maxz)
|
static IVec |
point(double minx,
double miny,
double minz,
double maxx,
double maxy,
double maxz)
|
static IVec |
point(IVec max)
|
static IVec |
point(IVec min,
IVec max)
|
static IVec |
pt()
|
static IVec |
pt(double max)
|
static IVec |
pt(double min,
double max)
|
static IVec |
pt(double maxx,
double maxy,
double maxz)
|
static IVec |
pt(double minx,
double miny,
double minz,
double maxx,
double maxy,
double maxz)
|
static IVec |
pt(IVec max)
|
static IVec |
pt(IVec min,
IVec max)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
defaultSeed
public static final long defaultSeed
- See Also:
- Constant Field Values
random
protected static java.util.Random random
IRand
public IRand()
init
public static void init()
init
public static void init(long seed)
initByTime
public static void initByTime()
get
public static double get()
getDouble
public static double getDouble(double min,
double max)
getDouble
public static double getDouble(double max)
getDouble
public static double getDouble()
get
public static double get(double min,
double max)
get
public static double get(double max)
getf
public static float getf()
getf
public static float getf(float min,
float max)
getf
public static float getf(float max)
getFloat
public static float getFloat()
getFloat
public static float getFloat(float min,
float max)
getFloat
public static float getFloat(float max)
geti
public static int geti(int min,
int max)
geti
public static int geti(int max)
geti
public static int geti()
- returns 0 or 1
getInt
public static int getInt(int min,
int max)
getInt
public static int getInt(int max)
getInt
public static int getInt()
getInteger
public static int getInteger(int min,
int max)
getInteger
public static int getInteger(int max)
getInteger
public static int getInteger()
pt
public static IVec pt(IVec min,
IVec max)
point
public static IVec point(IVec min,
IVec max)
getPoint
public static IVec getPoint(IVec min,
IVec max)
pt
public static IVec pt(IVec max)
point
public static IVec point(IVec max)
getPoint
public static IVec getPoint(IVec max)
pt
public static IVec pt(double minx,
double miny,
double minz,
double maxx,
double maxy,
double maxz)
pt
public static IVec pt(double maxx,
double maxy,
double maxz)
pt
public static IVec pt(double min,
double max)
pt
public static IVec pt(double max)
pt
public static IVec pt()
point
public static IVec point(double minx,
double miny,
double minz,
double maxx,
double maxy,
double maxz)
point
public static IVec point(double maxx,
double maxy,
double maxz)
point
public static IVec point(double min,
double max)
point
public static IVec point(double max)
point
public static IVec point()
getPoint
public static IVec getPoint(double minx,
double miny,
double minz,
double maxx,
double maxy,
double maxz)
getPoint
public static IVec getPoint(double maxx,
double maxy,
double maxz)
getPoint
public static IVec getPoint(double min,
double max)
getPoint
public static IVec getPoint(double max)
getPoint
public static IVec getPoint()
getPercent
public static boolean getPercent(double percent)
percent
public static boolean percent(double percent)
getColor
public static java.awt.Color getColor()
clr
public static java.awt.Color clr()
getColor
public static java.awt.Color getColor(int alpha)
clr
public static java.awt.Color clr(int alpha)
getColor
public static java.awt.Color getColor(float alpha)
clr
public static java.awt.Color clr(float alpha)
getGrayColor
public static java.awt.Color getGrayColor()
getGray
public static java.awt.Color getGray()
gray
public static java.awt.Color gray()
getGrayColor
public static java.awt.Color getGrayColor(int alpha)
getGray
public static java.awt.Color getGray(int alpha)
gray
public static java.awt.Color gray(int alpha)
getGrayColor
public static java.awt.Color getGrayColor(float alpha)
getGray
public static java.awt.Color getGray(float alpha)
gray
public static java.awt.Color gray(float alpha)