Skip to content
forked from sandydoo/flux

An ode to the macOS Drift screensaver that runs in the browser

License

Notifications You must be signed in to change notification settings

reallyconnected/flux

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

209 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Flux

An ode to the macOS Drift screensaver that runs in the browser.

See it live in your browser →


Backstory

I’ve been enamoured of the Drift screensaver ever since it came out with macOS Catalina. It’s mesmerizing. I feel like it’s become an instant classic, and, dare I say, it might stand to dethrone the venerable Flurry screensaver. Hats off to the folk at Apple responsible for this gem 🙌.

This is an attempt at capturing that magic and bottling it up in a more portable vessel. This isn’t a port though. The source code for the original is locked up in a spaceship somewhere in Cupertino. Instead, consider this a delicate blend of detective work and artistic liberty. It’s WebGL2 for now, but WebGPU is shaping up nicely, so native ports aren’t off the books.

Build

Using Nix

Build a new release in the result folder:

nix build

Or open a development shell with all the neccessary tools:

nix develop

cd web
yarn serve

Manual build

There’s a few things you’re going to have to install.

  • rustc with wasm32-unknown-unknown as a target
  • cargo
  • wasm-pack
  • node
  • pnpm or yarn
  • elm

How you get these dependencies depends on the operating system you’re running. Here’s an example for macOS and Linux using rustup:

rustup toolchain install stable
rustup target wasm32-unknown-unknown

cd web
pnpm install

Run a development server from the web folder:

pnpm serve

Build a release:

pnpm build

License

MIT © Sander Melnikov.

About

An ode to the macOS Drift screensaver that runs in the browser

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Rust 60.2%
  • Elm 20.3%
  • GLSL 10.4%
  • HTML 4.8%
  • Nix 3.1%
  • JavaScript 1.2%