Open xen2 opened 5 years ago
You can find the MonoGame related issue here: https://github.com/MonoGame/MonoGame/issues/6691
Highlights:
@cra0zy thanks for bringing attention to my bindings, as I said I try to keep API similar to native one and less allocation/faster bindins, it AIM to use modern .NET stuff like Unsafe, Numerics.Vectors etc, its built arround my math library (https://github.com/amerkoleci/Vortice.Mathematics) and the AIM is to use it even in my Vulkan bindings in the future.
There is no D3D9, D3D10 bindings or DirectInput, XAudio etc at the moment. DXR is supported using D3D12.
Feel free to ask if you have any question.
Just to keep you updated, last version (https://github.com/amerkoleci/Vortice.Windows/commit/8428bf45224b1222341c3cd0cf0ce451fda2033a) adds DXR raytracing, D3D12 render passes and variable rate shading support.
Would Veldrid be able to replace this? IDK if Stride uses SharpDX for more than just graphics.
Veldrid abstracts different graphics back ends. It uses SharpDX itself to call DirectX methods. It seems to me the point of this issue is to find a supported replacement for SharpDX. Veldrid is not that.
Looks like @amerkoleci 's project supports d3d9 now, we should probably move forward with his project then ? It doesn't support d3d10 but would loosing that be such a big deal ? @xen2
I didn't realize that Veldrid uses SharpDX. You're right then. That defeats the purpose.
@amerkoleci Cool, nice progress! Switching API is lot of work and it requires some investigation, which is why it wasn't started (yet). Also, it was not something that needed to be done urgently (it seems nobody offered help on it or needed one of the new features yet).
Just a few comments concerning Stride:
We'll need to double-check if current public API could use Vortice as-is (does it contain everything currently used? also need to review functions/overloads, i.e. the ones taking arrays: we want to avoid unnecessary boxing/allocation due to interop so we need to make sure there are proper overloads taking memory pointers directly).
Ideally, I was hoping to find a low-level binding where D3D COM objects would be stored in structs rather than class (avoid extra indirection/objects and keep things as close to D3D API as possible). For Stride the D3D layer is not user-facing so we want it as lean as possible rather than user-friendly. Note: that's just a preference, I am fine to move to a new solution even if this is not available.
Curious, it seems to work on UWP, has it ever been tested on Xbox One?
@Eideren We only use D3D11 API. We then use D3D9/10 feature levels when creating device (which are available inside the D3D11 API) to support less capable GPUs.
@xen2 i try to keep it more to native directx11 or directx12 api than SharpDX, and if you need any overload or faster API call please tell me and I will add it for sure, still replacing is small amount of time.
About UWP, yes, there is a game engine using it in UWP with editor as well environment https://github.com/Aminator/DirectX12GameEngine
SharpDX is now discontinued (RIP and thanks @xoofx and other contributors for the huge effort!)
It might be good to consider our options for the future.
In an ideal world with enough resources, it would be great to:
Xenko.Graphics
objects, so having two "layers" of wrapping/indirection is not necessary.calli
more easily (cf https://github.com/dotnet/csharplang/blob/master/proposals/static-delegates.md)