How can one achieve a dynamic glow effect in Java Slick2d? I want an image to be surrounded by a glow when I move my mouse over it for example.


enter image description here No glow

enter image description here Glow

Is it possible to make this programmatically?


1 Answer 1


I would suggest just making the image with a glowing effect, but if you must have it done in game then you would:

1) Render your scene or "glow objects" to texture A

2) Bind texture A, then using the horizontal shader, render a quad to texture B

3) Bind texture B, then using the vertical shader, render a quad to texture A

However This requires the following OpenGL extensions:

  • GL_ARB_shader_objects or GL20

  • GL_EXT_framebuffer_object or GL30

(You can find the full answer on the website below. The guy there explains it better than me)



You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .