![]() |
MAGE
v0.171.0
Matthias Advanced Game Engine
|
#include <static_mesh.hpp>
Public Member Functions | |
| StaticMesh (ID3D11Device &device, std::vector< VertexT > vertices, std::vector< IndexT > indices, D3D11_PRIMITIVE_TOPOLOGY primitive_topology=D3D11_PRIMITIVE_TOPOLOGY_TRIANGLELIST) | |
| StaticMesh (const StaticMesh &mesh)=delete | |
| StaticMesh (StaticMesh &&mesh) noexcept | |
| virtual | ~StaticMesh () |
| StaticMesh & | operator= (const StaticMesh &mesh)=delete |
| StaticMesh & | operator= (StaticMesh &&mesh) noexcept |
Public Member Functions inherited from mage::rendering::Mesh | |
| virtual | ~Mesh () |
| Mesh & | operator= (const Mesh &mesh)=delete |
| Mesh & | operator= (Mesh &&mesh) noexcept |
| std::size_t | GetNumberOfVertices () const noexcept |
| std::size_t | GetNumberOfIndices () const noexcept |
| std::size_t | GetVertexSize () const noexcept |
| DXGI_FORMAT | GetIndexFormat () const noexcept |
| D3D11_PRIMITIVE_TOPOLOGY | GetPrimitiveTopology () const noexcept |
| void | BindMesh (ID3D11DeviceContext &device_context) const noexcept |
| void | BindMesh (ID3D11DeviceContext &device_context, D3D11_PRIMITIVE_TOPOLOGY topology) const noexcept |
| void | Draw (ID3D11DeviceContext &device_context) const noexcept |
| void | Draw (ID3D11DeviceContext &device_context, std::size_t start_index, std::size_t nb_indices) const noexcept |
Private Member Functions | |
| void | SetupVertexBuffer (ID3D11Device &device) |
| void | SetupIndexBuffer (ID3D11Device &device) |
Private Attributes | |
| std::vector< VertexT > | m_vertices |
| std::vector< IndexT > | m_indices |
Additional Inherited Members | |
Protected Member Functions inherited from mage::rendering::Mesh | |
| Mesh (std::size_t vertex_size, DXGI_FORMAT index_format, D3D11_PRIMITIVE_TOPOLOGY primitive_topology) | |
| Mesh (const Mesh &mesh)=delete | |
| Mesh (Mesh &&mesh) noexcept | |
| void | SetNumberOfVertices (std::size_t nb_vertices) noexcept |
| void | SetNumberOfIndices (std::size_t nb_indices) noexcept |
Protected Attributes inherited from mage::rendering::Mesh | |
| ComPtr< ID3D11Buffer > | m_vertex_buffer |
| ComPtr< ID3D11Buffer > | m_index_buffer |
A class of static meshes.
| VertexT | The vertex type. |
| IndexT | The index type. |
|
explicit |
Constructs a static mesh.
| [in,out] | device | A reference to the device. |
| [in] | vertices | A vector containing the vertices. |
| [in] | indices | A vector containing the indices. |
| [in] | primitive_topology | The primitive topology. |
|
delete |
Constructs a static mesh from the given static mesh.
| [in] | mesh | A reference to the static mesh to copy. |
|
noexcept |
Constructs a static mesh by moving the given static mesh.
| [in] | mesh | A reference to the static mesh to move. |
|
virtual |
Destructs this static mesh.
|
delete |
Copies the given static mesh to this static mesh.
| [in] | mesh | A reference to the static mesh to copy. |
|
noexcept |
Moves the given static mesh to this static mesh.
| [in] | mesh | A reference to the static mesh to move. |
|
private |
Sets up the index buffer of this static mesh.
| [in,out] | device | A reference to the device. |
| Exception | Failed to setup the index buffer of this static mesh. |
|
private |
Sets up the vertex buffer of this static mesh.
| [in,out] | device | A reference to the device. |
| Exception | Failed to setup the vertex buffer of this static mesh. |
|
private |
The vector containing the indices of this static mesh.
|
private |
The vector containing the vertices of this static mesh.