/
daria_bel
/
VRLabs
Обзор
Документация
Войти
/
daria_bel
/
VRLabs
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
Lab1_BaseObjects/fcBaseObjects.h
92 строки
3 KB
Daria Bel
Лабораторные работы для daria_bel
14 май 2026, 09:22
14 май 2026, 09:22
e507b0f
Код
Авторство
О чём код?
//--------------------------------------------------------------------------- #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> #include "GLS.BaseClasses.hpp" #include "GLS.Coordinates.hpp" #include "GLS.GeomObjects.hpp" #include "GLS.Material.hpp" #include "GLS.Objects.hpp" #include "GLS.Scene.hpp" #include "GLS.SceneViewer.hpp" #include "GLS.SimpleNavigation.hpp" #include "GLS.VectorFileObjects.hpp" //--------------------------------------------------------------------------- class TFormBaseObjects : public TForm { __published: TGLScene *GLScene1; TGLSceneViewer *GLSceneViewer1; TGLLightSource *GLLightSource1; TGLMaterialLibrary *GLMaterialLibrary1; TGLTetrahedron *GLTetrahedron1; TGLCube *GLCube1; TGLOctahedron *GLOctahedron1; TGLDodecahedron *GLDodecahedron1; TGLIcosahedron *GLIcosahedron1; TGLCamera *GLCamera1; TGLSimpleNavigation *GLSimpleNavigation1; 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; void __fastcall ButtonColorClick(TObject *Sender); void __fastcall FormKeyDown(TObject *Sender, WORD &Key, TShiftState Shift); private: struct PolyhedronData { TGLBaseSceneObject* Polyhedron; TPanel* ColorPanel; TShape* ColorShape; TButton* ColorButton; String Prefix; int FaceCount; TGLMaterialLibrary* MaterialLib; }; PolyhedronData Polyhedrons[5]; void __fastcall SetupScene(); void __fastcall UpdatePolyhedronColors(TGLBaseSceneObject* Poly, String Prefix, int FaceCount, TColor Color, TGLMaterialLibrary* MaterialLib); void __fastcall SetDisplayMode(int mode); void __fastcall CreateMaterialsForPolyhedron(TGLBaseSceneObject* Poly, String Prefix, int FaceCount, TGLMaterialLibrary* MaterialLib); public: __fastcall TFormBaseObjects(TComponent* Owner); }; //--------------------------------------------------------------------------- extern PACKAGE TFormBaseObjects *FormBaseObjects; //--------------------------------------------------------------------------- #endif