// GATHER / Cross '03.08 // By Tsutomu HIGO URL: http://www.asahi-net.or.jp/~nj2t-hg/ #version 3.5; global_settings { assumed_gamma 2.2 max_trace_level 3 } light_source {<0, 5, 0> color <1, 1, 1>} camera { location <1, 10, -2> angle 15 look_at <0.3, -0.2, 0> } #declare R1 = seed(7); #declare StrengthVal = 0.3; #macro Meshsquare (Pmaxx, Pmaxy, Rrand, Rsize) //initialize the coordinates #declare Cp = array[Pmaxx][Pmaxy][3] #declare Xp = 0; #while (Xp < Pmaxx) #declare Yp = 0; #while (Yp < Pmaxy) #declare Cp[Xp][Yp][2] = 2*((Xp-Rrand/2+Rrand*rand(R1))/Pmaxx-0.5); #declare Cp[Xp][Yp][0] = 2*((Yp-Rrand/2+Rrand*rand(R1))/Pmaxx-0.5*Pmaxy/Pmaxx); #declare L = pow(Cp[Xp][Yp][0],2)+pow(Cp[Xp][Yp][2],2); #declare Cp[Xp][Yp][1] = -2*L; #declare Cp[Xp][Yp][2] = Cp[Xp][Yp][2]/Cp[Xp][Yp][1]; #declare Cp[Xp][Yp][0] = Cp[Xp][Yp][0]/Cp[Xp][Yp][1]; #declare Yp = Yp+1; #end #declare Xp = Xp+1; #end union { blob { threshold 0.3 #declare Xp = 0; #while (Xp < Pmaxx) #declare Yp = 0; #while (Yp < Pmaxy) sphere { Rsize/Pmaxx StrengthVal} #if (Yp > 0) cylinder { 0.5*Rsize/Pmaxx StrengthVal} #end #if (Xp > 0) cylinder { 0.5*Rsize/Pmaxx StrengthVal} #end #declare Yp = Yp+1; #end #declare Xp = Xp+1; #end pigment {color rgb <0.1, 0.3, 1>} finish { ambient 0.3 reflection 1 phong 2 brilliance 1 } no_shadow translate <0.5/Pmaxx, 0.5/Pmaxx, 0> } } #end Meshsquare (80, 80, 1, 4) sphere {<0, -3, 0> 0.3 pigment {color rgb <1, 0.8, 0.8>} finish { ambient 0.6 reflection 0.7 phong 2 diffuse 0.8 brilliance 1 } no_shadow }