Skip to content

ConvertToSinglePlane

Chuck Walbourn edited this page Jan 21, 2022 · 5 revisions
DirectXTex

Converts a planar image (such as 4:2:0 or 4:1:1 video format) to a non-planar format (typically 4:2:2 for video formats). Planar formats are not supported by other texture functions, so this routine can be used to convert planar data to a form that other functions will operate on.

HRESULT ConvertToSinglePlane(
    const Image& srcImage,
    ScratchImage& image );

HRESULT ConvertToSinglePlane(
    const Image* srcImages, size_t nimages,
    const TexMetadata& metadata,
    ScratchImage& image );

Remarks

The pixel format of the resulting image is determined by the format of the input. For example NV11 and NV12 are always converted to YUY2.

Recommended 8-Bit YUV Formats for Video Rendering
10-bit and 16-bit YUV Video Formats

For Use

  • Universal Windows Platform apps
  • Windows desktop apps
  • Windows 11
  • Windows 10
  • Windows 8.1
  • Xbox One
  • Xbox Series X|S
  • Windows Subsystem for Linux

Architecture

  • x86
  • x64
  • ARM64

For Development

  • Visual Studio 2022
  • Visual Studio 2019 (16.11)
  • clang/LLVM v12 - v18
  • GCC 10.5, 11.4, 12.3
  • MinGW 12.2, 13.2
  • CMake 3.20

Related Projects

DirectXTex Rust bindings

DirectX Tool Kit for DirectX 11

DirectX Tool Kit for DirectX 12

DirectXMesh

DirectXMath

Tools

Test Suite

Content Exporter

DxCapsViewer

See also

DirectX Landing Page

Clone this wiki locally