Skip to content

Commit

Permalink
Fix JUTXfb fakematch
Browse files Browse the repository at this point in the history
This match (with the u32 cast) is more likely to be the real match based on the inlines called in TP debug.
  • Loading branch information
LagoLunatic committed Jan 15, 2025
1 parent 8e44641 commit d2426c5
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions include/JSystem/JUtility/JUTVideo.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ class JUTVideo {
static void postRetraceProc(u32);
static void drawDoneCallback();

u32 getFbWidth() const { return mRenderObj->fb_width; }
u32 getEfbHeight() const { return mRenderObj->efb_height; }
u16 getFbWidth() const { return mRenderObj->fb_width; }
u16 getEfbHeight() const { return mRenderObj->efb_height; }
void getBounds(u16& width, u16& height) const {
width = (u16)getFbWidth();
height = (u16)getEfbHeight();
Expand Down
6 changes: 3 additions & 3 deletions src/JSystem/JUtility/JUTXfb.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,9 @@ JUTXfb::JUTXfb(const _GXRenderModeObj* pObj, JKRHeap* pHeap, JUTXfb::EXfbNumber
GXRenderModeObj* obj = JUTVideo::getManager()->getRenderMode();
initiate(obj->fb_width, obj->xfb_height, pHeap, xfbNum);
#else
u16 fb_width = JUTVideo::getManager()->getFbWidth();
u16 efb_height = JUTVideo::getManager()->getEfbHeight();
u16 xfb_height = JUTVideo::getManager()->getXfbHeight();
u16 fb_width = JUTVideo::getManager()->getRenderMode()->fb_width;
u16 efb_height = (u32)JUTVideo::getManager()->getRenderMode()->efb_height;
u16 xfb_height = JUTVideo::getManager()->getRenderMode()->xfb_height;
f32 scale_factor = GXGetYScaleFactor(efb_height, xfb_height);
u16 xfb_lines = GXGetNumXfbLines(efb_height, scale_factor);

Expand Down

0 comments on commit d2426c5

Please sign in to comment.