| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191 |
- //---------------------------------------------------------------------------
- #ifndef fcGLSViewerH
- #define fcGLSViewerH
- //---------------------------------------------------------------------------
- #include <System.Classes.hpp>
- #include <System.Actions.hpp>
- #include <System.ImageList.hpp>
- #include <Vcl.ActnCtrls.hpp>
- #include <Vcl.ActnList.hpp>
- #include <Vcl.ActnMan.hpp>
- #include <Vcl.ActnMenus.hpp>
- #include <Vcl.BandActn.hpp>
- #include <Vcl.ComCtrls.hpp>
- #include <Vcl.Dialogs.hpp>
- #include <Vcl.ExtCtrls.hpp>
- #include <Vcl.ImgList.hpp>
- #include <Vcl.StdActns.hpp>
- #include <Vcl.StdStyleActnCtrls.hpp>
- #include <Vcl.ToolWin.hpp>
- #include <Vcl.Controls.hpp>
- #include <Vcl.StdCtrls.hpp>
- #include <Vcl.Forms.hpp>
- #include "GLS.AsyncTimer.hpp"
- #include "GLS.BaseClasses.hpp"
- #include "GLS.Cadencer.hpp"
- #include "GLS.Coordinates.hpp"
- #include "GLS.Graph.hpp"
- #include "GLS.Material.hpp"
- #include "GLS.Objects.hpp"
- #include "GLS.GeomObjects.hpp"
- #include "GLS.MultiPolygon.hpp"
- #include "GLS.Extrusion.hpp"
- #include "GLS.Scene.hpp"
- #include "GLS.SceneViewer.hpp"
- #include "GLS.SimpleNavigation.hpp"
- #include "GLS.VectorFileObjects.hpp"
- #include "GLS.SkyDome.hpp"
- #include "GLS.Navigator.hpp"
- //---------------------------------------------------------------------------
- class TFormViewer : public TForm
- {
- __published: // IDE-managed Components
- TStatusBar *StatusBar;
- TGLSceneViewer *snViewer;
- TControlBar *ControlBar;
- TActionToolBar *atbTools;
- TActionToolBar *atbView;
- TActionToolBar *atbFile;
- TActionMainMenuBar *amMenuBar;
- TPanel *PanelLeft;
- TTreeView *tvScene;
- TGLScene *Scene;
- TGLCamera *Camera;
- TGLLightSource *LightSource;
- TGLXYZGrid *XYZGrid;
- TGLCube *CubeLines;
- TGLDummyCube *dcObject;
- TGLFreeForm *ffObject;
- TGLDummyCube *dcAxis;
- TGLDummyCube *dcWorld;
- TGLPoints *GLPoints;
- TGLMaterialLibrary *MaterialLib;
- TGLCadencer *Cadencer;
- TTimer *Timer;
- TActionManager *ActionManager;
- TAction *acOptimizeMesh;
- TAction *acProcessInvertNormals;
- TAction *acReverseRendering;
- TAction *acConvertToTriangles;
- TAction *acProcessStripify;
- TAction *acToolsOptions;
- TAction *acToolsFaceCulling;
- TAction *acToolsTexturing;
- TAction *acToolsLighting;
- TAction *acToolsNaviCube;
- TCustomizeActionBars *acToolsCustomize;
- TAction *acToolsShowFPS;
- TAction *acViewSmoothShading;
- TAction *acViewFlatShading;
- TAction *acViewFlatLines;
- TAction *acViewHiddenLines;
- TAction *acViewWireFrame;
- TAction *acViewZoomIn;
- TAction *acViewZoomOut;
- TAction *acViewReset;
- TAction *acFileOpen;
- TAction *acFilePick;
- TAction *acFileOpenTexLib;
- TAction *acFileSaveAs;
- TAction *acFileSaveTextures;
- TAction *acSaveTreeView;
- TAction *acLoadTreeView;
- TAction *acFileExit;
- THelpContents *acHelpContents;
- THelpTopicSearch *acHelpTopicSearch;
- TAction *acHelpGLSHomePage;
- TAction *acHelpAbout;
- TAction *acAADefault;
- TAction *acAA2X;
- TAction *acAA4X;
- TEditUndo *acEditUndo;
- TEditCut *acEditCut;
- TEditCopy *acEditCopy;
- TEditPaste *acEditPaste;
- TEditSelectAll *acEditSelectAll;
- TEditDelete *acEditDelete;
- TAction *acAA8X;
- TAction *acAA16X;
- TAction *acCSA8X;
- TAction *acCSA16X;
- TAction *acPoints;
- TAction *acToolsInfo;
- TAction *acSpheres;
- TImageList *ImageListMenu;
- TGLAsyncTimer *AsyncTimer;
- TGLSimpleNavigation *GLSimpleNavigation;
- TImageList *ImageListObjects;
- TOpenDialog *OpenDialog;
- TSaveDialog *SaveDialog;
- void __fastcall tvSceneClick(TObject *Sender);
- void __fastcall FormCreate(TObject *Sender);
- private: // User declarations
- TFileName AssetPath;
- TFileName TextureDir;
- // Base objects
- TGLLines *Lines;
- TGLPlane *Plane;
- TGLPolygon *Polygon;
- TGLCube *Cube;
- TGLFrustrum *Frustrum;
- TGLSphere *Sphere;
- TGLDisk *Disk;
- TGLCone *Cone;
- TGLCylinder *Cylinder;
- TGLCapsule *Capsule;
- TGLDodecahedron *Dodecahedron;
- TGLIcosahedron *Icosahedron;
- TGLHexahedron *Hexahedron;
- TGLOctahedron *Octahedron;
- TGLTetrahedron *Tetrahedron;
- // TGLSuperEllipsoid *SuperEllipsoid;
- // Advanced objects
- TGLAnnulus *Annulus;
- TGLArrowLine *ArrowLine;
- TGLArrowArc *ArrowArc;
- TGLMultiPolygon *MultiPolygon;
- TGLRevolutionSolid *RevolutionSolid;
- TGLExtrusionSolid *ExtrusionSolid;
- // Mesh objects
- TGLActor *Actor;
- TGLFreeForm *FreeForm;
- TGLMeshObject *MeshObject;
- // Environment objects
- TGLSkyBox *SkyBox;
- TGLSkyDome *SkyDome;
- TGLEarthSkyDome *EarthSkyDome;
- /*
- void DoResetCamera;
- void SetupFreeFormShading;
- void ApplyShadeModeToMaterial(aMaterial: TGLMaterial);
- void ApplyShadeMode;
- void ApplyFSAA;
- void ApplyFaceCull;
- void ApplyTexturing;
- void ApplyFPS;
- void DoOpen(const FileName: String);
- */
- public: // User declarations
- __fastcall TFormViewer(TComponent* Owner);
- bool md, nthShow;
- int mx, my;
- TGLShader *hlShader;
- /// StringlastFileName;
- bool lastLoadWithTextures;
- /*
- void ApplyBgColor;
- void ReadIniFile; override;
- void WriteIniFile;
- */
- };
- //---------------------------------------------------------------------------
- extern PACKAGE TFormViewer *FormViewer;
- //---------------------------------------------------------------------------
- #endif
|