Skip to content

Instantly share code, notes, and snippets.

View slambert's full-sized avatar

Steve Lambert slambert

View GitHub Profile
@slambert
slambert / modulo sound
Created April 14, 2020 21:46
Get your own fonts.
// Steve Lambert 2020-04-14
// Modulo sound
// v0.1
import processing.sound.*;
SinOsc sine;
int interval; // how often changes
int xPos; // circle location
@slambert
slambert / computersounds.pde
Created April 14, 2020 21:41
Computersounds
import processing.sound.*;
/*
The Computer Is Working Sounds
Now with cool black and white graphics
Steve Lambert December 1, 2015
*/
// initializing variables
int freq_ = 440; // sound frequency/pitch
int interval; // how often the sound changes
// Steve Lambert
// Synare simulator v0.2
// because I'm not gonna buy one on eBay.
// March 2018 and March 2020
import processing.sound.*;
SinOsc sine;
// sound variables
@slambert
slambert / time_passing_sketch_acupulco_edition.pde
Created March 17, 2020 20:36
Note: you'll have to add your own images! and size them
/* A sketch that has states
Steve Lambert March 17, 2020
Featuring Columbo!
v.01
*/
float elapsedTime;
float time;
PImage acapulco;
// Keypressed switch example
// Made by Steve Lambert February 25, 2020
color bgColor = color(255, 0, 0); // for bg color
boolean bgSwitch = false; // remembers the state of our switch
void setup() {
size(480, 480);
// done with setup
}
/*
/ Steve Lambert February 18, 2020
/ Student Demo of Loops
/
*/
// global variables
color blue = #1f5673;
color aqua = #90c3c8;
color skyblue = #90c3c8;
/*
Robot with Red Eyes using variables
Steve Lambert
Originally written sometime in 2012
*/
// robotWidth is the width of the robot body
int robotWidth = 200;
// xPos and yPos are the x and y coordinates of the center of the robot
int xPos = 300;
@slambert
slambert / not a bee anymore.pde
Last active February 18, 2020 02:51 — forked from MortytKane/not a bee anymore
can you guys help me?
// Where's your comments?
// Also add .pde to your filename to get the colors and hilighting to show up in your gist.
void setup() {
size(700, 700);
background(#D3FCFF);
noStroke();
println("setup done");
ellipseMode(CENTER);
}
//Moving Ball
//Steve Lambert February 11, 2020
//v0.1
//variables
color darkBlue = color(34,83,120);
color medBlue = color(22,149,163);
color lightBlue = color(172,240,242);
color offWhite = color(243,255,226);
color orange = color(235,127,0);
/*
Color Palette example sketch
includes examples of:
boolean variables
if/else
mousepressed
relational operators (> < == !=)
Steve Lambert February 11, 2020
*/