• 2D
  • [SOLVED] 2d pixels don't look good fullscreen even with aspect ratio

I followed this tutorial https://mail.google.com/mail/u/0/#inbox/FMfcgxwLtGqFLbhCcGcsbJbdBgTcSmXr

I used a resolution of 32 by 16 x 32 by 9 and even with a 16:9 ratio the pixels look ugly when I maximize the window to full-screen. I attached my project. I am running a high res DELL monitor that has a resolution of 1920x1080 (1080p) and I don't know how to set up for 2d pixel art that looks good even when scaled up.

Thanks.

@Ekamu said: I am running a high res DELL monitor that has a resolution of 1920x1080 (1080p) and I don't know how to set up for 2d pixel art that looks good even when scaled up.

The only thing I see is that your window stretch mode` is "viewport" but your window size width and height aren't exact integer divisors of 1920 and 1080. So you get a small amount of inconsistent stretching, where not every viewport pixel can occupy exactly the same number real screen pixels. If you use e.g. 480x270 (exactly 1/4th your target screen resolution) then that will go away.

That said, the effect is quite subtle in your example, due to how slightly the ratio is off and how simple your tile is, so this may not be the problem. Is it possible that your example tile just doesn't look the way you want under pixel magnification?

Even with a resolution that is a multiple of 1920x1080 like 960 x 540 (or your example of 480 x 270 ) doesn't work out well. I posted a screenshot to show how it looks. Its not subtle and actually very noticeable at least for me. I'm not sure if its pixel magnification of if its the windows default menu HUD (were you can maximize, minimize and close a window) that slightly distort the pixels.

I believe for that to work you need to make it full screen and make sure your viewport texture has mipmapping disabled. Otherwise you need to take the window size and window decorator sizes to account.

Ok, I added a toogle for fullscreen, you can press enter "ui_accept" to toogle fullscreen. I also used 480x270 as the resolution. However how do I disable mipmapping? Is that in project settings or in the inspector somewhere?

In import I already used the 2d pixel preset which has unchecked mipmaps unless your mean something else or somewhere else I don't know how to disable mipmapping.

I'm a bit lost in reading this https://docs.godotengine.org/en/2.1/learning/workflow/assets/importing_textures.html

IIRC there should be a setting for mipmapping in the inspector when you select your viewport container. That is, if you are using one. If you aren't then you probably don't need to worry about it.

edit: Running it in full screen on my 1080p monitor looks perfectly crisp. I used version 3.2.1. since that was the most convenient to me right now though.

@Ekamu said: Ok, I added a toogle for fullscreen, you can press enter "ui_accept" to toogle fullscreen. I also used 480x270 as the resolution.

Oh, I didn't realize that Windows doesn't have a way to full-screen any application. Good to know! But yes, explicitly going full-screen with an exact integer divisor of the screen dimensions should be resolving any distortion.

Note that the "2.1" in the URL is the Godot version, while you are presumably using the latest stable? In which case you want the stable release "Importing images" documentation page, with details hopefully better-matching your version of Godot.

That said, your import settings for the cube image are already set to generate a texture without mipmaps or a smooth rescale filter, which is how you want it for pixel art.

Try this: set widow size height and width to 240x135 then window size "test width" and "test height" to 960x540. That should give you a window in which the contents will be scaled up by the same amount as running at 480x270 fullscreen. Then compare side-by side how your graphics look versus zooming in 4x on your cube graphic in your image viewer/editor of choice. I think you'll find that they look identical.

Thanks. your right it looks identical. Also thank you for the link. Ill be sure to note the version number when checking out documentation.