ADTF Display Toolbox
Loading...
Searching...
No Matches
color_intf.h
Go to the documentation of this file.
1
7#pragma once
8
9namespace adtf
10{
11
12namespace disptb
13{
14
15namespace graphicslib
16{
17
18namespace dengar
19{
20
26class IColor
27{
28public:
32 virtual ~IColor()
33 {
34 }
35
39 virtual tVoid Release() = 0;
40
47 virtual tUInt32 GetRGBA() const = 0;
48
56 virtual tVoid SetRGBA(tUInt32 nRGBA) = 0;
57
63 virtual tUInt8 GetRed() const = 0;
64
72 virtual tVoid SetRed(tUInt8 nRedValue) = 0;
73
79 virtual tUInt8 GetGreen() const = 0;
80
88 virtual tVoid SetGreen(tUInt8 nGreenValue) = 0;
89
95 virtual tUInt8 GetBlue() const = 0;
96
104 virtual tVoid SetBlue(tUInt8 nBlueValue) = 0;
105
111 virtual tUInt8 GetAlpha() const = 0;
112
120 virtual tVoid SetAlpha(tUInt8 nAlphaValue) = 0;
121
127 virtual tUInt8 GetBrightness() const = 0;
128};
129
130} // namespace dengar
131
132using dengar::IColor;
133} // namespace graphicslib
134
135} // namespace disptb
136
137} // namespace adtf
Interface for color representation.
Definition color_intf.h:27
virtual tUInt8 GetRed() const =0
Returns the value for the red channel.
virtual tUInt8 GetAlpha() const =0
This function returns the value for the alpha channel.
virtual tUInt8 GetBrightness() const =0
This function returns the value for a calculated brightness.
virtual tUInt8 GetBlue() const =0
Returns the value for the blue channel.
virtual tVoid SetRGBA(tUInt32 nRGBA)=0
Sets a four Byte value containing the 3 Color channels and the alpha channel with the given value.
virtual ~IColor()
virtual destructor to ensure proper cleanup.
Definition color_intf.h:32
virtual tVoid Release()=0
Releases this color.
virtual tVoid SetGreen(tUInt8 nGreenValue)=0
Sets the value of the green channel.
virtual tVoid SetBlue(tUInt8 nBlueValue)=0
Sets the value of the blue channel.
virtual tVoid SetRed(tUInt8 nRedValue)=0
Sets the value of the red channel.
virtual tUInt8 GetGreen() const =0
Returns the value for the green channel.
virtual tUInt32 GetRGBA() const =0
Gets a four Byte value containing the 3 color channels and the alpha channel.
virtual tVoid SetAlpha(tUInt8 nAlphaValue)=0
Sets the value of the alpha channel.
Namespace for functionality provided by the Display Toolbox.
Main namespace.