diff --git a/core/hw/pvr/ta_vtx.cpp b/core/hw/pvr/ta_vtx.cpp index bd5bfc5bb..a03e86e85 100644 --- a/core/hw/pvr/ta_vtx.cpp +++ b/core/hw/pvr/ta_vtx.cpp @@ -1726,18 +1726,20 @@ void FillBGP(TA_context* ctx) } float ZV=0; + f32 bg_depth = ISP_BACKGND_D.f; + reinterpret_cast(bg_depth) &= 0xFFFFFFF0; // ISP_BACKGND_D has only 28 bits cv[0].x=-2000; cv[0].y=-2000; - cv[0].z=ISP_BACKGND_D.f; + cv[0].z=bg_depth; cv[1].x=640*scale_x + 2000; cv[1].y=0; - cv[1].z=ISP_BACKGND_D.f; + cv[1].z=bg_depth; cv[2].x=-2000; cv[2].y=480+2000; - cv[2].z=ISP_BACKGND_D.f; + cv[2].z=bg_depth; cv[3]=cv[2]; cv[3].x=640*scale_x+2000; diff --git a/core/nullDC.cpp b/core/nullDC.cpp index c08621090..e43a6117b 100755 --- a/core/nullDC.cpp +++ b/core/nullDC.cpp @@ -138,6 +138,13 @@ void LoadSpecialSettings() tr_poly_depth_mask_game = false; extra_depth_game = false; + if (reios_windows_ce) + { + printf("Enabling Extra depth scaling for Windows CE games\n"); + settings.rend.ExtraDepthScale = 0.1; + extra_depth_game = true; + } + // Tony Hawk's Pro Skater 2 if (!strncmp("T13008D", reios_product_number, 7) || !strncmp("T13006N", reios_product_number, 7) // Tony Hawk's Pro Skater 1 diff --git a/core/reios/reios.cpp b/core/reios/reios.cpp index 397efc7b9..de7e8a0dd 100644 --- a/core/reios/reios.cpp +++ b/core/reios/reios.cpp @@ -114,6 +114,7 @@ char reios_boot_filename[17]; char reios_software_company[17]; char reios_software_name[129]; char reios_bootfile[32]; +bool reios_windows_ce = false; bool pre_init = false; @@ -150,6 +151,7 @@ char* reios_disk_id() { memcpy(&reios_boot_filename[0], &ip_bin[96], 16 * sizeof(char)); memcpy(&reios_software_company[0], &ip_bin[112], 16 * sizeof(char)); memcpy(&reios_software_name[0], &ip_bin[128], 128 * sizeof(char)); + reios_windows_ce = memcmp("0WINCEOS.BIN", &reios_boot_filename[0], 12) == 0; return reios_product_number; } diff --git a/core/reios/reios.h b/core/reios/reios.h index 752fb4d68..38b32a902 100644 --- a/core/reios/reios.h +++ b/core/reios/reios.h @@ -14,6 +14,7 @@ void DYNACALL reios_trap(u32 op); char* reios_disk_id(); extern char reios_software_name[129]; extern char reios_product_number[11]; +extern bool reios_windows_ce; #define REIOS_OPCODE 0x085B