// maze_cube.pov // Nov. Sam Benge stbenge@hotmail.com #version 3.5; global_settings{ /*radiosity{ error_bound .25 count 300 pretrace_start .08 pretrace_end .02 nearest_count 10 recursion_limit 1 normal on brightness 1 gray_threshold 0 always_sample on }*/ assumed_gamma 1 } #declare R=seed(3021); #include"functions.inc" #declare Sqr=function(n){n*n} #default{finish{ambient 0}} #declare ctrans=<-5,-10.3,-3.5>; camera{ fisheye right x*.5*1.33 up y*.5 location <0,50,-100> look_at 0 angle 40 } light_source{<2,1,-1>*100000,<1.6 1.6 .8> area_light x*10000,y*10000,4,4 adaptive 1 jitter circular} light_source{<0,1,-1>*100000,<.3 .4 .5> area_light x*90000,y*90000,4,4 adaptive 1 jitter circular} plane{y,-10 pigment{bumps scale 5 poly_wave .3}normal{granite -.3 scale 10 poly_wave .5 accuracy .001}} // density function #declare pigm=pigment{planar scale 20 translate y*-10 color_map{[0 rgb 0][1 rgb 1]}} union{ #local Z=-10; #while(Z<=10) #local Y=-10; #while(Y<=10) #local X=-10; #while(X<=10) #declare pv=eval_pigment( pigm, ); #local thk = .9-pv.x*.9; #if(rand(R)>.33) #if(rand(R)>.33) box{<-1,-1,-1>,<-thk,1,-thk> translate} #else box{<-1,-1,-1>,<1,-thk,-thk> translate} #end #else box{<-1,-1,-1>,<-thk,-thk,1> translate} #end #local X=X+2; #end #local Y=Y+2; #end #local Z=Z+2; #end rotate y*(35+180)+x*180 pigment{rgb 1} }