TA: ISP_BACKGND_D has only 28 bits of precision
Calculate background depth accordingly add extradepthscaling of 0.1 to wince games so the last four bits of depth are significant
This commit is contained in:
parent
8564f497d4
commit
f454c79f08
|
@ -1726,18 +1726,20 @@ void FillBGP(TA_context* ctx)
|
|||
}
|
||||
|
||||
float ZV=0;
|
||||
f32 bg_depth = ISP_BACKGND_D.f;
|
||||
reinterpret_cast<u32&>(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;
|
||||
|
|
|
@ -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
|
||||
|
|
|
@ -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;
|
||||
}
|
||||
|
|
|
@ -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
|
||||
|
||||
|
|
Loading…
Reference in New Issue