Skip to content

Commit

Permalink
update to latest lus main (HarbourMasters#614)
Browse files Browse the repository at this point in the history
* update to latest lus main

* upstream otrexporter and zapdtr submodules

* upstream LUS submodule
  • Loading branch information
briaguya-ai authored May 31, 2024
1 parent 464c55f commit 65870f3
Show file tree
Hide file tree
Showing 7 changed files with 17 additions and 11 deletions.
3 changes: 3 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,9 @@ endif()
# Enable the Gfx debugger in LUS to use libgfxd from ZAPDTR
set(GFX_DEBUG_DISASSEMBLER ON)

# Tell LUS we're using F3DEX_GBI_2 (in a way that doesn't break libgfxd)
set(USE_F3DEX2 ON)

################################################################################
# Set target arch type if empty. Visual studio solution generator provides it.
################################################################################
Expand Down
2 changes: 1 addition & 1 deletion OTRExporter
2 changes: 1 addition & 1 deletion ZAPDTR
3 changes: 3 additions & 0 deletions mm/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -423,6 +423,7 @@ if (CMAKE_SYSTEM_NAME STREQUAL "Windows")
#"$<$<BOOL:${BUILD_CROWD_CONTROL}>:ENABLE_CROWD_CONTROL>"
"INCLUDE_GAME_PRINTF;"
#"ENABLE_CROWD_CONTROL;"
"F3DEX_GBI_2"
"UNICODE;"
"_UNICODE"
STORMLIB_NO_AUTO_LINK
Expand All @@ -437,6 +438,7 @@ elseif (CMAKE_SYSTEM_NAME STREQUAL "CafeOS")
"$<$<CONFIG:Release>:"
"NDEBUG"
">"
"F3DEX_GBI_2"
"SPDLOG_ACTIVE_LEVEL=3;"
"SPDLOG_NO_THREAD_ID;"
"SPDLOG_NO_TLS;"
Expand All @@ -450,6 +452,7 @@ elseif ("${CMAKE_CXX_COMPILER_ID}" MATCHES "GNU|Clang|AppleClang")
"$<$<CONFIG:Release>:"
"NDEBUG"
">"
"F3DEX_GBI_2"
# "$<$<BOOL:${BUILD_CROWD_CONTROL}>:ENABLE_CROWD_CONTROL>"
"SPDLOG_ACTIVE_LEVEL=0;"
"_CONSOLE;"
Expand Down
4 changes: 2 additions & 2 deletions mm/include/gfx.h
Original file line number Diff line number Diff line change
Expand Up @@ -244,8 +244,8 @@ void func_8012D374(GraphicsContext* gfxCtx, u8 r, u8 g, u8 b);
void func_8012D40C(f32* param_1, f32* param_2, s16* param_3);
void gSPSegment(void* value, int segNum, uintptr_t target);
void gSPSegmentLoadRes(void* value, int segNum, uintptr_t target);
void gDPSetTextureImage(Gfx* pkt, u32 format, u32 size, u32 width, uintptr_t i);
void gDPSetTextureImageFB(Gfx* pkt, u32 format, u32 size, u32 width, int fb);
// void gDPSetTextureImage(Gfx* pkt, u32 format, u32 size, u32 width, uintptr_t i);
// void gDPSetTextureImageFB(Gfx* pkt, u32 format, u32 size, u32 width, int fb);
void gSPDisplayList(Gfx* pkt, Gfx* dl);
void gSPDisplayListOffset(Gfx* pkt, Gfx* dl, int offset);
void gSPVertex(Gfx* pkt, uintptr_t v, int n, int v0);
Expand Down
12 changes: 6 additions & 6 deletions mm/src/code/stubs.c
Original file line number Diff line number Diff line change
Expand Up @@ -184,13 +184,13 @@ void gSPSegmentLoadRes(void* value, int segNum, uintptr_t target) {
__gSPSegment(value, segNum, target);
}

void gDPSetTextureImage(Gfx* pkt, u32 format, u32 size, u32 width, uintptr_t i) {
__gDPSetTextureImage(pkt, format, size, width, i);
}
// void gDPSetTextureImage(Gfx* pkt, u32 format, u32 size, u32 width, uintptr_t i) {
// __gDPSetTextureImage(pkt, format, size, width, i);
// }

void gDPSetTextureImageFB(Gfx* pkt, u32 format, u32 size, u32 width, int fb) {
__gDPSetTextureImageFB(pkt, format, size, width, fb);
}
// void gDPSetTextureImageFB(Gfx* pkt, u32 format, u32 size, u32 width, int fb) {
// __gDPSetTextureImageFB(pkt, format, size, width, fb);
// }

void gSPDisplayList(Gfx* pkt, Gfx* dl) {
char* imgData = (char*)dl;
Expand Down

0 comments on commit 65870f3

Please sign in to comment.