Exemplo n.º 1
0
 def add_koche_tetra(self):
     color1 = Color.Random()
     color2 = Color.Random()
     shape = Tetrahedron(1, color1)
     for i in range(6):
         subdivide(shape, color=color1.tinted(color2, i/5))
         stellate(shape, self.faces_endswith(shape, 'subdivide-center'), 1)
     return self.add_shape(shape)
Exemplo n.º 2
0
 def add_koche_tetra(self):
     color1 = Color.Random()
     color2 = Color.Random()
     shape = Tetrahedron(1, color1)
     for i in range(6):
         faces = _get_selected_faces(shape, i + 1)
         subdivide(shape, color=color1.tinted(color2, i/5))
         stellate(shape, faces=faces, height=1.2)
     return self.add_shape(shape)