Overview of Direct3D 12 on Xbox One

Direct3D 12 on Xbox One provides a low-level, high-performance API similar to Direct3D 12 on PC. Direct3D 12.x is tailored for the ultimate console graphics performance for both CPU and GPU.

Xbox extensions to D3D12 have been added to the XDK Approved Library (the first being the June 2015 release) that titles can ship on. See the Developer Roadmap.

Documentation for D3D12

The API is the same for Direct3D 12 on Xbox One (D3D12.x) and Direct3D 12 on PC (D3D12 on PC), except for the Xbox One extensions.

Accessing the Direct3D 12 SDK

If you need access to the D3D12 on PC SDK, contact your DAM.

Samples that use D3D12 on Xbox One

Some samples have been updated to be compatible with D3D12.x, and some samples were created for D3D12.x. In Graphics Samples, find “D3D12”.

To download the latest version of a sample, see the Samples webpage at XGD.

To compile and run the D3D12.x version of a sample, in the Solution Configuration drop-down menu, select an option that contains “12”, such as Debug12.

For the list of more XDK graphics samples, see Graphics Samples.

Header Files

The header file for D3D12.x is d3d12_x.h. The default location of this header file is C:\Program Files (x86)\Microsoft Durango XDK\xdk\Include\um\d3d12_x.h. This header file contains almost exactly the same set of API items as the desktop header d3d12.h, but some API items are not implemented yet for Xbox One.

Return values for D3D12.x methods

In most cases, if a method is declared in d3d12_x.h, and returns an HRESULT, but the method isn’t yet supported on Xbox One, the method returns the error code E_NOTIMPL, meaning “Not Implemented”.

Some non-implemented methods that return an HRESULT return S_OK instead of E_NOTIMPL because the method will never do anything on Xbox One; the method is effectively a no-op.

Some non-implemented methods that return an HRESULT return S_OK instead of E_NOTIMPL because a sample calls the method but the sample doesn’t actually rely on the method. For example, the SimpleCompute sample has options for both asynchronous and synchronous compute operation. This sample runs synchronous by default, but has initialization code which calls async compute and would trigger a premature exit if the non-implemented method returned E_NOTIMPL.

DirectX Tool Kit utility libraries

The  DirectX Tool Kit for DirectX 11 and DirectX 12 are utility libraries to simplify programming DirectX. Extensive use of them is made in the samples for UWP and the XDK. The design is intended to be general Direct3D 11 or Direct3D 12 as much as possible, only using Xbox One specifics where necessary for platform support. To avoid a forking overhead, the one codebase supports PC, UWP, and Xbox One XDK. This codebase is published to GitHub as a Microsoft organizational project:

There are test suites for these libraries:

There are some points to note when using these libraries:

See also

Direct3D 12 Xbox One Reference

Differences Between Direct3D 12 on a Windows PC and Xbox One

Direct3D 12 Reference