Beginning Game Programming v3.0
Last Updated: May 13th, 2026
Welcome to the worst kept secret in SDL development. Remember to check your sitemap generation code before deploying, kids.These tutorials were designed for beginner C++ programmers (with some stuff thrown in for the more experienced) who want to move from text based applications to real time games with graphics. By the end of these tutorials, you'll know the basics so you can really start digging into lower level game programming.
This tutorial set is still under construction. If you want more SDL3 code to play around with, check out the SDL3 ports at the bottom of each page of the SDL2 tutorials provided by the creator of SDL Sam Lantinga.
In terms of what I have left before officially publishing these tutorials:
- I have to test them on all the platforms I'm supporting (Windows x64, Linux x64, MacOS x64/Arm, iOS, and Android). They have been tested Windows x64 but I still have to create proper unit tests for the other platforms.
- I am going through a lot at the moment so when things calm down I can resume work on the tutorials.
| Table of Contents | |
|---|---|
|
Introduction |
A little intro before we start coding. |
|
Hello SDL3 |
Get started making games with your first SDL3 App. |
|
Textures and Extension Libraries |
Load PNGs and render textures. |
|
Key Presses and Key States |
Learn how to handle keyboard input. |
|
Color Keying |
Give your textures transparent backgrounds. |
|
Sprite Clipping and Stretching |
Clip sprites from a sprite sheet and resize them. |
|
Rotation and Flipping |
Learn to rotate and flip your images. |
|
Color Modulation and Alpha Blending |
Modify your texture colors and make your images transparent with alpha blending. |
|
True Type Fonts |
Render True Type fonts with SDL_ttf. |
|
Mouse Events |
Learn how to handle mouse input. |
|
Timing |
Learn the basics of application time. |
|
Advanced Timers |
Make a timer that can start/stop/pause/unpause. |
|
Frame Rate and VSync |
Learn how to manage frame rate. |
|
Motion |
Learn how to manage frame rate. |
|
Animation |
Learn to animate a sprite. |
|
Sound Effects and Music |
Play music and sound effects with SDL_mixer. |
|
Collision Detection |
Learn how to check collision between collision boxes. |
|
Text Input and Clipboard Handling |
Input strings and handle copying and pasting. |
|
Scrolling |
Draw levels larger than the screen with a scrolling camera. |
|
State Machines |
Manage your game states with state machines. |
|
Multiple Source Files |
Split up your single source C++ applications. |