Prerequisites and Setup

What to install before writing a line of DX12 code: Visual Studio, the right workloads, and the Windows SDK. CMake comes later — it's not needed until we refactor the project structure.

Early Draft Work in progress — GitHub links coming soon.

Before we write any code, we need a working C++ toolchain and the Windows SDK. This article walks through exactly what to install and why. If you already have Visual Studio 2022 set up for Windows development, skim the checklist at the bottom and move on.

Hardware and OS Requirements

Visual Studio 2022

Visual Studio is the standard toolchain for Windows-native C++ development. The free Community edition is fully sufficient for this series.

Download it from the official Visual Studio site. During installation, the Workloads tab is where the important choices are made.

Required Workload: Desktop development with C++

Select Desktop development with C++. This single workload pulls in everything needed:

The Windows SDK bundled with this workload includes d3d12.h, dxgi.h, and the d3d12.lib / dxgi.lib import libraries. You do not need to download the SDK separately unless you want a version newer than what Visual Studio bundles.

Checking What You Have

If you already have Visual Studio installed and are unsure which components are present, open the Visual Studio Installer from the Start menu, click Modify on your existing installation, and verify that “Desktop development with C++” is checked under Workloads.

You can also confirm the SDK version from inside Visual Studio: open any C++ project, right-click the project in Solution Explorer, go to Properties → General, and check the Windows SDK Version dropdown. Any 10.0.x SDK from 10.0.19041 onward is fine for this series.

Confirming the Compiler

Once Visual Studio is installed, open a Developer Command Prompt for VS 2022 (search for it in the Start menu) and run:

cl

You should see output like:

Microsoft (R) C/C++ Optimizing Compiler Version 19.xx.xxxxx
Copyright (C) Microsoft Corporation. All rights reserved.

If that works, MSVC is on your path and ready to use.

What You Do Not Need Yet

CMake

CMake is a cross-platform build system generator that we will use later in this series — but not right away. The first few chapters use a plain Visual Studio project so the focus stays on Win32 and DX12 rather than build infrastructure. CMake enters the picture after we have the window working and start organizing the project into multiple files.

If you want to install it now, you can grab it from cmake.org. The minimum version needed later is 3.21. But there is no reason to pause here waiting for it — we will walk through the setup step by step when we actually need it.

Git

Useful for following along with the source snapshots at the end of each chapter, but not required.

PIX, Nsight, or other GPU debuggers

These are GPU debugging and profiling tools. We will mention them when they become useful, but you absolutely do not need them to follow the early chapters.

Quick Checklist

Before moving on, verify:

That’s everything. The next chapter covers the shape of a Win32 application — the entry point, message loop, and window procedure — before we write any code.