cRgb24
Overview
Types and Definitions
cRgb24
struct cRgb24
{
uint8_t red;
uint8_t green;
uint8_t blue;
};
typedef struct cRgb24 cRgb24;
The cRgb24 struct can store a color from the RGB color space in 24 bits.
Generated
cRgb24Slice
struct cRgb24Slice
{
int64_t s;
cRgb24 const* v;
};
typedef struct cRgb24Slice cRgb24Slice;
Via the macro SLICES_C_ generated struct.
cVarRgb24Slice
struct cVarRgb24Slice
{
int64_t s;
cRgb24* v;
};
typedef struct cVarRgb24Slice cVarRgb24Slice;
Via the macro SLICES_C_ generated struct.
Functions
overall
rgb24_c_
#define rgb24_c_( Red, Green, Blue )
Creates a cCmyk instance.
eq_rgb24_c
#define eq_rgb24_c_( A, B ) \
eq_rgb24_c( (A), (B) )
bool eq_rgb24_c( cRgb24 a, cRgb24 b );
Example
#include "clingo/lang/expect.h"
#include "clingo/color/cRgb24.h"
int main( void )
{
init_tap_c_();
cRgb24 c1 = { 90, 46, 75 };
cRgb24 c2 = { 87, 75, 25 };
expect_c_( eq_rgb24_c( c1, c1 ) );
expect_c_( !eq_rgb24_c( c1, c2 ) );
return finish_tap_c_();
}