// Last edited on 2003-12-14 19:51:56 by stolfi // Exemplo de arquivo de descricao de cena para POV-ray // ====================================================================== #declare zoom = 0.9; #declare ctr = < 0, 0, 0 >; #declare camDir = < 10,0,60 >*0.9; camera { location ctr + 1.00*camDir right 1.00*x up 1.00*z sky z look_at ctr } // ====================================================================== // FONTES DE LUZ light_source { 10 * < 50, -10.0, +10.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, 70.0 > // Posição da lâmpada. color rgb 0.8 * < 1.00, 1.00, 1.00 > // Intensidade e corda luz. } light_source { 10 * < 0.0, -10.0, 10.0 > // Posição da lâmpada. color rgb 0.9 * < 1.00, 1.00, 1.00 > // Intensidade e corda luz. } // ====================================================================== // DESCRIÇÃO DA CENA #declare C = 1/255; background{ color rgb < 0.95, 0.90, 0.68 > } #declare cor_cristal = <0.9,0.7,1>; #declare tx_cristal = texture { finish{ ambient 0.1 diffuse 0.1 reflection 0.15 specular 1 roughness 0.001 } pigment { color cor_cristal filter 1 } } #declare cor_espelho = <0.1,0.1,0.2>; #declare tx_espelho = texture { pigment { rgb cor_espelho } finish { ambient 0.05 diffuse 0.05 reflection 0.95 specular 0.20 roughness 0.05 } } #declare cor_metal = <0.4,0.4,0.4>; #declare tx_metalica = texture { pigment { rgb cor_metal } finish { ambient 0.1 diffuse 0.1 specular 1 roughness .001 reflection {0.75 metallic} } } #declare azul = texture { pigment { color rgb < 0.10, 0.80, 1.00 > } finish { diffuse 0.5 specular 0.5 roughness 0.005 ambient 0.1 } } #declare amarelo = texture { pigment { color rgb < 1.00, 0.80, 0.10 > } finish { diffuse 0.5 specular 0.5 roughness 0.005 ambient 0.1 } } #declare vermelho = texture { pigment { color rgb < 1.0, 0.0, 0.0 > } finish { diffuse 0.5 specular 0.5 roughness 0.005 ambient 0.1 } } #declare verde = texture { pigment { color rgb < 0.0, 1.0, 0.0 > } finish { diffuse 0.5 specular 0.5 roughness 0.005 ambient 0.1 } } #declare laranja = texture { pigment { color rgb < 252*C, 200*C, 81*C > } finish { diffuse 0.5 specular 0.5 roughness 0.005 ambient 0.1 } } #declare preto = texture { pigment { color rgb < 0*C, 0*C, 0*C > } finish { diffuse 0.5 specular 0.5 roughness 0.005 ambient 0.1 } } #declare xadrez = texture { pigment {checker color rgb <1,1,0.9> color rgb <0,0,0.9> } } // Objetos // Os eixos para auxilio #declare eixo_x = cylinder { < -50, 0, 0 >, < 50, 0, 0 >, 0.1 texture { vermelho } } #declare eixo_y = cylinder { < -50, 0, 0 >, < 50, 0, 0 >, 0.1 texture { verde } rotate <0,0,90> } #declare eixo_z = cylinder { < -50, 0, 0 >, < 50, 0, 0 >, 0.1 texture { azul } rotate <90,90,0> } #declare eixos = union{ object{eixo_x} object{eixo_y} object{eixo_z} } //O Chao #declare chao = box{ <-50,-50,0>, <50,50,-1> texture { xadrez } } //--------------------------------------------------------// // #declare corte = cylinder{ <0,0,-6>, <0,0,0>, 5 texture{tx_cristal} } #declare fact = 0.3; #declare placa = difference { object{ box{ <-10,-10,-1>, <10,10,-5> texture{tx_metalica} } } object{ corte scale<2,2,1> translate<10,10,0> } object{ corte scale<2,2,1> translate<10,-10,0> } object{ corte scale<2,2,1> translate<-10,-10,0> } object{ corte scale<2,2,1> translate<-10,10,0> } }//difference //Letra L #declare letra_L = difference{ object{ box{ <-6,-10,-6> <6,10,-1> texture{azul} } } object{ box{ <-1,-3,-7> <7,11,-0> texture{azul} } } }//difference //Letra I #declare letra_I = box{ <-5,-2,-6> <5,2,-1> texture{verde} } //Letra V #declare letra_V1 = union{ object{ box{ <-5,-2,-6> <10,2,-1> texture{vermelho} } rotate 30*z translate<0,-4,0> } object{ box{ <-5,-2,-6> <10,2,-1> texture{vermelho} } rotate -30*z translate<0,4,0> } }//union #declare letra_V = difference{ object{letra_V1} object{ box{ <-5,-3,-7> <5,3,-0> texture{vermelho} } rotate 90*z translate <9,0,0> } object{ box{ <-5,-3,-7> <5,3,-0> texture{vermelho} } translate <0,6.5,0> scale<6,0,0> rotate 90*z } } // Aqui está a cena, finalmente: sky_sphere { pigment { gradient z color_map { [(1-cos(radians( 30)))/2 color <247*C,230*C,255*C>] [(1-cos(radians(120)))/2 color <255*C,2*C,80*C>] } scale 10 translate -1 } } union{ //object{eixos} object{placa scale<1.5,3,3> translate<0,0,1>} object{letra_L rotate 90*z scale<0.3,0.3,0.6> translate<-2,-4.4,5>} object{letra_I scale<0.6,0.6,0.6> translate<-2.3,0,5>} object{letra_V scale<0.6,0.45,0.6> translate<-2.8,5.5,5>} }