Jump to content

Disable Antialias in Phaser 3


Recommended Posts

In Phaser 2, there was a simple parameter you could set to disable antialiasing/smoothing, but i cannot disable it in Phaser 3. I assumed it should be in the config object like this, but it did not work:

const config = {
	width: window.innerWidth,
	height: window.innerHeight,
	parent: 'canvas',
	type: Phaser.AUTO,
	physics: {
		default: 'arcade',
		arcade: {
			gravity: {y: 0},
			debug: true
	scene: [
	antialias: false
const game =  new Phaser.Game(config);

Is there another way to disable it? I found "game.config.antialias" in the phaser.js file, but i tried with "false" and "0", nothing worked. I also found it in the WebGLRenderer.js file and it looks like it should be a boolean - but still, it did not work.

I tested it with <canvaselement>.getContext('webgl').getContextAttributes().antialias and the value is always true.

Link to comment
Share on other sites

  • 1 year later...

  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Create New...