// Exemplo de arquivo de descricao de cena para POV-ray // Last edited on 2003-09-04 15:25:26 by stolfi // ====================================================================== // CÂMERA camera { location < -2.00, 4.00, 2.00 > // Posição do observador. right -0.75*x // Largura RELATIVA da imagem. up 1.00*y // Altura RELATIVA da imagem. sky z // Qual direção é "para cima"? look_at < 0.00, 0.00, 0.00 > // Para onde a câmera está apontando. } // Nota: os parâmetros "right" e "up" devem ter a mesma proporção // que os parâmetros ${WIDTH} e ${HEIGHT} no Makefile. // ====================================================================== // FONTES DE LUZ light_source { 10 * < +50.0, +30.0, +50.0 > // Posição da lâmpada. color rgb 1.2 * < 1.00, 1.00, 1.00 > // Intensidade e corda luz. } light_source { 10 * < +50.0, -10.0, +10.0 > // Posição da lâmpada. color rgb 0.8 * < 1.00, 1.00, 1.00 > // Intensidade e corda luz. } // ====================================================================== // DESCRIÇÃO DA CENA background{ color rgb < 0.75, 0.80, 0.85 > } #declare raio = 2.000; #declare tinta_A = texture { pigment { color rgb < 0.10, 0.80, 1.00 > } finish { diffuse 0.5 specular 0.5 roughness 0.005 ambient 0.1 } } #declare tinta_B = texture { pigment { color rgb < 1.00, 0.80, 0.10 > } finish { diffuse 0.5 specular 0.5 roughness 0.005 ambient 0.1 } } #declare tinta_C = texture { pigment { color rgb < 0.40, 0.30, 0.80 > } finish { diffuse 0.5 specular 0.5 roughness 0.005 ambient 0.1 } } #declare tinta_D = texture { pigment { color rgb < 0.10, 0.10, 1.00 > } finish { diffuse 0.5 specular 0.5 roughness 0.005 ambient 0.1 } } #declare peao = cone{ <0.1, 0.1, 0.0 >,0.1 <0.1, 0.1, 1.0 >,0.0 texture {tinta_C} } #declare rei = union { cylinder{ <0.1, 0.1, 0.0>, <0.1, 0.1, 0.5>, 0.1 texture {tinta_C} } sphere{ <0.1, 0.1, 0.6>,0.1 texture {tinta_D} } } #declare torre = cylinder{ <0.1, 0.1, 0.0>, <0.1, 0.1, 1.0>, 0.1 texture {tinta_C} } #declare roleta = seed(12345); #declare j=0; #declare k=0; #while(j < 20) #declare i = 0; #while(i < 20) box{ <0.00+i, 0.00-j, 0.00> <0.20+i, 0.20-j, 0.20> #if(mod(k,2) = 0) texture {tinta_A} #else texture {tinta_B} #end } #declare var_rand = rand(roleta); #if(var_rand < 0.1) object{peao translate } #else #if(var_rand < 0.15) object{rei translate } #else #if(var_rand < 0.2) object{torre translate } #end #end #end #declare i = i+0.4; #end #declare i = 0; #while(i < 20) box{ <0.20+i, 0.00-j, 0.00> <0.40+i, 0.20-j, 0.20 > #if(mod(k,2) = 0) texture {tinta_B} #else texture {tinta_A} #end } #if(var_rand < 0.1) object{peao translate<0.20+i, 0.0-j, 0> } #else #if(var_rand < 0.2) object{rei translate<0.20+i, 0.0-j, 0> } #else #if(var_rand > 0.9) object{torre translate<0.20+i, 0.0-j, 0> } #end #end #end //object{peao // translate<0.20+i, 0.0-j, 0> //} #declare i = i+0.4; #end #declare k = k+1; #declare j = j+0.2; #end