mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-12-14 07:36:15 +00:00
D3D12: Support per plane views with NV12 textures
Adds support for NV12 texture format and per plane view aspects. Only allows planar sampling of imported DX11 textures. See usage tests for examples and formats.h for rules. Bug: dawn:551 Change-Id: I44b89d2c07bb9969638e77ce7c756ef367167f0c Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/38781 Commit-Queue: Bryan Bernhart <bryan.bernhart@intel.com> Reviewed-by: Austin Eng <enga@chromium.org>
This commit is contained in:
committed by
Commit Bot service account
parent
185c6a5b0f
commit
14a2398e71
@@ -109,6 +109,10 @@ namespace utils {
|
||||
|
||||
case wgpu::TextureFormat::Depth24Plus:
|
||||
case wgpu::TextureFormat::Depth24PlusStencil8:
|
||||
|
||||
// Block size of a multi-planar format depends on aspect.
|
||||
case wgpu::TextureFormat::R8BG8Biplanar420Unorm:
|
||||
|
||||
case wgpu::TextureFormat::Undefined:
|
||||
UNREACHABLE();
|
||||
}
|
||||
@@ -173,6 +177,9 @@ namespace utils {
|
||||
case wgpu::TextureFormat::BC7RGBAUnormSrgb:
|
||||
return 4u;
|
||||
|
||||
// Block size of a multi-planar format depends on aspect.
|
||||
case wgpu::TextureFormat::R8BG8Biplanar420Unorm:
|
||||
|
||||
case wgpu::TextureFormat::Undefined:
|
||||
UNREACHABLE();
|
||||
}
|
||||
@@ -237,6 +244,9 @@ namespace utils {
|
||||
case wgpu::TextureFormat::BC7RGBAUnormSrgb:
|
||||
return 4u;
|
||||
|
||||
// Block size of a multi-planar format depends on aspect.
|
||||
case wgpu::TextureFormat::R8BG8Biplanar420Unorm:
|
||||
|
||||
case wgpu::TextureFormat::Undefined:
|
||||
UNREACHABLE();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user