https://github.com/wagiejack/velarium
Toy Paint application made with SDL2+Odin, supports drawing, shapes, undo-redo , fill and lasso deletion.
https://github.com/wagiejack/velarium
canvas drawing odin paint paint-tool tool
Last synced: 4 months ago
JSON representation
Toy Paint application made with SDL2+Odin, supports drawing, shapes, undo-redo , fill and lasso deletion.
- Host: GitHub
- URL: https://github.com/wagiejack/velarium
- Owner: wagiejack
- License: mit
- Created: 2025-02-15T16:47:12.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2025-02-15T17:46:52.000Z (over 1 year ago)
- Last Synced: 2025-09-04T09:49:27.557Z (10 months ago)
- Topics: canvas, drawing, odin, paint, paint-tool, tool
- Language: Odin
- Homepage:
- Size: 387 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Velarium
Name was straight up takes up from Claude with the prompt "Cool canvas names possibly from old times",
Anyhow, this was made a **side project** after 3-modules into [Pikuma's 3-d Graphics Programming course](https://pikuma.com/courses/learn-3d-computer-graphics-programming),
I'd just gained ability to render pixels onto screen and was bored with theory, which jump-started a month's journey into making a paint desktop application `(ik ik, initializes at 800x600, has single paint colors, so not really something a "cracked guy with high agency" would make)`
This how the pixel manipulation wizardry got me feelin' like though

Although the course was in C, i did this in Odin+SDL2 cover Odin exposure Side-Quest
Here is a small demo

# Usage
| Category | Command | Action |
|-----------|---------|---------|
| Basic Drawing | `D` + Mouse | Draw continuously |
| Shapes | `D + R` + Drag | Create rectangle |
| | `D + C` + Drag | Create circle |
| | `D + E` + Drag | Create ellipse |
| | `D + T` + Drag | Create triangle |
| | `D + L` + Drag | Create straight line |
| Area Operations | `F` | Fill enclosed area (red) |
| | `D + X` + Drag | Clear circular selection |
| Undo/Redo | `U` | Undo last action |
| | `R` | Redo last action |
| Controls | `ESC` | Exit application |
| | *Auto* | Display reference grid |
# Prerequisites
| Platform | Component | Installation |
|:---:|:---:|:---:|
| All | Odin Compiler | Install from [odin-lang.org/docs/install](https://odin-lang.org/docs/install/)
Add to system PATH |
| macOS | SDL2 | `brew install sdl2` |
| Linux | SDL2 | `sudo apt-get install libsdl2-dev` |
| Windows | SDL2 | 1. Download from [SDL Releases](https://github.com/libsdl-org/SDL/releases)
2. Extract to `vendor/sdl2` in Odin directory |
# Building and Running
| Platform | Command |
|:---:|:---:|
| macOS | `odin run main.odin -file -extra-linker-flags:"-L/opt/homebrew/lib"` |
| Linux | `odin run main.odin -file` |
| Windows | `odin run main.odin -file` |
# Known Issues and Limitations
Window size is fixed at 800x600 pixels
Limited color palette (predefined colors only)
No file save/load functionality
# Contributing
Feel free to submit issues and enhancement requests. To contribute:
- Fork the repository
- Create a feature branch
- Commit your changes
- Push to the branch
- Create a Pull Request
# License
This project is open source and available under the MIT License.