// Exemplo de arquivo de descricao de cena para POV-ray // Last edited on 2010-03-04 15:44:01 by stolfi // ====================================================================== // CORES E TEXTURAS background{ color rgb < 1.0, 1.0, 1.0 > } #declare tx_plastico = texture{ pigment{ color rgb < 0.20, 0.70, 0.10 > } finish{ diffuse 0.8 ambient 0.1 specular 5.8 roughness 0.1 } } #declare tx_vidro = texture{ pigment{ color rgb < 0.1, 0.95, 0.20 > filter 0.85 } finish{ diffuse 0.03 reflection 0.25 ambient 0.02 specular 0.25 roughness 0.1 } } #declare tx_xadrez = texture{ pigment{ checker color rgb < 0.10, 0.42, 0.60 >, color rgb < 1.00, 0.97, 0.90 > } finish{ diffuse 0.9 ambient 0.1 } scale 1.0 } // ====================================================================== // DESCRIÇÃO DA CENA #declare fi = (sqrt(5)-1)/2; #macro face(p1, p2, p3) object { plane { , 1} } #end #declare dodecaedro = intersection { face(1, 0, fi) face(1, 0, -fi) face(-1, 0, fi) face(-1, 0, -fi) face(fi, 1, 0) face(fi, -1, 0) face(-fi, 1, 0) face(-fi, -1, 0) face(0, fi, 1) face(0, fi, -1) face(0, -fi, 1) face(0, -fi, -1) bounded_by{ sphere { <0, 0, 0>, 3 }} } #declare octaedro = intersection { face(1, 1, 1) face(1, 1, -1) face(1, -1, 1) face(1, -1, -1) face(-1, 1, 1) face(-1, 1, -1) face(-1, -1, 1) face(-1, -1, -1) bounded_by{ sphere { <0, 0, 0>, 3 }} } #declare cubo = intersection { face(1, 0, 0) face(0, 1, 0) face(0, 0, 1) face(-1, 0, 0) face(0, -1, 0) face(0, 0, -1) bounded_by{ sphere { <0, 0, 0>, 3 }} } #declare tetraedro = intersection { face(-1, -1, -1) face(1, 1, -1) face(-1, 1, 1) face(1, -1, 1) bounded_by{ sphere { <0, 0, 0>, 3 }} } #declare cub_oct = intersection { object{cubo scale 0.85} object{octaedro scale 1} } #declare icosaedro = intersection { object{dodecaedro scale 1.07 } object{octaedro scale 1 } } #declare chao = box{ <-20,-20,-1>, <+20,+20,0> } #include "eixos.inc" // Aqui está a cena, finalmente: union{ //object{ eixos(3.00) } object{ chao translate < 0,0,-4 > texture{ tx_xadrez } } object{cub_oct texture {tx_vidro} interior {ior 1.3} scale 1.5} object{icosaedro texture {tx_vidro} interior {ior 1.2} scale 1.2 translate<0, 4, 0>} //object{tetraedro texture {tx_plastico} interior {ior 1.4} translate <0, 2, 3> rotate <30, 40, 30>} //object{cubo texture {tx_vidro} interior {ior 1.3} translate <0, 3, 0>} //object{dodecaedro texture {tx_vidro} interior {ior 1.2}} //object{octaedro texture {tx_vidro} interior {ior 1.3} translate <0, -3, 0>} } #include "camlight.inc" #declare centro_cena = < 0.00, 1.60, 1.00 >; #declare raio_cena = 5.0; #declare dir_camera = < 1.00, 0.01, 8.00 >; #declare dist_camera = 13.0; #declare intens_luz = 1.00; camlight(centro_cena, raio_cena, dir_camera, dist_camera , z, intens_luz)