// MC930 - Computação Gráfica - 2003-S2 - Jorge Stolfi // Trabalho de Laboratório 05 - Fórmula Um - Chegada // Marilda Pereira Yamashiro 981756 25/09/2003 // ====================================================================== // CÂMERA camera { location 35*< 8.0, -10.00, 4.00 > // Posição do observador. right -1.0*x // Largura RELATIVA da imagem. up 0.75*y // Altura RELATIVA da imagem. sky z // Qual direção é "para cima"? look_at < 0.00, -40.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, 80.0, +10.0 > // Posição da lâmpada. color rgb 0.8 * < 1.00, 1.00, 1.00 > // Intensidade e corda luz. } // ====================================================================== // DESCRIÇÃO DA CENA #include "colors.inc" background{ color rgb < 0.85, 0.9, 1.0 > } #declare cabeca = sphere { < 0.00, 0.00, 9.0 >, 2.00 pigment { Blue } } #declare braco = cylinder { < -0.25, 0.00, 6.50 >, < -0.25, -2.50, 4.50 >, 0.50 pigment { Yellow } } #declare perna = cylinder { < 0.5, -0.50, 0.25 >, < 0.5, -3.00, -4.50 >, 0.75 pigment { Yellow } } #declare tronco = cone { < 0.00, 0.00, 9.00 >,0.50 < 0.00, 0.00, 0.00 >,2.15 pigment { Yellow } } # declare carroceria = box { <-5, -70, -3>, <-35, -100, 5> pigment {Blue} } #declare roda1 = torus { 2.5, 1.5 rotate -90*z translate <-5, -95,-3> pigment { Red } } #declare motorista = sphere { < 0.00, -135.00, 0.0 >, 2.00 pigment { Yellow } } #declare carro = difference{ union{ object { roda1 } object { roda1 translate <1,15,1>} object { roda1 translate <-30,1,1>} object { roda1 translate <-30,15,1>} object { carroceria } }} #declare pessoa = union { object { cabeca } object { tronco } object { braco } object { braco scale <1,-1,1> } object { perna } object { perna scale <1,-1,1>} } #declare famintos = union { object { pessoa } object { pessoa translate <1,-10,1> } object { pessoa translate <1,+10,1> } object { pessoa translate <-15,1,1> } object { pessoa translate <-15,-10,1> } object { pessoa translate <-15,10,1> } object { pessoa translate <+15,-10,1> } object { pessoa translate <+15,1,1> } object { pessoa translate <+15,10,1> } } prism { conic_sweep cubic_spline 0, // sweep the following shape from here ... 2, // ... up through here // 12, // the number of points making up the shape ... // <-50,50>,<0,80>,<50,50>,<50,-25>,<45,-25>,<45,55>,<-45,-55>,<-45,-25>,<-50,-25>,<-50,50>,<0,80>,<50,50> 6, <50,0>,<0,50>,<-50,0>,<-50,-50>,<0,50>,<50,0> pigment { Blue } finish {diffuse 1 ambient 0} rotate 45*z translate <200,200,1> } //lathe { // linear_spline // 6, // <10,0>, <10,10>, <30,20>, <20,30>, <20,40>, <0,40> // pigment { Red } // finish { // ambient .3 // phong .75 // } // } object { famintos} union{ object { carro } translate <0,0,0> translate <0,60*clock, 0> }