Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 12 additions & 7 deletions soh/include/z64.h
Original file line number Diff line number Diff line change
Expand Up @@ -95,13 +95,18 @@ typedef struct {

typedef struct {
/* 0x00000 */ u16 headMagic; // GFXPOOL_HEAD_MAGIC
/* 0x00008 */ Gfx polyOpaBuffer[0x2FC0];
/* 0x0BF08 */ Gfx polyXluBuffer[0x1000];
/* 0x0FF08 */ Gfx overlayBuffer[0x800];
/* 0x11F08 */ Gfx workBuffer[0x100];
/* 0x11308 */ Gfx unusedBuffer[0x40];
/* 0x12408 */ u16 tailMagic; // GFXPOOL_TAIL_MAGIC
} GfxPool; // size = 0x24820
// SOH [Port] polyOpaBuffer enlarged from 0x2FC0. It's allocated from both
// ends (display lists grow up, matrices/vertices grow down via THGA_AllocEnd,
// which has no lower bound). Very dense frames like the Death Mountain Trail
// rockfall drive the tail below the buffer into headMagic and hard-crash
// Graph_Update (graph.c:356). More headroom keeps those frames in bounds.
Comment on lines +98 to +102

@serprex serprex Jun 15, 2026

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
// SOH [Port] polyOpaBuffer enlarged from 0x2FC0. It's allocated from both
// ends (display lists grow up, matrices/vertices grow down via THGA_AllocEnd,
// which has no lower bound). Very dense frames like the Death Mountain Trail
// rockfall drive the tail below the buffer into headMagic and hard-crash
// Graph_Update (graph.c:356). More headroom keeps those frames in bounds.

we'd already doubled the size before

guessing you're on high FPS

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah im running it on my 480hz monitor actually 😅 I play counter strike so im a sucker for high fps

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we need to cap fps until interpolation doesn't generate N steps per frame that all get buffered here

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ahh ok yeah agreed this is just a bandaid fix, I see the there is already a fps limit of 360FPS in the settings but toggling match refresh rate overrides that. Maybe capping it at 360FPS internally would be a better solution. Anyway hmu if you want me to test any fps cap or interpolation change or anything else that I can contribute too😄

/* 0x00008 */ Gfx polyOpaBuffer[0x6000];
/* 0x30008 */ Gfx polyXluBuffer[0x1000];
/* 0x38008 */ Gfx overlayBuffer[0x800];
/* 0x3C008 */ Gfx workBuffer[0x100];
/* 0x3C808 */ Gfx unusedBuffer[0x40];
/* 0x3CA08 */ u16 tailMagic; // GFXPOOL_TAIL_MAGIC
} GfxPool; // size = 0x3CA10

typedef struct {
/* 0x0000 */ u32 size;
Expand Down
Loading