This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{-# LANGUAGE GADTs #-} | |
module Jam_2016_10_29 where | |
import Util | |
output = toProgram $ vec4 (v, v, v, 1) | |
& (+(bbF (texture2D backBuffer) uvN * copy osc7)) | |
bbF x = x | |
& lmap (view norm) | |
& lmap (*0.99) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{-# LANGUAGE GADTs #-} | |
module Jam_2016_10_29 where | |
import Util | |
output = toProgram $ (bbF (texture2D channel2) uvN) | |
bbF x = x | |
& lmap (view norm) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{-# LANGUAGE GADTs #-} | |
module Jam_2016_10_29 where | |
import Util | |
output = toProgram $ vec4 (v, v, v, 1) | |
& over (webcamF (texture2D channel2) uvN) | |
& mix 0.1 (bbF (texture2D backBuffer) uvN) | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{-# LANGUAGE TypeFamilies #-} | |
{-# LANGUAGE RankNTypes #-} | |
{-# LANGUAGE GADTs #-} | |
module Jam_2016_10_10 where | |
import Util | |
output = toProgram (remix rgba uvN) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{-# LANGUAGE ExplicitForAll #-} | |
{-# LANGUAGE RankNTypes #-} | |
{-# LANGUAGE PatternSynonyms #-} | |
{-# LANGUAGE ViewPatterns #-} | |
module Jam_2016_10_05 where | |
-- tempo sync | |
import Hylogen.WithHylide |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{-# LANGUAGE ExplicitForAll #-} | |
{-# LANGUAGE RankNTypes #-} | |
{-# LANGUAGE PatternSynonyms #-} | |
{-# LANGUAGE ViewPatterns #-} | |
module Jam_2016_10_05 where | |
-- tempo sync | |
import Hylogen.WithHylide |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
with import <nixpkgs> {}: | |
let fhs = pkgs.buildFHSUserEnv { | |
name = "ngrok-env"; | |
targetPkgs = pkgs: with pkgs; | |
[ glibc | |
]; | |
}; | |
in pkgs.stdenv.mkDerivation { | |
name = "ngrok"; | |
buildInputs = [ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{-# LANGUAGE RecordWildCards #-} | |
data Foo = Bar { a :: Int, b :: Int, c :: Int, d :: Int } | |
| Baz { x :: Int, y :: Int, z :: Int, w :: Int } | |
deriving (Show) | |
bar = Bar {a=1, b=2, c=3, d=4} | |
baz = Baz {x=10, y=20, z=30, w=40} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Hylogen.Expr | |
import Hylogen.WithHylide | |
findWithDefault :: ToGLSLType a => | |
(Expr a -> Booly) -> Expr a -> [Expr a] -> Expr a | |
findWithDefault predicate = foldr (\x acc -> sel (predicate x) x acc) | |
findWithDefault' :: (ToGLSLType a, ToGLSLType b) => | |
(Expr a -> Booly) -> Expr b -> [(Expr a, Expr b)] -> Expr b |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
http://comonad.com/reader/2008/representing-adjunctions/ | |
Let Hask be Set? | |
SET: | |
Objects are sets | |
Morphisms are total functions between sets | |
(wait, Hom-Sets are exponentials?????) | |
HASK: |