Skip to content

Instantly share code, notes, and snippets.

@sleexyz
Created May 21, 2017 22:16
Show Gist options
  • Save sleexyz/f963e0f4b3b5451184e574a73f2ee5b4 to your computer and use it in GitHub Desktop.
Save sleexyz/f963e0f4b3b5451184e574a73f2ee5b4 to your computer and use it in GitHub Desktop.
{-# LANGUAGE GADTs #-}
module Jam_2017_05_21 where
import Util
output = toProgram $ bb
where
bb = bbF (texture2D backBuffer) uvN
bbF x = x
& lmap (norm id)
& lmap (*1.01)
& lmap (mirrorX)
& lmap (mirrorY)
& lmap (\v -> vec2 (x_ v, y_ v) - 0.01 * sin v)
& rmap (mix (y_ mouse) rgba)
& lmap (rot (x_ mouse))
rgba = vec4(v, v, v, 1)
where
v = len uvN - gate 0.01 ( x_ uvN)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment