doitsujin / dxvk

Vulkan-based implementation of D3D8, 9, 10 and 11 for Linux / Wine
zlib License
13.19k stars 851 forks source link

Train Simulator Classic uses D3D9on12 #3445

Closed gatecat closed 1 year ago

gatecat commented 1 year ago

I'm trying to run the new DX12 Version of Train Simulator Classic under DXVK/Proton. It fails because ordinal 20 of d3d9.dll is not implemented, which after some research corresponds to Direct3DCreate9On12.

Software information

Log: steam-24010.log

gatecat commented 1 year ago

Sorry, didn't spot that DXVK doesn't support DX12 at all!

mbriar commented 1 year ago

DXVK still supports the d3d11on12 interop together with vkd3d-proton, so it might still be relevant (although I don't know if there is any interest to support this).

gatecat commented 1 year ago

Oh, that's interesting to know - I thought they were separate projects and integration would be very difficult.

K0bin commented 1 year ago

So their understanding of a D3D12 version is to slap Microsofts D3D9on12 on it.

That's a translation layer similar to DXVK except that it translates D3D9 to D3D12 instead of Vulkan. It's also very slow. Last time I tried it, it was running at 1/3 the speed of DXVK.

So I really don't get what the Train Simulator devs are trying to achieve with this. Because it's definitely not gonna be faster on Windows.

Blisto91 commented 1 year ago

I thought they were separate projects and integration would be very difficult.

They are different enough that it makes sense for separate repos, but they share some implementations like 11on12. Main dxvk dev also helps working on vkd3d-proton.

Anyway if it's to be supported it has to be implemented in both projects so it's legit to open a issue here.

K0bin commented 1 year ago

@Blisto91 I think VKD3D-Proton already has everything we would need.

gatecat commented 1 year ago

In the end, at least for TSC at the moment, this isn't actually needed as the DX12 version is literally just using 9on12 - as far as I can tell, running the DX12 version with Direct3DCreate9On12 behaving like Direct3DCreate9 and no other changes rins just the same as the usual DX9 version; so it's not actually mixing 9 and 12 in any way.

Of course, maybe this is still useful for something else in the future.

K0bin commented 1 year ago

Yup, I agree.

I don't plan to implement this atm but I'll keep the issue open in case I change my mind.

doitsujin commented 1 year ago

Is there even any public documentation for this, including GUIDs for the interop interfaces?