rsx: Surface format remapping enhancements

This commit is contained in:
kd-11 2022-01-15 14:49:51 +03:00 committed by kd-11
parent 5b980b99a0
commit f923eaf09a
4 changed files with 63 additions and 15 deletions

View file

@ -144,10 +144,16 @@ void GLGSRender::update_draw_state()
bool color_mask_r = rsx::method_registers.color_mask_r(index);
bool color_mask_a = rsx::method_registers.color_mask_a(index);
if (rsx::method_registers.surface_color() == rsx::surface_color_format::g8b8)
switch (rsx::method_registers.surface_color())
{
//Map GB components onto RG
case rsx::surface_color_format::b8:
rsx::get_b8_colormask(color_mask_r, color_mask_g, color_mask_b, color_mask_a);
break;
case rsx::surface_color_format::g8b8:
rsx::get_g8b8_r8g8_colormask(color_mask_r, color_mask_g, color_mask_b, color_mask_a);
break;
default:
break;
}
gl_state.color_maski(index, color_mask_r, color_mask_g, color_mask_b, color_mask_a);