omdxp/chip8
Chip8 Emulator in Zig
424ff5f9245ef352e4c508c77ddaeed2f46bd605
cc5c6a5d71a317ed4b0ad776842d1d0655f72d0a
A simple CHIP-8 emulator written in Zig, using SDL2 for graphics and keyboard input. This project is intended for learning, experimentation, and playing classic CHIP-8 games.
brew install sdl2
libSDL2.dylib
on macOS)brew install zig sdl2
zig build
To run a CHIP-8 game:
zig build run -- -p games/PONG
Replace games/PONG
with the path to any CHIP-8 ROM in the games/
directory.
Note: SDL2 is dynamically linked. You must have the SDL2 dynamic library (libSDL2.dylib
on macOS) available in your system library path. If you get a library not found error, ensure SDL2 is installed and your library path is set correctly.
main.zig
for mapping)src/
— Zig source filesgames/
— Example CHIP-8 ROMsbuild.zig
— Zig build scriptMIT License. See source files for details.