Edit in place
Reload shaders while keeping the last good frame after a bad edit.
Live shader authoring · Ruby
Load Ruby shader definitions, compile them through RLSL, and render them with RBGL.
gem install glaze
Iterate live, render headlessly, or export a self-contained WebGPU page.
Reload shaders while keeping the last good frame after a bad edit.
Use the CPU renderer or Metal on supported macOS hosts.
Capture PNGs, record sequences, or export WebGPU HTML.
A small first step
Install the gem, then follow the project guide for platform requirements and the full API.
require "glaze"
Glaze.shader(:pulse) do
params { float :speed, default: 1.0, range: 0.0..4.0 }
fragment do |point, resolution, uniforms|
wave = point[0] / resolution[0] + uniforms.time * uniforms.speed
[wave % 1.0, 0.2, 0.4, 1.0]
end
end