Add Slice to Span and sue it to make code cleaner

This commit is contained in:
Wojtek Figat
2025-01-05 17:41:27 +01:00
parent 78cf1a4948
commit 933fac6c13
12 changed files with 37 additions and 13 deletions

View File

@@ -102,7 +102,7 @@ GPUShaderProgram* GPUShaderVulkan::CreateGPUShaderProgram(ShaderStage type, cons
{
// Extract the SPIR-V shader header from the cache
SpirvShaderHeader* header = (SpirvShaderHeader*)bytecode.Get();
bytecode = Span<byte>(bytecode.Get() + sizeof(SpirvShaderHeader), bytecode.Length() - sizeof(SpirvShaderHeader));
bytecode = bytecode.Slice(sizeof(SpirvShaderHeader));
// Extract the SPIR-V bytecode
BytesContainer spirv;