+1 vote

Hi all!

I am trying to start writing shaders in Godot 3. I would like to implement a basic bloom shader in a 2D (pixel-art like) game. I know more or less how a fragment shader works, what is the syntax, and even how to perform some things like gaussian blur and similar stuff.

However, I've never worked with shaders and I do not know what is the best strategy to implement this kind of effect in 2D. I want an effect similar to this: https://www.youtube.com/watch?v=8NSWtp5ziLY It should looks like it emits light (and it should illuminate nearby objects, such as the tilemap or other characters in the game).

Any ideas on how to implement that? I have read some ideas for 3D shaders, but they do not seem to adapt very well to 2D sprites (since, for example, it looks like the effect of the fragment shader is bounded by the texture size of the sprite... How can I circumvent that?)

Also, resources & tutorials in 2D shading techniques would be super-appreciated!
Thank you very much in advance!

in Engine by (73 points)

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.