JNGL
Easy to use cross-platform 2D game library
Loading...
Searching...
No Matches
Public Member Functions | Static Public Member Functions | List of all members
Rgb Class Reference

Object representing a RGB color, new version of jngl::Color (which will be deprecated in the future) More...

#include <jngl/Rgb.hpp>

Public Member Functions

 Rgb (float red, float green, float blue)
 
float getRed () const
 0.0f ... 1.0f
 
void setRed (float)
 0.0f ... 1.0f
 
float getGreen () const
 0.0f ... 1.0fu
 
void setGreen (float)
 0.0f ... 1.0f
 
float getBlue () const
 0.0f ... 1.0f
 
void setBlue (float)
 0.0f ... 1.0f
 

Static Public Member Functions

static Rgb u8 (uint8_t red, uint8_t green, uint8_t blue)
 

Detailed Description

Object representing a RGB color, new version of jngl::Color (which will be deprecated in the future)

Definition at line 12 of file Rgb.hpp.

Constructor & Destructor Documentation

◆ Rgb()

Rgb ( float  red,
float  green,
float  blue 
)
Parameters
red0.0f ... 1.0f
green0.0f ... 1.0f
blue0.0f ... 1.0f

Values over 1.0f will result in 1.0f and negatives will result in 0.0f.


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