00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042 #ifndef __Params_h
00043 #define __Params_h
00044
00045 #ifndef EXTERN
00046 #ifdef _DVS_
00047 #define EXTERN
00048 #else
00049 #define EXTERN extern
00050 #endif
00051 #endif
00052
00053
00054 #define MAXCTAG 50000
00055 #define MAXSTAG 50000
00056
00057
00058 #define NIL 0
00059 #ifdef _Windows
00060 #define ERROR 0
00061 #else
00062 #define ERROR -1
00063 #endif
00064 #define SUCCESS -2
00065 #define PI 3.141592653589793
00066 #define PIPER2 1.570796326494896
00067 #define RTOD 57.295779513082321
00068 #define DTOR 0.017453292519943
00069
00070
00071 #define CURVED 1
00072
00073
00074 #define SOLID 0
00075 #define SHELL 1
00076 #define FACE 2
00077 #define LOOP 3
00078 #define EDGE 4
00079 #define HALFEDGE 5
00080 #define VERTEX 6
00081 #define AXIS 7
00082 #define GROUP 8
00083
00084 #define TRUE 1
00085 #define FALSE 0
00086
00087 #define PLUS 0
00088 #define MINUS 1
00089
00090 #define _VISIBLE 2
00091 #define INVISIBLE 1
00092 #define DONTSHOW 0
00093
00094 #define AxisOfTranslation 0
00095 #define AxisOfRotation 1
00096 #define NONE 2
00097 #define AxisSolid 3
00098 #define AxisGroup 4
00099 #define AxisSG 5
00100 #define GroupGroup 6
00101 #define GroupSolid 7
00102
00103
00104 #define X 0
00105 #define Y 1
00106 #define Z 2
00107
00108 #define FaceEqNOK(f) (!(FacFBits((f)) & 1))
00109 #define SetFaceEqOK(f) (FacFBits((f)) |= 1)
00110 #define SetFaceEqNOK(f) (FacFBits((f)) &= ~1)
00111
00112 #define FaceBoxNOK(f) (!(FacFBits(f) & 2))
00113 #define SetFaceBoxOK(f) (FacFBits(f) |= 2)
00114 #define SetFaceBoxNOK(f) (FacFBIts(f) &= ~2)
00115
00116 #define FaceBitNOK1(f) (!((FacFBits(f)) & 4))
00117 #define SetFaceBitOK1(f) ((FacFBits(f)) = (FacFBits(f)) | 4)
00118 #define SetFaceBitNOK1(f) ((FacFBits(f)) = (FacFBits(f)) & ~4)
00119
00120 #define FaceBitNOK2(f) (!((FacFBits(f)) & 8))
00121 #define SetFaceBitOK2(f) ((FacFBits(f)) = (FacFBits(f)) | 8)
00122 #define SetFaceBitNOK2(f) ((FacFBits(f)) = (FacFBits(f)) & ~8)
00123
00124 #define ShellBoxNOK(d) (!(SheDBits(d) & 1))
00125 #define SetShellBoxOK(d) (SheDBits(d) |= 1)
00126 #define SetShellBoxNOK(d) (SheDBits(d) &= ~1)
00127
00128 #define SolidBoxNOK(s) (!(SolSBits(s) & 1))
00129 #define SetSolidBoxOK(s) (SolSBits(s) |= 1)
00130 #define SetSolidBoxNOK(s) (SolSBits(s) &= ~1)
00131
00132
00133 #define INF 1e20;
00134
00135 #define MSD_lowNaoUtilizado(x) if (x) x = x
00136
00137 #define assert(exp) \
00138 if (!((exp))) { \
00139 fprintf(stderr, "\"%s\":Assertion failed (file %s, line %d)\n", # exp, \
00140 __FILE__, __LINE__); fflush(stdout); return (ERROR); }
00141
00142 #define assert1(exp) \
00143 if (!((exp))) { \
00144 fprintf(stderr, "\"%s\":Assertion failed (file %s, line %d)\n", # exp, \
00145 __FILE__, __LINE__); fflush(stdout); exit(1); }
00146
00147 #define EPS 0.0001
00148 #define CONTBVEPS 0.001
00149
00150 #define SetError(a) fprintf(stderr, "ERRO!\n")
00151
00152 #endif