mirror of
https://github.com/X11Libre/xserver.git
synced 2026-03-24 03:44:06 +00:00
treewide: replace PICT_FORMAT_BPP by PIXMAN_FORMAT_BPP
Try not to use old compat macros anymore, use the real ones instead. Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
This commit is contained in:
committed by
Enrico Weigelt
parent
ae1b649587
commit
7783ae7723
@@ -262,7 +262,7 @@ compAddAlternateVisual(ScreenPtr pScreen, CompScreenPtr cs,
|
|||||||
visual->bitsPerRGBValue = 8;
|
visual->bitsPerRGBValue = 8;
|
||||||
if (PICT_FORMAT_TYPE(alt->format) == PICT_TYPE_COLOR) {
|
if (PICT_FORMAT_TYPE(alt->format) == PICT_TYPE_COLOR) {
|
||||||
visual->class = PseudoColor;
|
visual->class = PseudoColor;
|
||||||
visual->nplanes = PICT_FORMAT_BPP(alt->format);
|
visual->nplanes = PIXMAN_FORMAT_BPP(alt->format);
|
||||||
visual->ColormapEntries = 1 << visual->nplanes;
|
visual->ColormapEntries = 1 << visual->nplanes;
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
|||||||
@@ -552,7 +552,7 @@ exaBufferGlyph(ScreenPtr pScreen,
|
|||||||
if (buffer->count == GLYPH_BUFFER_SIZE)
|
if (buffer->count == GLYPH_BUFFER_SIZE)
|
||||||
return ExaGlyphNeedFlush;
|
return ExaGlyphNeedFlush;
|
||||||
|
|
||||||
if (PICT_FORMAT_BPP(format) == 1)
|
if (PIXMAN_FORMAT_BPP(format) == 1)
|
||||||
format = PICT_a8;
|
format = PICT_a8;
|
||||||
|
|
||||||
for (i = 0; i < EXA_NUM_GLYPH_CACHES; i++) {
|
for (i = 0; i < EXA_NUM_GLYPH_CACHES; i++) {
|
||||||
|
|||||||
@@ -905,7 +905,7 @@ exaComposite(CARD8 op,
|
|||||||
(pSrc->format == pDst->format ||
|
(pSrc->format == pDst->format ||
|
||||||
(PICT_FORMAT_COLOR(pDst->format) &&
|
(PICT_FORMAT_COLOR(pDst->format) &&
|
||||||
PICT_FORMAT_COLOR(pSrc->format) &&
|
PICT_FORMAT_COLOR(pSrc->format) &&
|
||||||
pDst->format == PICT_FORMAT(PICT_FORMAT_BPP(pSrc->format),
|
pDst->format == PICT_FORMAT(PIXMAN_FORMAT_BPP(pSrc->format),
|
||||||
PICT_FORMAT_TYPE(pSrc->format),
|
PICT_FORMAT_TYPE(pSrc->format),
|
||||||
0,
|
0,
|
||||||
PICT_FORMAT_R(pSrc->format),
|
PICT_FORMAT_R(pSrc->format),
|
||||||
|
|||||||
@@ -751,9 +751,9 @@ combine_pict_format(PictFormatShort * des, const PictFormatShort src,
|
|||||||
*des = src;
|
*des = src;
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
src_bpp = PICT_FORMAT_BPP(src);
|
src_bpp = PIXMAN_FORMAT_BPP(src);
|
||||||
|
|
||||||
assert(src_bpp == PICT_FORMAT_BPP(mask));
|
assert(src_bpp == PIXMAN_FORMAT_BPP(mask));
|
||||||
|
|
||||||
new_vis = PICT_FORMAT_VIS(src) | PICT_FORMAT_VIS(mask);
|
new_vis = PICT_FORMAT_VIS(src) | PICT_FORMAT_VIS(mask);
|
||||||
|
|
||||||
@@ -1551,7 +1551,7 @@ glamor_composite_clipped_region(CARD8 op,
|
|||||||
&& (source->format == dest->format
|
&& (source->format == dest->format
|
||||||
|| (PICT_FORMAT_COLOR(dest->format)
|
|| (PICT_FORMAT_COLOR(dest->format)
|
||||||
&& PICT_FORMAT_COLOR(source->format)
|
&& PICT_FORMAT_COLOR(source->format)
|
||||||
&& dest->format == PICT_FORMAT(PICT_FORMAT_BPP(source->format),
|
&& dest->format == PICT_FORMAT(PIXMAN_FORMAT_BPP(source->format),
|
||||||
PICT_FORMAT_TYPE(source->format),
|
PICT_FORMAT_TYPE(source->format),
|
||||||
0,
|
0,
|
||||||
PICT_FORMAT_R(source->format),
|
PICT_FORMAT_R(source->format),
|
||||||
|
|||||||
@@ -43,7 +43,7 @@ glamor_upload_boxes(DrawablePtr drawable, BoxPtr in_boxes, int in_nbox,
|
|||||||
glamor_pixmap_private *priv = glamor_get_pixmap_private(pixmap);
|
glamor_pixmap_private *priv = glamor_get_pixmap_private(pixmap);
|
||||||
int box_index;
|
int box_index;
|
||||||
const struct glamor_format *f = glamor_format_for_pixmap(pixmap);
|
const struct glamor_format *f = glamor_format_for_pixmap(pixmap);
|
||||||
int bytes_per_pixel = PICT_FORMAT_BPP(f->render_format) >> 3;
|
int bytes_per_pixel = PIXMAN_FORMAT_BPP(f->render_format) >> 3;
|
||||||
char *tmp_bits = NULL;
|
char *tmp_bits = NULL;
|
||||||
|
|
||||||
if (glamor_drawable_effective_depth(drawable) == 24 && pixmap->drawable.depth == 32)
|
if (glamor_drawable_effective_depth(drawable) == 24 && pixmap->drawable.depth == 32)
|
||||||
@@ -153,7 +153,7 @@ glamor_download_boxes(DrawablePtr drawable, BoxPtr in_boxes, int in_nbox,
|
|||||||
glamor_pixmap_private *priv = glamor_get_pixmap_private(pixmap);
|
glamor_pixmap_private *priv = glamor_get_pixmap_private(pixmap);
|
||||||
int box_index;
|
int box_index;
|
||||||
const struct glamor_format *f = glamor_format_for_pixmap(pixmap);
|
const struct glamor_format *f = glamor_format_for_pixmap(pixmap);
|
||||||
int bytes_per_pixel = PICT_FORMAT_BPP(f->render_format) >> 3;
|
int bytes_per_pixel = PIXMAN_FORMAT_BPP(f->render_format) >> 3;
|
||||||
|
|
||||||
glamor_make_current(glamor_priv);
|
glamor_make_current(glamor_priv);
|
||||||
|
|
||||||
|
|||||||
@@ -620,7 +620,7 @@ glamor_get_rgba_from_pixel(CARD32 pixel,
|
|||||||
ashift = 0;
|
ashift = 0;
|
||||||
rshift = abits;
|
rshift = abits;
|
||||||
if (abits == 0)
|
if (abits == 0)
|
||||||
rshift = PICT_FORMAT_BPP(format) - (rbits + gbits + bbits);
|
rshift = PIXMAN_FORMAT_BPP(format) - (rbits + gbits + bbits);
|
||||||
gshift = rshift + rbits;
|
gshift = rshift + rbits;
|
||||||
bshift = gshift + gbits;
|
bshift = gshift + gbits;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -347,18 +347,18 @@ PictureCreateDefaultFormats(ScreenPtr pScreen, int *nformatp)
|
|||||||
pFormats[f].direct.blueMask = Mask (PICT_FORMAT_B(format));
|
pFormats[f].direct.blueMask = Mask (PICT_FORMAT_B(format));
|
||||||
|
|
||||||
pFormats[f].direct.blue =
|
pFormats[f].direct.blue =
|
||||||
(PICT_FORMAT_BPP(format) - PICT_FORMAT_B(format));
|
(PIXMAN_FORMAT_BPP(format) - PICT_FORMAT_B(format));
|
||||||
|
|
||||||
pFormats[f].direct.greenMask = Mask (PICT_FORMAT_G(format));
|
pFormats[f].direct.greenMask = Mask (PICT_FORMAT_G(format));
|
||||||
|
|
||||||
pFormats[f].direct.green =
|
pFormats[f].direct.green =
|
||||||
(PICT_FORMAT_BPP(format) - PICT_FORMAT_B(format) -
|
(PIXMAN_FORMAT_BPP(format) - PICT_FORMAT_B(format) -
|
||||||
PICT_FORMAT_G(format));
|
PICT_FORMAT_G(format));
|
||||||
|
|
||||||
pFormats[f].direct.redMask = Mask (PICT_FORMAT_R(format));
|
pFormats[f].direct.redMask = Mask (PICT_FORMAT_R(format));
|
||||||
|
|
||||||
pFormats[f].direct.red =
|
pFormats[f].direct.red =
|
||||||
(PICT_FORMAT_BPP(format) - PICT_FORMAT_B(format) -
|
(PIXMAN_FORMAT_BPP(format) - PICT_FORMAT_B(format) -
|
||||||
PICT_FORMAT_G(format) - PICT_FORMAT_R(format));
|
PICT_FORMAT_G(format) - PICT_FORMAT_R(format));
|
||||||
|
|
||||||
pFormats[f].direct.alphaMask = Mask (PIXMAN_FORMAT_A(format));
|
pFormats[f].direct.alphaMask = Mask (PIXMAN_FORMAT_A(format));
|
||||||
|
|||||||
Reference in New Issue
Block a user