This file contains 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(){ | |
long code1 = 100100441; | |
long code2 = 100100444; | |
long x1l1 = code1/1000000; | |
long y1l1 = (code1 - (code1/1000000)*1000000 )/1000; | |
long x1l2 = (code1 - (code1/1000)*1000) /100; | |
long y1l2 = (code1 - (code1/100)*100) /10; | |
//The square is like this: | |
// _ _ |
This file contains 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
final int frames = 60; | |
void setup(){ | |
size(500,500,P3D); | |
background(0); | |
noFill(); | |
stroke(255); | |
strokeWeight(2); | |
} |
This file contains 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
final int frames = 30; | |
void setup(){ | |
size(500,500,P3D); | |
background(0); | |
} | |
void draw(){ | |
background(0); | |
final int fc = frameCount; |
This file contains 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
val file = scala.io.Source.fromFile("quijote.txt") | |
val txt = file.mkString | |
val splited = txt.replace("\n", " ").replace("[ *]", " ").split(" ") | |
val wgram = scala.collection.mutable.HashMap[String, List[String]]() | |
(0 until splited.size-1).foreach{ i => | |
val word = splited(i) | |
wgram(word) = splited(i + 1) :: wgram.getOrElse(word, Nil) | |
} |
This file contains 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
// The Object | |
// | |
// GenerateMe submission to MCCC Sep 2016 | |
// generateme.blog@gmail.com | |
// http://generateme.tumblr.com/ | |
// http://folds2d.tumblr.com/ | |
void setup() { | |
size(540, 540); |
This file contains 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
import peasy.*; | |
PeasyCam cam; | |
ArrayList<Float> arr = new ArrayList<Float>(20); | |
void setup(){ | |
size(600,600, P3D); | |
smooth(8); | |
This file contains 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
float seed = second(); | |
Integer figures = 60; | |
void setup(){ | |
size(1280,720, P3D); | |
stroke(255, 20); | |
blendMode(ADD); | |
noFill(); | |
smooth(4); | |
/*for(Integer r:rules){ |
This file contains 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
import main.lib._ | |
import main.recorder.{GifRecorder, RecorderConfig} | |
import scala.scalajs.js.annotation.JSExport | |
import scala.util.Try | |
@JSExport | |
class ThreeJSApp21 extends BasicCanvas with SimplexNoise with DrawingUtils with StatsDisplay with GifRecorder with CameraControls with AutoClear{ | |
Setup._2D.asScene |
This file contains 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
#!/bin/bash | |
BRNCH=$(git rev-parse --abbrev-ref HEAD) | |
MSG=$1 | |
RE='^[A-Z]+-[0-9]+$' | |
EXTRACT=$(echo $BRNCH | cut -d'-' -f 1-2 | awk '{print toupper($0)}') | |
if [[ $EXTRACT =~ $RE ]]; then | |
CMTMSG="$EXTRACT - $MSG" | |
echo "Commit message: $CMTMSG" | |
git commit -m "$CMTMSG" | |
else |
This file contains 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
package main | |
import processing.core._ | |
/** | |
* Created by fake.vyral on 13/06/2014. | |
*/ | |
class Sketch extends PApplet{ | |
val CANTSPHERES= 20 | |
val gridSize = 200 |
NewerOlder