Click and drag your mouse (or finger on touch device) to draw a line. A new path is created for each touch or click.
Paths are stored in a nested array; you can inspect the variable in console: session (assuming the example is in it's own window).
| #include "Touch.h" | |
| #if defined(_USING_HID) | |
| #define CONTACT_COUNT_MAXIMUM 10 | |
| #define REPORTID_TOUCH 0x04 | |
| #define LSB(v) ((v >> 8) & 0xff) | |
| #define MSB(v) (v & 0xff) | 
| > var linesRaw = fs.readFileSync('lines.json', 'utf8'); | |
| > lines = JSON.parse(linesRaw) | |
| [ [ { x: 122.01388549804688, y: 183.01388549804688 }, | |
| { x: 119.01388549804688, y: 195.01388549804688 }, | |
| { x: 115.01388549804688, y: 307.0138854980469 }, | |
| { x: 115.01388549804688, y: 354.0138854980469 }, | |
| { x: 117.01388549804688, y: 360.0138854980469 } ], | |
| [ { x: 206.01388549804688, y: 177.01388549804688 }, | |
| { x: 204.01388549804688, y: 194.01388549804688 }, | |
| { x: 202.01388549804688, y: 287.0138854980469 }, | 
| #!/usr/bin/ruby | |
| # Make sure you have these gems installed | |
| require 'rubygems' | |
| require 'thread' | |
| require 'csv' | |
| require 'twitter' | |
| require 'marky_markov' | |
| # Create a new Twitter account that you'd like to have your auto-tweets posted to | 
| // Each bitbeam is 5/16 inches wide. It's length is determined by the number of holes. | |
| // Each hole is 8mm apart from each other | |
| // The center of holes are 4mm way from each side of the beam | |
| // The holes are 4.8 mm in diameter. | |
| beam_width = 7.9375; // 5/16 inches | |
| module beam(number_of_holes) { | 
| <!DOCTYPE html> | |
| <html> | |
| <head> | |
| <script>//<!-- | |
| // WebGL texture example | |
| top.CanvasFloatArray = top.CanvasFloatArray || WebGLFloatArray; | |
| var gl; | |
| var program; | 
| #!/bin/sh | |
| # Jason Huggins (@hugs) | |
| # | |
| # Install: | |
| # * Download http://sourceforge.net/projects/sox/files/sox/14.3.2/ | |
| # * Unzip and the place "play" binary somewhere in your $PATH | |
| # Explanation of settings: | |
| # - Stereo (2 channels): -c 2 |