.. _program_listing_file_Src_GraphicsEngineVulkan_scene_Model.hpp: Program Listing for File Model.hpp ================================== |exhale_lsh| :ref:`Return to documentation for file ` (``Src/GraphicsEngineVulkan/scene/Model.hpp``) .. |exhale_lsh| unicode:: U+021B0 .. UPWARDS ARROW WITH TIP LEFTWARDS .. code-block:: cpp #pragma once #include #include #include "scene/Mesh.hpp" #include "scene/Texture.hpp" namespace Kataglyphis { class Model { public: Model(); Model(VulkanDevice *device); void cleanUp(); void add_new_mesh(VulkanDevice *device, VkQueue transfer_queue, VkCommandPool command_pool, std::vector &vertices, std::vector &indices, std::vector &materialIndex, std::vector &materials); uint32_t getTextureCount() { return static_cast(modelTextures.size()); }; std::vector &getTextures() { return modelTextures; } std::vector &getTextureSamplers() { return modelTextureSamplers; } std::vector getTextureList() { return texture_list; }; uint32_t getMeshCount() { return 1; }; Mesh *getMesh(size_t index) { return &mesh; }; glm::mat4 getModel() { return model; }; uint32_t getCustomInstanceIndex() { return mesh_model_index; }; uint32_t getPrimitiveCount(); ObjectDescription getObjectDescription() { return mesh.getObjectDescription(); }; void set_model(glm::mat4 model); void addTexture(Texture newTexture); ~Model(); private: VulkanDevice *device{ VK_NULL_HANDLE }; void addSampler(Texture newTexture); uint32_t mesh_model_index{ static_cast(-1) }; Mesh mesh; glm::mat4 model; std::vector texture_list; std::vector modelTextures; std::vector modelTextureSamplers; }; }// namespace Kataglyphis