Package idare.imagenode.ColorManagement
Interface ColorScale
-
- All Superinterfaces:
Serializable
public interface ColorScale extends Serializable
AColorScaleprovidesColors based on its properties for values between 0 and 1.- Author:
- Thomas Pfau
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description ColorgetColor(double value)get a colorColorScalePanegetColorScalePane()Get aColorScalePaneas a description for thisColorScaleidare.imagenode.internal.ColorManagement.ColorScales.ColorScalePropertiesgetColorScaleProperties()Get the Properties of this ColorScale.voidmovePointOnScale(float origval, float targetval)Move a point in the 0-1 scale to the target value.voidsetColorCount(int count)Set the number of colors used by this scale.voidsetColorScaleProperties(idare.imagenode.internal.ColorManagement.ColorScales.ColorScaleProperties props)Set theColorScalePropertiesused by thisColorScaleThis can e.g.
-
-
-
Method Detail
-
getColor
Color getColor(double value)
get a color- Parameters:
value- a value between 0 and 1.- Returns:
- the appropriate color on the scale.
-
getColorScaleProperties
idare.imagenode.internal.ColorManagement.ColorScales.ColorScaleProperties getColorScaleProperties()
Get the Properties of this ColorScale. The properties show the fractions and associated colors used.- Returns:
- The
ColorScalePropertiesof thisColorScale
-
getColorScalePane
ColorScalePane getColorScalePane()
Get aColorScalePaneas a description for thisColorScale- Returns:
- A
ColorScalePanethat can represents this ColorScale
-
setColorScaleProperties
void setColorScaleProperties(idare.imagenode.internal.ColorManagement.ColorScales.ColorScaleProperties props)
Set theColorScalePropertiesused by thisColorScaleThis can e.g. adapt a certain color to a specific point in the scale (e.g. for 0 balancing) but can also be used to stretch specific parts of theColorScale.- Parameters:
props- TheColorScalePropertiesto be used.
-
setColorCount
void setColorCount(int count)
Set the number of colors used by this scale. This function does not need to have an effect and can potentially be simply ignored, but it will be called by discreet color maps and potentially other methods.- Parameters:
count- the number ofColors to use.
-
movePointOnScale
void movePointOnScale(float origval, float targetval)Move a point in the 0-1 scale to the target value. If Either origval or targetval are outside the 0-1 range, nothing will happen. THis should only influence the visual presentation.- Parameters:
origval- A value in the range of [0.0,1.0]. that should be movedtargetval- The value the origval shall be moved to in the range of [0.0,1.0].
-
-