diff options
| author | ladevieq <ladevie.quentin@gmail.com> | 2026-05-05 00:50:13 +0200 |
|---|---|---|
| committer | ladevieq <ladevie.quentin@gmail.com> | 2026-05-05 00:50:49 +0200 |
| commit | 37fdcb8a0f435c42f737252450626f2bd38bbd0f (patch) | |
| tree | 7eeb45a2d2d08483409a04c74fbc74fb2bbcde9f /include/mesh.hpp | |
| parent | 6818cbfe21beefc04e4a174d44a92159c34cead1 (diff) | |
Clean up around included files
Diffstat (limited to 'include/mesh.hpp')
| -rw-r--r-- | include/mesh.hpp | 22 |
1 files changed, 3 insertions, 19 deletions
diff --git a/include/mesh.hpp b/include/mesh.hpp index b88896d..c396814 100644 --- a/include/mesh.hpp +++ b/include/mesh.hpp @@ -1,15 +1,5 @@ #pragma once -#include <cstdint> -#include <vector> -#include <array> - -#ifdef API_TEST -#include "vk-device-types.hpp" -#else -#include "vk-renderer.hpp" -#endif // API_TEST - enum ATTRIBUTE_TYPE { POSITION, NORMAL, @@ -34,15 +24,15 @@ public: }; struct attribute { - uint8_t* data = nullptr; + const uint8_t* data = nullptr; size_t length = 0; }; struct submesh { attribute indices; std::array<attribute, ATTRIBUTE_TYPE::MAX_ATTRIBUTE> attributes; - uint32_t vertex_count = 0; - uint32_t index_count = 0; + u32 vertex_count = 0; + u32 index_count = 0; // material& material; }; @@ -93,15 +83,9 @@ private: std::vector<submesh_info> submeshes; struct gpu_mesh { -#ifdef API_TEST std::array<handle<device_buffer>, ATTRIBUTE_TYPE::MAX_ATTRIBUTE> attributes; const device_buffer& indices; const device_buffer& submeshes; -#else - std::array<Buffer*, ATTRIBUTE_TYPE::MAX_ATTRIBUTE> attributes; - Buffer* indices; - Buffer* submeshes; -#endif // API_TEST }; // allocate gpu mesh upon instanciation |
