#include <GL/glut.h>
#include "types.h"

typedef struct {
  vector up;
  vector dir;
  vector eye;
  vector target;  

  coord rollAngle;
  coord fov;

  int height;
  int width;

  int transformation;
} camera;

#define PAN    1
#define DOLLY  2
#define ROLL   3 
#define PITCH  4
#define YAW    5
#define LOOK   6
#define AROUND 7
#define ZOOM   8
#define FOV    9

void init(void);
void display(void);
void reshape(int w, int h);
void keyboard(unsigned char key, int x, int y);
void mouse(int button, int state, int x, int y);
void motion(int x, int y);

void updateCamera(int w, int h);
void initCamera();
void setCamera(camera source, camera* dest);
void translateCamera(coord x, coord y, coord z);
void rollCamera(coord angle);
void yawCamera(coord angle);
void pitchCamera(coord angle);
void rotateAroundTarget(coord x, coord y);
void adjustCamUp();





