The golden age of software rendering may be over, but we can still indulge in our hobbies and learn a thing or two along the way.

DIWide is a real-time software renderer that exists at the intersection of features, speed, and simplicity. It's designed to be fast enough for a game, and simple enough to serve as example code.

DIWide provides simple implementations of modern shading techniques, in contrast to existing software renderers which typically focus either on simpler graphical styles, or on compatibility with GPU-targetted graphics APIs like DirectX and OpenGL. By shrugging off features which are not strictly necessary for good-looking graphics - such as compiling shaders at runtime, texture borders, fancy color modes, etc. - DIWide trades some practicality for a great deal of simplicity.

I started this project as a way to have fun and practice writing optimized low-level code while learning about graphics programming and 3D math, but I'm making it public in hopes that it may be interesting or informative to somebody else. I'll be publishing articles and videos to share information and insights about optimization- and graphics-related topics that I come across while working on DIWide.

Current features:

  • perspective-correct vertex attribute interpolation
  • correct near-plane clipping, backface and viewport culling
  • fully gamma-correct pipeline
  • bilinear texture filtering
  • diffuse, normal, and roughness maps
  • high-resolution shadow mapping
  • simplified physically-based per-pixel lighting model
  • proof-of-concept SSE2-accelerated rasterizer
  • built-in GIF exporter
  • 60fps @ 480p on a 5-year-old laptop CPU

Planned features:

  • better test scenes
  • 4x MSAA
  • multiple lights with smart (per-model, per-triangle) light culling
  • mipmaps
  • cascaded shadow maps
  • cubemap skybox and reflections
  • cubemap shadows
  • tone mapping
  • bloom
  • full SSE2 and AVX2 rendering pipelines
  • multithreaded blit and rasterizer
  • articles and videos explaining interesting aspects of the implementation
  • 720p and beyond?