Skip to content

Instantly share code, notes, and snippets.

@realazthat
realazthat / index.js
Created September 19, 2016 21:10
requirebin sketch
let c = {b}; // press enter here at the end of the line
@realazthat
realazthat / index.js
Created September 19, 2016 21:10
requirebin sketch
function a(){
let c = {b}; // press enter here at the end of the line
}
@realazthat
realazthat / index.js
Last active September 19, 2016 21:07
requirebin sketch
function a(){
let c = {b}; // press enter at the end of this line here
}
@realazthat
realazthat / index.js
Created September 18, 2016 10:10
requirebin sketch
let regl = require('regl')();
let quad = require('glsl-quad');
let frag = `
precision highp float;
uniform float kernel[9];
@realazthat
realazthat / index.js
Last active September 14, 2016 18:47
demo for substack's implicit function rendering
let regl = require('regl')();
let mat4 = require('gl-mat4');
var build = require('implicit-mesh')
function f(x,y,z) {
return Math.sqrt(x*x + y*y + z*z);
}
@realazthat
realazthat / index.js
Last active September 9, 2016 01:37 — forked from mathisonian/index.js
requirebin sketch
document.body.style.margin = 0;
document.body.style.padding = 0;
const width = window.innerWidth;
const height = window.innerHeight;
const canvas = document.body.appendChild(document.createElement('canvas'))
const fit = require('canvas-fit');
const bezier = require('bezier');
@realazthat
realazthat / index.js
Last active September 9, 2016 00:48 — forked from mathisonian/index.js
requirebin sketch
document.body.style.margin = 0;
document.body.style.padding = 0;
const width = window.innerWidth;
const height = window.innerHeight;
const canvas = document.body.appendChild(document.createElement('canvas'))
const fit = require('canvas-fit');
const bezier = require('bezier');
@realazthat
realazthat / index.js
Created September 4, 2016 05:39
requirebin sketch
/*
<p>This example shows how you can use mipmaps in regl.</p>
*/
const regl = require('regl')({
extensions: ['EXT_texture_filter_anisotropic']
})
const drawCheckerboard = regl({
@realazthat
realazthat / index.js
Created September 4, 2016 05:35
requirebin sketch
/*
<p>This example shows how you can use mipmaps in regl.</p>
*/
const regl = require('regl')({
extensions: ['EXT_texture_filter_anisotropic']
})
const drawCheckerboard = regl({
@realazthat
realazthat / index.js
Created September 4, 2016 05:35
requirebin sketch
/*
<p>This example shows how you can use mipmaps in regl.</p>
*/
const regl = require('regl')({
extensions: ['EXT_texture_filter_anisotropic']
})
const drawCheckerboard = regl({