microsoft / Windows.UI.Composition-Win32-Samples

Windows.UI.Composition Win32 Samples
MIT License
459 stars 186 forks source link

Remove dependency to SharpDX for the screen capture sample app #102

Closed fengfranklu closed 2 years ago

fengfranklu commented 2 years ago

Since SharpDX is no longer supported and is not compatible with Dotnet 6 and above, can we remove this dependency and use libraries like Vortice.Windows or Microsoft's own code. This way we can compile the code to DotNet 6 and beyond. I have a project that is heavily relied on this sample and it is now stuck at Dotnet core 3.0. I do not know how to migrate. The whole project is blocked by this dependency. Thanks for your help.

robmikh commented 2 years ago

Instead of using SharpDX for D3D bindings, you can use CsWin32. Or you could write a C++/WinRT component and call it from your C# application.

If you'd like an example, this repo went the CsWin32 route.

fengfranklu commented 2 years ago

Thank you very much for your help. I will look into the CsWin32 route. Thanks!!