//------------------ ATENCAO ------------------------------// // Serao exibidas no maximo 10 barras verticais devido // // a limitacoes do proprio Prolog quando trata de leitura // // de arquivos. // //---------------------------------------------------------// #include "colors.inc" #include "metals.inc" #include "golds.inc" #include "stones1.inc" #include "textures.inc" background{ color rgb < 0.8,0.9,1.5 > } //background{ color rgbf < 0.9,0.9,0.8,1 > } //background{ color rgb < 1,1,1 > } //background {color MediumBlue } //definicao da camera camera { //location < 1, 1, 10 > location < 1, -3, 10 > //location < -10.0, 0.00, 1.00 > right < -0.60, 0.00, 0.00 > up < 0.00, 0.00, 0.80 > sky < 0.00, 1.00, 0.00 > look_at < 0.00, 1.00, 0.00 > } // ====================================================================== // FONTES DE LUZ //light_source { // 20*< 0.0, 10.0, 0.0 > // Posição da lâmpada. // color rgb 2.5 * < 1.00, 1.00, 1.00 > // Intensidade e corda luz. //} light_source { 20*< -10.0, 0.0, 0.0 > // Posição da lâmpada. color rgb 2.5 * < 1.00, 1.00, 1.00 > // Intensidade e corda luz. } light_source { 20*< 10.0, 0.0, 0.0 > // Posição da lâmpada. color rgb 2.5 * < 1.00, 1.00, 1.00 > // Intensidade e corda luz. } //light_source { // 20*< 0.0, 0.0, 10.0 > // Posição da lâmpada. // color rgb 2.5 * < 1.00, 1.00, 1.00 > // Intensidade e corda luz. //} // ====================================================================== // DESCRIÇÃO DA CENA #declare cor_cristal = < 0.8,0.9,1.5>; #declare cristal = texture { finish { ambient 0.1 diffuse 0.1 reflection 0.25 specular 1 roughness 0.001 } pigment { color cor_cristal filter 1} } #declare cor_cristal2 = < 1,1,0>; #declare cristal2 = texture { finish { ambient 0.1 diffuse 0.1 reflection 0.25 specular 1 roughness 0.001 } pigment { color cor_cristal2 filter 1} } #declare prata = material { texture { pigment { Silver } finish { ambient 0.05 diffuse 0.05 reflection Silver metallic specular 0.5 roughness 0.001 } } } #declare prata_escura = material { texture { pigment { rgb 0.1 } finish { ambient 0.05 diffuse 0.05 reflection rgb 0.1 metallic specular 0.5 roughness 0.001 } } } #declare ouro = material { texture { pigment { BrightGold } finish { ambient 0.05 diffuse 0.05 reflection BrightGold metallic specular 0.5 roughness 0.001 } } } #declare cristal_azul_luz = material { texture { pigment { rgbf <0.1, 0.1, 0.9, 1> } finish { ambient 4.8 diffuse 0.1 reflection 0.25 specular 1 roughness 0.001 } } interior {ior 1.1} } #declare cristal_azul = material { texture { pigment { rgbf <0.1, 0.1, 0.9, 1> } finish { ambient 0.1 diffuse 0.1 reflection 0.25 specular 1 roughness 0.001 } } interior {ior 1.1} } #declare cristal_amarelo = material { texture { pigment { rgbf <0.9, 0.9, 0.1, 1> } finish { ambient 0.1 diffuse 0.1 reflection rgbf <0.9, 0.9, 0.1, 1> specular 1 roughness 0.001 } } interior {ior 1.1} } #declare cristal_vermelho = material { texture { pigment { rgbf <0.65,0.1,0.1,1> } finish { ambient 0.1 diffuse 0.1 reflection 0.25 specular 1 roughness 0.001 } } interior {ior 1.1} } #declare cristal_verde = material { texture { pigment { rgbf <0.1, 1, 0.1, 1> } finish { ambient 0.1 diffuse 0.1 reflection 0.25 specular 1 roughness 0.001 } } interior {ior 1.1} } // OBJETOS /// #declare fundo = box{ <-2,0,0.8>, <2,2,1.5> //pigment {color Red} material {cristal_vermelho} texture { cristal} } #declare rolo_esq = cylinder { <-2.2, 0, 1.15>, <-2.2, 2, 1.15>, 0.3 material {prata} //pigment {color Green} } #declare rolo_dir = cylinder { <2.2, 0, 1.15>, <2.2, 2, 1.15>, 0.3 material {prata} //pigment {color Green} } #declare letraL_1 = lathe { linear_spline 7, <0, 1.5>, <0.2, 1.5-1/6>, <0, 1.5-2/6>, <0.2, 1.5-3/6>, <0,1.5-4/6>, <0.2,1.5-5/6>, <0,0.5> material {ouro} //pigment { Blue } finish { ambient .3 phong .75 } translate 1.55*z translate -1*x } #declare letraL_2 = lathe { linear_spline 5, <0, 1.5-2/6>, <0.2, 1.5-3/6>, <0,1.5-4/6>, <0.2,1.5-5/6>, <0,0.5> material {ouro} //pigment { Blue } finish { ambient .3 phong .75 } rotate -90*z translate 1.55*z translate 0.5*y translate -1.5*x } #declare letraI_1 = cone { <-0.1, 0.3, 1.55>, 0.15 <-0.1, 1.3, 1.55>, 0 material {prata} //pigment {color Blue} } #declare letraV = prism { linear_sweep cubic_spline 0, // sweep the following shape from here ... 1, // ... up through here 18, // the number of points making up the shape ... <3,-5>, <3,5>, <-5,0>, <3, -5>, <3,5>, <-5,0>, // sub-shape #1 <2,-4>, <2,4>, <-4,0>, <2,-4>, <2,4>, <-4,0>, // sub-shape #2 <1,-3>, <1,3>, <-3,0>, <1, -3>, <1,3>, <-3,0> // sub-shape #3 // pigment { Blue } material {ouro} rotate 90*x rotate 90*z scale <0.09,0.15,0.25> translate 0.5*x translate 0.9*y } #declare parte1 = torus { 0.2, 0.05 //pigment {Red} material {ouro} rotate 90*x } #declare corte1= box { <-1,-1,-1>, <1,0,1> material {ouro} //pigment {Red} } #declare corte2= box { <1,1,1>, <-1,0,-1> material {ouro} //pigment {Red} } #declare cima = difference { object {parte1 scale 1.7*x} object {corte1} } #declare baixo = difference { object {parte1 scale 1.7*x} object {corte2} } #declare olho = union{ object {cima} object {baixo} } // Aqui está a cena, finalmente: union { object {fundo} object {rolo_esq} object {rolo_dir} } union { object {letraL_1} object {letraL_2} } object {letraI_1} object {letraV translate 1.45*z translate 0.3*x} object {olho translate 1.5*z translate 1.6*y }//translate -0.3*x }