mirror of
https://github.com/EduApps-CDG/OpenDX
synced 2024-12-30 09:45:37 +01:00
[d3d11] Use clearBuffer to initialize UAV counters
This commit is contained in:
parent
7fa26f1c87
commit
a148233b13
@ -2814,14 +2814,13 @@ namespace dxvk {
|
|||||||
const DxvkBufferSlice counterSlice = uav->GetCounterSlice();
|
const DxvkBufferSlice counterSlice = uav->GetCounterSlice();
|
||||||
const D3D11UavCounter counterValue = { pUAVInitialCounts[i] };
|
const D3D11UavCounter counterValue = { pUAVInitialCounts[i] };
|
||||||
|
|
||||||
if (counterSlice.defined()
|
if (counterSlice.defined() && counterValue.atomicCtr != 0xFFFFFFFFu) {
|
||||||
&& counterValue.atomicCtr != 0xFFFFFFFFu) {
|
|
||||||
EmitCs([counterSlice, counterValue] (DxvkContext* ctx) {
|
EmitCs([counterSlice, counterValue] (DxvkContext* ctx) {
|
||||||
ctx->updateBuffer(
|
ctx->clearBuffer(
|
||||||
counterSlice.buffer(),
|
counterSlice.buffer(),
|
||||||
counterSlice.offset(),
|
counterSlice.offset(),
|
||||||
counterSlice.length(),
|
counterSlice.length(),
|
||||||
&counterValue);
|
counterValue.atomicCtr);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user