Skip to content

Comments

Fix web fullscreen sizing and stability#12

Merged
Atrix256 merged 1 commit intoAtrix256:mainfrom
fcarucci:fix/webgpu-fullscreen-fill
Feb 15, 2026
Merged

Fix web fullscreen sizing and stability#12
Atrix256 merged 1 commit intoAtrix256:mainfrom
fcarucci:fix/webgpu-fullscreen-fill

Conversation

@fcarucci
Copy link
Contributor

Summary

Fixes WebAssembly/WebGPU fullscreen behavior on web builds so rendering remains stable and fills the screen.

Changes

  • Added proper web fullscreen handling in thirteen.h (PlatformWeb):
    • Request fullscreen via emscripten_request_fullscreen_strategy.
    • Fallback to soft fullscreen if needed.
    • Handle fullscreen enter/exit with CSS updates so canvas fills viewport.
  • Improved WebGPU surface robustness during fullscreen transitions:
    • Recreate/reconfigure surface when texture acquisition fails.
    • Keep render path resilient to transient canvas/surface state changes.
  • Removed unsupported wgpuSurfacePresent usage in web runtime path.
  • Kept all fixes inside thirteen.h (no example source changes).

Validation

  • Rebuilt WASM sample with:
    • emcc Examples/Simple/main.cpp -std=c++17 -I. --use-port=emdawnwebgpu -sASYNCIFY -sALLOW_MEMORY_GROWTH=1 -o /tmp/thirteen_simple.html
  • Verified fullscreen no longer blacks out and canvas fills screen in Chrome

@Atrix256 Atrix256 merged commit aa6b707 into Atrix256:main Feb 15, 2026
20 checks passed
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