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

#include <SubmeshComponent.hpp>

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

Public Member Functions

C3D_API SubmeshComponent (Submesh &submesh, castor::String const &type, SubmeshComponentDataUPtr data={}, castor::StringArray deps={})
 Constructor.
 
virtual C3D_API ~SubmeshComponent () noexcept=default
 Destructor.
 
virtual C3D_API bool writeText (castor::String const &tabs, castor::Path const &folder, castor::String const &subfolder, castor::StringStream &file) const
 Writes the component content to text.
 
virtual C3D_API void accept (ConfigurationVisitorBase &vis)
 ConfigurationVisitorBase acceptance function.
 
virtual C3D_API SubmeshComponentFlag getSubmeshFlags () const noexcept
 
virtual C3D_API SubmeshComponentUPtr clone (Submesh &submesh) const =0
 Clones this component into given submesh.
 
virtual C3D_API ProgramFlags getProgramFlags (Pass const &pass) const noexcept
 
C3D_API void initialiseRenderData ()
 Initialises the render data specific for this component's submesh.
 

Getters.

castor::String const & getType () const noexcept
 
castor::StringArray const & getDependencies () const noexcept
 
SubmeshComponentPlugin const & getPlugin () const noexcept
 
SubmeshComponentID getId () const noexcept
 
SubmeshComponentDataRPtr getBaseData () const noexcept
 
SubmeshRenderDatagetRenderData () const noexcept
 
template<typename DataT >
DataT * getDataT () const noexcept
 
template<typename DataT >
DataT * getRenderDataT () const noexcept
 
- Public Member Functions inherited from castor::OwnedBy< Submesh >
Submesh * getOwner () const
 

Protected Attributes

SubmeshComponentDataUPtr m_data
 
SubmeshRenderDataPtr m_renderData
 

Additional Inherited Members

- Protected Member Functions inherited from castor::OwnedBy< Submesh >
 OwnedBy (Submesh &owner)
 Constructor.
 

Constructor & Destructor Documentation

◆ SubmeshComponent()

C3D_API castor3d::SubmeshComponent::SubmeshComponent ( Submesh & submesh,
castor::String const & type,
SubmeshComponentDataUPtr data = {},
castor::StringArray deps = {} )

Constructor.

Parameters
[in]submeshThe parent submesh.
[in]typeThe component type.
[in]dataThe component data.
[in]depsThe components this one depends on.

◆ ~SubmeshComponent()

virtual C3D_API castor3d::SubmeshComponent::~SubmeshComponent ( )
virtualdefaultnoexcept

Destructor.

Member Function Documentation

◆ accept()

virtual C3D_API void castor3d::SubmeshComponent::accept ( ConfigurationVisitorBase & vis)
inlinevirtual

ConfigurationVisitorBase acceptance function.

Parameters
[in,out]visThe ... visitor.

◆ clone()

virtual C3D_API SubmeshComponentUPtr castor3d::SubmeshComponent::clone ( Submesh & submesh) const
pure virtual

◆ getBaseData()

SubmeshComponentDataRPtr castor3d::SubmeshComponent::getBaseData ( ) const
inlinenoexcept

◆ getDataT()

template<typename DataT >
DataT * castor3d::SubmeshComponent::getDataT ( ) const
inlinenoexcept

◆ getDependencies()

castor::StringArray const & castor3d::SubmeshComponent::getDependencies ( ) const
inlinenoexcept

◆ getId()

SubmeshComponentID castor3d::SubmeshComponent::getId ( ) const
inlinenoexcept

Referenced by castor3d::PassMasksComponent::getSubmeshFlags(), and castor3d::SkinComponent::getSubmeshFlags().

Here is the caller graph for this function:

◆ getPlugin()

SubmeshComponentPlugin const & castor3d::SubmeshComponent::getPlugin ( ) const
inlinenoexcept

◆ getProgramFlags()

virtual C3D_API ProgramFlags castor3d::SubmeshComponent::getProgramFlags ( Pass const & pass) const
inlinevirtualnoexcept
Returns
The program flags.
Parameters
[in]passThe material pass.

Reimplemented in castor3d::InstantiationComponent, and castor3d::MeshletComponent.

◆ getRenderData()

SubmeshRenderData * castor3d::SubmeshComponent::getRenderData ( ) const
inlinenoexcept

◆ getRenderDataT()

template<typename DataT >
DataT * castor3d::SubmeshComponent::getRenderDataT ( ) const
inlinenoexcept

◆ getSubmeshFlags()

virtual C3D_API SubmeshComponentFlag castor3d::SubmeshComponent::getSubmeshFlags ( ) const
inlinevirtualnoexcept
Returns
The submesh flags.

Reimplemented in castor3d::PassMasksComponent, and castor3d::SkinComponent.

References castor3d::makeSubmeshComponentFlag().

Here is the call graph for this function:

◆ getType()

castor::String const & castor3d::SubmeshComponent::getType ( ) const
inlinenoexcept

◆ initialiseRenderData()

C3D_API void castor3d::SubmeshComponent::initialiseRenderData ( )

Initialises the render data specific for this component's submesh.

◆ writeText()

virtual C3D_API bool castor3d::SubmeshComponent::writeText ( castor::String const & tabs,
castor::Path const & folder,
castor::String const & subfolder,
castor::StringStream & file ) const
inlinevirtual

Writes the component content to text.

Parameters
[in]tabsThe current tabulation level.
[in]folderThe resources folder.
[in]subfolderThe resources subfolder.
[in,out]fileThe output file.

Member Data Documentation

◆ m_data

SubmeshComponentDataUPtr castor3d::SubmeshComponent::m_data
protected

◆ m_renderData

SubmeshRenderDataPtr castor3d::SubmeshComponent::m_renderData
protected

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