mirror of
https://github.com/X11Libre/xf86-video-ati.git
synced 2026-03-24 01:24:43 +00:00
replace PICT_a8 by PIXMAN_a8
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
0af57eb200
commit
a867f5e6d6
@@ -681,7 +681,7 @@ static struct formatinfo EVERGREENTexFormats[] = {
|
|||||||
{PIXMAN_r5g6b5, FMT_5_6_5},
|
{PIXMAN_r5g6b5, FMT_5_6_5},
|
||||||
{PIXMAN_a1r5g5b5, FMT_1_5_5_5},
|
{PIXMAN_a1r5g5b5, FMT_1_5_5_5},
|
||||||
{PIXMAN_x1r5g5b5, FMT_1_5_5_5},
|
{PIXMAN_x1r5g5b5, FMT_1_5_5_5},
|
||||||
{PICT_a8, FMT_8},
|
{PIXMAN_a8, FMT_8},
|
||||||
};
|
};
|
||||||
|
|
||||||
static uint32_t EVERGREENGetBlendCntl(int op, PicturePtr pMask, uint32_t dst_format)
|
static uint32_t EVERGREENGetBlendCntl(int op, PicturePtr pMask, uint32_t dst_format)
|
||||||
@@ -748,7 +748,7 @@ static Bool EVERGREENGetDestFormat(PicturePtr pDstPicture, uint32_t *dst_format)
|
|||||||
case PIXMAN_x1r5g5b5:
|
case PIXMAN_x1r5g5b5:
|
||||||
*dst_format = COLOR_1_5_5_5;
|
*dst_format = COLOR_1_5_5_5;
|
||||||
break;
|
break;
|
||||||
case PICT_a8:
|
case PIXMAN_a8:
|
||||||
*dst_format = COLOR_8;
|
*dst_format = COLOR_8;
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
@@ -944,7 +944,7 @@ static Bool EVERGREENTextureSetup(PicturePtr pPict, PixmapPtr pPix,
|
|||||||
pix_b = SQ_SEL_X; /* B */
|
pix_b = SQ_SEL_X; /* B */
|
||||||
pix_a = SQ_SEL_1; /* A */
|
pix_a = SQ_SEL_1; /* A */
|
||||||
break;
|
break;
|
||||||
case PICT_a8:
|
case PIXMAN_a8:
|
||||||
pix_r = SQ_SEL_0; /* R */
|
pix_r = SQ_SEL_0; /* R */
|
||||||
pix_g = SQ_SEL_0; /* G */
|
pix_g = SQ_SEL_0; /* G */
|
||||||
pix_b = SQ_SEL_0; /* B */
|
pix_b = SQ_SEL_0; /* B */
|
||||||
@@ -1204,7 +1204,7 @@ static void EVERGREENSetSolidConsts(ScrnInfoPtr pScrn, float *buf, int format, u
|
|||||||
pix_b = xf; /* B */
|
pix_b = xf; /* B */
|
||||||
pix_a = 1.0; /* A */
|
pix_a = 1.0; /* A */
|
||||||
break;
|
break;
|
||||||
case PICT_a8:
|
case PIXMAN_a8:
|
||||||
pix_r = 0.0; /* R */
|
pix_r = 0.0; /* R */
|
||||||
pix_g = 0.0; /* G */
|
pix_g = 0.0; /* G */
|
||||||
pix_b = 0.0; /* B */
|
pix_b = 0.0; /* B */
|
||||||
@@ -1461,7 +1461,7 @@ static Bool EVERGREENPrepareComposite(int op, PicturePtr pSrcPicture,
|
|||||||
case PIXMAN_r5g6b5:
|
case PIXMAN_r5g6b5:
|
||||||
cb_conf.comp_swap = 2; /* RGB */
|
cb_conf.comp_swap = 2; /* RGB */
|
||||||
break;
|
break;
|
||||||
case PICT_a8:
|
case PIXMAN_a8:
|
||||||
cb_conf.comp_swap = 3; /* A */
|
cb_conf.comp_swap = 3; /* A */
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -740,7 +740,7 @@ static struct formatinfo R600TexFormats[] = {
|
|||||||
{PIXMAN_r5g6b5, FMT_5_6_5},
|
{PIXMAN_r5g6b5, FMT_5_6_5},
|
||||||
{PIXMAN_a1r5g5b5, FMT_1_5_5_5},
|
{PIXMAN_a1r5g5b5, FMT_1_5_5_5},
|
||||||
{PIXMAN_x1r5g5b5, FMT_1_5_5_5},
|
{PIXMAN_x1r5g5b5, FMT_1_5_5_5},
|
||||||
{PICT_a8, FMT_8},
|
{PIXMAN_a8, FMT_8},
|
||||||
};
|
};
|
||||||
|
|
||||||
static uint32_t R600GetBlendCntl(int op, PicturePtr pMask, uint32_t dst_format)
|
static uint32_t R600GetBlendCntl(int op, PicturePtr pMask, uint32_t dst_format)
|
||||||
@@ -807,7 +807,7 @@ static Bool R600GetDestFormat(PicturePtr pDstPicture, uint32_t *dst_format)
|
|||||||
case PIXMAN_x1r5g5b5:
|
case PIXMAN_x1r5g5b5:
|
||||||
*dst_format = COLOR_1_5_5_5;
|
*dst_format = COLOR_1_5_5_5;
|
||||||
break;
|
break;
|
||||||
case PICT_a8:
|
case PIXMAN_a8:
|
||||||
*dst_format = COLOR_8;
|
*dst_format = COLOR_8;
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
@@ -959,7 +959,7 @@ static Bool R600TextureSetup(PicturePtr pPict, PixmapPtr pPix,
|
|||||||
pix_b = SQ_SEL_X; /* B */
|
pix_b = SQ_SEL_X; /* B */
|
||||||
pix_a = SQ_SEL_1; /* A */
|
pix_a = SQ_SEL_1; /* A */
|
||||||
break;
|
break;
|
||||||
case PICT_a8:
|
case PIXMAN_a8:
|
||||||
pix_r = SQ_SEL_0; /* R */
|
pix_r = SQ_SEL_0; /* R */
|
||||||
pix_g = SQ_SEL_0; /* G */
|
pix_g = SQ_SEL_0; /* G */
|
||||||
pix_b = SQ_SEL_0; /* B */
|
pix_b = SQ_SEL_0; /* B */
|
||||||
@@ -1248,7 +1248,7 @@ static void R600SetSolidConsts(ScrnInfoPtr pScrn, float *buf, int format, uint32
|
|||||||
pix_b = xf; /* B */
|
pix_b = xf; /* B */
|
||||||
pix_a = 1.0; /* A */
|
pix_a = 1.0; /* A */
|
||||||
break;
|
break;
|
||||||
case PICT_a8:
|
case PIXMAN_a8:
|
||||||
pix_r = 0.0; /* R */
|
pix_r = 0.0; /* R */
|
||||||
pix_g = 0.0; /* G */
|
pix_g = 0.0; /* G */
|
||||||
pix_b = 0.0; /* B */
|
pix_b = 0.0; /* B */
|
||||||
@@ -1500,7 +1500,7 @@ static Bool R600PrepareComposite(int op, PicturePtr pSrcPicture,
|
|||||||
case PIXMAN_r5g6b5:
|
case PIXMAN_r5g6b5:
|
||||||
cb_conf.comp_swap = 2; /* RGB */
|
cb_conf.comp_swap = 2; /* RGB */
|
||||||
break;
|
break;
|
||||||
case PICT_a8:
|
case PIXMAN_a8:
|
||||||
cb_conf.comp_swap = 3; /* A */
|
cb_conf.comp_swap = 3; /* A */
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -79,7 +79,7 @@ static struct formatinfo R100TexFormats[] = {
|
|||||||
{PIXMAN_r5g6b5, RADEON_TXFORMAT_RGB565},
|
{PIXMAN_r5g6b5, RADEON_TXFORMAT_RGB565},
|
||||||
{PIXMAN_a1r5g5b5, RADEON_TXFORMAT_ARGB1555 | RADEON_TXFORMAT_ALPHA_IN_MAP},
|
{PIXMAN_a1r5g5b5, RADEON_TXFORMAT_ARGB1555 | RADEON_TXFORMAT_ALPHA_IN_MAP},
|
||||||
{PIXMAN_x1r5g5b5, RADEON_TXFORMAT_ARGB1555},
|
{PIXMAN_x1r5g5b5, RADEON_TXFORMAT_ARGB1555},
|
||||||
{PICT_a8, RADEON_TXFORMAT_I8 | RADEON_TXFORMAT_ALPHA_IN_MAP},
|
{PIXMAN_a8, RADEON_TXFORMAT_I8 | RADEON_TXFORMAT_ALPHA_IN_MAP},
|
||||||
};
|
};
|
||||||
|
|
||||||
static struct formatinfo R200TexFormats[] = {
|
static struct formatinfo R200TexFormats[] = {
|
||||||
@@ -90,7 +90,7 @@ static struct formatinfo R200TexFormats[] = {
|
|||||||
{PIXMAN_r5g6b5, R200_TXFORMAT_RGB565},
|
{PIXMAN_r5g6b5, R200_TXFORMAT_RGB565},
|
||||||
{PIXMAN_a1r5g5b5, R200_TXFORMAT_ARGB1555 | R200_TXFORMAT_ALPHA_IN_MAP},
|
{PIXMAN_a1r5g5b5, R200_TXFORMAT_ARGB1555 | R200_TXFORMAT_ALPHA_IN_MAP},
|
||||||
{PIXMAN_x1r5g5b5, R200_TXFORMAT_ARGB1555},
|
{PIXMAN_x1r5g5b5, R200_TXFORMAT_ARGB1555},
|
||||||
{PICT_a8, R200_TXFORMAT_I8 | R200_TXFORMAT_ALPHA_IN_MAP},
|
{PIXMAN_a8, R200_TXFORMAT_I8 | R200_TXFORMAT_ALPHA_IN_MAP},
|
||||||
};
|
};
|
||||||
|
|
||||||
static struct formatinfo R300TexFormats[] = {
|
static struct formatinfo R300TexFormats[] = {
|
||||||
@@ -103,7 +103,7 @@ static struct formatinfo R300TexFormats[] = {
|
|||||||
{PIXMAN_r5g6b5, R300_EASY_TX_FORMAT(X, Y, Z, ONE, Z5Y6X5)},
|
{PIXMAN_r5g6b5, R300_EASY_TX_FORMAT(X, Y, Z, ONE, Z5Y6X5)},
|
||||||
{PIXMAN_a1r5g5b5, R300_EASY_TX_FORMAT(X, Y, Z, W, W1Z5Y5X5)},
|
{PIXMAN_a1r5g5b5, R300_EASY_TX_FORMAT(X, Y, Z, W, W1Z5Y5X5)},
|
||||||
{PIXMAN_x1r5g5b5, R300_EASY_TX_FORMAT(X, Y, Z, ONE, W1Z5Y5X5)},
|
{PIXMAN_x1r5g5b5, R300_EASY_TX_FORMAT(X, Y, Z, ONE, W1Z5Y5X5)},
|
||||||
{PICT_a8, R300_EASY_TX_FORMAT(ZERO, ZERO, ZERO, X, X8)},
|
{PIXMAN_a8, R300_EASY_TX_FORMAT(ZERO, ZERO, ZERO, X, X8)},
|
||||||
};
|
};
|
||||||
|
|
||||||
/* Common Radeon setup code */
|
/* Common Radeon setup code */
|
||||||
@@ -122,7 +122,7 @@ static Bool RADEONGetDestFormat(PicturePtr pDstPicture, uint32_t *dst_format)
|
|||||||
case PIXMAN_x1r5g5b5:
|
case PIXMAN_x1r5g5b5:
|
||||||
*dst_format = RADEON_COLOR_FORMAT_ARGB1555;
|
*dst_format = RADEON_COLOR_FORMAT_ARGB1555;
|
||||||
break;
|
break;
|
||||||
case PICT_a8:
|
case PIXMAN_a8:
|
||||||
*dst_format = RADEON_COLOR_FORMAT_RGB8;
|
*dst_format = RADEON_COLOR_FORMAT_RGB8;
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
@@ -151,7 +151,7 @@ static Bool R300GetDestFormat(PicturePtr pDstPicture, uint32_t *dst_format)
|
|||||||
case PIXMAN_x1r5g5b5:
|
case PIXMAN_x1r5g5b5:
|
||||||
*dst_format = R300_COLORFORMAT_ARGB1555;
|
*dst_format = R300_COLORFORMAT_ARGB1555;
|
||||||
break;
|
break;
|
||||||
case PICT_a8:
|
case PIXMAN_a8:
|
||||||
*dst_format = R300_COLORFORMAT_I8;
|
*dst_format = R300_COLORFORMAT_I8;
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
@@ -589,7 +589,7 @@ static Bool R100PrepareComposite(int op,
|
|||||||
if (!RADEONGetDestFormat(pDstPicture, &dst_format))
|
if (!RADEONGetDestFormat(pDstPicture, &dst_format))
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
||||||
if (pDstPicture->format == PICT_a8 && RadeonBlendOp[op].dst_alpha)
|
if (pDstPicture->format == PIXMAN_a8 && RadeonBlendOp[op].dst_alpha)
|
||||||
RADEON_FALLBACK(("Can't dst alpha blend A8\n"));
|
RADEON_FALLBACK(("Can't dst alpha blend A8\n"));
|
||||||
|
|
||||||
pixel_shift = pDst->drawable.bitsPerPixel >> 4;
|
pixel_shift = pDst->drawable.bitsPerPixel >> 4;
|
||||||
@@ -655,11 +655,11 @@ static Bool R100PrepareComposite(int op,
|
|||||||
cblend = RADEON_BLEND_CTL_ADD | RADEON_CLAMP_TX | RADEON_COLOR_ARG_C_ZERO;
|
cblend = RADEON_BLEND_CTL_ADD | RADEON_CLAMP_TX | RADEON_COLOR_ARG_C_ZERO;
|
||||||
ablend = RADEON_BLEND_CTL_ADD | RADEON_CLAMP_TX | RADEON_ALPHA_ARG_C_ZERO;
|
ablend = RADEON_BLEND_CTL_ADD | RADEON_CLAMP_TX | RADEON_ALPHA_ARG_C_ZERO;
|
||||||
|
|
||||||
if (pDstPicture->format == PICT_a8 ||
|
if (pDstPicture->format == PIXMAN_a8 ||
|
||||||
(pMask && pMaskPicture->componentAlpha && RadeonBlendOp[op].src_alpha))
|
(pMask && pMaskPicture->componentAlpha && RadeonBlendOp[op].src_alpha))
|
||||||
{
|
{
|
||||||
cblend |= RADEON_COLOR_ARG_A_T0_ALPHA;
|
cblend |= RADEON_COLOR_ARG_A_T0_ALPHA;
|
||||||
} else if (pSrcPicture->format == PICT_a8)
|
} else if (pSrcPicture->format == PIXMAN_a8)
|
||||||
cblend |= RADEON_COLOR_ARG_A_ZERO;
|
cblend |= RADEON_COLOR_ARG_A_ZERO;
|
||||||
else
|
else
|
||||||
cblend |= RADEON_COLOR_ARG_A_T0_COLOR;
|
cblend |= RADEON_COLOR_ARG_A_T0_COLOR;
|
||||||
@@ -667,7 +667,7 @@ static Bool R100PrepareComposite(int op,
|
|||||||
|
|
||||||
if (pMask) {
|
if (pMask) {
|
||||||
if (pMaskPicture->componentAlpha &&
|
if (pMaskPicture->componentAlpha &&
|
||||||
pDstPicture->format != PICT_a8)
|
pDstPicture->format != PIXMAN_a8)
|
||||||
cblend |= RADEON_COLOR_ARG_B_T1_COLOR;
|
cblend |= RADEON_COLOR_ARG_B_T1_COLOR;
|
||||||
else
|
else
|
||||||
cblend |= RADEON_COLOR_ARG_B_T1_ALPHA;
|
cblend |= RADEON_COLOR_ARG_B_T1_ALPHA;
|
||||||
@@ -951,7 +951,7 @@ static Bool R200PrepareComposite(int op, PicturePtr pSrcPicture,
|
|||||||
if (!RADEONGetDestFormat(pDstPicture, &dst_format))
|
if (!RADEONGetDestFormat(pDstPicture, &dst_format))
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
||||||
if (pDstPicture->format == PICT_a8 && RadeonBlendOp[op].dst_alpha)
|
if (pDstPicture->format == PIXMAN_a8 && RadeonBlendOp[op].dst_alpha)
|
||||||
RADEON_FALLBACK(("Can't dst alpha blend A8\n"));
|
RADEON_FALLBACK(("Can't dst alpha blend A8\n"));
|
||||||
|
|
||||||
pixel_shift = pDst->drawable.bitsPerPixel >> 4;
|
pixel_shift = pDst->drawable.bitsPerPixel >> 4;
|
||||||
@@ -1030,11 +1030,11 @@ static Bool R200PrepareComposite(int op, PicturePtr pSrcPicture,
|
|||||||
cblend = R200_TXC_OP_MADD | R200_TXC_ARG_C_ZERO;
|
cblend = R200_TXC_OP_MADD | R200_TXC_ARG_C_ZERO;
|
||||||
ablend = R200_TXA_OP_MADD | R200_TXA_ARG_C_ZERO;
|
ablend = R200_TXA_OP_MADD | R200_TXA_ARG_C_ZERO;
|
||||||
|
|
||||||
if (pDstPicture->format == PICT_a8 ||
|
if (pDstPicture->format == PIXMAN_a8 ||
|
||||||
(pMask && pMaskPicture->componentAlpha && RadeonBlendOp[op].src_alpha))
|
(pMask && pMaskPicture->componentAlpha && RadeonBlendOp[op].src_alpha))
|
||||||
{
|
{
|
||||||
cblend |= R200_TXC_ARG_A_R0_ALPHA;
|
cblend |= R200_TXC_ARG_A_R0_ALPHA;
|
||||||
} else if (pSrcPicture->format == PICT_a8)
|
} else if (pSrcPicture->format == PIXMAN_a8)
|
||||||
cblend |= R200_TXC_ARG_A_ZERO;
|
cblend |= R200_TXC_ARG_A_ZERO;
|
||||||
else
|
else
|
||||||
cblend |= R200_TXC_ARG_A_R0_COLOR;
|
cblend |= R200_TXC_ARG_A_R0_COLOR;
|
||||||
@@ -1042,7 +1042,7 @@ static Bool R200PrepareComposite(int op, PicturePtr pSrcPicture,
|
|||||||
|
|
||||||
if (pMask) {
|
if (pMask) {
|
||||||
if (pMaskPicture->componentAlpha &&
|
if (pMaskPicture->componentAlpha &&
|
||||||
pDstPicture->format != PICT_a8)
|
pDstPicture->format != PIXMAN_a8)
|
||||||
cblend |= R200_TXC_ARG_B_R1_COLOR;
|
cblend |= R200_TXC_ARG_B_R1_COLOR;
|
||||||
else
|
else
|
||||||
cblend |= R200_TXC_ARG_B_R1_ALPHA;
|
cblend |= R200_TXC_ARG_B_R1_ALPHA;
|
||||||
@@ -1619,7 +1619,7 @@ static Bool R300PrepareComposite(int op, PicturePtr pSrcPicture,
|
|||||||
R300_OUT_FMT_C2_SEL_GREEN |
|
R300_OUT_FMT_C2_SEL_GREEN |
|
||||||
R300_OUT_FMT_C3_SEL_BLUE);
|
R300_OUT_FMT_C3_SEL_BLUE);
|
||||||
break;
|
break;
|
||||||
case PICT_a8:
|
case PIXMAN_a8:
|
||||||
output_fmt = (R300_OUT_FMT_C4_8 |
|
output_fmt = (R300_OUT_FMT_C4_8 |
|
||||||
R300_OUT_FMT_C0_SEL_ALPHA);
|
R300_OUT_FMT_C0_SEL_ALPHA);
|
||||||
break;
|
break;
|
||||||
|
|||||||
Reference in New Issue
Block a user