screenshot layer format support is unclear, maybe broken
lunarpapillo opened this issue · 0 comments
This was found during SDK testing at: https://gitlab.khronos.org/vulkan/Vulkan-SDK-Packaging/-/issues/1426
The screenshot layer supports a Format parameter, as per: https://vulkan.lunarg.com/doc/sdk/1.3.275.0/windows/screenshot_layer.html
including:
UNORM
SNORM
USCALED
SSCALED
UINT
SINT
SRGB
USE_SWAPCHAIN_COLORSPACE
The talbe in the document is useless, repeating Enum Value and Label, having "N/A" as every Description, and claiming that all formats are supported on all platforms.
In reality, attempting to use some of the formats (in particular, UINT
and SINT
) provokes a cryptic warning message:
screenshot: incompatible output format requested, changing output format to VK_FORMAT_B8G8R8A8_UNORM
which is poor because the listed VK_FORMAT_B8G8R8A8_UNORM
is not one of the supported Format values. It seems there's some overloading of the term "format".
Worse, when this substitute format is actually used, the .ppm
file is incorrect. PPM requires colors to be specified in RGB order. The BGR order reverses the red and blue channels, changing the apparent colors, so this correct screenshot:
ends up being captured as:
I expect:
- the documentation to be useful
- information on "incompatible" formats is presented
- the term "format" is used consistently
- valid
.ppm
images are always created