//Caixa de Surpresas // ====================================================================== // CORES E TEXTURAS background{ color rgb < 0.75, 0.80, 0.85 > } #declare tx_fosca = texture{ pigment{ color rgb < 1.00, 0.80, 0.10 > } finish{ diffuse 0.9 ambient 0.1 } } #declare tx_color = texture{ pigment{ color rgb < 2.00, 0.40, 0.20 > } finish{ diffuse 0.9 ambient 0.1 } } // ====================================================================== // DESCRICAO DA CENA #include "eixos.inc" #macro arm_M (varHand) union{ cylinder { < 0, 0, 0 >, < 0, 0, -1.8 >, 0.23 texture{ tx_fosca }} object { Foot () rotate z*varHand translate < 0, 0, -1.8 > } } #end #macro Hand () box{< 0, 0, 0 >, < 0.3, 0.3, 0.1 > texture{ tx_fosca }} #end #macro Leg_B (varlegMed, varlegFoot) union{ cylinder{ < 0, 0, 0 >, < 0, 0, -1.5 >, 0.31 texture{ tx_fosca }} object {Leg_M (varlegFoot) rotate x*varlegMed translate < 0, 0, -1.5 >} } #end #macro Leg_M (varlegFoot) union{ cylinder { < 0, 0, 0 >, < 0, 0, -1.1 >, 0.23 texture{ tx_fosca }} object { Foot () rotate z*varlegFoot translate < 0, 0, -1.1 > } } #end #macro Foot () box{< 0, 0, 0 >, < 0.3, 0.3, 0.1 > texture{ tx_fosca }} #end #macro Animal (/*arm_r, hand_r, arm_l, hand_l, legBig_r, legMed_r, legFoot_r, legBig_L, legMed_l, legFoot_l*/) union{ sphere{ < 0, 0, 0 >, 2 texture{ tx_fosca }} sphere{ < 1.4, 1.4, 0.9 >, .5 texture{ tx_fosca }} sphere{ < -1.4, 1.4, 0.9 >, .5 texture{ tx_fosca }} cone{< 0, 0, 0 >, .7, < 0, 0, 2 >, 0 translate< -0.5, .30, 1.5 > texture{ tx_fosca }} cone{< 0, 0, 0 >, .7, < 0, 0, 2 >, 0 translate< 0.5, .30, 1.5 > texture{ tx_fosca }} sphere{ < 0, 0, 0 >, 2.8 translate< 0, 0, -3.5 > texture{ tx_fosca }} } #end // object{Leg_B(varlegMed, varlegFoot), rotate z*varlegBig} object{Animal()} object {eixos(3.00)} // object {animal (0, 0, 0, 0, 0, 0, 0, 0, 0, 0)} #include "camlight.inc" #declare centro_cena = < 0.00, 0.00, 0.00 >; #declare raio_cena = 11.0; #declare dir_camera = < 10.00, 17.00, 10.00 >; #declare dist_camera = 11.0; #declare intens_luz = 1.00; camlight(centro_cena, raio_cena, dir_camera, dist_camera , z, intens_luz)