Main MRPT website > C++ reference for MRPT 1.5.9
List of all members | Public Member Functions | Public Attributes | Static Public Attributes
mrpt::utils::TColor Struct Reference

Detailed Description

A RGB color - 8bit.

Definition at line 26 of file TColor.h.

#include <mrpt/utils/TColor.h>

Public Member Functions

 TColor ()
 
 TColor (uint8_t r, uint8_t g, uint8_t b, uint8_t alpha=255)
 
 TColor (const unsigned int color_RGB_24bit)
 
 TColor (const unsigned int color_RGB_24bit, const uint8_t alpha)
 
 operator unsigned int (void) const
 Operator for implicit conversion into an int binary representation 0xRRGGBB. More...
 
TColoroperator= (const TColor &other)
 
TColoroperator+= (const TColor &other)
 
TColoroperator-= (const TColor &other)
 

Public Attributes

uint8_t R
 
uint8_t G
 
uint8_t B
 
uint8_t A
 

Static Public Attributes

static TColor red = TColor(255,0,0)
 Predefined colors. More...
 
static TColor green = TColor(0,255,0)
 Predefined colors. More...
 
static TColor blue = TColor(0,0,255)
 Predefined colors. More...
 
static TColor white = TColor(255,255,255)
 Predefined colors. More...
 
static TColor black = TColor(0,0,0)
 Predefined colors. More...
 
static TColor gray = TColor(127,127,127)
 Predefined colors. More...
 

Constructor & Destructor Documentation

◆ TColor() [1/4]

mrpt::utils::TColor::TColor ( )
inline

Definition at line 28 of file TColor.h.

◆ TColor() [2/4]

mrpt::utils::TColor::TColor ( uint8_t  r,
uint8_t  g,
uint8_t  b,
uint8_t  alpha = 255 
)
inline

Definition at line 34 of file TColor.h.

◆ TColor() [3/4]

mrpt::utils::TColor::TColor ( const unsigned int  color_RGB_24bit)
inlineexplicit

Definition at line 40 of file TColor.h.

◆ TColor() [4/4]

mrpt::utils::TColor::TColor ( const unsigned int  color_RGB_24bit,
const uint8_t  alpha 
)
inline

Definition at line 46 of file TColor.h.

Member Function Documentation

◆ operator unsigned int()

mrpt::utils::TColor::operator unsigned int ( void  ) const
inline

Operator for implicit conversion into an int binary representation 0xRRGGBB.

Definition at line 57 of file TColor.h.

References R.

◆ operator+=()

TColor & TColor::operator+= ( const TColor other)

Definition at line 46 of file TColor.cpp.

References A, B, G, and R.

◆ operator-=()

TColor & TColor::operator-= ( const TColor other)

Definition at line 55 of file TColor.cpp.

References A, B, G, and R.

◆ operator=()

TColor & TColor::operator= ( const TColor other)

Definition at line 64 of file TColor.cpp.

References A, B, G, and R.

Member Data Documentation

◆ A

uint8_t mrpt::utils::TColor::A

◆ B

uint8_t mrpt::utils::TColor::B

◆ black

TColor TColor::black = TColor(0,0,0)
static

Predefined colors.

Definition at line 69 of file TColor.h.

◆ blue

TColor TColor::blue = TColor(0,0,255)
static

◆ G

uint8_t mrpt::utils::TColor::G

◆ gray

TColor TColor::gray = TColor(127,127,127)
static

Predefined colors.

Definition at line 70 of file TColor.h.

◆ green

TColor TColor::green = TColor(0,255,0)
static

◆ R

uint8_t mrpt::utils::TColor::R

◆ red

TColor TColor::red = TColor(255,0,0)
static

◆ white

TColor TColor::white = TColor(255,255,255)
static

Predefined colors.

Definition at line 68 of file TColor.h.




Page generated by Doxygen 1.8.14 for MRPT 1.5.9 Git: 690a4699f Wed Apr 15 19:29:53 2020 +0200 at miƩ abr 15 19:30:12 CEST 2020