Bilinear Filtered Scaling

An asset by ntfwc
The page banner background of a mountain and forest
Bilinear Filtered Scaling hero image

Quick Information

0 ratings
Bilinear Filtered Scaling icon image
ntfwc
Bilinear Filtered Scaling

Makes it easy to use an alternate form of window scaling that better preserves the apparent pixel sizing.Includes a bilinear filtering shader and a scene that uses it for window scaling. This prevents variations in pixel sizes at resolutions that can't be divided perfectly, while keeping pixels well defined. Especially useful for pixel art games.

Supported Engine Version
3.0.4
Version String
1.1
License Version
MIT
Support Level
community
Modified Date
6 years ago
Git URL
Issue URL

Description

This project provides a bilinear filtering shader and a script for using it with a viewport to replace the default window scaling.

This is mainly useful for pixel art games. The default scaling uses nearest-neighbor, which causes apparent pixel sizing to vary when at resolutions that are not perfect multiplications of the source resolution. By using this shader and updating the pixel_scale uniform, you get well defined pixels at any resolution larger than the source.

Using it

This is a Godot 3 project. Refer to the Godot 3 documentation for how to use the editor and launch a project.

The default scene shows a test image and demonstrates the shader working with window scaling. To use it in a project, you would only have to replace the TextureRect under the Viewport with your main scene, and set the source resolution for the script.

Makes it easy to use an alternate form of window scaling that better preserves the apparent pixel sizing.

Includes a bilinear filtering shader and a scene that uses it for window scaling. This prevents variations in pixel sizes at resolutions that can't be divided perfectly, while keeping pixels well defined. Especially useful for pixel art games.

Reviews

0 ratings

Your Rating

Headline must be at least 3 characters but not more than 50
Review must be at least 5 characters but not more than 500
Please sign in to add a review

Quick Information

0 ratings
Bilinear Filtered Scaling icon image
ntfwc
Bilinear Filtered Scaling

Makes it easy to use an alternate form of window scaling that better preserves the apparent pixel sizing.Includes a bilinear filtering shader and a scene that uses it for window scaling. This prevents variations in pixel sizes at resolutions that can't be divided perfectly, while keeping pixels well defined. Especially useful for pixel art games.

Supported Engine Version
3.0.4
Version String
1.1
License Version
MIT
Support Level
community
Modified Date
6 years ago
Git URL
Issue URL

Open Source

Released under the AGPLv3 license

Plug and Play

Browse assets directly from Godot

Community Driven

Created by developers for developers