This is a little experimental project using Zig directly with GLFW + Vulkan.
The goal is to learn graphics programming, make some interesting shaders, and eventually implement cimgui to modify various parameters.
This repository uses cimgui and imgui as submodules, please clone using the --recursive flag, or by doing: git submodule update --init --recursive
Install zig, glfw, vulkan-devel
Build+run with zig build run
Simple as
Currently only supports building on Windows using the precompiled lib-static-ucrt GLFW binary with glfw-3.4.
-
Install zig from your favorite package manager, or manually if needed
-
Install the Vulkan SDK from here
-
Get glfw binaries from here. Download the precompiled binaries and place them directly under /lib
Example folder structure:
lib
└───glfw-3.4.bin.WIN64
├───include
│ └───GLFW
└───lib-static-ucrt
The project can be built and run with zig build run
, this automatically adds the glfw3.dll to the path while running
If running the executable manually after build, ensure the appropriate glfw3.dll file is in the same directory
Use zig build --help
to see available build options
Of note are the Project-Specific Options, such as -Doptimize=ReleaseFast
. -Doptimize=Debug
is the default when no optimization level is specified.
GLFW Quick Start
GLFW Vulkan Guide
Vulkan Tutorial (Conveniently uses GLFW)