|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectcom.tensegrity.composite.coordinate.DefaultScaleLinear
This is the default implementation of the Scale interface. The
documentation can be found in the interface Scale.
DefaultMutableScaleLinear,
Scale| Field Summary |
| Fields inherited from interface com.tensegrity.composite.coordinate.Scale |
TYPE_LINEAR |
| Method Summary | |
Scale |
deepCopy()
Method to deep copy this scale instance. |
double |
descale(double minimum,
double maximum,
double valueToDescale)
Converts the value given by valueToDescale from the range
given by minimum and maximum to the range of
this Scale. |
boolean |
equals(java.lang.Object obj)
|
double |
getDescaleFactor(double minimum,
double maximum)
Returns the scale factor that converts a value from the range given by minimum and maximum to range of this
Scale. |
double |
getScaleFactor(double minimum,
double maximum)
Returns the scale factor that converts a value from the range of this Scale to the range given by minimum and
maximum. |
double |
getScaleMaximum()
Returns the maximum scale value for this Scale. |
double |
getScaleMinimum()
Returns the minimum scale value for this Scale. |
double |
getScaleRange()
Returns the scale range for this Scale. |
int |
hashCode()
|
double |
scale(double minimum,
double maximum,
double valueToScale)
Converts the value given by valueToScale from the range of
this Scale to the range given by minimum and
maximum. |
java.lang.String |
toString()
|
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Method Detail |
public double getScaleMinimum()
ScaleScale.
getScaleMinimum in interface Scalepublic double getScaleMaximum()
ScaleScale.
getScaleMaximum in interface Scalepublic double getScaleRange()
ScaleScale. The scale range is
defined as the interval between the minimum scale value and the maximum
scale value. The mathematical expression for this is:
getScaleRange in interface Scale
public double getScaleFactor(double minimum,
double maximum)
ScaleScale to the range given by minimum and
maximum. The mathematical expression for this is:maximum - minimum) /
(maximum scale value - minimum scale value)
.
getScaleFactor in interface Scaleminimum - the minimum value of the range to convert tomaximum - the maximum value of the range to convert to
public double getDescaleFactor(double minimum,
double maximum)
Scaleminimum and maximum to range of this
Scale. The mathematical expression for this is:maximum - minimum)
.
getDescaleFactor in interface Scaleminimum - the minimum value of the range to convert frommaximum - the maximum value of the range to convert from
public double scale(double minimum,
double maximum,
double valueToScale)
ScalevalueToScale from the range of
this Scale to the range given by minimum and
maximum. The mathematical expression for this is:valueToScale *
(maximum - minimum) /
(maximum scale value - minimum scale value)
.
scale in interface Scaleminimum - the minimum value of the range to convert tomaximum - the maximum value of the range to convert tovalueToScale - the value to convert
public double descale(double minimum,
double maximum,
double valueToDescale)
ScalevalueToDescale from the range
given by minimum and maximum to the range of
this Scale. The mathematical expression for this is:valueToScale *
(maximum scale value - minimum scale value) /
(maximum - minimum)
.
descale in interface Scaleminimum - the minimum value of the range to convert frommaximum - the maximum value of the range to convert fromvalueToDescale - the value to convert
public Scale deepCopy()
Scale
deepCopy in interface ScaleScale.public java.lang.String toString()
public boolean equals(java.lang.Object obj)
public int hashCode()
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||