|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectpslib.PSRange
public class PSRange
PSRange Class
The PSRange object allows a minimum and maximum value to be stored. Calls
to get()
map a value between 0 and 1 to the range and apply the
specified envelope and curvature.
Field Summary |
---|
Fields inherited from interface pslib.PSConstants |
---|
CAM2D_LOOK, CAM2D_RIGHT, CAM2D_UP, CORNER, INVERSE, INVERSE_TRIANGULAR, LEADING, LINEAR, MIDPOINT, NONE, STATIC, TRAILING, TRIANGULAR |
Constructor Summary | |
---|---|
PSRange(float mi,
float ma)
Create a new object instance with the specified values |
|
PSRange(float mi,
float ma,
int m)
Create a new object instance with the specified values |
|
PSRange(float mi,
float ma,
int m,
float c)
Create a new object instance with the specified values |
Method Summary | |
---|---|
float |
get(float v)
Map the input value to the range of this object instance |
float[] |
getRange()
|
void |
setCurve(float c)
Set the curve exponent |
void |
setMode(int m)
Set the envelope mode |
void |
setRange(float mi,
float ma)
Set the minimum and maximum values |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public PSRange(float mi, float ma)
mi
- minimumma
- maximumpublic PSRange(float mi, float ma, int m)
mi
- minimumma
- maximumm
- envelope modepublic PSRange(float mi, float ma, int m, float c)
mi
- minimumma
- maximumm
- envelope modec
- curve exponentMethod Detail |
---|
public final void setRange(float mi, float ma)
mi
- minimumma
- maximumpublic final float[] getRange()
public final void setMode(int m)
Available modes are: LINEAR, INVERSE, TRIANGULAR and INVERSE_TRIANGULAR
m
- envelope modepublic final void setCurve(float c)
c
- curve exponentpublic final float get(float v)
Input values will be constrained between 0 and 1
v
- input value
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |