Skip to content
This repository was archived by the owner on Mar 30, 2019. It is now read-only.
This repository was archived by the owner on Mar 30, 2019. It is now read-only.

[Direct3D12][UWP] #667

@zerppa

Description

@zerppa

The .NET native tool chain for UWP apps cannot handle D3D12, it seems.

  1. Create a new project, of type "Blank App (Universal Windows)", C#
  2. Add the NuGet package "SharpDX.Direct3D12" (3.0.0-beta01) to the project
  3. Rebuild project as Debug. This will succeed, and the app can be run
  4. Switch to Release mode, then rebuild again
  5. The compilation will fail with the following output:
1>  Starting .NET Native compilation
1>  Processing application code
1>  Computing application closure and generating interop code
1>C:\Program Files (x86)\MSBuild\Microsoft\.NetNative\x64\ilc\IlcInternals.targets(886,5): warning :           Unresolved P/Invoke method 'D3D12GetDebugInterface_!d3d12.dll' in assembly 'SharpDX.Direct3D12, Version=3.0.0.0, Culture=neutral, PublicKeyToken=b4dcf0f35e5521f1' because it is not available in UWP applications. Please either use an another API , or use [DllImport(ExactSpelling=true) to indicate that you understand the implications of using non-UWP application APIs.
1>  Generating serialization code
1>  Compiling interop code
1>  Cleaning up unreferenced code
1>  Generating native code
1>C:\Program Files (x86)\MSBuild\Microsoft\.NetNative\x64\ilc\IlcInternals.targets(1231,5): error : Error: NUTC300D:Internal Compiler Error: Type '$81_SharpDX.Direct3D12.RootSignatureDescription' is not valid for use outside of the managed environment, but is passed to native code while compiling method 'instance $81_SharpDX.Direct3D12.RootSignatureDescription $81_SharpDX.Direct3D12.RootSignatureDeserializer.GetRootSignatureDescription()'.
1>C:\Program Files (x86)\MSBuild\Microsoft\.NetNative\x64\ilc\IlcInternals.targets(1231,5): error : ILT0005: 'C:\Program Files (x86)\MSBuild\Microsoft\.NetNative\x64\ilc\Tools\nutc_driver.exe @"c:\users\zero\documents\visual studio 2015\Projects\D12Test\D12Test\obj\x64\Release\ilc\intermediate\nutcargs.rsp"' returned exit code 1

It does not make a difference whether x86 or x64. I have no problems with D3D11. I do have the latest UWP tools 1.1.1 update installed.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions