Скачиваний:
21
Добавлен:
01.05.2014
Размер:
1.72 Кб
Скачать
#if !defined(CH_H)
#define CH_H

#include "Point.h"
#include "Image.h"
#include "Q_T.H"
extern const gr_x,gr_y;
extern const double NaN,sc_x,sc_y;
extern const color;
extern const double eps;

extern FILE* fin;

typedef unsigned int uint;

typedef struct
{
	double x;
	double y;
} tpoint;

typedef struct
{
	tpoint p;
	tpoint q;
	double s;
} tpqs;

extern uint all_el;
extern uint fl_graph;

void PrErr(char *s,char *FName);
tpoint* ReadMas(TMyPointVector &p);
int VDraw_A(tpoint* Ar,uint end,TImage &Img,COLORREF Color, int PenStyle, int nWidth,int f=0);
int VDraw_P(const tpqs* P,uint end,TImage &Img,COLORREF Color, int PenStyle, int nWidth);
int VDraw_Q(QUEUE<tpqs> *Q,TImage &Img,COLORREF Color, int PenStyle, int nWidth);
int sort_points(const void *a,const void *b);
int sort_pairs(const void *a,const void *b);
int Search_Median(tpoint *Ar,uint beg,uint end,tpoint* M,uint *fl);
tpqs* Pairs(tpoint *Ar,uint beg,uint end,tpoint M,uint fl,
							double *s,uint *vf,uint *n);
int Opor_Line(tpoint* Ar,uint beg,uint end,tpoint M,uint fl,double s,
					 uint *num,int fl_up,TImage &Img);

tpoint* Update(tpoint* Ar,uint all,tpqs* R,double sl,uint vf,uint k,tpoint M,uint *fl,int side,
						tpoint* El,uint *n,int fl_up);
tpqs* Bridge(tpoint *Ar,uint beg,uint end,int fl_up,TImage &Img,BOOL hDraw,int f=0);
int UandD(tpoint* Ar,uint end,uint lb,uint le,tpoint** ArU,uint *U,tpoint** ArD,uint *D,int fl_up,TImage &Img,BOOL hDraw,tpqs &P);	
int CH(tpoint* Ar,uint u,QUEUE<tpqs> *Q,int fl_up,TImage &Img);
int Del_El_Q(QUEUE<tpqs> *Q);
tpqs* CH_all(tpoint* Ar,uint end,TImage &Img);
int Check(tpoint **Ar,uint *a);
MyUpdate(TMyPointVector &p, TImage &Img);
#endif
Соседние файлы в папке Source