Oh, that naughty sketch! Please let us know what the issue is below.
Apply Template
Applying this template will reset your sketch and remove all your changes. Are you sure you would like to continue?
Report Sketch
Report Comment
Please confirm that you would like to report the comment below.
We will review your submission and take any actions necessary per our Community Guidelines. In addition to reporting this comment, you can also block the user to prevent any future interactions.
Please report comments only when necessary. Unnecessary or abusive use of this tool may result in your own account being suspended.
Are you sure you want to delete your sketch?
Any files uploaded will be deleted as well.
Delete Comment?
This will also delete all the replies to this comment.
Delete this tab? Any code in it will be deleted as well.
Select a collection to submit your sketch
We Need Your Support
Since 2008, OpenProcessing has provided tools for creative coders to learn, create, and share over a million open source projects in a friendly environment.
Niche websites like ours need your continued support for future development and maintenance, while keeping it an ad-free platform that respects your data and privacy!
Please consider subscribing below to show your support with a "Plus" badge on your profile and get access to many other features!
A fork of Patternised Two by Craig Kirkwood
CC Attribution NonCommercial ShareAlike
Isometricism
Kirkwood
xxxxxxxxxx
function setup() {
createCanvas(windowWidth, windowHeight);
noLoop();
}
function draw() {
background('black');
noStroke();
blendMode(SCREEN);
textSize(16);
let allcolours = ['Gray', 'Tomato', 'Coral', 'OrangeRed', 'DarkOrange', 'Orange',
'Purple', 'Maroon', 'CadetBlue', 'PowderBlue', 'DeepSkyBlue',
'LightBlue', 'SkyBlue', 'LightSkyBlue', 'SteelBlue', 'DodgerBlue',
'LightSteelBlue', 'CornflowerBlue', 'RoyalBlue', 'Blue', 'DarkBlue', 'MediumBlue',
'MidnightBlue', 'NavyBlue', 'Brown', 'WebMaroon', 'RosyBrown',
'Sienna', 'Chocolate', 'SaddleBrown', 'SandyBrown', 'Peru', 'Bisque',
'Burlywood', 'Tan', 'BlanchedAlmond', 'NavajoWhite', 'Wheat', 'DarkGoldenrod',
'Goldenrod', 'Cornsilk', 'Olive', 'Aquamarine', 'Turquoise', 'MediumTurquoise', 'Aqua',
'Cyan', 'LightCyan', 'PaleTurquoise', 'DarkTurquoise', 'OliveDrab', 'YellowGreen',
'DarkOliveGreen', 'GreenYellow', 'Chartreuse', 'LawnGreen', 'DarkGreen', 'DarkSeaGreen',
'ForestGreen', 'Green', 'WebGreen', 'LightGreen', 'Lime', 'LimeGreen', 'PaleGreen',
'SeaGreen', 'MediumSeaGreen', 'SpringGreen', 'MediumSpringGreen', 'MediumAquamarine',
'LightSeaGreen', 'DarkCyan', 'Teal', 'Black', 'DarkGray', 'DimGray', 'Gainsboro',
'WebGray', 'LightGray', 'Silver', 'DarkSlateGray', 'LightSlateGray', 'SlateGray',
'DarkRed', 'Firebrick', 'IndianRed', 'LightCoral', 'Red', 'Salmon', 'DarkSalmon',
'LightSalmon', 'Crimson', 'MediumVioletRed', 'DeepPink', 'HotPink', 'PaleVioletRed',
'Pink', 'LightPink', 'Lavender', 'DarkSlateBlue', 'SlateBlue', 'MediumSlateBlue', 'MediumPurple',
'RebeccaPurple', 'BlueViolet', 'Indigo', 'DarkOrchid', 'DarkViolet', 'MediumOrchid',
'DarkMagenta', 'Fuchsia', 'Magenta', 'Plum', 'WebPurple', 'Thistle', 'Violet', 'Orchid',
'Snow', 'White', 'WhiteSmoke', 'MistyRose', 'Seashell', 'Linen', 'AntiqueWhite', 'OldLace',
'FloralWhite', 'Beige', 'Ivory', 'Honeydew', 'MintCream', 'Azure', 'AliceBlue', 'GhostWhite',
'LavenderBlush', 'PeachPuff', 'PapayaWhip', 'Moccasin', 'Gold', 'Khaki', 'LemonChiffon',
'PaleGoldenrod', 'DarkKhaki', 'LightGoldenrod', 'LightYellow', 'Yellow'];
let iso;
let v;
let vx; let vy;
let cubesize = 58;
let trax = 100; //horizontal spacing via translate
let tray = 100; //translate y value
let cols = 10; //number of cube columns
let lines = 8; //number of cube rows
let row = 100; //starting row
let rowoff= (2*cubesize); //row offset - vertical spacing
function cubemaker (csize) { // first function! csize is cube size
beginShape (); //left face
iso=210;
fill(random(allcolours));
vertex(0, 0);
for (let i = 0; i<3; i++) {
v = p5.Vector.fromAngle(radians(iso), csize);
vx = v.x; vy = v.y;
vertex(vx, vy);
iso=iso-60;
}
vertex(0, 0);
endShape ()
beginShape (); //right face
iso=90;
fill(random(allcolours));
vertex(0, 0);
for (let i = 0; i<3; i++) {
v = p5.Vector.fromAngle(radians(iso), csize);
vx = v.x; vy = v.y;
vertex(vx, vy);
iso=iso-60;
}
vertex(0, 0);
endShape ()
beginShape (); //top face
iso=210
fill(random(allcolours));
vertex(0, 0);
for (let i = 0; i<3; i++) {
v = p5.Vector.fromAngle(radians(iso), csize);
vx = v.x; vy = v.y; //point created from vector
vertex(vx, vy); //first vertex
iso=iso+60
}
vertex(0, 0);
endShape ();
} //defines the cubemaking function
for (let r = 0; r<lines; r++) {
push();
tray=row;
for (let i = 0; i<cols; i++) {
translate(trax, tray);
cubemaker (cubesize); //cube size
tray=0;
}
pop();
row=row+rowoff;
}
}
See More Shortcuts