#ifndef __SYNCH_H__
#define __SYNCH_H__

#include "motionflow.h"
#include "synch_constants.h"
#include "mask.h"


typedef struct {
  float x;
  float y;
} vector_t;


// Global Vectors
void      getGlobalVector(int index, float* x, float* y);
vector_t* getGlobalVectorSequence(int max);

// Centroids
void      getCentroid(int index, float* x, float* y);
vector_t* getCentroidSequence(int max);

// Cardboard
model_t* getCardboardSequence(int max);
void printModels(int max, model_t* modelSeq);

// Trajectory
vector_t* getTrajectoryFromGlobalVectors(int max, vector_t* globalVectorSeq);
void      getTrajectoryParameters(int max, vector_t* traj,
				  float* a, float* b, float* c, float* d);

// Disparity
float getDisparity(float a, float b, float c, 
		   float d, float e, float f);


// Util
void printTrajectory(FILE*, int max, vector_t* traj);
void printCurve(FILE*, int m, vector_t* traj, float a, float b, float c, float d);

#endif
