Setting up DirectX 11 with Visual Studio 2010
2012-02-14 22:38
330 查看
开始动手了
In Visual Studio 2010 I used the following steps:
First you need to create an empty Win32 project so select File -> New -> Project. Then select Win32 project from the choices. Give the project a name (I called mine Engine) and a location and then click on "Ok". Click "Next" and you will be given another menu.
Under "Additional options" put a check mark in the "Empty project" box and click on "Finish" and then click "Next". You should now have an basic Win32 empty project setup.
Now click "View" from the menu and select "Property Manager".
Next click on the arrow to the left of your project name (mine was called Engine) in the property manager window on the left part of the screen. This will display the solution configurations you have.
Select the "Debug | Win32" folder and double click "Microsoft.Cpp.Win32.user".
In the window that pops up select "VC++ Directories" from the menu on the left side. This will then display the directories that the project uses.
Now select "Include Directories" from the directory list and click on the down arrow that appears to the left. From the choices it pops up choose "Edit".
Click on the folder icon at the top (called New Line if you mouse over it) and click on the "..." that appears to the right side.
Navigate to the DirectX SDK include folder, different versions are named differently but on my system it was: C:\Program Files (x86)\Microsoft DirectX SDK (June 2010)\Include
Next click on "Select Folder" and then click "Ok".
The libraries directory is also needed so now select "Library Directories" from the directory list and click on the down arrow that appears to the left. From the choices it pops up choose "Edit".
Click on the folder icon at the top (called New Line if you mouse over it) and click on the "..." that appears to the right side.
Navigate to the DirectX SDK library folder, different versions are named differently but on my system it was: C:\Program Files (x86)\Microsoft DirectX SDK (June 2010)\Lib\x86
Next click on "Select Folder" and then click "Ok".
Finally click on the "Apply" button in the bottom right of the Property Pages window.
Now click "Ok" to close the window and your settings will be complete. From the menu click "View" and then "Solution Explorer" to return to your code. All DirectX projects should now compile fine and the error of "Cannot open include file: 'd3d11.h': No such
file or directory" should disappear. Also note that these settings will automatically be applied to the Release | Win32 solution configuration so you don't need to set them there. As well it should be persistent permanently for all new projects and will never
need to be setup again.
In Visual Studio 2010 I used the following steps:
First you need to create an empty Win32 project so select File -> New -> Project. Then select Win32 project from the choices. Give the project a name (I called mine Engine) and a location and then click on "Ok". Click "Next" and you will be given another menu.
Under "Additional options" put a check mark in the "Empty project" box and click on "Finish" and then click "Next". You should now have an basic Win32 empty project setup.
Now click "View" from the menu and select "Property Manager".
Next click on the arrow to the left of your project name (mine was called Engine) in the property manager window on the left part of the screen. This will display the solution configurations you have.
Select the "Debug | Win32" folder and double click "Microsoft.Cpp.Win32.user".
In the window that pops up select "VC++ Directories" from the menu on the left side. This will then display the directories that the project uses.
Now select "Include Directories" from the directory list and click on the down arrow that appears to the left. From the choices it pops up choose "Edit".
Click on the folder icon at the top (called New Line if you mouse over it) and click on the "..." that appears to the right side.
Navigate to the DirectX SDK include folder, different versions are named differently but on my system it was: C:\Program Files (x86)\Microsoft DirectX SDK (June 2010)\Include
Next click on "Select Folder" and then click "Ok".
The libraries directory is also needed so now select "Library Directories" from the directory list and click on the down arrow that appears to the left. From the choices it pops up choose "Edit".
Click on the folder icon at the top (called New Line if you mouse over it) and click on the "..." that appears to the right side.
Navigate to the DirectX SDK library folder, different versions are named differently but on my system it was: C:\Program Files (x86)\Microsoft DirectX SDK (June 2010)\Lib\x86
Next click on "Select Folder" and then click "Ok".
Finally click on the "Apply" button in the bottom right of the Property Pages window.
Now click "Ok" to close the window and your settings will be complete. From the menu click "View" and then "Solution Explorer" to return to your code. All DirectX projects should now compile fine and the error of "Cannot open include file: 'd3d11.h': No such
file or directory" should disappear. Also note that these settings will automatically be applied to the Release | Win32 solution configuration so you don't need to set them there. As well it should be persistent permanently for all new projects and will never
need to be setup again.
相关文章推荐
- Setting up NUnit for C# Unit Testing with Visual Studio C# Express 2008
- Setting up and running Subversion and Tortoise SVN with Visual Studio and .NET
- OpenGL Tutorial: (1) Setting up OpenGL with Visual Studio
- Setting up and running Subversion and Tortoise SVN with Visual Studio and .NET
- SQL Schema Comparison with Visual Studio 2010
- Setting up Visual Studio 2012 for SharePoint 2013 development offline
- SQL Data Comparison with Visual Studio 2010
- GSL 1.15 and 1.16 building with Visual Studio 2010 --FROM 4fire
- Changing Project Binding to Surround SCM Integration Provider with Visual Studio 2010
- Setting up Visual Studio Debugger Visualizers
- OpenCV 2.1.0 with Visual Studio 2010(1)
- Using CUDA and Thrust with Visual Studio 2010
- Sharing a C++ solution between Visual Studio 2010 and 11
- How to set up github to work with Visual Studio 2013
- OpenCV 2.1.0 with Visual Studio 2010(2)
- Coding Faster-Getting More Productive with Microsoft Visual Studio: Covers Microsoft Visual Studio 2005, 2008, and 2010
- Building Python 2.7.10 with Visual Studio 2010 or 2015 - Google Chrome
- Debugging DirectX 11 shaders with Visual Studio
- Debugging DirectX 11 shaders with Visual Studio
- Using Code Analysis with Visual Studio 2010 to Improve Code Quality