Hi everyone,
I’m currently working on a multi-machine synchronization setup using NVIDIA Sync cards, and I need some clarification regarding the differences and capabilities of Swap Groups, Swap Barriers, and Present Barriers in DirectX 11 and DirectX 12.
Here’s what I understand so far:
Swap Group & Swap Barrier (DX11):
- In DirectX 11, it’s possible to join a swap group, and then bind a swap barrier.
- This seems to ensure that the swap chains present frames simultaneously, but it doesn’t seem to block machines if one takes significantly longer to render a frame.
- Question: Is this behavior correct, is using the
NvAPI_DX1x_Present
any different than using the normalPresent
of DX11? So, do Swap Barriers in DX11 synchronize the display refresh but don’t enforce frame-by-frame blocking? Even if the “Blocking” parameter is set to true? Or is 0.5 sec too long? Will it only block for a few frames and then ignore the hanging machine?
Present Barrier (DX12):
- The Present Barrier is only available in DirectX 12, and from what I’ve gathered, it might ensure that all machines block until every participant submits its frame. This would guarantee perfect frame lock even if one machine takes longer to render.
- Question: Is it correct that Present Barriers enforce stricter synchronization compared to Swap Barriers in DX11? What is the difference between the Swap Barrier and Present Barrier and how should they be used?
Expected Behavior During Frame Freezes:
- In some tests, when simulating a 0.5-second freeze on a client or server in DX11, only the machine with the freeze was affected, while others continued to present frames.
- The frame counter seemed to be hardware-based and continued updating on all machines.
- Question: Does this mean that DX11 Swap Barriers don’t enforce blocking synchronization even if the “Blocking” parameter is set to true? Or is there any timeout when using swap barriers and/or present barriers?