Main Page | Namespace List | Class Hierarchy | Class List | Directories | File List | Class Members | File Members

ColorSeries.h

Go to the documentation of this file.
00001 
00002 //
00003 // This file is part of the MADELINE 2 program 
00004 // written by Edward H. Trager, Ritu Khanna and Adrian Marrs
00005 // Copyright (c) 2006 by the
00006 // Regents of the University of Michigan.
00007 // All Rights Reserved.
00008 // 
00009 // The latest version of this program is available from:
00010 // 
00011 //   http://eyegene.ophthy.med.umich.edu/madeline/
00012 //   
00013 // Released under the GNU General Public License.
00014 // A copy of the GPL is included in the distribution
00015 // package of this software, or see:
00016 // 
00017 //   http://www.gnu.org/copyleft/
00018 //   
00019 // ... for licensing details.
00020 // 
00022 
00023 //
00024 // ColorSeries.h  2006.12.01.ET
00025 //
00026 
00027 #include <vector>
00028 #include "DrawingColor.h"
00029 
00030 #ifndef ColorSeries_INCLUDED
00031 #define ColorSeries_INCLUDED
00032 
00033 class ColorSeries{
00034         
00035 private:
00036         
00037         static double _twoSaturations[2];
00038         static double _threeSaturations[3];
00039         static double _fourSaturations[4];
00040         static double _fiveSaturations[5];
00041         static double *_saturations[6];
00042         
00043         unsigned _levels;
00044         DrawingColor _endColor;
00045         DrawingColor _startColor;
00046         
00047         std::vector<DrawingColor> _colorSeries;
00048         
00049 public:
00050         
00051         ColorSeries(unsigned levels=2,const DrawingColor &endColor=DrawingColor("black","#000"),const DrawingColor &startColor=DrawingColor("white","#fff"));
00052         
00053         DrawingColor get(unsigned level) const;
00054         std::string getColorAtLevel(unsigned level) const;
00055         std::string reversedSeriesGetColorAtLevel(unsigned level) const;
00056         bool useBlackInkAtLevel(unsigned level) const;
00057         bool reversedSeriesUseBlackInkAtLevel(unsigned level) const;
00058 };
00059 
00060 #endif

Generated on Fri Nov 18 16:24:39 2011 for MADELINE by  doxygen 1.4.4