GLASSA stained-glass puzzle game with a tactile editor, a responsive musical score and a custom C++ geometry system.GodotGDScriptC++View case study
Technical art
Making GLASS look refractive with an opaque material and a deliberately limited view of what lies behind it.

I spent time looking through pieces of real stained glass before settling the material in GLASS. At a workshop I photographed different textures held up to the light. Some bent the image broadly; others broke it into smaller variations. The texture of the surface mattered as much as the colour.
On a phone, the effect needed to suggest that material without reproducing everything light does in real glass. The game looks at a particular kind of window, from a limited set of views. I could build for that situation.
The surface in GLASS is not transparent. It shades as an opaque material and constructs the image that appears to lie behind the pane.
A normal map supplies the small changes in surface direction. I use that direction to cast into a virtual sky-and-cloud model. Another part of the shader samples a cached image of the puzzle's lines and permanent colours, projected onto a plane behind the pane. The result combines the puzzle information and the sky.
It looks as though the glass is refracting the scene, but it is working with those deliberately limited sources. There is no need to claim a complete representation of the world behind it.
The cached puzzle plane lets the effect include recognisable parts of the window. The sky gives the surface something to distort beyond those lines and colours. The normal map ties both to the texture of the pane.
That is more specific than a general refraction system. It also avoids relying on conventional transparent rendering for the panes. An opaque material does not make every cost disappear: the sky evaluation, texture reads and geometry still have to fit the device. It simply lets me spend the budget on the particular image I need.
The workshop photographs were useful when a technically interesting effect stopped looking like glass. I could compare the result with a real surface instead of adding more complexity because I knew how to calculate it.
This is the sort of detail I enjoy working on. A small change to distortion or surface texture can do more for the material than a much more elaborate effect. The point was to get a window that reads well in GLASS, not a shader that claims to handle every possible piece of glass.