This file contains 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
let canvas; | |
let img; | |
function preload(){ | |
img = loadImage("img.jpg"); | |
} | |
function setup() { | |
// shaders require WEBGL mode to work | |
canvas = createCanvas(windowWidth, windowHeight, WEBGL); |
This file contains 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
wget http://dlib.net/files/dlib-19.6.tar.bz2 | |
tar xvf dlib-19.6.tar.bz2 | |
cd dlib-19.6/ | |
mkdir build | |
cd build | |
cmake .. | |
cmake --build . --config Release | |
sudo make install | |
sudo ldconfig | |
cd .. |
This file contains 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
ofFbo fbo; | |
ofShader shader; | |
void setup(){ | |
fbo.allocate(w, h, GL_RGBA); | |
shader.load("shader"); | |
} | |
void update(){ | |
if (save ){ |
This file contains 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
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="UTF-8"> | |
<title>Your Title Here</title> | |
</head> | |
<body> | |
Your content here | |
</body> | |
</html> |
This file contains 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
rate = -1; | |
clockStart = 420; // num seconds | |
function padZero(n){ | |
if (n < 10) return "0" + n else return "" + n | |
} | |
clockTime = Math.max(clockStart + rate*(time - inPoint),0); | |
t = Math.floor(clockTime); |
This file contains 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
static float smooth_dist = 0.0; | |
vector<ofVec2f> DrawLook::smoothPoints(ofVec2f p, ofVec2f lp, ofVec2f llp, float size){ | |
vector<ofVec2f> points; | |
float step = MAX(size / 4, 1.0); | |
ofVec2f mp1 = lp; | |
mp1.middle(llp); | |
ofVec2f mp2 = p; |
This file contains 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
#just run from current directory | |
# will rename all files to 00001.jpg 00002.jpg etc. | |
ls | cat -n | while read n f; do mv "$f" `printf "%05d.jpg" $n`; done |
This file contains 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
vec3 gammaCorrect(vec3 color, float gamma){ | |
return pow(color, vec3(1.0/gamma)); | |
} | |
vec3 levelRange(vec3 color, float minInput, float maxInput){ | |
return min(max(color - vec3(minInput), vec3(0.0)) / (vec3(maxInput) - vec3(minInput)), vec3(1.0)); | |
} | |
vec3 finalLevels(vec3 color, float minInput, float gamma, float maxInput){ | |
return gammaCorrect(levelRange(color, minInput, maxInput), gamma); |
This file contains 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
<?php | |
// Get the url of to be proxied | |
// Is it a POST or a GET? | |
$url = ($_POST['url']) ? $_POST['url'] : $_GET['url']; | |
$headers = ($_POST['headers']) ? $_POST['headers'] : $_GET['headers']; | |
$mimeType =($_POST['mimeType']) ? $_POST['mimeType'] : $_GET['mimeType']; | |
//Start the Curl session | |
$session = curl_init($url); |
This file contains 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
ls -tr | xargs -I{} cat {} > ../allI.txt |