41 lines
781 B
C++
41 lines
781 B
C++
|
#ifndef LIBRARY_COLOR_HPP
|
||
|
#define LIBRARY_COLOR_HPP
|
||
|
|
||
|
namespace vkvm {
|
||
|
|
||
|
/**
|
||
|
* color values represented as rgb values.
|
||
|
* @author Johannes Theiner
|
||
|
* @since 0.1.0
|
||
|
*/
|
||
|
class Color {
|
||
|
|
||
|
private:
|
||
|
unsigned char red;
|
||
|
unsigned char green;
|
||
|
unsigned char blue;
|
||
|
|
||
|
public:
|
||
|
Color(unsigned char red, unsigned char green, unsigned char blue) noexcept;
|
||
|
|
||
|
auto getRed() -> unsigned char;
|
||
|
|
||
|
auto getGreen() -> unsigned char;
|
||
|
|
||
|
auto getBlue() -> unsigned char;
|
||
|
|
||
|
auto setRed(unsigned char value) -> void;
|
||
|
|
||
|
auto setGreen(unsigned char value) -> void;
|
||
|
|
||
|
auto setBlue(unsigned char value) -> void;
|
||
|
|
||
|
};
|
||
|
|
||
|
const static Color black = Color(0, 0, 0);
|
||
|
const static Color white = Color(255, 255, 255);
|
||
|
|
||
|
}
|
||
|
|
||
|
#endif
|