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

◆ to_vulkan_format()

vk::Format MayaFlux::Portal::Graphics::TextureLoom::to_vulkan_format ( ImageFormat  format)
static

Convert Portal ImageFormat to Vulkan format.

Definition at line 552 of file TextureLoom.cpp.

553{
554 switch (format) {
555 case ImageFormat::R8:
556 return vk::Format::eR8Unorm;
557 case ImageFormat::RG8:
558 return vk::Format::eR8G8Unorm;
560 return vk::Format::eR8G8B8Unorm;
562 return vk::Format::eR8G8B8A8Unorm;
565 return vk::Format::eB8G8R8A8Unorm;
567 return vk::Format::eB8G8R8A8Srgb;
568 return vk::Format::eR8G8B8A8Srgb;
569 case ImageFormat::R16:
570 return vk::Format::eR16Unorm;
572 return vk::Format::eR16G16Unorm;
574 return vk::Format::eR16G16B16A16Unorm;
576 return vk::Format::eR16Sfloat;
578 return vk::Format::eR16G16Sfloat;
580 return vk::Format::eR16G16B16A16Sfloat;
582 return vk::Format::eR32Sfloat;
584 return vk::Format::eR32G32Sfloat;
586 return vk::Format::eR32G32B32A32Sfloat;
588 return vk::Format::eD16Unorm;
590 return vk::Format::eX8D24UnormPack32;
592 return vk::Format::eD32Sfloat;
594 return vk::Format::eD24UnormS8Uint;
595 default:
596 return vk::Format::eR8G8B8A8Unorm;
597 }
598}
@ DEPTH24_STENCIL8
24-bit depth + 8-bit stencil
@ RG16
Two channel 16-bit unsigned integer.
@ BGRA8
8-bit BGRA unsigned normalized
@ RGBA16
Four channel 16-bit unsigned integer.
@ RGBA32F
Four channel 32-bit float.
@ R16F
Single channel 16-bit float.
@ R16
Single channel 16-bit unsigned integer.
@ RGBA16F
Four channel 16-bit float.
@ RG32F
Two channel 32-bit float.
@ R32F
Single channel 32-bit float.
@ RG16F
Two channel 16-bit float.
@ RGBA8_SRGB
Four channel 8-bit sRGB.

References MayaFlux::Portal::Graphics::BGRA8, MayaFlux::Portal::Graphics::BGRA8_SRGB, MayaFlux::Portal::Graphics::DEPTH16, MayaFlux::Portal::Graphics::DEPTH24, MayaFlux::Portal::Graphics::DEPTH24_STENCIL8, MayaFlux::Portal::Graphics::DEPTH32F, MayaFlux::Portal::Graphics::R16, MayaFlux::Portal::Graphics::R16F, MayaFlux::Portal::Graphics::R32F, MayaFlux::Portal::Graphics::R8, MayaFlux::Portal::Graphics::RG16, MayaFlux::Portal::Graphics::RG16F, MayaFlux::Portal::Graphics::RG32F, MayaFlux::Portal::Graphics::RG8, MayaFlux::Portal::Graphics::RGB8, MayaFlux::Portal::Graphics::RGBA16, MayaFlux::Portal::Graphics::RGBA16F, MayaFlux::Portal::Graphics::RGBA32F, MayaFlux::Portal::Graphics::RGBA8, and MayaFlux::Portal::Graphics::RGBA8_SRGB.

Referenced by create_2d(), create_2d_array(), create_3d(), create_cubemap(), create_render_target(), and create_storage_image().

+ Here is the caller graph for this function: