/*========================================================= Scala a chiocciola mobibile che si attorciglia in un verso e nell'altro Metodi e Modelli Matematici Gian Marco Todesco, ottobre 2007 http://archinet.uniroma3.it/mate/metodi/2007 =========================================================*/ #include "colors.inc" #include "textures.inc" camera { location 6*<0,3,-4> right x*image_width/image_height look_at 10*y angle 50 } light_source {<5,10,-2> color 1 } light_source {<-5,10,-2> color 1 } #declare Angolo = 20*sin(clock*pi*2); plane {y,-2 pigment {White}} union { #local H = 0.17; #local I = 0; #local N = 100; #while(I,<2,H,0.5> texture {Yellow_Pine} } cylinder { 0, <1.5,0.5*H,0>, 0.1 translate -0.1*y texture {Silver_Metal} } translate y*2*H*I rotate y*Angolo*I } #local I = I +1; #end cylinder { 0,2*N*H*y,0.5 texture {Silver_Metal} } pigment {Red} }