MachineIntelligenceCore:Algorithms
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
Color.hpp
Go to the documentation of this file.
1 
23 #ifndef __COLOR_H__
24 #define __COLOR_H__
25 
26 namespace mic {
27 namespace types {
28 
33 typedef enum {
34  RGBA,
37 } image_type;
38 
43 typedef enum {
44  RED,
46  BLUE,
50 
55 class color_rgba {
56 public:
58  uint8_t r;
60  uint8_t g;
62  uint8_t b;
64  uint8_t a;
65 
70  {
71  r = g = b = a = 0;
72  }
73 
77  color_rgba (uint8_t r_, uint8_t g_, uint8_t b_, uint8_t a_) :
78  r(r_), g(g_), b(b_), a(a_)
79  {}
80 };
81 
82 
83 }//: namespace types
84 
85 }//: namespace mic
86 
87 #endif
image_type
Possible image types.
Definition: Color.hpp:33
uint8_t a
Value of A component.
Definition: Color.hpp:64
BINARY.
Definition: Color.hpp:36
GRAYSCALE.
Definition: Color.hpp:35
uint8_t b
Value of B component.
Definition: Color.hpp:62
Class for storing single a pixel of four channel (RGBA) image.
Definition: Color.hpp:55
color_channel
Possible types of image channels.
Definition: Color.hpp:43
uint8_t g
Value of G component.
Definition: Color.hpp:60
uint8_t r
Value of R component.
Definition: Color.hpp:58
color_rgba(uint8_t r_, uint8_t g_, uint8_t b_, uint8_t a_)
Definition: Color.hpp:77