COGS
Computer Graphics Structures library
cogs::Color4f Struct Reference

Holds four color channels in float format in range 0-1. More...

Public Member Functions

 Color4f (float red, float green, float blue, float alpha)
 
 Color4f (const Color3b &col)
 
 Color4f (const Color4b &col)
 
 Color4f (const Color3f &col)
 
 Color4f (const Color3f &col, float alpha)
 
 Color4f (const Color3hex &col)
 
 Color4f (const Color4hex &col)
 
float * GetPtr ()
 
const float * GetPtr () const
 
Color4f operator+ (const Color4f &col) const
 
Color4f & operator+= (const Color4f &col)
 
Color4f & operator*= (float multiplier)
 
Color4f Mix (const Color4f &col, float weight) const
 

Data Fields

float r = 0.0f
 
float g = 0.0f
 
float b = 0.0f
 
float a = 1.0f
 

Detailed Description

Holds four color channels in float format in range 0-1.