From 75a0994ec1bd712aa36a2abbd0b63d5875368794 Mon Sep 17 00:00:00 2001 From: Jannik Vogel Date: Sun, 21 May 2017 23:33:12 +0200 Subject: [PATCH] Support blit surface format 0x4 --- hw/xbox/nv2a.c | 3 +++ hw/xbox/nv2a_int.h | 1 + 2 files changed, 4 insertions(+) diff --git a/hw/xbox/nv2a.c b/hw/xbox/nv2a.c index 4e6cd5ef10..650ccf2c14 100644 --- a/hw/xbox/nv2a.c +++ b/hw/xbox/nv2a.c @@ -2813,6 +2813,9 @@ static void pgraph_method(NV2AState *d, case NV062_SET_COLOR_FORMAT_LE_Y8: bytes_per_pixel = 1; break; + case NV062_SET_COLOR_FORMAT_LE_R5G6B5: + bytes_per_pixel = 2; + break; case NV062_SET_COLOR_FORMAT_LE_A8R8G8B8: bytes_per_pixel = 4; break; diff --git a/hw/xbox/nv2a_int.h b/hw/xbox/nv2a_int.h index 6814a3c49a..10dddd8a6f 100644 --- a/hw/xbox/nv2a_int.h +++ b/hw/xbox/nv2a_int.h @@ -670,6 +670,7 @@ # define NV062_SET_CONTEXT_DMA_IMAGE_DESTIN 0x00000188 # define NV062_SET_COLOR_FORMAT 0x00000300 # define NV062_SET_COLOR_FORMAT_LE_Y8 0x01 +# define NV062_SET_COLOR_FORMAT_LE_R5G6B5 0x04 # define NV062_SET_COLOR_FORMAT_LE_A8R8G8B8 0x0A # define NV062_SET_PITCH 0x00000304 # define NV062_SET_OFFSET_SOURCE 0x00000308