Skip to content

lczyk/pixel-goo

Repository files navigation

pixel-goo

version homebrew tap

Goo-like particle system simulation running on the GPU.

Something similar to Sebastian Lague's Ant and Slime Simulations - particles following one another's trails, but without looking at the code.

Runs as a window (goo) or as an animated desktop wallpaper: goo-macwp on macOS, goo-wlwp on wayland (layer-shell), goo-x11wp on X11. Still being tinkered with, so expect the tunables to move around.

Install

Via Homebrew (macOS and Linuxbrew):

brew install lczyk/pixel-goo/goo

This installs the goo binary (plus goo-macwp, the desktop-wallpaper variant, on macOS).

If Homebrew refuses to load the tap with a trust error, it's the third-party tap gate (HOMEBREW_REQUIRE_TAP_TRUST). Trust it once and retry:

brew trust --tap lczyk/pixel-goo

Build from source

./nob.c              # show usage (default target)
./nob.c build        # compile bin/goo
./nob.c run          # build and run
./nob.c clean        # remove bin/ and the generated headers

./nob.c build-macwp  # macos wallpaper   -> bin/goo-macwp
./nob.c build-wlwp   # wayland wallpaper -> bin/goo-wlwp
./nob.c build-x11wp  # x11 wallpaper     -> bin/goo-x11wp

Autoformat

./nob.c format   # clang-format the top-level *.c/*.h (skips lib/)

ToDo's

  • automagically include shader files at compile time
  • fullscreen mode is still a bit janky
  • no acceleration and velocity shaders
  • no velocity double buffer
  • fix segfault buggs
  • ? add frame rendering
  • trail buffer colormap sampling
  • screen rendering shader could blend between density and trail colormap
  • ? better lerp in screen rendering shader

About

Goo-like particle system simulation running on the GPU

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages