Ardour  9.0-pre0-582-g084a23a80d
libs/gtkmm2ext/gtkmm2ext/rgb_macros.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define RGB_TO_UINT(r, g, b)   ((((guint)(r))<<16)|(((guint)(g))<<8)|((guint)(b)))
 
#define RGB_TO_RGBA(x, a)   (((x) << 8) | ((((guint)a) & 0xff)))
 
#define RGBA_TO_UINT(r, g, b, a)   RGB_TO_RGBA(RGB_TO_UINT(r,g,b), a)
 
#define RGB_WHITE   RGB_TO_UINT(0xff, 0xff, 0xff)
 
#define RGB_BLACK   RGB_TO_UINT(0x00, 0x00, 0x00)
 
#define RGB_RED   RGB_TO_UINT(0xff, 0x00, 0x00)
 
#define RGB_GREEN   RGB_TO_UINT(0x00, 0xff, 0x00)
 
#define RGB_BLUE   RGB_TO_UINT(0x00, 0x00, 0xff)
 
#define RGB_YELLOW   RGB_TO_UINT(0xff, 0xff, 0x00)
 
#define RGB_VIOLET   RGB_TO_UINT(0xff, 0x00, 0xff)
 
#define RGB_CYAN   RGB_TO_UINT(0x00, 0xff, 0xff)
 
#define RGBA_WHITE   RGB_TO_RGBA(RGB_WHITE, 0xff)
 
#define RGBA_BLACK   RGB_TO_RGBA(RGB_BLACK, 0xff)
 
#define RGBA_RED   RGB_TO_RGBA(RGB_RED, 0xff)
 
#define RGBA_GREEN   RGB_TO_RGBA(RGB_GREEN, 0xff)
 
#define RGBA_BLUE   RGB_TO_RGBA(RGB_BLUE, 0xff)
 
#define RGBA_YELLOW   RGB_TO_RGBA(RGB_YELLOW, 0xff)
 
#define RGBA_VIOLET   RGB_TO_RGBA(RGB_VIOLET, 0xff)
 
#define RGBA_CYAN   RGB_TO_RGBA(RGB_CYAN, 0xff)
 
#define RGB_GREY(x)   RGB_TO_UINT(x,x,x)
 
#define RGBA_GREY(x)   RGB_TO_RGBA(RGB_GREY(x), 0xff)
 
#define UINT_RGBA_R(x)   (((guint)(x))>>24)
 
#define UINT_RGBA_G(x)   ((((guint)(x))>>16)&0xff)
 
#define UINT_RGBA_B(x)   ((((guint)(x))>>8)&0xff)
 
#define UINT_RGBA_A(x)   (((guint)(x))&0xff)
 
#define UINT_RGBA_R_FLT(x)   ((((guint)(x))>>24)/255.0)
 
#define UINT_RGBA_G_FLT(x)   (((((guint)(x))>>16)&0xff)/255.0)
 
#define UINT_RGBA_B_FLT(x)   (((((guint)(x))>>8)&0xff)/255.0)
 
#define UINT_RGBA_A_FLT(x)   ((((guint)(x))&0xff)/255.0)
 
#define UINT_RGBA_CHANGE_R(x, r)   (((x)&(~(0xff<<24)))|(((r)&0xff)<<24))
 
#define UINT_RGBA_CHANGE_G(x, g)   (((x)&(~(0xff<<16)))|(((g)&0xff)<<16))
 
#define UINT_RGBA_CHANGE_B(x, b)   (((x)&(~(0xff<<8)))|(((b)&0xff)<<8))
 
#define UINT_RGBA_CHANGE_A(x, a)   (((x)&(~0xff))|((a)&0xff))
 
#define UINT_TO_RGB(u, r, g, b)   { (*(r)) = ((u)>>16)&0xff; (*(g)) = ((u)>>8)&0xff; (*(b)) = (u)&0xff; }
 
#define UINT_TO_RGBA(u, r, g, b, a)   { UINT_TO_RGB(((u)>>8),r,g,b); (*(a)) = (u)&0xff; }
 
#define MONO_INTERPOLATE(v1, v2, t)   ((gint)rint((v2)*(t)+(v1)*(1-(t))))
 
#define UINT_INTERPOLATE(c1, c2, t)
 
#define PIXEL_RGB(p, r, g, b)   {((guchar*)(p))[0]=(r); ((guchar*)(p))[1]=(g); ((guchar*)(p))[2]=(b);}
 
#define PIXEL_RGBA(p, r, g, b, a)
 
#define PIXEL_RGB_UINT(p, i)   UINT_TO_RGB((i), ((guchar*)p), ((guchar*)p)+1, ((guchar*)p)+2)
 
#define PIXEL_RGBA_UINT(p, i)    PIXEL_RGBA((p), ((i)>>24)&0xff, ((i)>>16)&0xff, ((i)>>8)&0xff, (i)&0xff)
 
#define PIXEL_BLACK(p)   PIXEL_RGB(p,0,0,0)
 
#define PIXEL_WHITE(p)   PIXEL_RGB(p,0xff,0xff,0xff)
 
#define PIXEL_GREY(p, g)   PIXEL_RGB(p,g,g,g)
 
#define PIXEL_GREYA(p, g, a)   PIXEL_RGBA(p,g,g,g,a)
 
#define BUF_PTR(inbuf, ptx, pty)    ((inbuf)->buf + 3*((ptx)-(inbuf)->rect.x0) + (inbuf)->buf_rowstride*((pty)-(inbuf)->rect.y0))
 
#define BUF_INBOUNDS_X(inbuf, ptx)   ((inbuf)->rect.x0 <= (ptx) && (ptx) < (inbuf)->rect.x1)
 
#define BUF_INBOUNDS_Y(inbuf, pty)   ((inbuf)->rect.y0 <= (pty) && (pty) < (inbuf)->rect.y1)
 
#define PAINT_DOT(inbuf, colr, colg, colb, ptx, pty)
 
#define FAST_PAINT_DOT(inbuf, colr, colg, colb, ptx, pty)
 
#define PAINT_DOTA(inbuf, colr, colg, colb, cola, ptx, pty)
 
#define FAST_PAINT_DOTA(inbuf, colr, colg, colb, cola, ptx, pty)
 
#define PAINT_HORIZ(inbuf, colr, colg, colb, ptx0, ptx1, pty)
 
#define FAST_PAINT_HORIZ(inbuf, colr, colg, colb, ptx0, ptx1, pty)
 
#define PAINT_HORIZA(inbuf, colr, colg, colb, cola, ptx0, ptx1, pty)
 
#define PAINT_VERT(inbuf, colr, colg, colb, ptx, pty0, pty1)
 
#define FAST_PAINT_VERT(inbuf, colr, colg, colb, ptx, pty0, pty1)
 
#define PAINT_VERTA(inbuf, colr, colg, colb, cola, ptx, pty0, pty1)
 
#define PAINT_VERTA_GR(inbuf, colr, colg, colb, cola, ptx, pty0, pty1, origin_y, obj_top)
 
#define PAINT_BOX(inbuf, colr, colg, colb, cola, ptx0, pty0, ptx1, pty1)
 
#define PAINT_BOX_GR(inbuf, colr, colg, colb, cola, ptx0, pty0, ptx1, pty1, v_span)
 
#define FAST_PAINT_BOX(inbuf, colr, colg, colb, cola, ptx0, pty0, ptx1, pty1)
 

Macro Definition Documentation

◆ BUF_INBOUNDS_X

#define BUF_INBOUNDS_X (   inbuf,
  ptx 
)    ((inbuf)->rect.x0 <= (ptx) && (ptx) < (inbuf)->rect.x1)

Definition at line 93 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ BUF_INBOUNDS_Y

#define BUF_INBOUNDS_Y (   inbuf,
  pty 
)    ((inbuf)->rect.y0 <= (pty) && (pty) < (inbuf)->rect.y1)

Definition at line 95 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ BUF_PTR

#define BUF_PTR (   inbuf,
  ptx,
  pty 
)     ((inbuf)->buf + 3*((ptx)-(inbuf)->rect.x0) + (inbuf)->buf_rowstride*((pty)-(inbuf)->rect.y0))

Definition at line 91 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ FAST_PAINT_BOX

#define FAST_PAINT_BOX (   inbuf,
  colr,
  colg,
  colb,
  cola,
  ptx0,
  pty0,
  ptx1,
  pty1 
)
Value:
{ \
GnomeCanvasBuf* pb_buf = (inbuf); \
guchar* pb_p; \
guchar* pb_pp; \
gint pb_i, pb_j; \
\
pb_p = BUF_PTR(pb_buf, ptx0, pty0); \
for (pb_j=pty0; pb_j<pty1; ++pb_j) { \
pb_pp = pb_p; \
for (pb_i=ptx0; pb_i<ptx1; ++pb_i) { \
PIXEL_RGBA(pb_pp, colr, colg, colb, cola); \
pb_pp += 3; \
} \
pb_p += pb_buf->buf_rowstride; \
} \
}
#define BUF_PTR(inbuf, ptx, pty)

Definition at line 331 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ FAST_PAINT_DOT

#define FAST_PAINT_DOT (   inbuf,
  colr,
  colg,
  colb,
  ptx,
  pty 
)
Value:
{ \
guchar* pd_p; \
pd_p = BUF_PTR(inbuf, ptx, pty); \
PIXEL_RGB(pd_p, (colr), (colg), (colb)); \
}

Definition at line 105 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ FAST_PAINT_DOTA

#define FAST_PAINT_DOTA (   inbuf,
  colr,
  colg,
  colb,
  cola,
  ptx,
  pty 
)
Value:
{ \
guchar* pd_p; \
pd_p = BUF_PTR(inbuf, ptx, pty); \
PIXEL_RGBA(pd_p, (colr), (colg), (colb), (cola)); \
}

Definition at line 119 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ FAST_PAINT_HORIZ

#define FAST_PAINT_HORIZ (   inbuf,
  colr,
  colg,
  colb,
  ptx0,
  ptx1,
  pty 
)
Value:
{ \
GnomeCanvasBuf* ph_buf = (inbuf); \
guchar* ph_p; \
gint ph_a0, ph_a1; \
gint ph_colr=(colr), ph_colg=(colg), ph_colb=(colb); \
\
ph_a0 = MAX(ph_buf->rect.x0, (gint)(ptx0)); \
ph_a1 = MIN(ph_buf->rect.x1, (gint)(ptx1)); \
\
if (ph_a0 < ph_a1 && BUF_INBOUNDS_Y(ph_buf, (gint)(pty))) { \
ph_p = BUF_PTR(ph_buf, ph_a0, pty); \
while (ph_a0 < ph_a1) { \
PIXEL_RGB(ph_p, ph_colr, ph_colg, ph_colb); \
++ph_a0; \
ph_p += 3; \
} \
} \
}
#define BUF_INBOUNDS_Y(inbuf, pty)

Definition at line 144 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ FAST_PAINT_VERT

#define FAST_PAINT_VERT (   inbuf,
  colr,
  colg,
  colb,
  ptx,
  pty0,
  pty1 
)
Value:
{ \
GnomeCanvasBuf* fpv_buf = (inbuf); \
guchar* fpv_p; \
gint fpv_b0, fpv_b1; \
\
fpv_b0 = MAX(fpv_buf->rect.y0, (gint)(pty0)); \
fpv_b1 = MIN(fpv_buf->rect.y1, (gint)(pty1)); \
\
fpv_p = BUF_PTR(fpv_buf, ptx, fpv_b0); \
\
while (fpv_b0 < fpv_b1) { \
PIXEL_RGB(fpv_p, colr, colg, colb); \
++fpv_b0; \
fpv_p += fpv_buf->buf_rowstride; \
} \
}

Definition at line 201 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ MONO_INTERPOLATE

#define MONO_INTERPOLATE (   v1,
  v2,
 
)    ((gint)rint((v2)*(t)+(v1)*(1-(t))))

Definition at line 65 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ PAINT_BOX

#define PAINT_BOX (   inbuf,
  colr,
  colg,
  colb,
  cola,
  ptx0,
  pty0,
  ptx1,
  pty1 
)
Value:
{ \
GnomeCanvasBuf* pb_buf = (inbuf); \
guchar* pb_p; \
guchar* pb_pp; \
gint pb_a0, pb_a1, pb_b0, pb_b1, pb_i, pb_j; \
gint pb_colr=(colr), pb_colg=(colg), pb_colb=(colb), pb_cola=(cola); \
\
pb_a0 = MAX(pb_buf->rect.x0, (ptx0)); \
pb_a1 = MIN(pb_buf->rect.x1, (ptx1)); \
pb_b0 = MAX(pb_buf->rect.y0, (pty0)); \
pb_b1 = MIN(pb_buf->rect.y1, (pty1)); \
\
if (pb_a0 < pb_a1 && pb_b0 < pb_b1) { \
pb_p = BUF_PTR(pb_buf, pb_a0, pb_b0); \
for (pb_j=pb_b0; pb_j<pb_b1; ++pb_j) { \
pb_pp = pb_p; \
for (pb_i=pb_a0; pb_i<pb_a1; ++pb_i) { \
PIXEL_RGBA(pb_pp, pb_colr, pb_colg, pb_colb, pb_cola); \
pb_pp += 3; \
} \
pb_p += pb_buf->buf_rowstride; \
} \
} \
}

Definition at line 267 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ PAINT_BOX_GR

#define PAINT_BOX_GR (   inbuf,
  colr,
  colg,
  colb,
  cola,
  ptx0,
  pty0,
  ptx1,
  pty1,
  v_span 
)
Value:
{ \
GnomeCanvasBuf* pb_buf = (inbuf); \
guchar* pb_p; \
guchar* pb_pp; \
gint pb_a0, pb_a1, pb_b0, pb_b1, pb_i, pb_j; \
gint pb_colr=(colr), pb_colg=(colg), pb_colb=(colb), pb_cola=(cola); \
gint sat; \
gint y_fract; \
gint y_span = MAX(abs(v_span), 1); \
\
pb_a0 = MAX(pb_buf->rect.x0, (ptx0)); \
pb_a1 = MIN(pb_buf->rect.x1, (ptx1)); \
pb_b0 = MAX(pb_buf->rect.y0, (pty0)); \
pb_b1 = MIN(pb_buf->rect.y1, (pty1)); \
\
if (pb_a0 < pb_a1 && pb_b0 < pb_b1) { \
pb_p = BUF_PTR(pb_buf, pb_a0, pb_b0); \
for (pb_j=pb_b0; pb_j<pb_b1; ++pb_j) { \
y_fract = 0xFF * (abs(pb_j - pty0)); \
y_fract = y_fract / y_span; \
sat = 0xFF - (y_fract >> 1); \
pb_pp = pb_p; \
for (pb_i=pb_a0; pb_i<pb_a1; ++pb_i) { \
PIXEL_RGBA(pb_pp, (((pb_colr << 8) * sat) >> 16), (((pb_colg << 8) * sat) >> 16), (((pb_colb << 8) * sat) >> 16), pb_cola); \
pb_pp += 3; \
} \
pb_p += pb_buf->buf_rowstride; \
} \
} \
}

Definition at line 296 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ PAINT_DOT

#define PAINT_DOT (   inbuf,
  colr,
  colg,
  colb,
  ptx,
  pty 
)
Value:
{ \
guchar* pd_p; \
if (BUF_INBOUNDS_X(inbuf, ptx) && BUF_INBOUNDS_Y(inbuf, pty)) { \
pd_p = BUF_PTR(inbuf, ptx, pty); \
PIXEL_RGB(pd_p, (colr), (colg), (colb)); \
} \
}
#define BUF_INBOUNDS_X(inbuf, ptx)

Definition at line 97 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ PAINT_DOTA

#define PAINT_DOTA (   inbuf,
  colr,
  colg,
  colb,
  cola,
  ptx,
  pty 
)
Value:
{ \
guchar* pd_p; \
if (BUF_INBOUNDS_X(inbuf, ptx) && BUF_INBOUNDS_Y(inbuf, pty)) { \
pd_p = BUF_PTR(inbuf, ptx, pty); \
PIXEL_RGBA(pd_p, (colr), (colg), (colb), (cola)); \
} \
}

Definition at line 111 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ PAINT_HORIZ

#define PAINT_HORIZ (   inbuf,
  colr,
  colg,
  colb,
  ptx0,
  ptx1,
  pty 
)
Value:
{ \
GnomeCanvasBuf* ph_buf = (inbuf); \
guchar* ph_p; \
gint ph_a0, ph_a1; \
gint ph_colr=(colr), ph_colg=(colg), ph_colb=(colb); \
\
ph_a0 = MAX(ph_buf->rect.x0, (gint)(ptx0)); \
ph_a1 = MIN(ph_buf->rect.x1, (gint)(ptx1)); \
\
if (ph_a0 < ph_a1 && BUF_INBOUNDS_Y(ph_buf, (gint)(pty))) { \
ph_p = BUF_PTR(ph_buf, ph_a0, pty); \
while (ph_a0 < ph_a1) { \
PIXEL_RGB(ph_p, ph_colr, ph_colg, ph_colb); \
++ph_a0; \
ph_p += 3; \
} \
} \
}

Definition at line 125 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ PAINT_HORIZA

#define PAINT_HORIZA (   inbuf,
  colr,
  colg,
  colb,
  cola,
  ptx0,
  ptx1,
  pty 
)
Value:
{ \
GnomeCanvasBuf* ph_buf = (inbuf); \
guchar* ph_p; \
gint ph_a0, ph_a1; \
gint ph_colr=(colr), ph_colg=(colg), ph_colb=(colb), ph_cola=(cola); \
\
ph_a0 = MAX(ph_buf->rect.x0, (gint)(ptx0)); \
ph_a1 = MIN(ph_buf->rect.x1, (gint)(ptx1)); \
\
if (ph_a0 < ph_a1 && BUF_INBOUNDS_Y(ph_buf, (gint)(pty))) { \
ph_p = BUF_PTR(ph_buf, ph_a0, pty); \
while (ph_a0 < ph_a1) { \
PIXEL_RGBA(ph_p, ph_colr, ph_colg, ph_colb, ph_cola); \
++ph_a0; \
ph_p += 3; \
} \
} \
}

Definition at line 163 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ PAINT_VERT

#define PAINT_VERT (   inbuf,
  colr,
  colg,
  colb,
  ptx,
  pty0,
  pty1 
)
Value:
{ \
GnomeCanvasBuf* pv_buf = (inbuf); \
guchar* pv_p; \
gint pv_b0, pv_b1; \
gint pv_colr=(colr), pv_colg=(colg), pv_colb=(colb);\
\
pv_b0 = MAX(pv_buf->rect.y0, (gint)(pty0)); \
pv_b1 = MIN(pv_buf->rect.y1, (gint)(pty1)); \
\
if (pv_b0 < pv_b1 && BUF_INBOUNDS_X(pv_buf, (gint)(ptx))) { \
pv_p = BUF_PTR(pv_buf, ptx, pv_b0); \
while (pv_b0 < pv_b1) { \
PIXEL_RGB(pv_p, pv_colr, pv_colg, pv_colb); \
++pv_b0; \
pv_p += pv_buf->buf_rowstride; \
} \
} \
}

Definition at line 182 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ PAINT_VERTA

#define PAINT_VERTA (   inbuf,
  colr,
  colg,
  colb,
  cola,
  ptx,
  pty0,
  pty1 
)
Value:
{ \
GnomeCanvasBuf* pv_buf = (inbuf); \
guchar* pv_p; \
gint pv_b0, pv_b1; \
gint pv_colr=(colr), pv_colg=(colg), pv_colb=(colb), pv_cola=(cola);\
\
pv_b0 = MAX(pv_buf->rect.y0, (pty0)); \
pv_b1 = MIN(pv_buf->rect.y1, (pty1)); \
\
if (pv_b0 < pv_b1 && BUF_INBOUNDS_X(pv_buf, ptx)) { \
pv_p = BUF_PTR(pv_buf, ptx, pv_b0); \
while (pv_b0 < pv_b1) { \
PIXEL_RGBA(pv_p, pv_colr, pv_colg, pv_colb, pv_cola); \
++pv_b0; \
pv_p += pv_buf->buf_rowstride; \
} \
} \
}

Definition at line 218 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ PAINT_VERTA_GR

#define PAINT_VERTA_GR (   inbuf,
  colr,
  colg,
  colb,
  cola,
  ptx,
  pty0,
  pty1,
  origin_y,
  obj_top 
)
Value:
{ \
GnomeCanvasBuf* pv_buf = (inbuf); \
guchar* pv_p; \
gint pv_b0, pv_b1; \
gint pv_colr=(colr), pv_colg=(colg), pv_colb=(colb), pv_cola=(cola); \
gint y_fract; \
gint y_span = (origin_y - obj_top); \
gint sat; \
\
pv_b0 = MAX(pv_buf->rect.y0, (pty0)); \
pv_b1 = MIN(pv_buf->rect.y1, (pty1)); \
\
if (pv_b0 < pv_b1 && BUF_INBOUNDS_X(pv_buf, ptx)) { \
pv_p = BUF_PTR(pv_buf, ptx, pv_b0); \
while (pv_b0 < pv_b1) { \
y_fract = (abs(origin_y - pv_b0)) * 0xFF; \
y_fract = y_fract / y_span; \
sat = 0xFF - (y_fract); \
PIXEL_RGBA(pv_p, (((pv_colr << 8) * sat) >> 16), (((pv_colg << 8) * sat) >> 16), (((pv_colb << 8) * sat) >> 16), pv_cola); \
++pv_b0; \
pv_p += pv_buf->buf_rowstride; \
} \
} \
}

Definition at line 238 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ PIXEL_BLACK

#define PIXEL_BLACK (   p)    PIXEL_RGB(p,0,0,0)

Definition at line 87 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ PIXEL_GREY

#define PIXEL_GREY (   p,
 
)    PIXEL_RGB(p,g,g,g)

Definition at line 89 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ PIXEL_GREYA

#define PIXEL_GREYA (   p,
  g,
 
)    PIXEL_RGBA(p,g,g,g,a)

Definition at line 90 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ PIXEL_RGB

#define PIXEL_RGB (   p,
  r,
  g,
 
)    {((guchar*)(p))[0]=(r); ((guchar*)(p))[1]=(g); ((guchar*)(p))[2]=(b);}

Definition at line 71 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ PIXEL_RGB_UINT

#define PIXEL_RGB_UINT (   p,
 
)    UINT_TO_RGB((i), ((guchar*)p), ((guchar*)p)+1, ((guchar*)p)+2)

Definition at line 83 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ PIXEL_RGBA

#define PIXEL_RGBA (   p,
  r,
  g,
  b,
 
)
Value:
{ if ((a)>=0xff) { PIXEL_RGB(p,r,g,b) } \
else if ((a)>0) { \
guint pixel_tmp; \
pixel_tmp = ((guchar*)(p))[0]; \
((guchar*)(p))[0] = pixel_tmp + ((((r)-pixel_tmp)*(a)+0x80) >> 8); \
pixel_tmp = ((guchar*)(p))[1]; \
((guchar*)(p))[1] = pixel_tmp + ((((g)-pixel_tmp)*(a)+0x80) >> 8); \
pixel_tmp = ((guchar*)(p))[2]; \
((guchar*)(p))[2] = pixel_tmp + ((((b)-pixel_tmp)*(a)+0x80) >> 8); }}
#define PIXEL_RGB(p, r, g, b)

Definition at line 73 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ PIXEL_RGBA_UINT

#define PIXEL_RGBA_UINT (   p,
 
)     PIXEL_RGBA((p), ((i)>>24)&0xff, ((i)>>16)&0xff, ((i)>>8)&0xff, (i)&0xff)

Definition at line 85 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ PIXEL_WHITE

#define PIXEL_WHITE (   p)    PIXEL_RGB(p,0xff,0xff,0xff)

Definition at line 88 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ RGB_BLACK

#define RGB_BLACK   RGB_TO_UINT(0x00, 0x00, 0x00)

Definition at line 32 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ RGB_BLUE

#define RGB_BLUE   RGB_TO_UINT(0x00, 0x00, 0xff)

Definition at line 35 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ RGB_CYAN

#define RGB_CYAN   RGB_TO_UINT(0x00, 0xff, 0xff)

Definition at line 38 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ RGB_GREEN

#define RGB_GREEN   RGB_TO_UINT(0x00, 0xff, 0x00)

Definition at line 34 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ RGB_GREY

#define RGB_GREY (   x)    RGB_TO_UINT(x,x,x)

Definition at line 47 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ RGB_RED

#define RGB_RED   RGB_TO_UINT(0xff, 0x00, 0x00)

Definition at line 33 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ RGB_TO_RGBA

#define RGB_TO_RGBA (   x,
 
)    (((x) << 8) | ((((guint)a) & 0xff)))

Definition at line 29 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ RGB_TO_UINT

#define RGB_TO_UINT (   r,
  g,
 
)    ((((guint)(r))<<16)|(((guint)(g))<<8)|((guint)(b)))

Definition at line 28 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ RGB_VIOLET

#define RGB_VIOLET   RGB_TO_UINT(0xff, 0x00, 0xff)

Definition at line 37 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ RGB_WHITE

#define RGB_WHITE   RGB_TO_UINT(0xff, 0xff, 0xff)

Definition at line 31 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ RGB_YELLOW

#define RGB_YELLOW   RGB_TO_UINT(0xff, 0xff, 0x00)

Definition at line 36 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ RGBA_BLACK

#define RGBA_BLACK   RGB_TO_RGBA(RGB_BLACK, 0xff)

Definition at line 40 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ RGBA_BLUE

#define RGBA_BLUE   RGB_TO_RGBA(RGB_BLUE, 0xff)

Definition at line 43 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ RGBA_CYAN

#define RGBA_CYAN   RGB_TO_RGBA(RGB_CYAN, 0xff)

Definition at line 46 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ RGBA_GREEN

#define RGBA_GREEN   RGB_TO_RGBA(RGB_GREEN, 0xff)

Definition at line 42 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ RGBA_GREY

#define RGBA_GREY (   x)    RGB_TO_RGBA(RGB_GREY(x), 0xff)

Definition at line 48 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ RGBA_RED

#define RGBA_RED   RGB_TO_RGBA(RGB_RED, 0xff)

Definition at line 41 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ RGBA_TO_UINT

#define RGBA_TO_UINT (   r,
  g,
  b,
 
)    RGB_TO_RGBA(RGB_TO_UINT(r,g,b), a)

Definition at line 30 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ RGBA_VIOLET

#define RGBA_VIOLET   RGB_TO_RGBA(RGB_VIOLET, 0xff)

Definition at line 45 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ RGBA_WHITE

#define RGBA_WHITE   RGB_TO_RGBA(RGB_WHITE, 0xff)

Definition at line 39 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ RGBA_YELLOW

#define RGBA_YELLOW   RGB_TO_RGBA(RGB_YELLOW, 0xff)

Definition at line 44 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ UINT_INTERPOLATE

#define UINT_INTERPOLATE (   c1,
  c2,
 
)
Value:

Definition at line 66 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ UINT_RGBA_A

#define UINT_RGBA_A (   x)    (((guint)(x))&0xff)

Definition at line 52 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ UINT_RGBA_A_FLT

#define UINT_RGBA_A_FLT (   x)    ((((guint)(x))&0xff)/255.0)

Definition at line 56 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ UINT_RGBA_B

#define UINT_RGBA_B (   x)    ((((guint)(x))>>8)&0xff)

Definition at line 51 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ UINT_RGBA_B_FLT

#define UINT_RGBA_B_FLT (   x)    (((((guint)(x))>>8)&0xff)/255.0)

Definition at line 55 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ UINT_RGBA_CHANGE_A

#define UINT_RGBA_CHANGE_A (   x,
 
)    (((x)&(~0xff))|((a)&0xff))

Definition at line 60 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ UINT_RGBA_CHANGE_B

#define UINT_RGBA_CHANGE_B (   x,
 
)    (((x)&(~(0xff<<8)))|(((b)&0xff)<<8))

Definition at line 59 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ UINT_RGBA_CHANGE_G

#define UINT_RGBA_CHANGE_G (   x,
 
)    (((x)&(~(0xff<<16)))|(((g)&0xff)<<16))

Definition at line 58 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ UINT_RGBA_CHANGE_R

#define UINT_RGBA_CHANGE_R (   x,
 
)    (((x)&(~(0xff<<24)))|(((r)&0xff)<<24))

Definition at line 57 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ UINT_RGBA_G

#define UINT_RGBA_G (   x)    ((((guint)(x))>>16)&0xff)

Definition at line 50 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ UINT_RGBA_G_FLT

#define UINT_RGBA_G_FLT (   x)    (((((guint)(x))>>16)&0xff)/255.0)

Definition at line 54 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ UINT_RGBA_R

#define UINT_RGBA_R (   x)    (((guint)(x))>>24)

Definition at line 49 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ UINT_RGBA_R_FLT

#define UINT_RGBA_R_FLT (   x)    ((((guint)(x))>>24)/255.0)

Definition at line 53 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ UINT_TO_RGB

#define UINT_TO_RGB (   u,
  r,
  g,
 
)    { (*(r)) = ((u)>>16)&0xff; (*(g)) = ((u)>>8)&0xff; (*(b)) = (u)&0xff; }

Definition at line 61 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.

◆ UINT_TO_RGBA

#define UINT_TO_RGBA (   u,
  r,
  g,
  b,
 
)    { UINT_TO_RGB(((u)>>8),r,g,b); (*(a)) = (u)&0xff; }

Definition at line 63 of file libs/gtkmm2ext/gtkmm2ext/rgb_macros.h.