DirectX Graphics Development with Visual Studio 2012

Visual Studio 2012 includes several new features for developing and debugging applications that use DirectX.  Here are links to references and resources so you can get started with these new features. 

Getting Started

You can write and build apps that use DirectX with Visual Studio Express 2012 for Windows 8 or Visual Studio Express 2012 for Windows Desktop, or any of the retail versions of Visual Studio 2012 (Professional, Premium, and Ultimate).  You also don’t need a separate DirectX SDK download – the DirectX SDK is now part of the Windows SDK, and the Windows 8 SDK is included in Visual Studio 2012. 

You do need a retail version of Visual Studio 2012 to use the Visual Studio Graphics Debugging and Graphics Asset tools described later in this post.

If you have projects that were using the DirectX SDK, check out “Where is the DirectX SDK?” to learn how to use these projects with Visual Studio 2012.

Samples

There are many DirectX samples on the MSDN Samples Gallery, for both Windows Store and desktop apps.  You can also search for and download samples directly from the New Project window in Visual Studio 2012.

Also check out the Visual Studio 3D Starter Kit sample, which is a great way to get started with the basic steps of creating games such as loading textures and models, working with a camera and 3D scene, and using XAML and DirectX together.

Resources for using DirectX in Windows Store Apps

Not only does Visual Studio include the same DirectX support for the new Windows Store apps as it does for desktop apps, you can also combine XAML and DirectX in the same Windows Store app.

Compiling and using HLSL files

Visual Studio now includes support for HLSL files in the IDE, including syntax coloring, indenting, and outlining.  We also support using the HLSL compiler (FXC.exe) with MSBuild so you can easily compile your HLSL files into .cso (compiled shader output) format.  You can configure the compiler settings on a per-file basis through Property Pages.

Visual Studio DirectX Graphics Diagnostics

The DirectX Graphics Diagnostics tools help you diagnose and debug DirectX rendering issues by analyzing frames captured into a log file.  These tools integrate some of the functionality from the PIX for Windows tool that was part of the DirectX SDK.  To debug apps running on tablets or other devices which don’t have Visual Studio installed, you can capture frames programmatically and then open the logs in Visual Studio to debug after the fact.

Tools for Graphics Assets

As a developer, wouldn’t it be great to look at graphics assets such as textures or 3D models without needing to compile them into your game or app and run it?  Or to see the textures or models while you’re using the Graphics Diagnostics tools to visually understand what’s being (or not being) rendered?  Visual Studio 2012 includes tools that allow you to view graphics assets directly from the IDE.  You can also use the Shader Designer to create shaders using a visual tool, so you can visualize what the shader will do as you’re designing it.

Videos

Feedback

We would love to hear from you about the graphics tools in Visual Studio!  To report bugs, please use the Visual Studio Connect site.  The Visual Studio UserVoice site is the best place to submit suggestions and ideas for future releases.

Still more that you want to know?  Leave us feedback in the comments.

Updates

12 Nov 2012:  Added links to the Visual Studio 3D Starter Kit (download and Channel 9 video) and Build 2012 video.