Somakube (4).
En af Piet Heins somakuber. Du kan dreje figuren ved at trække med musen. Hvis du holder musen nede, skifter markøren, og du kan trække figuren. Du kan zoome med musehjulet (eller ved at pinche).
Figure3D figure = Position [0,0] Size [x,y] Origin [x/2,y/2] Unit x/12 Angles [30,-30,0] Color "white" Dynamic;
Net kube =
Points
[-1,-1,-1], [1,-1,-1], [1,1,-1], [-1,1,-1],
[-1,-1,1], [1,-1,1], [1,1,1], [-1,1,1]
Lines
[0,1], [1,2], [2,3], [3,0], [4,5], [5,6], [6,7], [7,4],
[0,4], [1,5], [2,6], [3,7]
Faces
[0,1,2,3], [4,5,6,7], [0,1,5,4], [1,2,6,5], [2,3,7,6], [3,0,4,7]
Constant;
Net kube1 = Translate kube [0,-1,0] Constant;
Net kube2 = Translate kube [-2,-1,0] Constant;
Net kube3 = Translate kube [2,-1,0] Constant;
Net kube4 = Translate kube [0,1,0] Constant;
Net soma = Union kube1 kube2 kube3 kube4 Constant;
Scene scene = soma Color "black" "#c0c0c0";