Skip to content

lbr-dev/IZG-Project

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 

Repository files navigation

Software GPU Rasterizer

A software implementation of a GPU rendering pipeline. Written in C++17 as part of the IZG (Computer Graphics Principles) course at FIT VUT Brno.

Score 20/20 pts.

Demo


What it implements

The full rendering pipeline executed in software on the CPU:

  • Command buffer — GPU command queue (bind, draw, clear, user/sub commands)
  • Vertex assembly — indexed and non-indexed, attribute fetching from buffers
  • Vertex shader — programmable per-vertex transform stage
  • Perspective division & viewport transform
  • Backface culling — front face configurable (CW/CCW)
  • Near-plane clipping — clip-space triangle clipping before rasterization
  • Rasterization — barycentric coordinates, perspective-correct interpolation
  • Stencil test — configurable comparison, separate front/back ops (sfail/dpfail/dppass)
  • Depth test — with optional depth write
  • Fragment shader — programmable per-fragment stage with discard support
  • Blending — configurable source/destination factors and equation
  • Color/depth/stencil write masks
  • 3D model rendering — glTF/GLB model loading with per-mesh shaders

Running

Download the latest binaries from the Releases page.

Linux

chmod +x izgProject_linux
./izgProject_linux

macOS

chmod +x izgProject_macos
# First run: right-click the binary -> Open, or:
xattr -d com.apple.quarantine ./izgProject_macos
./izgProject_macos

Controls

Input Action
Left mouse + drag Rotate camera
Right mouse + drag Zoom
Middle mouse + drag Pan
n / p Next / previous scene
w s a d q e Move camera
Esc Quit

Flags

./izgProject -h          # help
./izgProject -c          # run conformance tests (Linux only, see below)
./izgProject --method N  # select rendering method (scene)

Note: Conformance tests (-c) require the teacher's pre-compiled reference binary, which was only provided for Linux and Windows. Tests will not run on macOS.


Notes

Source code is not public — course project policy. Built and tested on Ubuntu 24.04 (x86_64) and macOS (aarch64).

About

Project for subject IZG - Computer Graphics Principles

Topics

Resources

Stars

Watchers

Forks

Contributors