Cuberite
A lightweight, fast and extensible game server for Minecraft
Public Types | Public Member Functions | Public Attributes | List of all members
cColor Class Reference

#include <Color.h>

Public Types

enum  eColorLimits : unsigned int { COLOR_MIN = 0, COLOR_MAX = 255, COLOR_LIMIT = 256, COLOR_NONE = 0xFFFFFFFF }
 

Public Member Functions

 cColor ()
 
 cColor (unsigned char a_Red, unsigned char a_Green, unsigned char a_Blue)
 
void Clear ()
 Resets the color. More...
 
unsigned char GetBlue () const
 Returns the blue value of the color. More...
 
unsigned char GetGreen () const
 Returns the green value of the color. More...
 
unsigned char GetRed () const
 Returns the red value of the color. More...
 
bool IsValid () const
 Returns whether the color is a valid color. More...
 
void SetBlue (unsigned char a_Blue)
 Alters the blue value of the color. More...
 
void SetColor (unsigned char a_Red, unsigned char a_Green, unsigned char a_Blue)
 Changes the color. More...
 
void SetGreen (unsigned char a_Green)
 Alters the green value of the color. More...
 
void SetRed (unsigned char a_Red)
 Alters the red value of the color. More...
 

Public Attributes

unsigned int m_Color
 

Detailed Description

Definition at line 13 of file Color.h.

Member Enumeration Documentation

enum cColor::eColorLimits : unsigned int
Enumerator
COLOR_MIN 
COLOR_MAX 
COLOR_LIMIT 
COLOR_NONE 

Definition at line 17 of file Color.h.

Constructor & Destructor Documentation

cColor::cColor ( )
inline

Definition at line 24 of file Color.h.

cColor::cColor ( unsigned char  a_Red,
unsigned char  a_Green,
unsigned char  a_Blue 
)
inline

Definition at line 25 of file Color.h.

Member Function Documentation

void cColor::Clear ( void  )
inline

Resets the color.

Definition at line 53 of file Color.h.

unsigned char cColor::GetBlue ( ) const

Returns the blue value of the color.

Definition at line 73 of file Color.cpp.

unsigned char cColor::GetGreen ( ) const

Returns the green value of the color.

Definition at line 64 of file Color.cpp.

unsigned char cColor::GetRed ( ) const

Returns the red value of the color.

Definition at line 55 of file Color.cpp.

bool cColor::IsValid ( void  ) const
inline

Returns whether the color is a valid color.

Definition at line 28 of file Color.h.

void cColor::SetBlue ( unsigned char  a_Blue)

Alters the blue value of the color.

Definition at line 46 of file Color.cpp.

void cColor::SetColor ( unsigned char  a_Red,
unsigned char  a_Green,
unsigned char  a_Blue 
)

Changes the color.

Definition at line 19 of file Color.cpp.

void cColor::SetGreen ( unsigned char  a_Green)

Alters the green value of the color.

Definition at line 37 of file Color.cpp.

void cColor::SetRed ( unsigned char  a_Red)

Alters the red value of the color.

Definition at line 28 of file Color.cpp.

Member Data Documentation

unsigned int cColor::m_Color

Definition at line 56 of file Color.h.


The documentation for this class was generated from the following files: