Skip to content

Commit

Permalink
treat NV12's block size as (2, 2)
Browse files Browse the repository at this point in the history
  • Loading branch information
xiaopengli89 committed Nov 20, 2023
1 parent 1a3c902 commit e74be69
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions wgpu-types/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2334,7 +2334,7 @@ pub enum TextureFormat {
/// - 1: Dual 8 bit channel chrominance at half width and half height.
///
/// Valid view formats for luminance are [`TextureFormat::R8Unorm`] and [`TextureFormat::R8Uint`].
///
///
/// Valid view formats for chrominance are [`TextureFormat::Rg8Unorm`] and [`TextureFormat::Rg8Uint`].
///
/// Width and height must be even.
Expand Down Expand Up @@ -2892,8 +2892,9 @@ impl TextureFormat {
| Self::Depth24Plus
| Self::Depth24PlusStencil8
| Self::Depth32Float
| Self::Depth32FloatStencil8
| Self::NV12 => (1, 1),
| Self::Depth32FloatStencil8 => (1, 1),

Self::NV12 => (2, 2),

Self::Bc1RgbaUnorm
| Self::Bc1RgbaUnormSrgb
Expand Down

0 comments on commit e74be69

Please sign in to comment.