MayaFlux 0.4.0
Digital-First Multimedia Processing Framework
Loading...
Searching...
No Matches

◆ to_vk_descriptor_type()

vk::DescriptorType MayaFlux::Portal::Graphics::to_vk_descriptor_type ( DescriptorRole  role)
inline

Convert DescriptorRole to the corresponding vk::DescriptorType.

Definition at line 92 of file ShaderUtils.hpp.

93{
94 switch (role) {
95 case DescriptorRole::UNIFORM:
96 return vk::DescriptorType::eUniformBuffer;
97 case DescriptorRole::STORAGE:
98 return vk::DescriptorType::eStorageBuffer;
99 case DescriptorRole::TEXTURE:
100 return vk::DescriptorType::eCombinedImageSampler;
101 case DescriptorRole::STORAGE_IMAGE:
102 return vk::DescriptorType::eStorageImage;
103 }
104 return vk::DescriptorType::eStorageBuffer;
105}

References STORAGE, STORAGE_IMAGE, TEXTURE, and UNIFORM.