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 __Mancommd_h
00043 #define __Mancommd_h
00044
00045 #include <stdio.h>
00046
00047 #define BUFLENG 256
00048 typedef struct command COMTYPE;
00049 struct command
00050 {
00051 char *comname;
00052 void (*comfunc)(void);
00053 };
00054
00055
00056 void help(void);
00057 void helpman(COMTYPE *p);
00058
00059
00060 char optin(void);
00061 char lineins(char *s);
00062 void control(void);
00063
00064
00065 #if defined (_Windows)
00066 void msdinit(void);
00067
00068 #else
00069 int main(int argc, char **argv);
00070
00071 #endif
00072 void maninit(void);
00073 void MSD_readFileExecute(void);
00074 void MSD_executeFileCommand(char *name);
00075 void endfunc(void);
00076 void comerror(void);
00077
00078
00079 void strupper(unsigned char *s);
00080 void strlower(unsigned char *s);
00081 void skipsp(char **p);
00082 void skipnext(char **p);
00083
00084
00085 void MSD_execSetTrace(void);
00086 void MSD_execResetTrace(void);
00087
00088 #ifdef _DVS_
00089 FILE *instream;
00090 char linebuf[BUFLENG];
00091 char *restbuf;
00092
00093 COMTYPE comtable[] =
00094 {
00095 { "AFFINE", MSD_execNameAffine },
00096 { "AREA", MSD_execNameArea },
00097 { "ASHOW", MSD_execAnaliseShow },
00098 { "AXIS", MSD_execManipulateAxis },
00099 { "CAMERA", MSD_execCamera },
00100 { "CARENA", MSD_execNameCentroCarena },
00101 { "CGRAVIDADE", MSD_execNameCentroDeGravidade },
00102 { "CLEAR", MSD_execClear },
00103 { "COLOR", MSD_execColor },
00104 { "CONE", MSD_execNameMakeCone },
00105 { "COPY", MSD_execNameCopyElement },
00106 { "CUBE", MSD_execNameMakeCube },
00107 { "CYLINDER", MSD_execNameMakeCylinder },
00108 { "DELETE", MSD_execNameDeleteElement },
00109 { "DENSABS", MSD_execNameDensidadeAbsoluta },
00110 { "DENSFLUIDO", MSD_execDensidadeFluido },
00111 { "DENSREL", MSD_execNameDensidadeRelativa },
00112 #if !defined (__UNIX_) && !defined (_Windows)
00113 { "DIR", MSD_execDir },
00114 #endif
00115 { "DISPLAY", MSD_execDisplay },
00116 { "DISPCOOR", MSD_execDisplayCoordinates },
00117 { "DISPFILE", MSD_execDisplayFile },
00118 { "END", endfunc },
00119 { "FILE", MSD_readFileExecute },
00120 { "GROUP", MSD_execManipulateGroup },
00121 { "HELP", help },
00122 { "INERCIA", MSD_execNameMatrizInercia },
00123 { "INTERSECT", MSD_execNameIntersection },
00124 { "LIST", MSD_execListElement },
00125 { "LOAD", MSD_execNameLoadSolid },
00126 { "MASSA", MSD_execNameMassa },
00127 { "MINUS", MSD_execNameDifference },
00128 { "MONITOR", MSD_execMonitor },
00129 { "MOVE", MSD_execNameTranslateElement },
00130 { "NCOPY", MSD_execNameNCopySolid },
00131 { "NEW", maninit },
00132 { "PRINT", MSD_execPrint },
00133 { "PRISM", MSD_execNameMakePrism },
00134 { "PROJETADA", MSD_execNameAreaProjetada },
00135 { "PROJTOT", MSD_execProjetadaTotal },
00136 { "PROPRIEDADE", MSD_execManipulatePropriedade },
00137 { "PYRAMID", MSD_execNameMakePyramid },
00138 #ifdef __ROV__
00139 { "RCIRCULO", MSD_execNameMakeCirculo },
00140 { "RCUBO", MSD_execNameMakeCubo },
00141 { "RPERFILI", MSD_execNameMakePerfilI },
00142 { "RPERFILL", MSD_execNameMakePerfilL },
00143 { "RPERFILT", MSD_execNameMakePerfilT },
00144 { "RPIRAMIDE", MSD_execNameMakePiramide },
00145 { "RPLACA", MSD_execNameMakePlaca },
00146 { "RPRISMA", MSD_execNameMakePrisma },
00147 { "RESFERA", MSD_execNameMakeEsfera },
00148 { "RQUADRADO", MSD_execNameMakeQuadrado },
00149 { "RRETANGULO", MSD_execNameMakeRetangulo },
00150 { "RTRIANGULO", MSD_execNameMakeTriangulo },
00151 { "RDIM", MSD_execNameDimensaoPrincipal },
00152 { "RDESLOCA", MSD_execNameDesloca },
00153 { "RROTACIONA", MSD_execNameRotaciona },
00154 { "RORDENA", MSD_execOrdena },
00155 #endif
00156 { "RESETTRACE", MSD_execResetTrace },
00157 { "REVOLVE", MSD_execNameMakeRevolve },
00158 { "RENAME", MSD_execNameRenameElement },
00159 { "ROTATE", MSD_execNameRotateElement },
00160 #ifdef __curved_env__
00161 { "ROUND", MSD_execRound, },
00162 { "ROUNDALL", MSD_execRndAllEdges, },
00163 #endif
00164 { "SAVE", MSD_execNameSaveSolid },
00165 { "SCALE", MSD_execNameScale },
00166 { "SETTRACE", MSD_execSetTrace },
00167 { "SHOW", MSD_execShow },
00168 { "SPLIT", MSD_execNameSplit },
00169 { "SPHERE", MSD_execNameMakeSphere },
00170 { "SWEEP", MSD_execNameMakeSweep },
00171 { "TCGRAVIDADE", MSD_execCentroMassaTotal },
00172 { "TCARENA", MSD_execCentroCarenaTotal },
00173 { "TEMPUXO", MSD_execEmpuxoTotal },
00174 { "TIME", MSD_execTime },
00175 { "TINERCIA", MSD_execMatrizInerciaTotal },
00176 { "TMASSA", MSD_execMassaTotal },
00177 { "TORUS", MSD_execNameMakeTorus },
00178 { "TPESO", MSD_execPesoTotal },
00179 { "TVOLFLU", MSD_execVolumeFlutuabilidadeTotal },
00180 { "TVOLUME", MSD_execVolumeTotal },
00181 { "UNION", MSD_execNameUnion },
00182 { "VOLUME", MSD_execNameVolume },
00183 { "WAIT", MSD_execWait },
00184 { "WINDOW", MSD_execWindow },
00185 #ifdef __Extended_Version
00186 { "LLISTA", MSD_execListSolid },
00187 { "MVSF", MSD_execMVSF },
00188 { "MSFKR", MSD_execMSFKR2 },
00189 { "MSFKR2", MSD_execMSFKR2 },
00190 { "MFKRH", MSD_execMFKRH2 },
00191 { "MFKRH2", MSD_execMFKRH2 },
00192 { "MEV", MSD_execMEV },
00193 { "SEMV", MSD_execSEMV },
00194 { "SVME", MSD_execSVME3 },
00195 { "SVME2", MSD_execSVME2 },
00196 { "SVME3", MSD_execSVME3 },
00197 { "MEKR", MSD_execMEKR2 },
00198 { "MEKR2", MSD_execMEKR2 },
00199 { "MEF", MSD_execMEF2 },
00200 { "MEF2", MSD_execMEF2 },
00201 { "KVSF", MSD_execKVSF },
00202 { "KSFMR", MSD_execKSFMR },
00203 { "KFMRH", MSD_execKFMRH },
00204 { "KEV", MSD_execKEV2 },
00205 { "JVKE", MSD_execJVKE },
00206 { "JEKV", MSD_execJEKV },
00207 { "KEV2", MSD_execKEV2 },
00208 { "KEMR", MSD_execKEMR },
00209 { "KEF", MSD_execKEF2 },
00210 { "KEF2", MSD_execKEF2 },
00211 { "DETACH", MSD_execDetach },
00212 { "GLUE", MSD_execGlue },
00213 { "MERGE", MSD_execMerge },
00214 { "DOINV", MSD_execSetDoInverse },
00215 { "UNDO", MSD_execUndoOp },
00216 { "LOPS", MSD_highPrintAllOps },
00217 { "HARDREM", MSD_execHardRemove },
00218 { "NAME", MSD_execNome },
00219 { "REMSOFT", MSD_execNameSoftRemove },
00220 { "LIMPA", MSD_execCleanSolid },
00221 { "MODIFYNAMES", MSD_execModifyIds },
00222 { "NEWLOC", MSD_execNewVertexLocation },
00223 { "REVERT", MSD_execRevert },
00224 { "RMOVE", MSD_execRingMove },
00225 { "ALLRINGMOVE", MSD_execAllRingMove },
00226 { "TRANS", MSD_execTranslate },
00227 { "TRANSFORMA", MSD_execTransformation },
00228 { "IDROTATE", MSD_execRotate },
00229 { "LADJAFACE", MSD_execNameListFaceAdjacency },
00230 { "IDUNION", MSD_execUnion },
00231 { "IDMINUS", MSD_execDifference },
00232 { "IDINTERSECT", MSD_execIntersection },
00233 { "IDCUBE", MSD_execMakeCube },
00234 { "IDCYLINDER", MSD_execMakeCylinder },
00235
00236 #ifdef __curved_env__
00237 { "GETHE", hget_he },
00238 { "GETMATE", hget_mate },
00239 { "GETNEXT", hget_next },
00240 { "GETPREV", hget_prev },
00241 { "CNEWLOC", cnewloc },
00242 { "CMEV", hcmev },
00243 { "CMEF", hcmef },
00244 { "MEMO_SHOW", hshow_memo },
00245 { "PUTCTAG", MSD_execSetCurveAtributeToEdge },
00246 { "CPUTCTAG", cputctag },
00247 { "NEWPOLY", MSD_execNewCurvePolyline },
00248 { "ADDPOINT", MSD_execAddPointToCurve },
00249 { "EVALPOLYLINE", MSD_execEvaluateCurvePolyline },
00250 { "CEVALPOLYLINE",ceval_polyline },
00251 { "EVALEDGES", MSD_execEvalEdge },
00252 #endif
00253 #endif
00254 { "UNDO", MSD_execUndoOp },
00255 { "LOPS", MSD_highPrintAllOps },
00256 { "ROPS", MSD_highPrintAllRedoOps },
00257 { "TRACE", MSD_execTrace },
00258 #ifdef _Windows
00259 { "ANIME", animatio },
00260 { "CINEMA", cinema },
00261 #endif
00262 { "\0", comerror }
00263 };
00264
00265 #else
00266 extern COMTYPE comtable[];
00267 extern FILE *instream;
00268 extern char linebuf[BUFLENG];
00269 extern char *restbuf;
00270 #endif
00271
00272 #endif