Back to index

nux  3.0.0
Colors.cpp
Go to the documentation of this file.
00001 /*
00002  * Copyright 2010 Inalogic® Inc.
00003  *
00004  * This program is free software: you can redistribute it and/or modify it
00005  * under the terms of the GNU Lesser General Public License, as
00006  * published by the  Free Software Foundation; either version 2.1 or 3.0
00007  * of the License.
00008  *
00009  * This program is distributed in the hope that it will be useful, but
00010  * WITHOUT ANY WARRANTY; without even the implied warranties of
00011  * MERCHANTABILITY, SATISFACTORY QUALITY or FITNESS FOR A PARTICULAR
00012  * PURPOSE.  See the applicable version of the GNU Lesser General Public
00013  * License for more details.
00014  *
00015  * You should have received a copy of both the GNU Lesser General Public
00016  * License along with this program. If not, see <http://www.gnu.org/licenses/>
00017  *
00018  * Authored by: Jay Taoko <jaytaoko@inalogic.com>
00019  *
00020  */
00021 
00022 
00023 #include "Colors.h"
00024 
00025 namespace nux
00026 {
00027   namespace color
00028   {
00029     // Definition of Luma coefficients as per ITU-R Recommendation BT.601
00030     // http://en.wikipedia.org/wiki/Rec._601
00031     const float LumaRed   = 0.299f;
00032     const float LumaGreen = 0.587f;
00033     const float LumaBlue  = 0.114f;
00034 
00035     //     // Definition of Luma coefficients as per ITU-R Recommendation BT.709
00036     //     // http://en.wikipedia.org/wiki/Rec._709
00037     //     float LumaRed   = 0.2126f;
00038     //     float LumaGreen = 0.7152f;
00039     //     float LumaBlue  = 0.0722f;
00040 
00041     const Color Transparent(0, 0, 0, 0);
00042 
00043     //Red colors
00044     const Color IndianRed(0xCD, 0x5C, 0x5C);
00045     const Color LightCoral(0xF0, 0x80, 0x80);
00046     const Color Salmon(0xFA, 0x80, 0x72);
00047     const Color DarkSalmon(0xE9, 0x96, 0x7A);
00048     const Color LightSalmon(0xFF, 0xA0, 0x7A);
00049     const Color Crimson(0xDC, 0x14, 0x3C);
00050     const Color Red(0xFF, 0x00, 0x00);
00051     const Color FireBrick(0xB2, 0x22, 0x22);
00052     const Color DarkRed(0x8B, 0x00, 0x00);
00053 
00054     //Pink colors
00055     const Color Pink(0xFF, 0xC0, 0xCB);
00056     const Color LightPink(0xFF, 0xB6, 0xC1);
00057     const Color HotPink(0xFF, 0x69, 0xB4);
00058     const Color DeepPink(0xFF, 0x14, 0x93);
00059     const Color MediumVioletRed(0xC7, 0x15, 0x85);
00060     const Color PaleVioletRed(0xDB, 0x70, 0x93);
00061 
00062     //Orange colors
00063     //const Color LightSalmon       = Color (0xFF/255.0f, 0xA0/255.0f, 0x7A/255.0f);//     255     160     122
00064     const Color Coral(0xFF, 0x7F, 0x50);
00065     const Color Tomato(0xFF, 0x63, 0x47);
00066     const Color OrangeRed(0xFF, 0x45, 0x00);
00067     const Color DarkOrange(0xFF, 0x8C, 0x00);
00068     const Color Orange(0xFF, 0xA5, 0x00);
00069 
00070     //Yellow colors
00071     const Color Gold(0xFF, 0xD7, 0x00);
00072     const Color Yellow(0xFF, 0xFF, 0x00);
00073     const Color LightYellow(0xFF, 0xFF, 0xE0);
00074     const Color LemonChiffon(0xFF, 0xFA, 0xCD);
00075     const Color LightGoldenrodYellow(0xFA, 0xFA, 0xD2);
00076     const Color PapayaWhip(0xFF, 0xEF, 0xD5);
00077     const Color Moccasin(0xFF, 0xE4, 0xB5);
00078     const Color PeachPuff(0xFF, 0xDA, 0xB9);
00079     const Color PaleGoldenrod(0xEE, 0xE8, 0xAA);
00080     const Color Khaki(0xF0, 0xE6, 0x8C);
00081     const Color DarkKhaki(0xBD, 0xB7, 0x6B);
00082 
00083     //Purple colors
00084     const Color Lavender(0xE6, 0xE6, 0xFA);
00085     const Color Thistle(0xD8, 0xBF, 0xD8);
00086     const Color Plum(0xDD, 0xA0, 0xDD);
00087     const Color Violet(0xEE, 0x82, 0xEE);
00088     const Color Orchid(0xDA, 0x70, 0xD6);
00089     const Color Fuchsia(0xFF, 0x00, 0xFF);
00090     const Color Magenta(0xFF, 0x00, 0xFF);
00091     const Color MediumOrchid(0xBA, 0x55, 0xD3);
00092     const Color MediumPurple(0x93, 0x70, 0xDB);
00093     const Color BlueViolet(0x8A, 0x2B, 0xE2);
00094     const Color DarkViolet(0x94, 0x00, 0xD3);
00095     const Color DarkOrchid(0x99, 0x32, 0xCC);
00096     const Color DarkMagenta(0x8B, 0x00, 0x8B);
00097     const Color Purple(0x80, 0x00, 0x80);
00098     const Color Indigo(0x4B, 0x00, 0x82);
00099     const Color SlateBlue(0x6A, 0x5A, 0xCD);
00100     const Color DarkSlateBlue(0x48, 0x3D, 0x8B);
00101 
00102     //Green colors
00103     const Color GreenYellow(0xAD, 0xFF, 0x2F);
00104     const Color Chartreuse(0x7F, 0xFF, 0x00);
00105     const Color LawnGreen(0x7C, 0xFC, 0x00);
00106     const Color Lime(0x00, 0xFF, 0x00);
00107     const Color LimeGreen(0x32, 0xCD, 0x32);
00108     const Color PaleGreen(0x98, 0xFB, 0x98);
00109     const Color LightGreen(0x90, 0xEE, 0x90);
00110     const Color MediumSpringGreen(0x00, 0xFA, 0x9A);
00111     const Color SpringGreen(0x00, 0xFF, 0x7F);
00112     const Color MediumSeaGreen(0x3C, 0xB3, 0x71);
00113     const Color SeaGreen(0x2E, 0x8B, 0x57);
00114     const Color ForestGreen(0x22, 0x8B, 0x22);
00115     const Color Green(0x00, 0x80, 0x00);
00116     const Color DarkGreen(0x00, 0x64, 0x00);
00117     const Color YellowGreen(0x9A, 0xCD, 0x32);
00118     const Color OliveDrab(0x6B, 0x8E, 0x23);
00119     const Color Olive(0x80, 0x80, 0x00);
00120     const Color DarkOliveGreen(0x55, 0x6B, 0x2F);
00121     const Color MediumAquamarine(0x66, 0xCD, 0xAA);
00122     const Color DarkSeaGreen(0x8F, 0xBC, 0x8F);
00123     const Color LightSeaGreen(0x20, 0xB2, 0xAA);
00124     const Color DarkCyan(0x00, 0x8B, 0x8B);
00125     const Color Teal(0x00, 0x80, 0x80);
00126 
00127     //Blue colors
00128     const Color Aqua(0x00, 0xFF, 0xFF);
00129     const Color Cyan(0x00, 0xFF, 0xFF);
00130     const Color LightCyan(0xE0, 0xFF, 0xFF);
00131     const Color PaleTurquoise(0xAF, 0xEE, 0xEE);
00132     const Color Aquamarine(0x7F, 0xFF, 0xD4);
00133     const Color Turquoise(0x40, 0xE0, 0xD0);
00134     const Color MediumTurquoise(0x48, 0xD1, 0xCC);
00135     const Color DarkTurquoise(0x00, 0xCE, 0xD1);
00136     const Color CadetBlue(0x5F, 0x9E, 0xA0);
00137     const Color SteelBlue(0x46, 0x82, 0xB4);
00138     const Color LightSteelBlue(0xB0, 0xC4, 0xDE);
00139     const Color PowderBlue(0xB0, 0xE0, 0xE6);
00140     const Color LightBlue(0xAD, 0xD8, 0xE6);
00141     const Color SkyBlue(0x87, 0xCE, 0xEB);
00142     const Color LightSkyBlue(0x87, 0xCE, 0xFA);
00143     const Color DeepSkyBlue(0x00, 0xBF, 0xFF);
00144     const Color DodgerBlue(0x1E, 0x90, 0xFF);
00145     const Color CornflowerBlue(0x64, 0x95, 0xED);
00146     const Color MediumSlateBlue(0x7B, 0x68, 0xEE);
00147     const Color RoyalBlue(0x41, 0x69, 0xE1);
00148     const Color Blue(0x00, 0x00, 0xFF);
00149     const Color MediumBlue(0x00, 0x00, 0xCD);
00150     const Color DarkBlue(0x00, 0x00, 0x8B);
00151     const Color Navy(0x00, 0x00, 0x80);
00152     const Color MidnightBlue(0x19, 0x19, 0x70);
00153 
00154     //Brown colors
00155     const Color Cornsilk(0xFF, 0xF8, 0xDC);
00156     const Color BlanchedAlmond(0xFF, 0xEB, 0xCD);
00157     const Color Bisque(0xFF, 0xE4, 0xC4);
00158     const Color NavajoWhite(0xFF, 0xDE, 0xAD);
00159     const Color Wheat(0xF5, 0xDE, 0xB3);
00160     const Color BurlyWood(0xDE, 0xB8, 0x87);
00161     const Color Tan(0xD2, 0xB4, 0x8C);
00162     const Color RosyBrown(0xBC, 0x8F, 0x8F);
00163     const Color SandyBrown(0xF4, 0xA4, 0x60);
00164     const Color Goldenrod(0xDA, 0xA5, 0x20);
00165     const Color DarkGoldenrod(0xB8, 0x86, 0x0B);
00166     const Color Peru(0xCD, 0x85, 0x3F);
00167     const Color Chocolate(0xD2, 0x69, 0x1E);
00168     const Color SaddleBrown(0x8B, 0x45, 0x13);
00169     const Color Sienna(0xA0, 0x52, 0x2D);
00170     const Color Brown(0xA5, 0x2A, 0x2A);
00171     const Color Maroon(0x80, 0x00, 0x00);
00172 
00173     //White colors
00174     const Color White(0xFF, 0xFF, 0xFF);
00175     const Color Snow(0xFF, 0xFA, 0xFA);
00176     const Color Honeydew(0xF0, 0xFF, 0xF0);
00177     const Color MintCream(0xF5, 0xFF, 0xFA);
00178     const Color Azure(0xF0, 0xFF, 0xFF);
00179     const Color AliceBlue(0xF0, 0xF8, 0xFF);
00180     const Color GhostWhite(0xF8, 0xF8, 0xFF);
00181     const Color WhiteSmoke(0xF5, 0xF5, 0xF5);
00182     const Color Seashell(0xFF, 0xF5, 0xEE);
00183     const Color Beige(0xF5, 0xF5, 0xDC);
00184     const Color OldLace(0xFD, 0xF5, 0xE6);
00185     const Color FloralWhite(0xFF, 0xFA, 0xF0);
00186     const Color Ivory(0xFF, 0xFF, 0xF0);
00187     const Color AntiqueWhite(0xFA, 0xEB, 0xD7);
00188     const Color Linen(0xFA, 0xF0, 0xE6);
00189     const Color LavenderBlush(0xFF, 0xF0, 0xF5);
00190     const Color MistyRose(0xFF, 0xE4, 0xE1);
00191 
00192     //Grey colors
00193     const Color Gainsboro(0xDC, 0xDC, 0xDC);
00194     const Color LightGrey(0xD3, 0xD3, 0xD3);
00195     const Color Silver(0xC0, 0xC0, 0xC0);
00196     const Color DarkGray(0xA9, 0xA9, 0xA9);
00197     const Color Gray(0x80, 0x80, 0x80);
00198     const Color DimGray(0x69, 0x69, 0x69);
00199     const Color LightSlateGray(0x77, 0x88, 0x99);
00200     const Color SlateGray(0x70, 0x80, 0x90);
00201     const Color DarkSlateGray(0x2F, 0x4F, 0x4F);
00202     const Color Black(0x00, 0x00, 0x00);
00203 
00204     // More Colors
00205     const Color Aubergine(0x2B, 0x0B, 0x30);
00206   }
00207 }