My Recent Pastes (71 and counting)
All Pasties (over 71 and counting)
Below are summaries of the 15 most recent pasties by Erik Kastner.
February 26, 2008
9:31AM EDT
by Erik Kastner
View more (79 lines)
1 2 3 4 5 |
/***************************************************************
* Erik Kastner - OpenGL Boxes going up up up in processing
***************************************************************/
import processing.opengl.*;
import javax.media.opengl.*;
|
February 26, 2008
9:30AM EDT
by Erik Kastner
View more (76 lines)
1 2 3 4 5 |
import processing.opengl.*; import javax.media.opengl.*; PGraphicsOpenGL pgl; GL gl; |
February 25, 2008
8:39AM EDT
by Erik Kastner
View more (39 lines)
1 2 3 4 5 |
/*************************************************************************************************** /* Erik Kastner - moving color field with perlin noise /* inspired by: http://www.flickr.com/photos/digitaltribes/2282828255/in/pool-564856@N20 /* (but totally different /***************************************************************************************************/ |
February 24, 2008
4:38AM EDT
by Erik Kastner
View more (85 lines)
1 2 3 4 5 |
/********************************************************/ /* Erik Kastner. http://metaatem.net /* Playing with processing - balls falling /********************************************************/ |
February 20, 2008
9:39PM EDT
by Erik Kastner
View more (11 lines)
1 2 3 4 5 |
class String def to_money self.split(//).inject(0) {|a, c| a += c.upcase[0] - 64} end |
February 17, 2008
3:01AM EDT
by Erik Kastner
View more (184 lines)
1 2 3 4 5 |
# Erik Kastner 2008-02-16 small blog engine with XMLRPC, hAtom and S3 upload (through xlmrpc) support require 'rubygems' require 'sinatra' require 'xmlrpc/marshal' require 'active_record' |
February 13, 2008
9:59AM EDT
by Erik Kastner
View more (49 lines)
1 2 3 4 5 |
# Erik Kastner 2008-02-13 iterative merge sort in ruby require 'rubygems' require 'activesupport' # iterative merge sort. given [10,9,8,7,6,5,4,3,2,1], first loop would do |
February 12, 2008
4:26PM EDT
by Erik Kastner
View more (55 lines)
1 2 3 4 5 |
# Erik Kastner 2008-02-12 Script to get our lost comments from google's cache require 'rubygems' require 'db' require 'open-uri' |
November 30, 2007
9:27PM EDT
by Erik Kastner
View more (19 lines)
1 2 3 4 5 |
require 'osx/cocoa' module OSXApps class Base def self.all |
November 30, 2007
10:03AM EDT
by Erik Kastner
View more (189 lines)
1 2 3 4 5 |
#!/usr/bin/env ruby # use it like so: Net::HTTP.multi_post_form(url, params) require 'net/http' class Net::HTTP |
November 29, 2007
2:29PM EDT
by Erik Kastner
View more (35 lines)
1 2 3 4 5 |
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-type" content="text/html; charset=utf-8"> |
November 28, 2007
2:24AM EDT
by Erik Kastner
View more (104 lines)
1 2 3 4 5 |
#!/usr/bin/env ruby class User require 'rubygems' require 'sqlite3' |
November 22, 2007
9:45AM EDT
by Erik Kastner
View more (30 lines)
1 2 3 4 5 |
# # MoveController.rb # movebutton # # Created by Erik Kastner on 11/22/07. |
November 22, 2007
9:43AM EDT
by Erik Kastner
View more (8 lines)
1 2 3 4 5 |
require 'osx/cocoa' class MoveController < OSX::NSObject ib_outlet :button, :image ib_action :move do |
November 15, 2007
12:06PM EDT
by Erik Kastner
View more (48 lines)
1 2 3 4 5 |
# use it like so: Net::HTTP.multi_post_form(url, params) class Net::HTTP def self.multi_post_form(url, params) req = Post.new(url.path) |
Pastie