A low-level software renderer from (almost all) first principles for learning purposes.
Go to file
2017-06-20 22:22:39 +10:00
docs Add documentation 2017-06-09 18:24:37 +10:00
src Fix some dqn platform compile problems 2017-06-20 22:22:39 +10:00
.gitignore Add platform api to access from dll 2017-05-11 22:51:39 +10:00
readme.md Add documentation 2017-06-09 18:24:37 +10:00
Win32DTRenderer.sln Add mem diagnostics, prepare for bitmap rotation 2017-05-17 02:49:33 +10:00

DTRenderer

DTRenderer is an attempt to build a simple software renderer from the ground up. The main goal is to build an intuitive understanding of graphics mathematics, rendering pipeline and core concepts. It runs as a Win32 program with minimal dependencies.

DTRenderer Demo

The following resouces have been largely informative to my understanding of the software renderer,

Building

DTRenderer is a Win32 program and can be compiled with build.bat which requires Microsoft Visual Studio cl.exe to be in the Windows path. It is originally built using Visual Studio 2017, older versions are still somewhat compatible, albeit there are some switches which have been renamed in the 2017 edition.

The Visual Studio solution file is provided as a thin wrapper for interfacing with the Visual Studio debugger and can not be used to compile.

Milestones

  • 2D Software Rendering
    • Alpha Blending
    • Bilinear Filtering
    • Correct Color Space Pipeline (SRGB <-> Linear)
    • Rasterisation
    • Texture Mapping
    • Translation, Rotation, Scale
  • 3D Model Rendering
    • Full Bright, Flat, Gouraud Lighting
    • Orthographic, Perspective Projections
    • Translation, Rotation, Scale
  • Custom Wavefront Obj Loader (minimal subset)
  • Hot-Reloadable DLL for Renderer Code (taken from Handmade Hero)
  • SIMD "Optimisation" (with a grain of salt, tried to with some % improvements)

Libraries

The external libraries that have been used,

  • STB Single File Libraries
    • STB Image (for image loading)
    • STB TrueType (and RectPack) (for creating bitmap font)

Debugging Libraries

These libraries are non-essential and used for validating results and debugging the program.

  • STB ImageWrite (for debugging renders, TrueType output etc.)
  • EasyProfiler (for profiling)
  • TinyRenderer (for comparing data output for validity of results)