Jump to content

Disable sprite smoothing?


Recommended Posts

Hello all!

I'm currently playing around with pixi.js and i have used to these things with normal canvas. I think this might have been asked many times, but how do i disable that image anti-aliasing from pixi.js? In normal canvas i could use context.imageSmoothingEnabled= false, but i think that this doesn't help here?

- I have tried to set canvas css to image-rendering: pixelated;

- i tried PIXI.settings.SCALE_MODE = PIXI.SCALE_MODES.NEAREST; but it doesn't help.

- I also used antialising: disabled at the autoDetectRender -function.


Anybody have any idea how to make it work? Or can you even disable it?

Screenshot from 2017-02-23 13:30:31.png

Link to comment
Share on other sites

On 2/25/2017 at 5:56 AM, ServerCharlie said:

Isn't the antialias supposed to be set: false, instead of disabled? :/ 

Yeah i tried both ways.


On 2/24/2017 at 2:40 PM, ivan.popelyshev said:

       That should be before loader, not after textures are set up. But even with that fix , I dont see that it works :( I'm gonna think about it

Yeah it didn't work. It's weird that the canvas rendering works fine, there is no smoothing. But if it uses webgl, it goes smooth.

Link to comment
Share on other sites

12 minutes ago, ivan.popelyshev said:

That's definitely a bug with "settings". You can mark with NEAREST all the textures manually before the first render. Otherwise you have to wait while somebody finds the mistake and fixes it, i dont have time right now.

How do i change the scalemode for textures manually? I found the scalemode variable from texture -> basetexture -variable, is it the right one to change?


E: Yeah it worked manually. Guess i have to make function which changes them manually then.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Recently Browsing   0 members

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