fObjmoveC.h 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384
  1. //---------------------------------------------------------------------------
  2. #ifndef fObjmoveCH
  3. #define fObjmoveCH
  4. //---------------------------------------------------------------------------
  5. #include <vcl.h>
  6. #include <tchar.h>
  7. //---------------------------------------------------------------------------
  8. #include <System.Classes.hpp>
  9. #include <Vcl.Controls.hpp>
  10. #include <Vcl.StdCtrls.hpp>
  11. #include <Vcl.Forms.hpp>
  12. #include <Vcl.ExtCtrls.hpp>
  13. #include <GLS.Scene.hpp>
  14. #include "GLS.Objects.hpp"
  15. #include "GLS.Graph.hpp"
  16. #include "GLS.Collision.hpp"
  17. #include "GLS.Texture.hpp"
  18. #include "Stage.VectorGeometry.hpp"
  19. #include "GLS.VectorFileObjects.hpp"
  20. #include "GLS.SceneViewer.hpp"
  21. #include "GLS.SpaceText.hpp"
  22. #include "GLS.GeomObjects.hpp"
  23. #include "GLS.Color.hpp"
  24. #include "GLS.Coordinates.hpp"
  25. #include "GLS.BaseClasses.hpp"
  26. #include "GLS.BitmapFont.hpp"
  27. #include "GLS.WindowsFont.hpp"
  28. #include "GLS.HUDObjects.hpp"
  29. #include <Vcl.ComCtrls.hpp>
  30. //---------------------------------------------------------------------------
  31. class TFormObjmove : public TForm
  32. {
  33. __published: // IDE-managed Components
  34. TGLSceneViewer *Scene;
  35. TPanel *Panel1;
  36. TButton *Button1;
  37. TGroupBox *GroupBox1;
  38. TCheckBox *ShowAxes;
  39. TGLScene *GLScene1;
  40. TGLCube *Floor;
  41. TGLLightSource *TopLight1;
  42. TGLCube *Cube1;
  43. TGLCube *Cube2;
  44. TGLDummyCube *DummyCube1;
  45. TGLArrowLine *XArrow;
  46. TGLArrowLine *YArrow;
  47. TGLArrowLine *ZArrow;
  48. TGLSpaceText *TxtX;
  49. TGLSpaceText *TxtY;
  50. TGLSpaceText *TxtZ;
  51. TGLCamera *GLCamera1;
  52. TGLHUDText *HUDText;
  53. TGLHUDText *HUDTextObj;
  54. TGLWindowsBitmapFont *GLWindowsBitmapFont1;
  55. TStatusBar *StatusBar;
  56. void __fastcall FormCreate(TObject *Sender);
  57. void __fastcall SceneMouseDown(TObject *Sender, TMouseButton Button, TShiftState Shift,
  58. int X, int Y);
  59. void __fastcall SceneMouseMove(TObject *Sender, TShiftState Shift, int X, int Y);
  60. void __fastcall ShowAxesClick(TObject *Sender);
  61. void __fastcall FormMouseWheel(TObject *Sender, TShiftState Shift, int WheelDelta,
  62. TPoint &MousePos, bool &Handled);
  63. void __fastcall FormKeyPress(TObject *Sender, System::WideChar &Key);
  64. void __fastcall FormKeyUp(TObject *Sender, WORD &Key, TShiftState Shift);
  65. private: // User declarations
  66. TGLVector lastMouseWorldPos;
  67. bool movingOnZ;
  68. TGLCustomSceneObject *CurrentPick;
  69. int SceneMouseMoveCnt;
  70. TGLVector __fastcall MouseWorldPos(int X, int Y);
  71. void __fastcall UpdateHUDText();
  72. void __fastcall ProcessPick(TGLBaseSceneObject* pick);
  73. public: // User declarations
  74. __fastcall TFormObjmove(TComponent* Owner);
  75. };
  76. //---------------------------------------------------------------------------
  77. extern PACKAGE TFormObjmove *FormObjmove;
  78. //---------------------------------------------------------------------------
  79. #endif