0 votes

I am working on an NES-style project in Godot 3.1 beta 9.

My native resolution is 256x240 and my sprite size is 16x16. I have use_pixel_snap set to true, display/window/stretch /mode set to 2d, display/window/stretch/aspect set to keep.

I notice that when I enter fullscreen, however, my player sprite has some strange pixel artifacts. It largely looks like it is supposed to, with the 16x16 sprite cleanly scaling up.

Unfortunately, sometimes there are a few stray pixels where they shouldn't be. If I move the player a little, they either go away, or change to new positions. I notice them more frequently when my sprite is facing left (during which the spite has flip_h = true), but I also notice them periodically when moving right.

Here is an example:

enter image description here

(I had to take this photo with my phone, since Windows screencap doesn't work when Godot is fullscreen.)

The sprite should look like this:

enter image description here

What is causing these artifacts and how do I get rid of them?

I have confirmed that I have imported my assets using lossless compression.

in Engine by (1,597 points)
edited by

I'm no 2D expert. My idea is just that you check the import setting for the texture. It should be lossless. (Maybe check also the defaults in the project preferences)

You might try also going with the latest beta: https://godotengine.org/article/dev-snapshot-godot-3-1-beta-9
Especially if your project renders on GLES2.

These all are just guesses. Might help might or not change anything.

Are you use Camera2D?

Yes, Camera2D, no scrolling.

Updated to Godot 3.1 beta 9 and confirmed I have imported my assets using lossless compression. The problem persists.

Please log in or register to answer this question.

Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read Frequently asked questions and How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to [email protected] with your username.