/* -*-ePiX-*- */
#include "epix.h"
using namespace ePiX;

int main(int argc, char* argv[])
{
  if (argc == 3)
    {
      char* arg;
      double temp1, temp2;
      temp1=strtod(argv[1], &arg);
      temp2=strtod(argv[2], &arg);

      tix()=temp1/temp2;
    }

  picture(P(-4,-4), P(4,4), "5 x 5in");

  begin();
  revolutions();

  grid(1,1);

  P ctr(3.25,-3.25); // "clock" center
  bold();
  ellipse(ctr, P(0.5,0.5)); // clock face

  line(ctr, ctr+polar(0.4,tix())); // hands
  label_angle(tix()-0.25);
  label(ctr+polar(0.6,tix()), "$\\theta$");

  // a cube :)
  domain R(P(-2,-2,-2), P(2,2,2), mesh(1,1,1));

  camera.at(sph(10,tix(),-0.05));
  plain(Cyan());
  plot(xyz, R); // draw cube; xyz = Cartesian pt constructor

  camera.at(sph(10,0.01 + tix(),-0.05)); // 3.6 degrees away
  red(1.4); // slightly lightened red
  plot(xyz, R);

  end();
}
