This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// 1) DECLARE THE ARRAYS | |
float[] xpositions = new float[50]; | |
float[] ypositions = new float[50]; | |
void setup() { | |
size(800, 600); | |
// 2) INITIALIZE THE ARRAYS (FILL THEM WITH VALUES) | |
for(int i=0; i<xpositions.length; i++) { | |
xpositions[i] = random(width); | |
ypositions[i] = random(height); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Include library | |
#include <FastLED.h> | |
// How many leds are in the strip? | |
#define NUM_LEDS 33 | |
// Data pin that led data will be written out over | |
#define DATA_PIN 3 | |
// This is an array of leds. One item for each led in your strip. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Include library | |
#include <FastLED.h> | |
// How many leds are in the strip? | |
#define NUM_LEDS 33 | |
// Data pin that led data will be written out over | |
#define DATA_PIN 3 | |
// This is an array of leds. One item for each led in your strip. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* 3 DMX controlled LED Par Light example | |
* | |
* In this example we're using 3 par lights model Chauvet DJ Eve P-130 RGB | |
* Each light can have up to 9 DMX channels to control different | |
* functionality of the light. For an overview of the channels | |
* look at https://open-fixture-library.org/chauvet-dj/eve-p-130-rgb | |
* | |
* For this example the lights should be set to 9 channel DMX mode | |
* on the light itself. And, light1 should start at DMX channel 1, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<pre><code> | |
----------begin_max5_patcher---------- | |
2031.3oc4as0aaaCE94jeEBtu5ow6jZu0Ur0UfMrgc6gUTLPKyjnNYIMIY2z | |
Nr+6iWjc8EYE5HozU67fQrHkN5bNe7b4iz+y0WMYV98ppIAeUvqCt5p+45qt | |
xdIyEtp46WMYg793TYkcZSlUHqiuSUNYpaPYVVdsrNIOyN7ydVvKJUxZUfLX | |
9x57LUPxB4spfm8r02wJYYlbgxNcjYFadVEk4040uuPsY7hj6S2beIp2sJoJ | |
YVRZR86MCCaFI+lapT0Ns.DBlZ9H3MMCllG+Wp4yKk2VEWlmlZlFnYr3zj3+ | |
p9tx7k2d21WW+BLKUc2g2fafUGNvraWjOWs8K0r7x4ZUaq4jL2pS4yd6Wfwq | |
0prkKRxRU0VqazGuX9x50Wc8SzZ4Sxt8OKUwMZKBABoSC3.RHS+mfCfPNTv0 | |
WCgDFSADuswv8TMlX28OYxlg1XyW8gPiaoLT620hbhY3+85qMeLcv.IeqTab |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<pre><code> | |
----------begin_max5_patcher---------- | |
2059.3oc6b10aaaCEF95jeEBpWzaxbE+TT6tggNfNfc0.1EKMXfVhIVMxhdR | |
x4iVz+6ihTx0NgJgNR1QXQEnIvTT4HR9vy4kGRquc5I9yk2IJ889Yuy8N4ju | |
c5ImnKptfSZ97I9K42EmwK0Uye9JdU7BQg+YlKxyykU7pTYt9xu6cd+5Bd9U | |
BOt2MoIBYo27hzqVTkKJK+PrLupfWV8gRwJdg9t7d26Z+ScCuHmuTXLSQrrr | |
3bvEsWbUgrRVc+JwlprJ8trM2Zp31aRKSmmlkVce8kAMWQd4kkhJSKLXVvY0 | |
+v6hlKlIiuVjjTvupLtPlkUWsflqEmkFec0hB45qVrc4pGf4YhEO9FLW3lGe | |
g4WsTlH19gZtrHQ0EtUcjqqxDU0sOyipu+lGRcGdZ9U+SgHtogvPvYHDBR.Q | |
DD.RNyCDhY0EginAQnPUIv.VcyEf1tAmudYZtxP5wxv1Ba6Qu4qyL86yTC4J |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void setup() { | |
size(500, 500); | |
noStroke(); | |
} | |
void draw() { | |
background(0); | |
// check if the mouse is in the correct quadrant by | |
// using different combinations of conditional test between |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void setup() { | |
size(500, 500); | |
// using rectMode(CENTER) to make it easy | |
// to draw a rectangle in the center of the screen | |
rectMode(CENTER); | |
} | |
void draw() { | |
background(0); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// declare five color variables | |
color color1 = color(0, 255, 255); | |
color color2 = color(255, 0, 0); | |
color color3 = color(200, 0, 0); | |
color color4 = color(150, 0, 0); | |
color color5 = color(100, 0, 0); | |
// create a counter variable | |
int counter = 0; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// variables for the line x positions | |
int line1, line2, line3; | |
// color variables | |
color color1, color2, color3, color4; | |
void setup() { | |
// set up window size | |
size(800, 600); |
NewerOlder