camera { location <0, 30, 100 > right -0.75*y // Largura RELATIVA da imagem. up 1.00*x // Altura RELATIVA da imagem. sky y // Qual direção é "para cima"? look_at < 13, 50, 3 > // Para onde a câmera está apontando. } light_source { <100, 180, 100> color rgb 5 * < 1.00, 1.00, 1.00 > // Intensidade e corda luz. } background{ color rgb <0.75,0.8,0.85> } #declare azul = <0.1,0.2,0.9>; #declare branco = <1,1,1>; #macro arvore(n,xis_ant,ze_ant) #local xis1 = 50*rand(s); #local xis2 = -20*rand(s); #local ze1 = 5*rand(s); #local ze2 = -6*rand(s); #if (n=1) sphere {,2 pigment {color branco}} #else union { #if (n=5) box {<3,k*n+3,3>,<-3,(k*n)-3,-3> pigment {color branco}} #else sphere {,2 pigment {color branco}} #end cylinder{,,0.5 pigment {color azul}} arvore(n-1,xis1,ze1) cylinder{,,0.5 pigment {color azul}} arvore(n-1,xis2,ze2) } #end #end #declare n=5; #declare k=20 ; #declare s=seed(12345); object {arvore(n,0,0)}