a vibe coded Blender style shader studio running on the Nintendo 64

Vasily 8a91239edc Initial commit: N64 Node Shader Studio in pure Rust 6 روز پیش
crates 8a91239edc Initial commit: N64 Node Shader Studio in pure Rust 6 روز پیش
dist 8a91239edc Initial commit: N64 Node Shader Studio in pure Rust 6 روز پیش
.gitignore 8a91239edc Initial commit: N64 Node Shader Studio in pure Rust 6 روز پیش
Cargo.lock 8a91239edc Initial commit: N64 Node Shader Studio in pure Rust 6 روز پیش
Cargo.toml 8a91239edc Initial commit: N64 Node Shader Studio in pure Rust 6 روز پیش
README.md 8a91239edc Initial commit: N64 Node Shader Studio in pure Rust 6 روز پیش
build-rom.ps1 8a91239edc Initial commit: N64 Node Shader Studio in pure Rust 6 روز پیش
el plan.md 8a91239edc Initial commit: N64 Node Shader Studio in pure Rust 6 روز پیش

README.md

N64 Node Shader Studio

A pure #[no_std] Rust interactive node-based shader studio for real Nintendo 64 hardware (zero C dependencies), compiling node graphs directly into 64-bit N64 Reality Display Processor (G_SETCOMBINE) hardware commands with a live 3D hardware-rasterized preview viewport.

Workspace Layout

  • crates/shader-core: Pure #![no_std] engine (no alloc) containing the zero-heap NodeGraph, Graph-to-RDP compiler + software reference evaluator, 6 shader presets, procedural 32×32 RGBA5551 textures, 4 procedural 3D meshes (Sphere, Torus, Cube, Teapot), SGI-style split-screen UI + 4×6 bitmap font, and CRC-16 EEPROM graph serializer.
  • crates/n64-rom: Bare-metal #![no_std] #![no_main] MIPS III (mips-nintendo64-none) ROM using VR4300 cache ops, VI (320×240p / 640×480i with Expansion Pak), direct RDP triangle/combiner/TMEM command lists, SI/PIF Joybus Controller + N64 Mouse + 4K/16K EEPROM drivers, and CP0/DPC silicon performance counters.

Building & Testing

Run host PC unit tests:

cargo test

Build the bootable .z64 ROM into dist/n64-shader-studio.z64 (requires nightly-2025-01-12 with rust-src and nust64):

.\build-rom.ps1

Copy dist/n64-shader-studio.z64 onto your EverDrive-64 / SummerCart64 SD card and boot on real N64 hardware.

Controls

Input Action
Analog Stick / N64 Mouse Move cursor across the Left 65% Node Canvas
D-Pad Snap cursor directly to nearest pin or node title bar (or navigate menus)
A Button (or Mouse Left) Start/complete wire between pins, unplug connected input, drag node title bar, or edit node parameters
B Button (or Mouse Right) Cancel drag, close popup, or unplug hovered input pin
Z Button Open Add-Node menu at cursor
Z + B Delete hovered node (Output node is protected)
Start Open Studio Menu (6 Presets, Auto-Spin, Perf HUD, 320p/480i toggle, EEPROM Save/Load)
L Button Cycle 3D preview mesh (Sphere, Torus, Cube, Teapot)
R Button Cycle lighting preset (Studio, Rim, Toon, Sunset)
Z + R Toggle wireframe overlay
C-Buttons Orbit 3D preview camera