/
Alexandr_mamonov
/
lab
Обзор
Документация
Войти
/
Alexandr_mamonov
/
lab
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
CI/CD
Аналитика
Безопасность
master
Lab1_BaseObjects/fcBaseObjects.h
97 строк
3 KB
Александр Мамонов
Add visualization lab projects
11 май 2026, 20:15
11 май 2026, 20:15
e92b10e
Код
Авторство
О чём код?
//--------------------------------------------------------------------------- #ifndef fcBaseObjectsH #define fcBaseObjectsH //--------------------------------------------------------------------------- #include <System.Classes.hpp> #include <Vcl.Controls.hpp> #include <Vcl.StdCtrls.hpp> #include <Vcl.Forms.hpp> #include <Vcl.ExtCtrls.hpp> #include <Vcl.Dialogs.hpp> // GLScene ���������� #include "GLS.BaseClasses.hpp" #include "GLS.Coordinates.hpp" #include "GLS.GeomObjects.hpp" #include "GLS.Objects.hpp" #include "GLS.Scene.hpp" #include "GLS.SceneViewer.hpp" #include "GLS.SimpleNavigation.hpp" #include "GLS.Material.hpp" #include "GLS.VectorFileObjects.hpp" //--------------------------------------------------------------------------- class TFormBaseObjects : public TForm { __published: // IDE-managed Components // GLScene ���������� TGLScene *GLScene1; TGLSceneViewer *GLSceneViewer1; TGLLightSource *GLLightSource1; TGLSimpleNavigation *GLSimpleNavigation1; TGLMaterialLibrary *GLMaterialLibrary1; // ������������� TGLTetrahedron *GLTetrahedron1; TGLCube *GLCube1; TGLOctahedron *GLOctahedron1; TGLDodecahedron *GLDodecahedron1; TGLIcosahedron *GLIcosahedron1; // �������� ���������� TPanel *Panel1; TGroupBox *GroupBoxTetra; TPanel *PanelTetra; TShape *ShapeTetra; TButton *ButtonTetra; TGroupBox *GroupBoxCube; TPanel *PanelCube; TShape *ShapeCube; TButton *ButtonCube; TGroupBox *GroupBoxOcta; TPanel *PanelOcta; TShape *ShapeOcta; TButton *ButtonOcta; TGroupBox *GroupBoxDodeca; TPanel *PanelDodeca; TShape *ShapeDodeca; TButton *ButtonDodeca; TGroupBox *GroupBoxIcosa; TPanel *PanelIcosa; TShape *ShapeIcosa; TButton *ButtonIcosa; TColorDialog *ColorDialog1; TGLCamera *GLCamera1; // ����������� void __fastcall ButtonColorClick(TObject *Sender); private: // User declarations struct PolyhedronData { TGLBaseSceneObject* Polyhedron; TPanel* ColorPanel; TShape* ColorShape; TButton* ColorButton; String Prefix; int FaceCount; TGLMaterialLibrary* MaterialLib; }; PolyhedronData Polyhedrons[5]; void __fastcall CreateMaterialsForPolyhedron(TGLBaseSceneObject* Poly, String Prefix, int FaceCount, TGLMaterialLibrary* MaterialLib); void __fastcall UpdatePolyhedronColors(TGLBaseSceneObject* Poly, String Prefix, int FaceCount, TColor Color, TGLMaterialLibrary* MaterialLib); void __fastcall SetupScene(); public: __fastcall TFormBaseObjects(TComponent* Owner); }; //--------------------------------------------------------------------------- extern PACKAGE TFormBaseObjects *FormBaseObjects; //--------------------------------------------------------------------------- #endif