00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017 #ifndef __TLLINE_H__
00018 #define __TLLINE_H__
00019
00020
00021 #include "tlVision.h"
00022
00023
00024
00025
00026 class tlLine
00027 {
00028 public:
00029 float theta, r;
00030 tlPoint *p1;
00031 tlPoint *p2;
00032
00033 public:
00034
00035 tlLine ();
00036 tlLine (tlLine *line);
00037 tlLine (float theta, float r);
00038 tlLine (int x1, int y1, int x2, int y2);
00039 tlLine (tlPoint *p1, tlPoint *p2);
00040 virtual ~tlLine ();
00041
00042
00043 int set (tlLine *line);
00044 int set (float theta, float r);
00045 int set (int x1, int y1, int x2, int y2);
00046 int set (tlPoint *p1, tlPoint *p2);
00047
00048
00049 int fit (tlChain *chain);
00050
00051
00052 int clip (tlRect *rect);
00053 int clip (int width, int height);
00054
00055
00056 int copy (tlLine *line);
00057 int copyTo (tlLine *line);
00058 };
00059
00060
00061
00062 #endif