// Exemplo de arquivo de descricao de cena para POV-ray
// Last edited on 2003-09-04 15:25:26 by stolfi

// ======================================================================
// CÂMERA 

camera {
  location  <  10.00, 0.00, 8.00 >  // Posição do observador.
  right     -0.8*x                // Largura RELATIVA da imagem.
  up        0.60*y                 // Altura RELATIVA da imagem.      
  sky       z                      // Qual direção é "para cima"?
  look_at   <  0.00, 0.00, 3.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 * < 5.0, +3.0, +5.0 >              // Posição da lâmpada.
  color rgb 1.2 * < 1.00, 1.00, 1.00 >   // Intensidade e corda luz.
} 

light_source {
  10 * < -5.0, -3.0, +5.0 >             // Posição da lâmpada.
  color rgb 0.8 * < 1.00, 1.00, 1.00 >   // Intensidade e corda luz.
} 

// ======================================================================
// DESCRIÇÃO DA CENA 

background{ color rgb < 0.75, 0.80, 0.85 > }

#declare raio = 2.000;

#declare Vermelho = 
  texture {
    pigment { color rgb < 1, 0, 0 > }
    finish { diffuse 0.5 specular 0.5 roughness 0.005 ambient 0.1 }
  }

#declare Verde = 
  texture {
    pigment { color rgbf < 0, 1, 0, 0> }
    finish { diffuse 0.5 specular 0.5 roughness 0.005 ambient 0.1 }
  }

#declare Azul = 
  texture {
    pigment { color rgb < 0, 0, 1 > }
    finish { diffuse 0.5 specular 0.5 roughness 0.005 ambient 0.1 }
  }

#declare Amarelo = 
  texture {
    pigment { color rgb < 1, 1, 0> }
    finish { diffuse 0.5 specular 0.5 roughness 0.005 ambient 0.1 }
  }

#declare Roxo = 
  texture {
    pigment { color rgb < 0.5, 0, 1> }
    finish { diffuse 0.5 specular 0.5 roughness 0.005 ambient 0.1 }
  }

#declare parede = 
box {
<-1.2, -0.5, 0>,
<-0.8, 0.5, 3.5>
texture {Amarelo}
}


#declare base =
cylinder {
<0, 0, 0>,
<0, 0, 0.5>,
1
texture {Vermelho}
}

#declare buraco_base = 
cylinder {
<0, 0, 0.3>,
<0, 0, 0.6>,
0.5
texture {Azul}
}
  
#declare topo =
cylinder {
<0, 0, 3>,
<0, 0, 3.5>,
1
texture {Azul}
}

#declare haste = 
cylinder {
<0, 0, 3>,
<0, 0, 1.5>,
0.1
texture {Roxo}
}

#declare mexedor =
sphere {
<0, 0, 1.2>, 0.3
texture {Verde}
 }

#declare lado1 =
box {
<0.3, -0.3, 0.9>,
<-0.3, -0.1, 1.5>
texture {Verde}
}

#declare lado2 =
box {
<0.3, 0.1, 0.9>,
<-0.3, 0.3, 1.5>
texture {Verde}
}

#declare furo = 
cylinder {
<0, -0.3, 1.2>,
<0, 0.3, 1.2>,
0.2
texture {Verde}
}

#declare xicara1 =
sphere {
<0, 2.5, 0.5>, 0.5
texture {Roxo}
}

#declare xicara2 = 
sphere {
<0, 2.5, 0.5>, 0.45
texture {Verde}
}

#declare corte = 
box {
<-0.5, 2, 0.6>,
<0.5, 3, 1.1>
texture {Verde}
}

#declare basex =
cylinder {
<0, 2.5, 0>,
<0, 2.5, 0.15>,
0.4
texture {Roxo}
}

#declare chao = 
box {
<-3, -3, -0.2>,
<3, 5, 0>
texture {Amarelo}
}


// Aqui está a cena, finalmente:
object {chao}
union {
difference {
object {base}
object {buraco_base}
}
object {parede}
object {topo}
}
object {haste}

difference {
object {mexedor}
object {lado1}
object {lado2}
object {furo}
}
union{
difference {
object {xicara1}
object {xicara2}
object {corte}
}
object {basex}
}