Class CrossCompiler#

Class Documentation#

class CrossCompiler#

SPIRV cross compiler data.

Public Functions

explicit CrossCompiler(std::span<const u32> SPIRVBinary)#

Create a new SPIRV cross compiler instance.

Parameters:

SPIRVBinary – SPIRV binary data.

~CrossCompiler() = default#

Destructor.

consteval CrossCompiler(const CrossCompiler&) = delete#
CrossCompiler(CrossCompiler&&) noexcept = default#
consteval CrossCompiler &operator=(const CrossCompiler&) noexcept = delete#
CrossCompiler &operator=(CrossCompiler&&) = default#
void ReflectEntryPoint()#

Reflect the shaders entry point.

void ReflectShaderResources()#

Reflect the shaders used resources.

void ReflectShaderVariables()#

Reflect the shaders uniform variables.

std::array<u32, 3> GetComputeShaderWorkGroupSize() const#

Retrieve the compute shader work group size.

Returns:

Compute shader work group size.

u32 GetTessellationControlShaderControlPoint() const#

Retrieve tessellation control shader control point count.

Returns:

Tessellation control shader control point count.

constexpr const std::vector<Resource> &GetShaderResources() const noexcept#

Retrieve the shader resources.

Returns:

Shader resources.

constexpr const std::vector<Variable> &GetUniformVariables() const noexcept#

Retrieve the uniform variables.

Returns:

Uniform variables.

constexpr std::string GetEntryPoint() const noexcept#

Rertieve the name of the entry point.

Returns:

Name of entry point.