sventon subversion web client - http://www.sventon.org
[show recent changes]
 
  Help
HEAD
Rev: 9986 - svn://svn.freehep.org/svn / sandbox / Plotter / src / plotter / GrayScaleColorMap.java
Unified Diff View - GrayScaleColorMap.java
Search for Help
/sandbox/Plotter/src/plotter/GrayScaleColorMap.java @ revision 9985
/sandbox/Plotter/src/plotter/GrayScaleColorMap.java @ revision 9986
@@ -5,11 +5,16 @@  *  * @author tonyj  */ -public class GrayScaleColorMap implements ColorMap { - -    public Color getColor(double value, float alpha) { -       if (value < 0 || value > 1) throw new IllegalArgumentException("Value must be in range [0,1]: "+value); -       float v = (float) value; -       return new Color(v,v,v,alpha); -    } +public class GrayScaleColorMap implements ColorMap +{ +   public Color getColor(double value, float alpha) +   { +      if (value < 0 || value > 1) throw new IllegalArgumentException("Value must be in range [0,1]: "+value); +      float v = (float) value; +      return new Color(v,v,v,alpha); +   } +   public String toString() +   { +      return "Gray Scale"; +   } }


feed icon

sventon 2.5.1