00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022 #ifndef CMDDISPLAY_H
00023 #define CMDDISPLAY_H
00024
00025 #include "Command.h"
00026 #include "DisplayDevice.h"
00027 #include "utilities.h"
00028
00029 class VMDApp;
00030 class Axes;
00031
00032
00033
00034
00035
00036
00037
00038
00040 class CmdResetView : public Command {
00041 protected:
00042 virtual void create_text(void);
00043 public:
00044 CmdResetView();
00045 };
00046
00047
00049 class CmdDisplayStereo : public Command {
00050 private:
00051 char *mode;
00052 protected:
00053 virtual void create_text(void);
00054 public:
00055 CmdDisplayStereo(const char *newmode);
00056 ~CmdDisplayStereo();
00057 };
00058
00059
00061 class CmdDisplayStereoSwap : public Command {
00062 private:
00063 int onoff;
00064 protected:
00065 virtual void create_text(void);
00066 public:
00067 CmdDisplayStereoSwap(int turnon);
00068 };
00069
00070
00072 class CmdDisplayCacheMode : public Command {
00073 private:
00074 char *mode;
00075 protected:
00076 virtual void create_text(void);
00077 public:
00078 CmdDisplayCacheMode(const char *newmode);
00079 ~CmdDisplayCacheMode();
00080 };
00081
00082
00084 class CmdDisplayRenderMode : public Command {
00085 private:
00086 char *mode;
00087 protected:
00088 virtual void create_text(void);
00089 public:
00090 CmdDisplayRenderMode(const char *newmode);
00091 ~CmdDisplayRenderMode();
00092 };
00093
00094
00096 class CmdDisplayProj : public Command {
00097 public:
00098 CmdDisplayProj(const char *proj);
00099 ~CmdDisplayProj();
00100 private:
00101 char *projection;
00102 protected:
00103 virtual void create_text(void);
00104 };
00105
00106
00108 class CmdDisplayEyesep : public Command {
00109 private:
00110 float sep;
00111 protected:
00112 virtual void create_text(void);
00113 public:
00114 CmdDisplayEyesep(float newsep);
00115 };
00116
00117
00119 class CmdDisplayFocallen : public Command {
00120 private:
00121 float flen;
00122 protected:
00123 virtual void create_text(void);
00124 public:
00125 CmdDisplayFocallen(float newlen);
00126 };
00127
00128
00130 class CmdDisplayScreenHeight : public Command {
00131 private:
00132 float val;
00133 protected:
00134 virtual void create_text(void);
00135 public:
00136 CmdDisplayScreenHeight(float newval);
00137 };
00138
00139
00141 class CmdDisplayScreenDistance : public Command {
00142 private:
00143 float val;
00144 protected:
00145 virtual void create_text(void);
00146 public:
00147 CmdDisplayScreenDistance(float newval);
00148 };
00149
00150
00152 class CmdDisplayAAOn : public Command {
00153 private:
00154 int onoff;
00155 protected:
00156 virtual void create_text(void);
00157 public:
00158 CmdDisplayAAOn(int turnon);
00159 };
00160
00161
00163 class CmdDisplayDepthcueOn : public Command {
00164 private:
00165 int onoff;
00166 protected:
00167 virtual void create_text(void);
00168 public:
00169 CmdDisplayDepthcueOn(int turnon);
00170 };
00171
00172
00174 class CmdDisplayCullingOn : public Command {
00175 private:
00176 int onoff;
00177 protected:
00178 virtual void create_text(void);
00179 public:
00180 CmdDisplayCullingOn(int turnon);
00181 };
00182
00184 class CmdDisplayBackgroundGradientOn : public Command {
00185 private:
00186 int onoff;
00187 protected:
00188 virtual void create_text(void);
00189 public:
00190 CmdDisplayBackgroundGradientOn(int turnon);
00191 };
00192
00193
00194
00196 class CmdDisplayFPSOn : public Command {
00197 private:
00198 int onoff;
00199 protected:
00200 virtual void create_text(void);
00201 public:
00202 CmdDisplayFPSOn(int turnon);
00203 };
00204
00205
00211 class CmdDisplayClip : public Command {
00212 private:
00213 int changenear;
00214 int setval;
00215 float amount;
00216 protected:
00217 virtual void create_text(void);
00218 public:
00219 CmdDisplayClip(int ischangenear, int issetval, float newamt);
00220 };
00221
00222
00225 class CmdDisplayClipNear : public CmdDisplayClip {
00226 public:
00227 CmdDisplayClipNear(float nearval) :
00228 CmdDisplayClip(TRUE, TRUE, nearval) {
00229 }
00230 };
00231
00232
00234 class CmdDisplayClipNearRel : public CmdDisplayClip {
00235 public:
00236 CmdDisplayClipNearRel(float nearval) :
00237 CmdDisplayClip(TRUE, FALSE, nearval) {
00238 }
00239 };
00240
00241
00243 class CmdDisplayClipFar : public CmdDisplayClip {
00244 public:
00245 CmdDisplayClipFar(float farclip) :
00246 CmdDisplayClip(FALSE, TRUE, farclip) {
00247 }
00248 };
00249
00250
00252 class CmdDisplayClipFarRel : public CmdDisplayClip {
00253 public:
00254 CmdDisplayClipFarRel(float farclip) :
00255 CmdDisplayClip(FALSE, FALSE, farclip) {
00256 }
00257 };
00258
00259
00261 class CmdDisplayCueMode : public Command {
00262 private:
00263 char *mode;
00264 protected:
00265 void create_text();
00266 public:
00267 CmdDisplayCueMode(const char *newmode)
00268 : Command(DISP_CUEMODE) {
00269 mode = stringdup(newmode);
00270 }
00271 ~CmdDisplayCueMode() { delete [] mode; }
00272 };
00273
00274
00276 class CmdDisplayCueStart : public Command {
00277 private:
00278 float value;
00279 protected:
00280 void create_text();
00281 public:
00282 CmdDisplayCueStart(float newvalue)
00283 : Command(DISP_CUESTART), value(newvalue) {}
00284 };
00285
00286
00288 class CmdDisplayCueEnd : public Command {
00289 private:
00290 float value;
00291 protected:
00292 void create_text();
00293 public:
00294 CmdDisplayCueEnd(float newvalue)
00295 : Command(DISP_CUEEND), value(newvalue) {}
00296 };
00297
00298
00300 class CmdDisplayCueDensity : public Command {
00301 private:
00302 float value;
00303 protected:
00304 void create_text();
00305 public:
00306 CmdDisplayCueDensity(float newvalue)
00307 : Command(DISP_CUEDENSITY), value(newvalue) {}
00308 };
00309
00311 class CmdDisplayShadowOn : public Command {
00312 private:
00313 int onoff;
00314 protected:
00315 void create_text();
00316 public:
00317 CmdDisplayShadowOn(int turnon);
00318 };
00319
00321 class CmdDisplayAOOn : public Command {
00322 private:
00323 int onoff;
00324 protected:
00325 void create_text();
00326 public:
00327 CmdDisplayAOOn(int turnon);
00328 };
00329
00331 class CmdDisplayAOAmbient : public Command {
00332 private:
00333 float value;
00334 protected:
00335 void create_text();
00336 public:
00337 CmdDisplayAOAmbient(float newvalue)
00338 : Command(DISP_AO_AMBIENT), value(newvalue) {}
00339 };
00340
00342 class CmdDisplayAODirect : public Command {
00343 private:
00344 float value;
00345 protected:
00346 void create_text();
00347 public:
00348 CmdDisplayAODirect(float newvalue)
00349 : Command(DISP_AO_DIRECT), value(newvalue) {}
00350 };
00351
00352
00354 class CmdDisplayAxes : public Command {
00355 private:
00356 char *pos;
00357 protected:
00358 virtual void create_text();
00359 public:
00360 CmdDisplayAxes(const char *newpos)
00361 : Command(CMD_AXES) {
00362 pos = stringdup(newpos);
00363 }
00364 ~CmdDisplayAxes() { delete [] pos; }
00365 };
00366
00367
00369 class CmdDisplayStageLocation : public Command {
00370 public:
00371 CmdDisplayStageLocation(const char *newpos)
00372 : Command(CMD_STAGE) {
00373 pos = stringdup(newpos);
00374 }
00375 ~CmdDisplayStageLocation() { delete [] pos; }
00376 protected:
00377 void create_text();
00378 private:
00379 char *pos;
00380 };
00381
00382
00384 class CmdDisplayStagePanels : public Command {
00385 public:
00386 CmdDisplayStagePanels(int newnum)
00387 : Command(CMD_STAGE), num(newnum) {}
00388 protected:
00389 void create_text();
00390 private:
00391 int num;
00392 };
00393
00394
00396 class CmdDisplayStageSize : public Command {
00397 public:
00398 CmdDisplayStageSize(float newsz)
00399 : Command(CMD_STAGE), sz(newsz) {}
00400 protected:
00401 void create_text();
00402 private:
00403 float sz;
00404 };
00405
00406
00408 class CmdDisplayLightOn : public Command {
00409 private:
00410 int n, onoff;
00411 protected:
00412 void create_text();
00413 public:
00414 CmdDisplayLightOn(int ln, int turnon)
00415 : Command(DISP_LIGHT_ON), n(ln), onoff(turnon) {}
00416 };
00417
00418
00420 class CmdDisplayLightHL : public Command {
00421 private:
00422 int n, hl;
00423 protected:
00424 void create_text();
00425 public:
00426 CmdDisplayLightHL(int ln, int highlt)
00427 : Command(DISP_LIGHT_HL), n(ln), hl(highlt) {}
00428 };
00429
00430
00432 class CmdDisplayLightRot : public Command {
00433 private:
00434 float theta;
00435 char axis;
00436 int n;
00437 protected:
00438 void create_text();
00439 public:
00440 CmdDisplayLightRot(int ln, float th, char ax)
00441 : Command(DISP_LIGHT_ROT), theta(th), axis(ax), n(ln) {}
00442 };
00443
00444
00446 class CmdDisplayLightMove : public Command {
00447 private:
00448 float pos[3];
00449 int n;
00450 protected:
00451 void create_text();
00452 public:
00453 CmdDisplayLightMove(int ln, const float *newpos)
00454 : Command(DISP_LIGHT_MOVE), n(ln) {
00455 for (int i=0; i<3; i++) pos[i] = newpos[i];
00456 }
00457 };
00458
00459 #endif
00460