// Last edited on 2023-12-30 06:26:50 by stolfi #version 3.7; global_settings { assumed_gamma 2.2 } #include "textures.inc" #include "objs.inc" #declare tx_painel = texture { pigment { color rgb< 1, 0, 0 > } finish { ambient 1 diffuse 0 } } #declare chao = box{ <-50,-50,-1>, <+50,+50,0> } #macro lateral(wid, dep, hei) #local pad = 0.5; #local L1 = union { box { <0, 0, 0>, texture { tx_verde } rotate <45, 0, 0> translate < -(wid / 2), hei * 0.72, -dep > } box { <0, 0, 0>, texture { tx_painel } rotate <45, 0, 0> translate < -((wid - pad) / 2) , hei * 0.7, -0.5 > } } #local L2 = object{ L1 rotate < 0, 0, 90 > } #local L3 = object{ L1 rotate < 0, 0, 180 > } #local L4 = object{ L1 rotate < 0, 0, 270 > } difference { union { object { L1 } object { L2 } object { L3 } object { L4 } box { <0, 0, 0.69 * (hei-dep)>, translate < -(wid / 2), -(wid / 2), 0 > texture { tx_verde } } } box { <-hei, -hei, 0.69 * (hei-dep)>, texture { tx_verde } } } #end #macro templo() union { object { chao translate < 0,0,2 > texture{ tx_xadrez } } object { lateral(5, 2, 10) } object { lateral(5, 2, 10) scale <0.7, 0.7, 1> rotate < 0, 0, 45 > } } #end object{ templo() } #include "direcao_do_sol.inc" #include "parametros.inc" #local dir_norte = < 0.0, cos(radians(lat)), sin(radians(lat)) >; #local dir_sol = direcao_do_sol(lat, lon, mes, hora); #include "eixos.inc" #local cmp_eixos = 5.0; // object{ eixos(cmp_eixos) } #declare cmin = < -6.5, -6.5, +1.9 >; #declare cmax = < +6.5, +6.5, +5.9 >; #declare centro_cena = (cmin + cmax)/2; #include "gaiola.inc" // object{ gaiola(cmin,cmax) } // object{ gaichao(cmin,cmax) } #include "camsol.inc" #declare raio_cena = 0.65*vlength(cmax-cmin); #declare intens_luz = 1.20; // #declare vista = 3; camsol(centro_cena, raio_cena, vista, dir_norte, dir_sol, intens_luz)