A site dedicated to learn SDL GPU and Graphics one step at a time. Folks familiar with existing APIs should feel comfortable skipping around.

Most of the following lessons actual prose hasn't been started, or have at best have loose partial outlines. That said, we have examples up through the Vertex and Index Buffers lesson, although we're still tweaking all of the examples as we move along. The titles will say the status at the end, unless they're mostly complete, which is just the first two at time of writing.

Introduction and the Template

Status:
  • Example: Finished
  • Chapter: Finished

An introduction to this series, what you should expect, choices that have been made, additional resources, and a demonstration of setting up the template project if you'd prefer that over rolling your own.

Window and Clearing

Status:
  • Example: Finished
  • Chapter: Finished

Before you render a triangle, you must first create a window, and then ideally clear it to a friendly blue color. Covers the basics of initialization of SDL, the Window, and the GPU Device, as well as the most basic usage of Command Buffers, Swapchain Textures, and a RenderPass.

A Triangle

Status:
  • Example: Finished
  • Chapter: Finished

After clearing the screen, the next milestone is rendering a triangle Triangle. Will cover the creation of Vertex and Fragment shaders and a simple demonstration of "Vertex Pulling".

Uniform Buffers and a Fullscreen Triangle

Status:
  • Example: Finished
  • Chapter: Finished

More interesting rendering will require learning buffers, we'll begin with the simplest type to use, Uniform Buffers. As well as an example of why you might actually use a single triangle later on in your Graphics journey.

Quads and Textures

Status:
  • Example: Finished
  • Chapter: In progress

Extending off of Uniform Buffers, we'll learn about Texture Buffers, so we can finally display images beyond colored shapes.

Depth

Status:
  • Example: Finished
  • Chapter: Outlined

Draw overlapping quads at different depths and use a depth buffer to resolve their visibility.

The Object To NDC Pipeline

Status:
  • Example: Finished
  • Chapter: Outlined

We've been skirting around it, but it's time to talk in more detail about coordinate spaces and how we transform between them. We'll also be demonstraiting the Orthographic Projection so we can display objects in a more sensible space than a [-1, -1] to [1, 1] box.

The Cube and Math

Status:
  • Example: Finished
  • Chapter: Outlined

We're not done learning about APIs that can help us in 2D, but it's time to start learning about 3D rendering. We'll be rendering a cube, and along the way learn about properly constructing a model matrix, and expand out our math library.

Vertex and Index Buffers for Real

Status:
  • Example: Finished
  • Chapter: Outlined

Move cube geometry out of the shader and into vertex and index buffers.

An "FPS" Camera

Status:
  • Example: Finished
  • Chapter: Outlined

Without a dynamic camera, we'll be really struggling when rendering models and scenes, so lets get this out of the way.