// Exercicio 4 de laboratorio - 26/10/2000 // Marilia Goulart Honorio - 971259 #include "colors.inc" background{ color rgb < 1, 1, 1 > } light_source { < 20.00, 0.00, 8.00 > color rgb < 1.00, 1.00, 1.00 > } camera { location < 14.00, 0.00, 0.00 > right < -1.20, 0.00, 0.00 > up < 0.00, 0.00, 0.90 > sky < 0.00, 0.00, 1.00 > look_at < 0.00, 0.00, 0.00 > } //#declare raio = 2.000; //#declare tinta_A = // texture { // pigment { color rgb < 0.10, 0.80, 1.00 > } // finish { diffuse 0.5 specular 0.5 roughness 0.005 ambient 0.1 } // } //#declare tinta_B = // texture { // pigment { color rgb < 1.00, 0.80, 0.10 > } // finish { diffuse 0.5 specular 0.5 roughness 0.005 ambient 0.1 } // } //#declare bola = // sphere { // < 0.00, 0.00, 0.00 >, 2.00 // texture { tinta_A } // } //#declare furo1 = // cylinder { // < -2.00, -2.00, -2.00 >, // < +2.00, +2.00, +2.00 >, // 0.75 // texture { tinta_B } // } //#declare fruta = // blob { // threshold .65 // cylinder { <-.75,-.75,0>, <.75,.75,0>, .5, 1 } // pigment { Blue } //finish { phong 1 } // texture {tinta_A} // } //#declare fruta2 = // blob { // threshold .65 // sphere { <2.5,0,0>, 1.5, 1 pigment { Red } } // sphere { <0,0,0>,3.5, 1 pigment { Red } } // sphere { <-2.5,0,0>,1.5, 1 pigment { Red } } // finish { diffuse 0.5 specular 0.5 roughness 0.005 ambient 0.1 } // } //#declare fruta3 = // blob { // threshold .60 // sphere { <2.5,0,0>, 1.5, 1 pigment { White } } // sphere { <0,0,0>,3.5, 1 pigment { White } } // sphere { <-2.5,0,0>,1.5, 1 pigment { White } } // finish { diffuse 0.5 specular 0.5 roughness 0.005 ambient 0.1 } // } #declare sol = sphere { <-2,2,4>, 2 pigment { Yellow } } #declare caixaCortaSol = box { <0,0,0>, <-4,2,6> texture { pigment { Yellow } } } #declare caixaAzul = box { <0,-2,0>, <-2,0,6> //texture { pigment { color rgbt <1,1,1,1> } } texture { pigment { Blue } } } //#declare recheio1 = // blob{ // threshold .65 // sphere { <0,0,0>, 2.5, 1 // texture { // pigment { color Yellow } // normal { bumps 0.4 scale 0.2 } } // finish { phong 1} // } // } #declare meuNomeAcima = text { ttf "arial.ttf" "M H" 1.0, 0.0 pigment { BrightGold } finish { reflection .25 specular 1 } //translate -3*t } #declare meuNomeAbaixo = text { ttf "arial.ttf" " G " 1.0, 0.0 pigment { BrightGold } finish { reflection .25 specular 1 } //translate -3*t } //#declare recheio2 = // blob{ // threshold .65 // sphere { <2,0,0>, 1.5, 1 // texture { // pigment { color Green } } // //normal { bumps 0.4 scale 0.2 } } // finish { phong 1} // } // } //#declare recheio3 = // blob{ // threshold .65 // sphere { <-2,0,0>, 1.5, 1 // texture { // pigment { color Green } // normal { bumps 0.8 scale 0.2 } } // finish { phong 1} // } // } // Aqui está a cena, finalmente: object {caixaAzul //translate <0,-4,0> rotate <-90*clock,0,0> } object{ difference{ object {sol} object {caixaCortaSol} } rotate <90*clock,0,0> translate<0,7.5*clock,0> } object {meuNomeAcima rotate <0,0,90> rotate <0,90,0> //translate <1,-2,6> translate <1,1,2.5> translate <0,0,-2*clock> } object {meuNomeAbaixo rotate <0,0,90> rotate <0,90,0> //translate <1,-2,2> translate <1,1,-1.5> translate <0,0,2*clock> } //difference{ // difference{ // object { fruta2 } // object { recheio1 } // object { recheio2 } // object { recheio3 } // } // object { caixa } //}