Engine²
Open-source game engine written in C++.
Loading...
Searching...
No Matches
Graphic::Resource::Shader Class Reference

#include <Shader.hpp>

Public Member Functions

virtual ~Shader ()
 Shader (Shader &&other) noexcept
Shaderoperator= (Shader &&other) noexcept
 Shader (const Shader &)=delete
Shaderoperator= (const Shader &)=delete
const ShaderDescriptorGetDescriptor () const
wgpu::BindGroupLayout GetBindGroupLayout (uint32_t groupIndex=0) const
const auto & GetPipeline () const

Static Public Member Functions

static Shader Create (const ShaderDescriptor &descriptor, Context &context)

Private Member Functions

 Shader (void)=default

Static Private Member Functions

static wgpu::ShaderModule _createShaderModule (std::string_view name, std::string_view source, const wgpu::Device &device)
static std::vector< wgpu::VertexBufferLayout > _createVertexBufferLayouts (const ShaderDescriptor &descriptor)

Private Attributes

ShaderDescriptor descriptor
wgpu::RenderPipeline pipeline = nullptr

Constructor & Destructor Documentation

◆ ~Shader()

virtual Graphic::Resource::Shader::~Shader ( )
inlinevirtual

◆ Shader() [1/3]

Graphic::Resource::Shader::Shader ( Shader && other)
inlinenoexcept

◆ Shader() [2/3]

Graphic::Resource::Shader::Shader ( const Shader & )
delete

◆ Shader() [3/3]

Graphic::Resource::Shader::Shader ( void )
privatedefault

Member Function Documentation

◆ _createShaderModule()

wgpu::ShaderModule Graphic::Resource::Shader::_createShaderModule ( std::string_view name,
std::string_view source,
const wgpu::Device & device )
inlinestaticprivate

◆ _createVertexBufferLayouts()

std::vector< wgpu::VertexBufferLayout > Graphic::Resource::Shader::_createVertexBufferLayouts ( const ShaderDescriptor & descriptor)
inlinestaticprivate

◆ Create()

Shader Graphic::Resource::Shader::Create ( const ShaderDescriptor & descriptor,
Context & context )
inlinestatic

◆ GetBindGroupLayout()

wgpu::BindGroupLayout Graphic::Resource::Shader::GetBindGroupLayout ( uint32_t groupIndex = 0) const
inline

◆ GetDescriptor()

const ShaderDescriptor & Graphic::Resource::Shader::GetDescriptor ( ) const
inline

◆ GetPipeline()

const auto & Graphic::Resource::Shader::GetPipeline ( ) const
inline

◆ operator=() [1/2]

Shader & Graphic::Resource::Shader::operator= ( const Shader & )
delete

◆ operator=() [2/2]

Shader & Graphic::Resource::Shader::operator= ( Shader && other)
inlinenoexcept

Member Data Documentation

◆ descriptor

ShaderDescriptor Graphic::Resource::Shader::descriptor
private

◆ pipeline

wgpu::RenderPipeline Graphic::Resource::Shader::pipeline = nullptr
private

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