@@ -1443,7 +1443,7 @@ void CVulkanLogicalDevice::createRayTracingPipelines_impl(
1443
1443
});
1444
1444
core::vector<VkPipelineShaderStageCreateInfo> vk_shaderStage (maxShaderStages, { VK_STRUCTURE_TYPE_PIPELINE_SHADER_STAGE_CREATE_INFO, nullptr });
1445
1445
core::vector<VkRayTracingShaderGroupCreateInfoKHR> vk_shaderGroup (maxShaderStages, { VK_STRUCTURE_TYPE_RAY_TRACING_SHADER_GROUP_CREATE_INFO_KHR, nullptr });
1446
- core::vector<VkSpecializationInfo> vk_specializationInfos (createInfos. size () , { 0 , nullptr , 0 , nullptr });
1446
+ core::vector<VkSpecializationInfo> vk_specializationInfos (maxShaderStages , { 0 , nullptr , 0 , nullptr });
1447
1447
core::vector<VkSpecializationMapEntry> vk_specializationMapEntry (validation.count );
1448
1448
core::vector<uint8_t > specializationData (validation.dataSize );
1449
1449
@@ -1487,14 +1487,7 @@ void CVulkanLogicalDevice::createRayTracingPipelines_impl(
1487
1487
{
1488
1488
if (specInfo.shader )
1489
1489
{
1490
- const auto stage = specInfo.shader ->getStage ();
1491
- *(outShaderStage++) = {
1492
- .sType = VK_STRUCTURE_TYPE_PIPELINE_SHADER_STAGE_CREATE_INFO,
1493
- .pNext = nullptr ,
1494
- .stage = static_cast <VkShaderStageFlagBits>(stage),
1495
- .module = static_cast <const CVulkanShader*>(specInfo.shader )->getInternalObject (),
1496
- .pName = specInfo.entryPoint .c_str (),
1497
- };
1490
+ *(outShaderStage++) = getVkShaderStageCreateInfoFrom (specInfo,outRequiredSubgroupSize,outSpecInfo,outSpecMapEntry,outSpecData);
1498
1491
}
1499
1492
}
1500
1493
outCreateInfo->stageCount = std::distance<decltype (outCreateInfo->pStages )>(outCreateInfo->pStages ,outShaderStage);
0 commit comments