Last active
April 28, 2020 01:48
-
-
Save davidvandenbor/31ea0b06ad81401fa371230b0dfbff3d to your computer and use it in GitHub Desktop.
Revisions
-
davidvandenbor revised this gist
Apr 28, 2020 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -1,4 +1,4 @@ ## Drawing tiny houses with P5.js and javascript nested loops Using P5.js in combination with nested javascript loops to draw a grid of tiny houses. **Preview:** [at bl.ocks.org](https://bl.ocks.org/David-van-den-Bor/31ea0b06ad81401fa371230b0dfbff3d) -
davidvandenbor revised this gist
Apr 28, 2020 . No changes.There are no files selected for viewing
-
davidvandenbor revised this gist
Apr 28, 2020 . 1 changed file with 2 additions and 2 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -2,11 +2,11 @@ <html lang="en"> <head> <meta name="description" content="Huisjes tekenen met P5.js"> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <meta http-equiv="X-UA-Compatible" content="ie=edge"> <title>Drawing houses with p5.js</title> <!-- Links to P5.js libraries --> <script src="https://cdnjs.cloudflare.com/ajax/libs/p5.js/0.9.0/p5.js" crossorigin=""></script> -
davidvandenbor revised this gist
Apr 28, 2020 . 1 changed file with 0 additions and 1 deletion.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -2,6 +2,5 @@ Using P5.js in combination with nested javascript loops to draw a grid of tiny houses. **Preview:** [at bl.ocks.org](https://bl.ocks.org/David-van-den-Bor/31ea0b06ad81401fa371230b0dfbff3d) Edit / Play around with it for yourself in **Plunker**! > See link below: https://plnkr.co/edit/gist:31ea0b06ad81401fa371230b0dfbff3d -
davidvandenbor revised this gist
Apr 28, 2020 . 1 changed file with 1 addition and 3 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -1,9 +1,7 @@ ## Drawing tiny houses with P5.js Using P5.js in combination with nested javascript loops to draw a grid of tiny houses. **Preview:** [at bl.ocks.org](https://bl.ocks.org/David-van-den-Bor/31ea0b06ad81401fa371230b0dfbff3d) Edit / Play around with it for yourself in **Plunker**! > See link below: https://plnkr.co/edit/gist:31ea0b06ad81401fa371230b0dfbff3d -
davidvandenbor revised this gist
Apr 28, 2020 . 1 changed file with 5 additions and 3 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -1,7 +1,9 @@ ## Drawing tiny houses with P5.js Using P5.js in combination with nested javascript loops to draw a grid of tiny houses. **Preview:** [at bl.ocks.org](https://bl.ocks.org/David-van-den-Bor/31ea0b06ad81401fa371230b0dfbff3d) ### Edit: Edit / Play around with it for yourself in **Plunker**! > See link below: https://plnkr.co/edit/gist:31ea0b06ad81401fa371230b0dfbff3d -
davidvandenbor revised this gist
Apr 28, 2020 . 1 changed file with 7 additions and 2 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -1,2 +1,7 @@ ## Drawing a grid with tiny houses with P5.js **Preview:** [at bl.ocks.org](https://bl.ocks.org/David-van-den-Bor/b98556c9eedd735e79a4af043835f909) ### Edit: Edit / Play around with it for yourself in **Plunker**! > See link below: https://plnkr.co/edit/gist:b98556c9eedd735e79a4af043835f909 -
davidvandenbor renamed this gist
Apr 28, 2020 . 1 changed file with 0 additions and 0 deletions.There are no files selected for viewing
File renamed without changes. -
davidvandenbor revised this gist
Apr 27, 2020 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -1,2 +1,2 @@ ## Huisjes tekenen met P5.js source bestanden op JSBin https://jsbin.com/dogiper/edit?html,js,output -
davidvandenbor revised this gist
Apr 27, 2020 . No changes.There are no files selected for viewing
-
davidvandenbor revised this gist
Apr 27, 2020 . 1 changed file with 2 additions and 0 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,2 @@ ## Huisjes tekenen met P5.js source https://jsbin.com/dogiper/edit?html,js,output -
davidvandenbor revised this gist
Apr 27, 2020 . No changes.There are no files selected for viewing
-
davidvandenbor revised this gist
Apr 27, 2020 . No changes.There are no files selected for viewing
-
davidvandenbor revised this gist
Apr 27, 2020 . 2 changed files with 2 additions and 51 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -14,56 +14,7 @@ </head> <body> <script src="index.js"></script> </body> </html> File renamed without changes. -
davidvandenbor created this gist
Apr 27, 2020 .There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,69 @@ <!DOCTYPE html> <html lang="en"> <head> <meta name="description" content="Huisjes tekenen met P5.js"> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <meta http-equiv="X-UA-Compatible" content="ie=edge"> <title>Huisjes maken met p5.js</title> <!-- Links to P5.js libraries --> <script src="https://cdnjs.cloudflare.com/ajax/libs/p5.js/0.9.0/p5.js" crossorigin=""></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/p5.js/0.9.0/addons/p5.dom.min.js" crossorigin=""></script> </head> <body> <script id="jsbin-javascript"> // The p5.js push() function allows you to create a new state and pop() function restores the state to the previous conditions. This allows you to have completely different settings applied to individual objects without worrying those settings to affect the shapes that come after as long as you do everything in between a push() and a pop() call. Here is how it works: function setup() { createCanvas(900, 900); } function draw() { background(240); for (var x = 5; x < 600; x = x + 50) { for (var y = 5; y < 600; y = y + 50) { push(); translate(x, y); drawHouse(); pop(); } } } function drawHouse() { triangle(15, 0, 0, 15, 30, 15); rect(0, 15, 30, 25); rect(12, 30, 10, 10); } </script> <script id="jsbin-source-javascript" type="text/javascript">// The p5.js push() function allows you to create a new state and pop() function restores the state to the previous conditions. This allows you to have completely different settings applied to individual objects without worrying those settings to affect the shapes that come after as long as you do everything in between a push() and a pop() call. Here is how it works: function setup() { createCanvas(900, 900); } function draw() { background(240); for (var x = 5; x < 600; x = x + 50) { for (var y = 5; y < 600; y = y + 50) { push(); translate(x, y); drawHouse(); pop(); } } } function drawHouse() { triangle(15, 0, 0, 15, 30, 15); rect(0, 15, 30, 25); rect(12, 30, 10, 10); }</script></body> </html> 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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,23 @@ // The p5.js push() function allows you to create a new state and pop() function restores the state to the previous conditions. This allows you to have completely different settings applied to individual objects without worrying those settings to affect the shapes that come after as long as you do everything in between a push() and a pop() call. Here is how it works: function setup() { createCanvas(900, 900); } function draw() { background(240); for (var x = 5; x < 600; x = x + 50) { for (var y = 5; y < 600; y = y + 50) { push(); translate(x, y); drawHouse(); pop(); } } } function drawHouse() { triangle(15, 0, 0, 15, 30, 15); rect(0, 15, 30, 25); rect(12, 30, 10, 10); }