Skip to content

Reflection technique study

Eight ways to bounce a ray off a mirror.

A research fleet of pure-C# renderers, each committed to one honest reflection technique - recursive path tracing, planar render-to-texture, cubemap probes, screen-space marching, curved and imperfect glass. No game engine, no shader language, no external image assets: every pixel is traced or rastered in plain C# against the OnlyCSharp 1.7 library (GIF encoder and seeded RNG only), then written straight to an animated GIF.

Renderers
8
Techniques
6
External assets
0
Language
C# only

Method

How these were made

Each renderer is a standalone C# console project. It builds against a small slice of the OnlyCSharp 1.7 library - the GIF byte-encoder, a seeded PCG32 RNG for jitter and soft shadows, and value noise - and reaches for nothing else. There is no OpenGL, no shading language, and no texture file on disk; the geometry, cameras, lighting, and every reflection are computed in ordinary managed code and resolved to an animated GIF.

The point of the fleet is comparison. Run the same mirror problem through recursive tracing, then a mirrored-camera pass, then a cubemap probe, and the tradeoffs stop being abstract: the traced hall shows real bounce energy loss, the screen-space floor visibly loses off-screen reflections, and the curved-glass study foregrounds the surface imperfections a clean model hides.