box()

box()
box() \ Language (API) \ Processing 2+

create box on center
box width is width
centerMode

size(100,100,P3D);
translate(50,50,0);
rotateY(0);
noFill();

box(40);
box(40,20,50);

fill(255,0,0);
ellipse(0,0,5,5); // red

fill(0,255,0);
ellipse(40,0,5,5); // green