#version unofficial megapov 1.21; camera{ location <0,1,-5> look_at <0,1,0> } global_settings{ ambient_light 0 montecarlo{ mc_rand_seed mc_max_diffuse_bounce 3 mc_pixel_refresh_ratio 0.3 } } light_source{<25,25,-25>,rgb 1} default{finish{montecarlo{mc_diffuse{ 1 1 1}}}} // Define a spline for the light to follow #declare lightspline = spline{ natural_spline #declare ht = 2.4; // bottom part -0.1, <0,0.5,-1> 0.0, <0,0,-1> 0.02, <0,0.25,-1> 0.05, vrotate(<0,0.7,-1>,y*5) // spiral up #declare n=30; #declare c=0; #while(c,y*5) 1.98, <0,0.25,1> 2.0, <0,0,1> 2.1, <0,0.5,1> } // Assemble a coordinate system by rotating incrementally. // Then the sweep will just transfer any cross section along // and produce a mesh #declare dt = 1.0e-4; #declare n = 400; #declare X = array[n]; #declare Y = array[n]; #declare Z = array[n]; #declare X[0] = x; #declare Y[0] = z; #declare Z[0] = y; #declare c=1; #while(c*0.2; #declare crosssecnorm[cc] = ; #declare cc=cc+1; #end // Transform and apply the cross section to the path #declare pts = array[n][nc]; #declare nrm = array[n][nc]; #declare c=0; #while(c; color_map{ [0 rgb 1*col] [0.5 rgb 0.05*col] } } finish{ ambient 10 diffuse 0 } } translate -y*0.3 scale <-1,1,1> } // Ground-plane with grid #declare plane_finish = finish{ ambient 0 diffuse 0.8 montecarlo{mc_diffuse{1 15 3}} } plane{y,0 texture{ pigment{ gradient z color_map{ [0 rgb 1] [0.95 rgb 1] [0.95001 rgb <0.5,0.5,0.8>] [1.0 rgb <0.5,0.5,0.8>] } } finish{plane_finish} } texture{ pigment{ gradient x color_map{ [0 rgbf 1] [0.95 rgbf 1] [0.95001 rgbf <0.5,0.5,0.8,0.0>] [1.0 rgbf <0.5,0.5,0.8,0.0>] } } finish{plane_finish} } } // Some random junk, just to make it interesting #declare s1 = seed(2152); #include "colors.inc" #declare c=0; #while(c<40) sphere{y*0.5,0.5 scale 0.15 translate *10 pigment{ rgb CHSV2RGB() } finish{ ambient 0 #declare interp = rand(s1); reflection 1.0-interp diffuse interp montecarlo{ mc_diffuse{ 1 15 3 } } } } #declare c=c+1; #end #declare c=0; #while(c<40) box{-0.5,0.5 rotate y*rand(s1)*360 translate y*0.5 scale 0.15 translate *10 pigment{ rgb CHSV2RGB() } finish{ ambient 0 #declare interp = rand(s1); reflection 1.0-interp diffuse interp montecarlo{ mc_diffuse{ 1 15 3 } } } } #declare c=c+1; #end