fCudaD.pas 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121
  1. unit fCudaD;
  2. interface
  3. uses
  4. Winapi.Windows,
  5. Winapi.Messages,
  6. System.SysUtils,
  7. System.Variants,
  8. System.Classes,
  9. Vcl.Graphics,
  10. Vcl.Controls,
  11. Vcl.Forms,
  12. Vcl.Dialogs,
  13. Vcl.ExtCtrls,
  14. Vcl.Menus,
  15. Vcl.ComCtrls,
  16. fFastFourierD,
  17. fPostProcessingD,
  18. fScalarProductD,
  19. fSimpleTexD,
  20. fFluidsD,
  21. fVertexGenD;
  22. type
  23. TFormCudaD = class(TForm)
  24. PanelLeft: TPanel;
  25. tvCuda: TTreeView;
  26. MainMenu: TMainMenu;
  27. PageControl: TPageControl;
  28. tsFastFourierTrans: TTabSheet;
  29. tsPostProcessing: TTabSheet;
  30. tsScalarProduct: TTabSheet;
  31. tsSimpleTexture: TTabSheet;
  32. tsVertexDataGen: TTabSheet;
  33. tsStableFluids: TTabSheet;
  34. procedure tvCudaClick(Sender: TObject);
  35. procedure FormCreate(Sender: TObject);
  36. procedure FormShow(Sender: TObject);
  37. private
  38. public
  39. end;
  40. var
  41. FormCudaD: TFormCudaD;
  42. implementation
  43. {$R *.dfm}
  44. procedure TFormCudaD.FormCreate(Sender: TObject);
  45. begin
  46. // FastFourierTrans
  47. FormFFT := TFormFFT.Create(tsFastFourierTrans);
  48. FormFFT.Parent := tsFastFourierTrans;
  49. FormFFT.Align := alClient;
  50. FormFFT.BorderStyle := bsNone;
  51. FormFFT.Show;
  52. // PostProcessing
  53. FormPP := TFormPP.Create(tsPostProcessing);
  54. FormPP.Parent := tsPostProcessing;
  55. FormPP.Align := alClient;
  56. FormPP.BorderStyle := bsNone;
  57. FormPP.Show;
  58. // ScalarProduct
  59. FormSP := TFormSP.Create(tsScalarProduct);
  60. FormSP.Parent := tsScalarProduct;
  61. FormSP.Align := alClient;
  62. FormSP.BorderStyle := bsNone;
  63. FormSP.Show;
  64. // SimpleTexture
  65. FormST := TFormST.Create(tsSimpleTexture);
  66. FormST.Parent := tsSimpleTexture;
  67. FormST.Align := alClient;
  68. FormST.BorderStyle := bsNone;
  69. FormST.Show;
  70. // StableFluids
  71. FormSF := TFormSF.Create(tsStableFluids);
  72. FormSF.Parent := tsStableFluids;
  73. FormSF.Align := alClient;
  74. FormSF.BorderStyle := bsNone;
  75. FormSF.Show;
  76. // VertexDataGen
  77. FormVDG := TFormVDG.Create(tsVertexDataGen);
  78. FormVDG.Parent := tsVertexDataGen;
  79. FormVDG.Align := alClient;
  80. FormVDG.BorderStyle := bsNone;
  81. FormVDG.Show;
  82. end;
  83. procedure TFormCudaD.FormShow(Sender: TObject);
  84. begin
  85. PageControl.ActivePage := tsVertexDataGen;
  86. end;
  87. procedure TFormCudaD.tvCudaClick(Sender: TObject);
  88. begin
  89. tvCuda.Items[0].DropHighlighted := False;
  90. case tvCuda.Selected.Index of
  91. 0:
  92. PageControl.ActivePage := tsFastFourierTrans;
  93. 1:
  94. PageControl.ActivePage := tsPostProcessing;
  95. 2:
  96. PageControl.ActivePage := tsScalarProduct;
  97. 3:
  98. PageControl.ActivePage := tsSimpleTexture;
  99. 4:
  100. PageControl.ActivePage := tsStableFluids;
  101. 5:
  102. PageControl.ActivePage := tsVertexDataGen;
  103. end;
  104. end;
  105. end.