问题
Is there a way, on 2017, to develop a DirectX application using either C# or Basic? I'm using Visual Studio 2017 with Framework 4.5.2 and I'm having a hard work trying to install/find the DirectX SDK references on Visual Studio.
Should I be using a dedicated IDE or am I doing something wrong? I don't even know if Microsoft is still supporting DirectX SDK for .NET.
I've spent like 4 hours scavenging Google but haven't been able to find anything that isn't from one or two years ago, so yeah. It's not like I'm not trying to find it by myself.
回答1:
The legacy DirectX SDK installs the "Managed DirectX 1.1" assemblies, which haven't been updated since ~2006. They were designed for .NET 1.1 and legacy Direct3D 9, so they kinda worked with .NET 2.0 - 3.5, but do not work with .NET 4.0 or later without hacks which is why they don't show up in VS 2017.
Your best option these days is to use SharpDX or SlimDX. If you are specifically interested in game development, you can also use MonoGame or commercial products like Unity3D.
See DirectX and .NET, Microsoft Docs, Where is the DirectX SDK (2015 Edition)?
来源:https://stackoverflow.com/questions/43961070/how-to-develop-directx-applications