Skip to content

Commit

Permalink
[dxvk] Add VK_FORMAT_G8_B8_R8_3PLANE_420_UNORM
Browse files Browse the repository at this point in the history
  • Loading branch information
K0bin authored and misyltoad committed Apr 8, 2023
1 parent d9a6b40 commit 31af522
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
9 changes: 8 additions & 1 deletion src/dxvk/dxvk_format.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -556,6 +556,13 @@ namespace dxvk {
// VK_FORMAT_A4B4G4R4_UNORM_PACK16
{ 2, RGBA, VK_IMAGE_ASPECT_COLOR_BIT },

// VK_FORMAT_G8_B8_R8_3PLANE_420_UNORM
{ 8, RGB, VK_IMAGE_ASPECT_PLANE_0_BIT | VK_IMAGE_ASPECT_PLANE_1_BIT | VK_IMAGE_ASPECT_PLANE_2_BIT,
DxvkFormatFlag::MultiPlane, VkExtent3D { 1, 1, 1 },
{ DxvkPlaneFormatInfo { 1, { 1, 1 } },
DxvkPlaneFormatInfo { 1, { 2, 2 } },
DxvkPlaneFormatInfo { 1, { 2, 2 } } } },

// VK_FORMAT_G8_B8R8_2PLANE_420_UNORM
{ 6, RGB, VK_IMAGE_ASPECT_PLANE_0_BIT | VK_IMAGE_ASPECT_PLANE_1_BIT,
DxvkFormatFlag::MultiPlane, VkExtent3D { 1, 1, 1 },
Expand All @@ -568,7 +575,7 @@ namespace dxvk {
{ VK_FORMAT_UNDEFINED, VK_FORMAT_BC7_SRGB_BLOCK },
{ VK_FORMAT_G8B8G8R8_422_UNORM_KHR, VK_FORMAT_B8G8R8G8_422_UNORM_KHR },
{ VK_FORMAT_A4R4G4B4_UNORM_PACK16, VK_FORMAT_A4B4G4R4_UNORM_PACK16 },
{ VK_FORMAT_G8_B8R8_2PLANE_420_UNORM, VK_FORMAT_G8_B8R8_2PLANE_420_UNORM },
{ VK_FORMAT_G8_B8_R8_3PLANE_420_UNORM, VK_FORMAT_G8_B8R8_2PLANE_420_UNORM },
}};


Expand Down
2 changes: 1 addition & 1 deletion src/dxvk/dxvk_format.h
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ namespace dxvk {
};

/// Number of formats defined in lookup table
constexpr size_t DxvkFormatCount = 152;
constexpr size_t DxvkFormatCount = 153;

/// Format lookup table
extern const std::array<DxvkFormatInfo, DxvkFormatCount> g_formatInfos;
Expand Down

0 comments on commit 31af522

Please sign in to comment.