Version: 1.0
Loading...
Searching...
No Matches
Color conversion functions

Detailed Description

The functions in this section are used in color conversion between various color spaces.

Functions

void rgb2yiq (unsigned char *R, unsigned char *G, unsigned char *B, short *Y, short *I, short *Q)
 RGB to YIQ color space conversion.
 
void yiq2rgb (short *Y, short *I, short *Q, unsigned char *R, unsigned char *G, unsigned char *B)
 YIQ to RGB color space conversion.
 
void rgb2hsl (float r, float g, float b, float *h, float *s, float *l)
 RGB to HSL color space conversion.
 
void hsl2rgb (float h, float s, float l, float *r, float *g, float *b)
 HSL to RGB color space conversion.
 
void rgb2hsv (unsigned char R, unsigned char G, unsigned char B, unsigned char *H, unsigned char *S, unsigned char *V)
 RGB to HSV color space conversion.
 
void hsv2rgb (unsigned char H, unsigned char S, unsigned char V, unsigned char *R, unsigned char *G, unsigned char *B)
 HSV to RGB color space conversion.
 
void rgb2ycbcr (unsigned char R, unsigned char G, unsigned char B, unsigned char *y, unsigned char *cb, unsigned char *cr)
 RGB to YCbCr color space conversion.
 
void ycbcr2rgb (unsigned char y, unsigned char Cb, unsigned char Cr, unsigned char *R, unsigned char *G, unsigned char *B)
 YCbCr to RGB color space conversion.
 
void rgb2cmyk (unsigned char R, unsigned char G, unsigned char B, float *c, float *m, float *y, float *k)
 RGB to CMYK color space conversion.
 
void cmyk2rgb (float c, float m, float y, float k, unsigned char *R, unsigned char *G, unsigned char *B)
 CMYK to RGB color space conversion.
 
void lab2rgb (double L, double a, double b, unsigned char *R, unsigned char *G, unsigned char *B)
 CIELAB to RGB color space conversion.
 
void rgb2lab (unsigned char R, unsigned char G, unsigned char B, double *L, double *a, double *b)
 RGB to CIELAB color space conversion.
 

Function Documentation

◆ rgb2yiq()

void rgb2yiq ( unsigned char * R,
unsigned char * G,
unsigned char * B,
short * Y,
short * I,
short * Q )

RGB to YIQ color space conversion.

◆ yiq2rgb()

void yiq2rgb ( short * Y,
short * I,
short * Q,
unsigned char * R,
unsigned char * G,
unsigned char * B )

YIQ to RGB color space conversion.

◆ rgb2hsl()

void rgb2hsl ( float r,
float g,
float b,
float * h,
float * s,
float * l )

RGB to HSL color space conversion.

◆ hsl2rgb()

void hsl2rgb ( float h,
float s,
float l,
float * r,
float * g,
float * b )

HSL to RGB color space conversion.

◆ rgb2hsv()

void rgb2hsv ( unsigned char R,
unsigned char G,
unsigned char B,
unsigned char * H,
unsigned char * S,
unsigned char * V )

RGB to HSV color space conversion.

◆ hsv2rgb()

void hsv2rgb ( unsigned char H,
unsigned char S,
unsigned char V,
unsigned char * R,
unsigned char * G,
unsigned char * B )

HSV to RGB color space conversion.

◆ rgb2ycbcr()

void rgb2ycbcr ( unsigned char R,
unsigned char G,
unsigned char B,
unsigned char * y,
unsigned char * cb,
unsigned char * cr )

RGB to YCbCr color space conversion.

◆ ycbcr2rgb()

void ycbcr2rgb ( unsigned char y,
unsigned char Cb,
unsigned char Cr,
unsigned char * R,
unsigned char * G,
unsigned char * B )

YCbCr to RGB color space conversion.

◆ rgb2cmyk()

void rgb2cmyk ( unsigned char R,
unsigned char G,
unsigned char B,
float * c,
float * m,
float * y,
float * k )

RGB to CMYK color space conversion.

◆ cmyk2rgb()

void cmyk2rgb ( float c,
float m,
float y,
float k,
unsigned char * R,
unsigned char * G,
unsigned char * B )

CMYK to RGB color space conversion.

◆ lab2rgb()

void lab2rgb ( double L,
double a,
double b,
unsigned char * R,
unsigned char * G,
unsigned char * B )

CIELAB to RGB color space conversion.

◆ rgb2lab()

void rgb2lab ( unsigned char R,
unsigned char G,
unsigned char B,
double * L,
double * a,
double * b )

RGB to CIELAB color space conversion.