A high performance painting application built entirely in C and SDL2.
I built this project because I wanted to understand how software actually works "under the hood." Instead of using a heavy engine, I wanted to access the hardware directly using C.
Draw Paint is about the joy of putting pixels on a screen with code that I wrote from scratch just pure logic and a C23 compiler. I am also a huge fan of distributing my code with others a.k.a Open source.
- Pixel Circles: Custom coded drawing algorithm optimized for performance.
- Color Palette: Quick access colors at the top of your screen.
- Portable: Compiles into a single, standalone executable for Windows.
The interface is designed to stay out of your way so you can just focus on creating.
| Action | Control |
|---|---|
| Draw | Left Mouse Button |
| Change Brush Size | Mouse Wheel |
| Change Color | Click a color in the top palette |
| Save Image | Press S (Saves as painting.bmp) adding soon .png and .jpg support |
| Clear Canvas | Press C |
This project uses a custom Makefile to handle the heavy lifting. You will need MinGW-w64 and the SDL2 development libraries installed on your system.
- Windows: Install MinGW-w64 and SDL2.
- Linux/macOS: Install GCC and SDL2 via your package manager (
sudo apt install libsdl2-dev).
Builds with extra info for debugging and keeps the console window open.
- Windows:
mingw32-make debug - Linux/macOS:
make debug
Optimizes the code for speed and hides the console window.
- Windows:
mingw32-make release - Linux/macOS:
make release
This project is licensed under the MIT License. This means you are free to use, modify, and distribute the code however you like, as long as you provide credit. See the LICENSE file for details.
- SDL2 Team: For the amazing cross platform library that makes hardware access possible.
- The C Community: For keeping the most powerful language in the world alive for over 50 years.
- You: For checking out my project! If you like it feel free to give it a ⭐ on GitHub.

