// Trabalho de laboratorio numero 6
// Povvy em Nova Embalagem
// MP004 -1s/2001
// Aluna: Simone da Silva Amorim


background{ color rgb < 0,0.95,0.7 > }

light_source {
  < 8.00, 2.00, 4.00 >
  color rgb < 1.00, 1.00, 1.00 >
}

light_source {
    < 100.0, -100.0, 100.0>
  color rgb 1.8* < 1, 1, 1 >
}

camera {
  location  <  8.00, 2.00, 2.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 cor_cristal = color rgb <0,0,0.9>;
#declare tx_cristal =
   texture{
      finish{
         ambient 0.1 diffuse 0.1
         reflection 0.25
         specular 1 roughness 0.001
         }
         pigment {color cor_cristal filter 1}
    }


#declare garrafa =
union{
  cylinder { <0,0,0>,<0,0,-1>, 0.35 pigment {color rgb <1,1,0>}}
  cone { <0, 0, 0>, 0.35
         <0,0,1>, 0.1
         pigment {color rgb <1,1,0>}
  }
  torus { 0.1, 0.06
       rotate -90*z
       rotate -90*y
       pigment { color rgb <1,0,0> }
       translate <0,0,1>
  }
}

#declare bola = difference{
     sphere { <0,0,0>, 1.5 pigment {color rgb <0,0,1> }
     }
     plane{<0,0,1>0}
     texture { tx_cristal}
     hollow interior{ior 1.5}
}

#declare texto =
union{
  text{ttf "cyrvetic.ttf", "POVVY", 0.1, 0
     rotate 90*x
     rotate 90*z
     pigment { color rgb <1,1,1>}
     translate <2,-1,0.5>
  }
  text{ttf "cyrvetic.ttf", "Super Vitaminado", 0.1, 0
     rotate 90*x
     rotate 90*z
     pigment { color rgb <1,1,1>}
     translate <2,-4,-0.5>
  }
}

#declare chao =
    plane { <0, 0, 1>, -4
    pigment { radial frequency 1.07 turbulence 50 scale 0.15
            color_map{[0.2 color rgb <0,0.1,0>][0.75 color rgb <0,0.9,0>]}}
    }


// Aqui está a cena, finalmente:
object { garrafa}
object { bola translate <0, 0, 2*clock>}
object { bola rotate 180*y translate <0, 0, -2*clock> }
object { texto rotate 720*clock*z }
object { chao}