Skip to content

Instantly share code, notes, and snippets.

View bmoren's full-sized avatar

Ben Moren bmoren

View GitHub Profile
@bmoren
bmoren / folder-poetry-MCAD.md
Last active January 22, 2020 14:56
An adaptation of Melanie Hoff's Folder poetry workshop for a net-art assignment @ mcad

What if we could transform our online networks from something we passively receive to something we actively create? Folder Poetry is the practice of using the structure of computer folder organization as a new kind of poetic form like the haiku or iambic pentameter. By naming and nesting folders and files, we can create unfolding narratives, rhythmic prose, and choose-your-own-adventure poetry.

Terms

  • Folder Poetry is the practice of using the structure of computer folder organization as a new kind of poetic form like the haiku or iambic pentameter. By naming and nesting folders and files, we can create unfolding narratives, rhythmic prose, and choose-your-own-adventure poetry.
  • The Terminal is desktop application to control and make changes to your op
@bmoren
bmoren / indexhibit2flatfile.js
Created July 25, 2019 19:36
a nodejs script to convert indexhibit sites to a flat file markdown hierarchy
/*
use this to convert an indexhibit over and over site to a flatfile markdown structure.
change the input path for each indexhibit subsection folder, and run it for each section.
dont forget to copy each output after completion as this script will auto-delete the output folder upon completion for further runnings.
2019 – MIT
Ben Moren
http://benmoren.com
*/
@bmoren
bmoren / install.sh
Last active March 26, 2019 19:14
how to set up a standalone Raspberry pi with node for one off art projects
We couldn’t find that file to show.
@bmoren
bmoren / index.html
Created February 19, 2019 16:43
a 2D grid example for starting out a grid based project
<!-- !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
<!-- you dont really need this file, its just to show you how to use this grid system! -->
<!-- !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
<!DOCTYPE html>
<html lang="en" dir="ltr">
<head>
@bmoren
bmoren / index.html
Last active February 7, 2019 02:37
a simple 12 column grid to de-complexify css grid for students' first go.
<!DOCTYPE html>
<html lang="en" dir="ltr">
<head>
<meta charset="utf-8">
<title></title>
<link rel="stylesheet" href="simplegrid.css">
<link rel="stylesheet" href="testing.css">
</head>
<body>
@bmoren
bmoren / 10print.js
Last active February 3, 2018 21:50
10 print in p5js using nested loops
let gridSize = 15; //set the size of the grid
//we're doing everything inside of the setup so that we can clearly see the results, what happens in the draw loop?
function setup() {
createCanvas(windowWidth,windowHeight); // create a new canvas that fills the screen.
background(0,0,255)// set the background to blue
stroke(255) // set the stroke color to white
strokeWeight(4) //set the stroke to 4px weight
//nested for loop, remmeber, in this case it will move over one X column, then draw down all of the y's, move over one x col, draw all of the y's, etc.
@bmoren
bmoren / sketch.js
Created May 6, 2017 14:30
get a users ip using an api
var userIP
function setup() {
createCanvas(windowWidth,windowHeight)
//go to https://www.ipify.org/ for more information on the api in use here
loadJSON('https://api.ipify.org?format=json',function(returnedData){
userIP = returnedData.ip //put it in the global scope.
console.log(userIP);
})
@bmoren
bmoren / updateJSON.php
Created April 28, 2017 15:47
append a json object to an array
<?php
$elements = json_encode( $_POST['data'],JSON_NUMERIC_CHECK ) . ',';
openlog("myScriptLog", LOG_PID | LOG_PERROR, LOG_LOCAL0);
syslog(LOG_INFO, $elements);
// $test = "{
@bmoren
bmoren / sketch.js
Last active June 25, 2020 19:13
getting started with color tracking in tracking.js + p5.js
var colors;
var capture;
var trackingData;
function setup() {
createCanvas(windowWidth,windowHeight)
capture = createCapture(VIDEO); //capture the webcam
capture.position(0,0) //move the capture to the top left
capture.style('opacity',0.5)// use this to hide the capture later on (change to 0 to hide)...
@bmoren
bmoren / highlow.js
Created March 8, 2017 04:11
basic p5js high low with keys
var currentNumber = 0
var previousNumber = 0
var score = 0
function setup() {
createCanvas(windowWidth,windowHeight)
}