Class for model. More...
#include <Model.hpp>
Classes | |
struct | Builder |
struct | Vertex |
Public Member Functions | |
Model (Device &device, const Builder &builder) | |
~Model ()=default | |
Model (const Model &)=delete | |
Model & | operator= (const Model &)=delete |
Model (Model &&)=delete | |
Model & | operator= (Model &&)=delete |
void | bind (VkCommandBuffer commandBuffer) const |
void | draw (VkCommandBuffer commandBuffer) const |
Private Member Functions | |
void | createVertexBuffer (const std::vector< Vertex > &vertices) |
void | createIndexBuffer (const std::vector< uint32_t > &indices) |
Private Attributes | |
Device & | m_device |
std::unique_ptr< Buffer > | m_vertexBuffer |
uint32_t | m_vertexCount |
bool | m_hasIndexBuffer {false} |
std::unique_ptr< Buffer > | m_indexBuffer |
uint32_t | m_indexCount |
Definition at line 20 of file model.cpp.
References createIndexBuffer(), createVertexBuffer(), ven::Model::Builder::indices, and ven::Model::Builder::vertices.
|
default |
|
delete |
|
delete |
void ven::Model::bind | ( | VkCommandBuffer | commandBuffer | ) | const |
|
private |
Definition at line 43 of file model.cpp.
References ven::Buffer::map().
Referenced by Model().
|
private |
Definition at line 26 of file model.cpp.
References ven::Buffer::map().
Referenced by Model().
void ven::Model::draw | ( | VkCommandBuffer | commandBuffer | ) | const |