From f03267388fa59dd0d99b88c99ef9da92a658f52c Mon Sep 17 00:00:00 2001 From: rr- Date: Fri, 26 Mar 2021 00:13:25 +0100 Subject: [PATCH] port ATI3DCIF_NullSub --- docs/progress.svg | 12 ++++++------ docs/progress.txt | 2 +- src/specific/ati.c | 6 ++++++ src/specific/ati.h | 1 + 4 files changed, 14 insertions(+), 7 deletions(-) diff --git a/docs/progress.svg b/docs/progress.svg index 7cd83f9a4..d6235a3a1 100644 --- a/docs/progress.svg +++ b/docs/progress.svg @@ -700,7 +700,7 @@ gourA gtmapA wgtmapA -ATI3DCIF_NullSub +ATI3DCIF_NullSub InitATI3DCIF ATI3DCIF_GetInfo ATI3DCIF_TextureReg @@ -1422,7 +1422,7 @@ SeedRandomControl SeedRandomDraw sub_437AC0 -ATI3DCIF_NullSub +ATI3DCIF_NullSub ATI3DCIF_ContextCreate ATI3DCIF_RenderEnd DoNothing @@ -1431,10 +1431,10 @@ SampleLoader KeyGet S_CDVolume -Functions decompiled (count): 81.26% -Functions decompiled (bytesize): 74.95% -Functions not decompiled, but with known names (count): 10.77% -Functions not decompiled, but with known names (bytesize): 11.92% +Functions decompiled (count): 81.40% +Functions decompiled (bytesize): 74.96% +Functions not decompiled, but with known names (count): 10.63% +Functions not decompiled, but with known names (bytesize): 11.91% Functions not decompiled, with unknown names (count): 7.97% Functions not decompiled, with unknown names (bytesize): 13.13% diff --git a/docs/progress.txt b/docs/progress.txt index 76d14b807..ca363bca7 100644 --- a/docs/progress.txt +++ b/docs/progress.txt @@ -980,7 +980,7 @@ transA 0x0043EAE4 0x00000139 - gourA 0x0043EC1D 0x00000185 - gtmapA 0x0043EDA2 0x00000311 - wgtmapA 0x0043F0B3 0x00000355 - -ATI3DCIF_NullSub 0x00450500 0x00000006 - +ATI3DCIF_NullSub 0x00450500 0x00000006 + InitATI3DCIF 0x00450510 0x00000296 - ATI3DCIF_GetInfo 0x004507B0 0x0000000E + ATI3DCIF_TextureReg 0x004507C0 0x00000013 + diff --git a/src/specific/ati.c b/src/specific/ati.c index ecf073bfa..2fe05cf49 100644 --- a/src/specific/ati.c +++ b/src/specific/ati.c @@ -19,6 +19,11 @@ #define ATI3DCIF_RenderPrimList_lib ((C3D_EC (**)(C3D_VLIST vList, C3D_UINT32 u32NumVert))0x00459D2C) // clang-format on +C3D_EC ATI3DCIF_NullSub() +{ + return C3D_EC_GENFAIL; +} + C3D_EC __stdcall ATI3DCIF_GetInfo(PC3D_3DCIFINFO info) { return (*ATI3DCIF_GetInfo_lib)(info); @@ -85,6 +90,7 @@ C3D_EC __stdcall ATI3DCIF_RenderPrimList(C3D_VLIST vList, C3D_UINT32 u32NumVert) void T1MInjectSpecificATI() { + INJECT(0x00450500, ATI3DCIF_NullSub); INJECT(0x004507B0, ATI3DCIF_GetInfo); INJECT(0x004507C0, ATI3DCIF_TextureReg); INJECT(0x004507E0, ATI3DCIF_TextureUnreg); diff --git a/src/specific/ati.h b/src/specific/ati.h index bce7383ba..6af849155 100644 --- a/src/specific/ati.h +++ b/src/specific/ati.h @@ -442,6 +442,7 @@ typedef enum { #pragma pack(pop) +C3D_EC ATI3DCIF_NullSub(); C3D_EC __stdcall ATI3DCIF_GetInfo(C3D_3DCIFINFO *info); C3D_EC __stdcall ATI3DCIF_TextureReg(C3D_PTMAP ptmapToReg, C3D_PHTX phtmap); C3D_EC __stdcall ATI3DCIF_TextureUnreg(C3D_HTX htxToUnreg);