r300g: add support for L8A8 colorbuffers
Blending with DST_ALPHA is undefined. SRC_ALPHA works, though. I bet some other formats have similar limitations too.
This commit is contained in:
@@ -369,6 +369,7 @@ static uint32_t r300_translate_colorformat(enum pipe_format format)
|
||||
return R300_COLOR_FORMAT_I8;
|
||||
|
||||
/* 16-bit buffers. */
|
||||
case PIPE_FORMAT_L8A8_UNORM:
|
||||
case PIPE_FORMAT_R8G8_UNORM:
|
||||
case PIPE_FORMAT_R8G8_SNORM:
|
||||
return R300_COLOR_FORMAT_UV88;
|
||||
@@ -504,6 +505,8 @@ static uint32_t r300_translate_out_fmt(enum pipe_format format)
|
||||
|
||||
/* 16-bit outputs, two channels.
|
||||
* COLORFORMAT_UV88 stores C2 and C0. */
|
||||
case PIPE_FORMAT_L8A8_UNORM:
|
||||
return modifier | R300_C0_SEL_A | R300_C2_SEL_R;
|
||||
case PIPE_FORMAT_R8G8_UNORM:
|
||||
case PIPE_FORMAT_R8G8_SNORM:
|
||||
return modifier | R300_C0_SEL_G | R300_C2_SEL_R;
|
||||
|
||||
Reference in New Issue
Block a user