fBumpShaderC.h 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100
  1. //---------------------------------------------------------------------------
  2. #ifndef fBumpShaderCH
  3. #define fBumpShaderCH
  4. //---------------------------------------------------------------------------
  5. #include <System.Classes.hpp>
  6. #include <Vcl.Controls.hpp>
  7. #include <Vcl.StdCtrls.hpp>
  8. #include <Vcl.Forms.hpp>
  9. #include <Vcl.ExtCtrls.hpp>
  10. #include <Vcl.Imaging.jpeg.hpp>
  11. #include "GLS.BaseClasses.hpp"
  12. #include "GLS.Cadencer.hpp"
  13. #include "GLS.Coordinates.hpp"
  14. #include "GLSL.CustomShader.hpp"
  15. #include "GLS.GeomObjects.hpp"
  16. #include "GLS.Graph.hpp"
  17. #include "GLS.Material.hpp"
  18. #include "GLS.Objects.hpp"
  19. #include "GLS.Scene.hpp"
  20. #include "GLS.VectorFileObjects.hpp"
  21. #include "GLS.SceneViewer.hpp"
  22. #include "GLS.FileTGA.hpp"
  23. #include "GLS.FileSMD.hpp"
  24. #include "GLS.FileMD2.hpp"
  25. #include "GLS.File3DS.hpp"
  26. #include "Formats.DDSImage.hpp"
  27. #include "GLS.FileMS3D.hpp"
  28. #include "GLS.Utils.hpp"
  29. #include "GLS.BaseClasses.hpp"
  30. #include "GLSL.Shader.hpp"
  31. #include "GLSL.BumpShaders.hpp"
  32. //---------------------------------------------------------------------------
  33. class TForm1 : public TForm
  34. {
  35. __published: // IDE-managed Components
  36. TGLSceneViewer *Viewer;
  37. TPanel *Panel1;
  38. TCheckBox *LightMovingCheckBox;
  39. TCheckBox *RollPitchTurnCheckBox;
  40. TCheckBox *ShaderEnabledCheckBox;
  41. TCheckBox *MultiLightShaderCheckBox;
  42. TCheckBox *UseSpecularTextureCheckBox;
  43. TCheckBox *UseNormalTextureCheckBox;
  44. TCheckBox *ShowNotGLSceneObjectsCheckBox;
  45. TGLScene *Scene;
  46. TGLDummyCube *GUICube;
  47. TGLArrowLine *GLArrowLine1;
  48. TGLXYZGrid *GLXYZGrid1;
  49. TGLDummyCube *LightCube;
  50. TGLLightSource *Light;
  51. TGLSphere *GLSphere1;
  52. TGLDummyCube *LightCube2;
  53. TGLLightSource *Light2;
  54. TGLSphere *GLSphere2;
  55. TGLDummyCube *WorldCube;
  56. TGLActor *Sphere_little;
  57. TGLActor *Sphere_big;
  58. TGLActor *Teapot;
  59. TGLActor *Fighter;
  60. TGLCube *GLCube;
  61. TGLDodecahedron *GLDodecahedron;
  62. TGLSphere *GLSphere;
  63. TGLCamera *Camera;
  64. TGLCadencer *Cadencer;
  65. TTimer *Timer1;
  66. TGLMaterialLibrary *MaterialLibrary;
  67. TGLSLBumpShader *MyBumpShader;
  68. TGLMaterialLibrary *TrinityMatlib;
  69. void __fastcall FormCreate(TObject *Sender);
  70. void __fastcall ShaderEnabledCheckBoxClick(TObject *Sender);
  71. void __fastcall ShowNotGLSceneObjectsCheckBoxClick(TObject *Sender);
  72. void __fastcall MultiLightShaderCheckBoxClick(TObject *Sender);
  73. void __fastcall UseSpecularTextureCheckBoxClick(TObject *Sender);
  74. void __fastcall UseNormalTextureCheckBoxClick(TObject *Sender);
  75. void __fastcall CadencerProgress(TObject *Sender, const double deltaTime, const double newTime);
  76. void __fastcall ViewerMouseDown(TObject *Sender, TMouseButton Button, TShiftState Shift,
  77. int X, int Y);
  78. void __fastcall ViewerMouseMove(TObject *Sender, TShiftState Shift, int X, int Y);
  79. void __fastcall Timer1Timer(TObject *Sender);
  80. void __fastcall FormMouseWheel(TObject *Sender, TShiftState Shift, int WheelDelta,
  81. TPoint &MousePos, bool &Handled);
  82. void __fastcall LightCubeProgress(TObject *Sender, const double deltaTime, const double newTime);
  83. void __fastcall FormClose(TObject *Sender, TCloseAction &Action);
  84. private: // User declarations
  85. int mx, my;
  86. TGLSLMLBumpShader *MultiLightShader;
  87. public: // User declarations
  88. __fastcall TForm1(TComponent* Owner);
  89. };
  90. //---------------------------------------------------------------------------
  91. extern PACKAGE TForm1 *Form1;
  92. //---------------------------------------------------------------------------
  93. #endif