// Trem da alegria #include "colors.inc" // ====================================================================== // CÂMERA camera { location < 5,30 , 0.00 > // Posição do observador. //location < -5, 40 , 5.00 > right 1.00*x // Largura RELATIVA da imagem. up 0.5*y // Altura RELATIVA da imagem. sky z // Qual direção é "para cima"? look_at < 5.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, -20.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 tx_cristal_2 = texture{ pigment{ Gray } finish{ ambient 0.05 diffuse 0.25 reflection Gray specular 0.20 roughness 0.05 } } #declare tx_cristal_1 = texture{ pigment{ Gold } finish{ ambient 0.05 diffuse 0.3 reflection Gold specular 0.20 roughness 0.05 } } #declare tx_verdeb = texture{ pigment{ DarkGreen } finish{ ambient 0.05 diffuse 0.3 reflection DarkGreen specular 0.20 roughness 0.05 } } #declare tx_aco = texture{ finish{ ambient 0.1 diffuse 0.1 reflection 0.25 specular 1 roughness 0.001 } pigment {color Brown filter 1} } #declare tx_ouro = texture{ finish{ ambient 0.1 diffuse 0.1 reflection 0.25 specular 1 roughness 0.001 } pigment {color Blue filter 1} } #declare mao = union{ cone{ <0.5, 0,0>, 0.5, <1.5, 0, 0>, 0.8 texture {tx_cristal_1} } difference{ sphere{ <0.5, 0, 0>, 0.5 texture {tx_aco} } box{ <0.5, 0.7, 0.7>, <1.2, -0.7, -0.7> texture {tx_aco} } } cone{ <1.5, 0, 0.4>, 0.35, <2.3, 0, 0.4>, 0.1 texture{tx_aco} } cone{ <1.5, 0, -0.4>, 0.35, <2.3, 0, -0.4>, 0.1 texture{tx_ouro} } } declare antebracogenerico = union{ difference{ sphere{ <0.5, 0, 0>, 0.5 texture {tx_aco} } box{ <0.5, 0.7, 0.7>, <1.2, -0.7, -0.7> texture {tx_aco} } } cylinder{ <0.5, 0, 0>, <3.5, 0, 0>, 0.5 texture {tx_cristal_2} } difference{ sphere{ <3.5, 0, 0>, 0.5 texture {tx_aco} } box{ <3.5, 0.7, 0.7>, <2.8, -0.7, -0.7> texture {tx_aco} } } } declare antebraco1 = union{ object{antebracogenerico} object{mao rotate <50*clock, 0, 0> translate <4, 0, 0>} } declare antebraco2 = union{ object{antebracogenerico} object{antebraco1 rotate <0, 40-80*clock, 0> translate <4, 0, 0>} } declare antebraco3 = union{ object{antebracogenerico} object{antebraco2 rotate <0, -50+90*clock, 0> translate <4, 0, 0>} } declare antebraco4 = union{ object{antebracogenerico} object{antebraco3 rotate <0, -90+130*clock, 0> translate <4, 0, 0>} } declare braco = union{ difference{ sphere{ <1, 0, 0>, 1 texture {tx_aco} } box{ <1, 1.2, 1.2>, <2.1, -1.2, -1.2> texture {tx_aco} } } cone{ <1, 0, 0>, 1, <3.5, 0, 0>, 0.5 texture{tx_cristal_2} } cylinder{ <3.5, 0, 0>, <4.5, 0, 0>, 0.5 texture {tx_cristal_2} } difference{ sphere{ <4.5, 0, 0>, 0.5 texture {tx_aco} } box{ <4.5, 0.7, 0.7>, <3.8, -0.7, -0.7> texture {tx_aco} } } object{antebraco4 rotate <0, 90-50*clock, 0> translate <5, 0, 0>} } declare corpo= union{ cylinder{ <0, 0, 3>, <0, 0, -6>, 2 texture {tx_cristal_2} scale <2.2, 1, 1> translate <-5.4, 0, 0> } sphere{ <-1, 0, 0>, 1 texture {tx_aco} } object{braco rotate <-150+240*clock, 0, 0>} } union{ object {corpo} }