Skip to content

gfx: start EFB aspect fit enabled to match the default viewport policy - #312

Open
StilesCrisis wants to merge 1 commit into
encounter:mainfrom
StilesCrisis:efb-aspect-fit-default
Open

StilesCrisis wants to merge 1 commit into
encounter:mainfrom
StilesCrisis:efb-aspect-fit-default

Conversation

@StilesCrisis

Copy link
Copy Markdown

GXState::viewportPolicy defaults to AURORA_VIEWPORT_FIT, but efb's g_aspectFit started out false.

If your code never called AuroraSetViewportPolicy, GX would map viewports as FIT even though the framebuffer was sized to the window’s aspect ratio. This meant that a 4:3 game in a widescreen window was stretched to fill it instead of being letterboxed.

This clearly isn't a huge bug—you can always set the policy—but the code is not self-consistent. g_gxState.viewportPolicy starts as AURORA_VIEWPORT_FIT, so assuming it behaves like FIT would be reasonable, but rendering behaves like STRETCH. It's surprising that you need to call AuroraSetViewportPolicy(AURORA_VIEWPORT_FIT) when that's the default value in code.

GXState::viewportPolicy defaults to AURORA_VIEWPORT_FIT, but efb's
g_aspectFit started out false.

If your code never called AuroraSetViewportPolicy, GX would map
viewports as FIT even though the framebuffer was sized to the window's
aspect ratio. This meant that a 4:3 game in a widescreen window was
stretched to fill it instead of being letterboxed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SjpWoYqNDKkH5Zpdbz3WaW
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants