Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:08:17

0001 #ifndef _SIPIXELCONTINUOUSPALETTE_
0002 #define _SIPIXELCONTINUOUSPALETTE_
0003 
0004 /** \class SiPixelContinuousPalette
0005  * *
0006  *  Class that handles the SiPixel color codes
0007  *
0008  *  \author Dario Menasce
0009  *
0010  *  This namespace defines a color space to produce
0011  *  a smooth color palette. The index of the r,g and b
0012  *  vectors is a normalized integer [0-99].
0013  */
0014 
0015 namespace SiPixelContinuousPalette {
0016   constexpr int r[] = {255, 134, 122, 110, 98,  86,  74,  63,  51,  39,  27,  15,  3,   0,   0,   0,   0,
0017                        0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0,
0018                        0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0,
0019                        0,   0,   0,   0,   10,  22,  34,  46,  57,  69,  81,  93,  105, 117, 129, 141, 153,
0020                        165, 176, 188, 200, 212, 224, 236, 248, 250, 255, 255, 255, 255, 255, 255, 255, 255,
0021                        255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255};
0022 
0023   constexpr int g[] = {255, 0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   20,  32,  44,
0024                        56,  68,  80,  91,  103, 115, 127, 139, 151, 163, 175, 187, 199, 210, 222, 234, 246,
0025                        255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,
0026                        255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,
0027                        255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 238, 226, 214, 202, 190, 178, 166,
0028                        154, 142, 131, 119, 107, 95,  83,  71,  59,  47,  35,  23,  12,  0,   0};
0029   constexpr int b[] = {255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,
0030                        255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,
0031                        253, 251, 239, 227, 216, 204, 192, 180, 168, 156, 144, 132, 120, 108, 97,  85,  73,
0032                        61,  49,  37,  25,  13,  6,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0,
0033                        0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0,
0034                        0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0,   0};
0035 }  // namespace SiPixelContinuousPalette
0036 
0037 #endif