Closed SelfishOlex closed 1 year ago
Note, the switch can be done from a command line: -rhi=vulkan
or -rhi=dx12
Can you attach output log after enabling device validation? It may provide further leads as to where the issue maybe.
Can you attach output log after enabling device validation? It may provide further leads as to where the issue maybe.
@moudgils Done.
Thank you, I will try to reproduce it and see if we can do something.
Took a quick look at the particle effect issue. The problem is with the vertex data for the particle effect in questions. For Vulkan it looks messed up. Vk is to the left and dx12 is to the right. If I had to take a guess its the maybe the sim code didnt update the gpu memory correctly.
@ValPKFX Any updates here?
FYI We just made o3de-multiplayer-sample, and o3de-multiplayersample-assets all public. If you build latest MPS (would recommend using the stabilization/2305 branches), you can see this just in the Editor viewport without needing to run actual game. Impacts several VFXs in this project.
Can provide videos, logs etc if that will help.
Hi, thanks for reporting the issue. Val is out this week unfortunately, I'll try to take a look. GPU Buffers fill logic isn't API dependent in the plugin / PopcornFX runtime, things that come to mind to double check:
Resolved on development branch, commit id 92ea37adb2ad0ee94d4bfd3d4ea2dbbd0220094f
Also fixed in upcoming PopcornFX v2.15.5
Thanks for reporting the issue
Issue came from Atom RHI difference between D3D12 and Vulkan. For Ribbon particles, we were incorrectly doing the vertex input positions setup (via AZ::RHI::InputStreamLayoutBuilder
):
// Before:
layoutBuilder.AddBuffer()->Channel("POSITION", AZ::RHI::Format::R32G32B32_FLOAT);
// After:
layoutBuilder.AddBuffer()->Channel("POSITION", AZ::RHI::Format::R32G32B32A32_FLOAT);
This second parameter is ignored in D3D12 Atom/RHI, as vertex buffer stride is specifed when IASetVertexBuffers
is called.
In Vulkan byte stride is specified when the graphics pipeline is created, ignoring the RHI::StreamBufferView
infos.
Additional debug asserts in Atom or errors could help quickly identify such issues
Was there a PR for this issue?
There was no PR, it's the commit 92ea37adb2ad0ee94d4bfd3d4ea2dbbd0220094f
A ribbon trail particle looks fine with DX12 Atom:
However, the same level and the same particle effect looks wrong with a Vulkan renderer:
For reference the effect is "Straight_Shot_Effect.pkfx" and I'm attacking a zip of the PopcornFX project. PopcornFX.zip
'-rhi=vulkan -rhi-device-validation=enable': Game_vulkan.log
'-rhi=dx12 -rhi-device-validation=enable': Game_dx12.log