diff --git a/src/spirv/spirv_module.cpp b/src/spirv/spirv_module.cpp index 9c141007..ee62307e 100644 --- a/src/spirv/spirv_module.cpp +++ b/src/spirv/spirv_module.cpp @@ -470,6 +470,13 @@ namespace dxvk { } + uint32_t SpirvModule::constNull( + uint32_t typeId) { + return this->defConst(spv::OpConstantNull, + typeId, 0, nullptr); + } + + uint32_t SpirvModule::lateConst32( uint32_t typeId) { uint32_t resultId = this->allocateId(); diff --git a/src/spirv/spirv_module.h b/src/spirv/spirv_module.h index 2845909d..b33bfe35 100644 --- a/src/spirv/spirv_module.h +++ b/src/spirv/spirv_module.h @@ -217,6 +217,9 @@ namespace dxvk { uint32_t constUndef( uint32_t typeId); + uint32_t constNull( + uint32_t typeId); + uint32_t lateConst32( uint32_t typeId);