00001
00022 #ifndef INC_MI32_LINERAST_H
00023 #define INC_MI32_LINERAST_H
00024
00025 #ifndef INC_MI32_STDDEFNS_H
00026 #include <mi32/stddefns.h>
00027 #endif
00028
00029 class POLYLINE;
00030
00031 class LINERASTERIZER2D {
00032 public:
00033
00034 class SPAN {
00035 public:
00036
00037 void Process (const INT32 colmin, const INT32 colmax, const INT32 lin) {v_Process(colmin, colmax, lin);};
00038 void ProcessSpan (const double x1, const double y1, const double x2, const double y2) {v_ProcessSpan (x1, y1, x2, y2);};
00039
00040 private:
00041
00042 virtual void v_Process (const INT32 colmin, const INT32 colmax, const INT32 lin) = 0;
00043 virtual void v_ProcessSpan (const double x1, const double y1, const double x2, const double y2);
00044 };
00045
00046 static void MakeScans (
00047 const POLYLINE& polyline,
00048 SPAN& span
00049 );
00050
00051 private:
00052
00053 LINERASTERIZER2D();
00054 ~LINERASTERIZER2D();
00055 LINERASTERIZER2D(const LINERASTERIZER2D&);
00056
00057 };
00058
00059 class LINERASTERIZER3D {
00060 public:
00061
00062 class SPAN {
00063 public:
00064
00065 void ProcessCell (const double x1, const double y1, const double z1, const double x2, const double y2, const double z2) { v_ProcessCell(x1, y1, z1, x2, y2, z2); }
00066 void ProcessSpan (const double x1, const double y1, const double z1, const double x2, const double y2, const double z2) { v_ProcessSpan (x1, y1, z1, x2, y2, z2); }
00067
00068 private:
00069
00070 virtual void v_ProcessCell (const double x1, const double y1, const double z1, const double x2, const double y2, const double z2) = 0;
00071 virtual void v_ProcessSpan (const double x1, const double y1, const double z1, const double x2, const double y2, const double z2);
00072 };
00073
00074 static void MakeScans (
00075 const POLYLINE& polyline,
00076 SPAN& span
00077 );
00078
00079 private:
00080
00081 LINERASTERIZER3D();
00082 ~LINERASTERIZER3D();
00083 LINERASTERIZER3D(const LINERASTERIZER3D&);
00084
00085 };
00086
00087 #endif
00088