KiCad PCB EDA Suite
Loading...
Searching...
No Matches
SGCOLOR Class Reference

#include <sg_base.h>

Public Member Functions

 SGCOLOR ()
 
 SGCOLOR (float aRVal, float aGVal, float aBVal)
 
void GetColor (float &aRedVal, float &aGreenVal, float &aBlueVal) const noexcept
 
void GetColor (SGCOLOR &aColor) const noexcept
 
void GetColor (SGCOLOR *aColor) const noexcept
 
bool SetColor (float aRedVal, float aGreenVal, float aBlueVal)
 
bool SetColor (const SGCOLOR &aColor) noexcept
 
bool SetColor (const SGCOLOR *aColor) noexcept
 

Protected Attributes

float red
 
float green
 
float blue
 

Private Member Functions

bool checkRange (float aRedVal, float aGreenVal, float aBlueVal) const noexcept
 

Detailed Description

Definition at line 43 of file sg_base.h.

Constructor & Destructor Documentation

◆ SGCOLOR() [1/2]

SGCOLOR::SGCOLOR ( )

Definition at line 34 of file sg_base.cpp.

References blue, green, and red.

◆ SGCOLOR() [2/2]

SGCOLOR::SGCOLOR ( float  aRVal,
float  aGVal,
float  aBVal 
)

Definition at line 41 of file sg_base.cpp.

References blue, checkRange(), green, and red.

Member Function Documentation

◆ checkRange()

bool SGCOLOR::checkRange ( float  aRedVal,
float  aGreenVal,
float  aBlueVal 
) const
privatenoexcept

Definition at line 118 of file sg_base.cpp.

Referenced by SetColor(), and SGCOLOR().

◆ GetColor() [1/3]

void SGCOLOR::GetColor ( float &  aRedVal,
float &  aGreenVal,
float &  aBlueVal 
) const
noexcept

◆ GetColor() [2/3]

void SGCOLOR::GetColor ( SGCOLOR aColor) const
noexcept

Definition at line 67 of file sg_base.cpp.

References red.

◆ GetColor() [3/3]

void SGCOLOR::GetColor ( SGCOLOR aColor) const
noexcept

Definition at line 75 of file sg_base.cpp.

References red.

◆ SetColor() [1/3]

bool SGCOLOR::SetColor ( const SGCOLOR aColor)
noexcept

Definition at line 98 of file sg_base.cpp.

References red.

◆ SetColor() [2/3]

bool SGCOLOR::SetColor ( const SGCOLOR aColor)
noexcept

Definition at line 107 of file sg_base.cpp.

References red.

◆ SetColor() [3/3]

bool SGCOLOR::SetColor ( float  aRedVal,
float  aGreenVal,
float  aBlueVal 
)

Member Data Documentation

◆ blue

float SGCOLOR::blue
protected

Definition at line 48 of file sg_base.h.

Referenced by SetColor(), and SGCOLOR().

◆ green

float SGCOLOR::green
protected

Definition at line 47 of file sg_base.h.

Referenced by SetColor(), and SGCOLOR().

◆ red

float SGCOLOR::red
protected

Definition at line 46 of file sg_base.h.

Referenced by SetColor(), and SGCOLOR().


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