Castor3D 0.16.0
Multiplatform 3D engine
Public Member Functions | Protected Attributes | List of all members
castor3d::SubmeshComponentData Struct Referenceabstract

#include <SubmeshComponent.hpp>

Inheritance diagram for castor3d::SubmeshComponentData:
Inheritance graph
[legend]
Collaboration diagram for castor3d::SubmeshComponentData:
Collaboration graph
[legend]

Public Member Functions

C3D_API SubmeshComponentData (Submesh &submesh)
 
C3D_API bool initialise (RenderDevice const &device)
 Initialises the submesh.
 
C3D_API void cleanup (RenderDevice const &device)
 Cleans the submesh.
 
C3D_API void upload (UploadData &uploader)
 Uploads data on VRAM.
 
virtual C3D_API void gather (PipelineFlags const &flags, Pass const &pass, ObjectBufferOffset const &bufferOffsets, ashes::BufferCRefArray &buffers, castor::Vector< uint64_t > &offsets, ashes::PipelineVertexInputStateCreateInfoCRefArray &layouts, uint32_t &currentBinding, uint32_t &currentLocation)=0
 Gathers buffers that need to go in a vertex layout.
 
virtual C3D_API void copy (SubmeshComponentDataRPtr data) const =0
 Copies given component's data into this one.
 
virtual C3D_API VkBufferUsageFlags getUsageFlags () const noexcept
 

Getters.

void needsUpdate ()
 
- Public Member Functions inherited from castor3d::SubmeshSubComponent
 SubmeshSubComponent ()=default
 
 SubmeshSubComponent (SubmeshSubComponent const &)=delete
 
SubmeshSubComponentoperator= (SubmeshSubComponent const &)=delete
 
C3D_API SubmeshSubComponent (SubmeshSubComponent &&) noexcept=default
 
C3D_API SubmeshSubComponentoperator= (SubmeshSubComponent &&) noexcept=default
 
virtual C3D_API ~SubmeshSubComponent () noexcept=default
 

Protected Attributes

Submeshm_submesh
 

Constructor & Destructor Documentation

◆ SubmeshComponentData()

C3D_API castor3d::SubmeshComponentData::SubmeshComponentData ( Submesh & submesh)

Member Function Documentation

◆ cleanup()

C3D_API void castor3d::SubmeshComponentData::cleanup ( RenderDevice const & device)

Cleans the submesh.

Parameters
[in]deviceThe render device.

◆ copy()

virtual C3D_API void castor3d::SubmeshComponentData::copy ( SubmeshComponentDataRPtr data) const
pure virtual

◆ gather()

virtual C3D_API void castor3d::SubmeshComponentData::gather ( PipelineFlags const & flags,
Pass const & pass,
ObjectBufferOffset const & bufferOffsets,
ashes::BufferCRefArray & buffers,
castor::Vector< uint64_t > & offsets,
ashes::PipelineVertexInputStateCreateInfoCRefArray & layouts,
uint32_t & currentBinding,
uint32_t & currentLocation )
pure virtual

Gathers buffers that need to go in a vertex layout.

Parameters
[in]flagsThe pipeline flags.
[in]passThe material pass.
[in]bufferOffsetsHolds the buffers.
[in,out]buffersReceives the buffers.
[in,out]offsetsReceives the buffers offsets.
[in,out]layoutsReceives the vertex layouts.
[in,out]currentBindingThe current buffer binding.
[in,out]currentLocationThe current attribute location.

Implemented in castor3d::BaseDataComponentT< SubmeshDataT, DataT >::ComponentData, castor3d::InstantiationComponent::ComponentData, castor3d::MeshletComponent::ComponentData, castor3d::MorphComponent::ComponentData, castor3d::PassMasksComponent::ComponentData, castor3d::SkinComponent::ComponentData, and castor3d::IndexMapping::ComponentData.

◆ getUsageFlags()

virtual C3D_API VkBufferUsageFlags castor3d::SubmeshComponentData::getUsageFlags ( ) const
inlinevirtualnoexcept
Returns
The buffer usage flags.

Reimplemented in castor3d::IndexMapping::ComponentData.

◆ initialise()

C3D_API bool castor3d::SubmeshComponentData::initialise ( RenderDevice const & device)

Initialises the submesh.

Parameters
[in]deviceThe render device.

◆ needsUpdate()

void castor3d::SubmeshComponentData::needsUpdate ( )
inline

◆ upload()

C3D_API void castor3d::SubmeshComponentData::upload ( UploadData & uploader)

Uploads data on VRAM.

Remarks
For host visible buffers.
Parameters
[in,out]uploaderReceives the upload requests.

Member Data Documentation

◆ m_submesh

Submesh& castor3d::SubmeshComponentData::m_submesh
protected

The documentation for this struct was generated from the following file: