5 MandelWow is a generalized version of Mandelbrot & Julia in which both C and Z0 vary in a 4-dimensional space.
6 On each frame we render a 3D slice of the MandelWow, varying the remaining dimension through time.
8 I wrote this demo to learn Rust & basic GLSL. Mind the mess.
13 The native binary requires OpenGL 3.1. Should perform well on reasonably modern
16 * Linux with NVidia GTX 970 (Mesa 17.1 Nouveau driver)
17 * Linux with Intel HD Graphics 4000 (Ivy Bridge)
18 * Windows 10 with NVidia GTX 970
19 * The asmjs and WebAssembly build works on Chromium 57 and Firefox 53
21 ## Building from source
25 Install cargo (either your distro's packaged version or via rustup), then go to the source root and type:
36 Mandelwow depends on [libxm](https://github.com/nukep/libxm-rs) and [SDL2](https://github.com/AngryLawyer/rust-sdl2) for sound.
37 Both are tricky to build using Rust's MSVC toolchain because they assume GCC, so I recommend using the GNU toolchain instead.
38 I followed these steps to build a native Windows binary:
40 * Install Cargo via [rustup](https://www.rustup.rs).
41 * Install mingw-w64. The [MSYS2](http://www.msys2.org/) installer provides the basic shell environment and the package manager.
42 * From the MSYS2 console, install the W64 native toolchain and libSDL2:
45 pacman -S mingw-w64-x86_64-gcc mingw-w64-x86_64-SDL2
47 * While you're at it, you may also want to install the git package: `pacman -S git`
48 * I had to manually add the mingw-w64 toolchain to your path:
50 export PATH="/mingw64/bin:$PATH"
51 export LIBRARY_PATH=/mingw64/lib
53 * In case `cargo` and `rustup` aren't in the shell path, add `$USERPROFILE/.cargo/bin` too.
54 * Next, install the Rust toolchain targeting GCC:
56 rustup toolchain install stable-x86_64-pc-windows-gnu
57 rustup default stable-x86_64-pc-windows-gnu
59 * Now you can proceed to mandelwow's source tree and build a native Windows binary without further hassles:
64 ### WebAssembly / asm.js
70 curl -O https://s3.amazonaws.com/mozilla-games/emscripten/releases/emsdk-portable.tar.gz
71 tar xf emsdk-portable.tar.gz
72 source emsdk-portable/emsdk_env.sh
73 emsdk install emscripten-1.37.9 --build=MinSizeRel
74 emsdk activate emscripten-1.37.9 --build=MinSizeRel
81 curl https://sh.rustup.rs -sSf | sh
83 rustup toolchain install nightly
84 rustup default nightly
85 rustup target install asmjs-unknown-emscripten
86 rustup target install wasm32-unknown-emscripten
89 Build and run mandelwow:
96 Build the WebAssembly binary:
105 This project is GPL 3.0.
106 The support/ directory contains some code forked from Glium, which was originally Apache 2.0.