SPARK  0.1.0
A general purpose game engine written in C++.
Loading...
Searching...
No Matches
spark::render::IVertexBufferLayout Class Referenceabstract

Describes the layout of a vertex buffer. More...

#include <VertexBuffer.h>

Inheritance diagram for spark::render::IVertexBufferLayout:
spark::render::IBufferLayout spark::render::vk::VulkanVertexBufferLayout

Public Member Functions

virtual std::vector< const BufferAttribute * > attributes () const noexcept=0
 Gets the attributes of the vertex buffer.
 
virtual void addAttribute (BufferAttribute &&attribute) noexcept=0
 Adds an attribute to the vertex buffer layout.
 
- Public Member Functions inherited from spark::render::IBufferLayout
virtual std::size_t elementSize () const noexcept=0
 Gets the size of a single element in the buffer.
 
virtual unsigned int binding () const noexcept=0
 Gets the binding point the buffer will be bound to.
 
virtual BufferType type () const noexcept=0
 Gets the type of the buffer.
 

Detailed Description

Describes the layout of a vertex buffer.

Member Function Documentation

◆ addAttribute()

virtual void spark::render::IVertexBufferLayout::addAttribute ( BufferAttribute && attribute)
pure virtualnoexcept

Adds an attribute to the vertex buffer layout.

Parameters
attributeThe BufferAttribute to add.

Implemented in spark::render::vk::VulkanVertexBufferLayout.

◆ attributes()

virtual std::vector< const BufferAttribute * > spark::render::IVertexBufferLayout::attributes ( ) const
nodiscardpure virtualnoexcept

Gets the attributes of the vertex buffer.

Returns
A std::vector of BufferAttribute representing the attributes of the vertex buffer.

Implemented in spark::render::vk::VulkanVertexBufferLayout.