Crimson Engine 1.0.0
A high-performance C++20 game engine prototype showcasing a custom ECS, Vulkan renderer, and ImGui editor.
Loading...
Searching...
No Matches
EditorUIInternal.hpp
Go to the documentation of this file.
1#pragma once
2#include <string>
3#include <vector>
4#include <filesystem>
5#include <imgui.h>
6#include "../ecs/Entity.hpp"
9
11 std::string assetPath;
12 float scale = 1.0f;
13 bool generateNormals = true;
14 bool allowMissingPos = false;
15 bool forceInPlace = false;
17
18 struct AnimMetadata {
19 std::string name;
20 double duration = 0.0;
21 };
22 std::vector<AnimMetadata> animations;
23
24 struct TexMetadata {
25 std::string name;
26 size_t index = 0;
27 bool hasEmbeddedContent = false;
28 size_t contentSize = 0;
29 };
30 std::vector<TexMetadata> textures;
31};
32
36extern std::filesystem::path s_importSettingsAssetPath;
41extern std::string s_editingTilesetPath;
43extern bool s_tilesetLoaded;
44extern int s_brushTileId;
45extern bool s_brushModeActive;
47extern ImVec2 s_tsPanOffset;
48extern float s_tsCellSize;
49extern bool s_tsIsPanning;
50extern ImVec2 s_tsPanStart;
51extern ImVec2 s_tsPanOffsetStart;
52
53void loadImportSettingsMetadata(const std::filesystem::path& path);
55bool writeExtractedFile(const std::string& relativePath, const void* data, size_t size);
56bool entityHasSkin(Registry& registry, Entity entity);
void loadImportSettingsMetadata(const std::filesystem::path &path)
Definition EditorUI.cpp:81
int s_brushTileId
Definition EditorUI.cpp:72
bool s_tilesetLoaded
Definition EditorUI.cpp:71
Engine::TilesetAsset s_editingTileset
Definition EditorUI.cpp:70
bool s_openImportSettingsWindow
Definition EditorUI.cpp:60
std::string s_editingTilesetPath
Definition EditorUI.cpp:69
ImportSettingsMetadata s_importMetadata
Definition EditorUI.cpp:62
bool s_openNodeGraphDemoWindow
Definition EditorUI.cpp:66
bool s_brushModeActive
Definition EditorUI.cpp:73
bool writeExtractedFile(const std::string &relativePath, const void *data, size_t size)
Definition EditorUI.cpp:244
bool s_openAnimationEditorWindow
Definition EditorUI.cpp:65
Entity s_brushTilemapEntity
Definition EditorUI.cpp:74
ImVec2 s_tsPanOffsetStart
Definition EditorUI.cpp:79
bool s_tsIsPanning
Definition EditorUI.cpp:77
ImVec2 s_tsPanOffset
Definition EditorUI.cpp:75
bool s_triggerLoadImportSettings
Definition EditorUI.cpp:61
float s_tsCellSize
Definition EditorUI.cpp:76
bool entityHasSkin(Registry &registry, Entity entity)
Definition EditorUI.cpp:271
ImVec2 s_tsPanStart
Definition EditorUI.cpp:78
void saveImportSettings()
Definition EditorUI.cpp:177
bool s_openTilesetEditorWindow
Definition EditorUI.cpp:64
std::filesystem::path s_importSettingsAssetPath
Definition EditorUI.cpp:63
bool s_openAnimatorControllerWindow
Definition EditorUI.cpp:67
TextureFilterMode
Definition Material.hpp:6
@ Bilinear
Definition Material.hpp:8
Lightweight identifier representing a game object in the Entity Component System.
Definition Entity.hpp:11
Coordinates entities and components, providing creation, removal, lookup, and views.
Definition Registry.hpp:30
A disk asset (.tileset JSON) that owns an ordered list of TileAssets. At runtime, a CPU-side atlas is...
Definition TilesetAsset.hpp:47
Definition EditorUIInternal.hpp:18
double duration
Definition EditorUIInternal.hpp:20
std::string name
Definition EditorUIInternal.hpp:19
Definition EditorUIInternal.hpp:24
size_t contentSize
Definition EditorUIInternal.hpp:28
bool hasEmbeddedContent
Definition EditorUIInternal.hpp:27
size_t index
Definition EditorUIInternal.hpp:26
std::string name
Definition EditorUIInternal.hpp:25
Definition EditorUIInternal.hpp:10
std::string assetPath
Definition EditorUIInternal.hpp:11
float scale
Definition EditorUIInternal.hpp:12
bool allowMissingPos
Definition EditorUIInternal.hpp:14
std::vector< AnimMetadata > animations
Definition EditorUIInternal.hpp:22
std::vector< TexMetadata > textures
Definition EditorUIInternal.hpp:30
bool generateNormals
Definition EditorUIInternal.hpp:13
bool forceInPlace
Definition EditorUIInternal.hpp:15
TextureFilterMode filterMode
Definition EditorUIInternal.hpp:16
tag text data
Definition ufbx.cpp:7532