Has anyone here every implemented shadows for 2D GUI objects with OpenGL shaders? In theory it’s possible and it looks like servo supports rendering shadows for html in OpenGL. I found some sites that give shaders for shadows.
Any help or tips on how to wire them in would be awesome. I don’t know how to add them with Figuro’s rendering engine and it’d probably take me a while to figure it out. The renderer is essentially the same as Fidget and is based on a texture atlas. The existing shaders look pretty simple. Here’s the core of the OpenGL stuff:
https://github.com/elcritch/figuro/blob/main/src/figuro/renderer/opengl/glcontext.nim
I recently added some Pixie based shadows, which are awesome, but can take far to long to render in realtime. So I’m doing resizing hacks which lowers the quality of the shadows. Especially for inset shadows.
It’d also be great to be able to support that glassy blurred background effect in OpenGL as well!