Skip to content

Add GameConfig.antialiasGL - #763

Merged
samme merged 1 commit into
phaserjs:masterfrom
asger-finding:add-antialiasgl-config
Oct 29, 2026
Merged

samme merged 1 commit into
phaserjs:masterfrom
asger-finding:add-antialiasgl-config

Conversation

@asger-finding

Copy link
Copy Markdown
Contributor

This PR

  • changes documentation
  • changes TypeScript definitions
  • changes the public-facing API

Describe the changes below:

The game config's antialias sets both texture smoothing (stage.smoothed) and the WebGL context's antialias attribute, so you can't turn off the context's multisampling and keep smooth textures. We've found that on weak or software-rendered GPUs, that multisampling can be a huge cost per frame, causing our low-powered players to lag.

Turning it off took a software-rendered game round from 38 to 60 fps.

antialiasGL in the game config now sets the context attribute on its own, like Phaser 3's antialiasGL. It defaults to antialias, so existing games are unchanged.

@samme
samme merged commit 2c8f1b5 into phaserjs:master Oct 29, 2026
1 check 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