d3d11: fix indirect indexed draw
Bug: dawn:1791 Change-Id: If2fe2df3fdd5d719070e07afd1d7c7b68b42e1ee Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/131801 Kokoro: Kokoro <noreply+kokoro@google.com> Commit-Queue: Peng Huang <penghuang@chromium.org> Reviewed-by: Austin Eng <enga@chromium.org>
This commit is contained in:
parent
2ab0ee01f9
commit
3ee4f6af41
|
@ -171,13 +171,12 @@ MaybeError BindGroupTracker::ApplyBindGroup(BindGroupIndex index) {
|
||||||
case kInternalStorageBufferBinding: {
|
case kInternalStorageBufferBinding: {
|
||||||
ASSERT(IsSubset(bindingInfo.visibility, wgpu::ShaderStage::Compute));
|
ASSERT(IsSubset(bindingInfo.visibility, wgpu::ShaderStage::Compute));
|
||||||
ComPtr<ID3D11UnorderedAccessView> d3d11UAV;
|
ComPtr<ID3D11UnorderedAccessView> d3d11UAV;
|
||||||
DAWN_TRY_ASSIGN(d3d11UAV, ToBackend(binding.buffer)
|
DAWN_TRY_ASSIGN(
|
||||||
->CreateD3D11UnorderedAccessView1(
|
d3d11UAV, ToBackend(binding.buffer)
|
||||||
0, binding.buffer->GetSize()));
|
->CreateD3D11UnorderedAccessView1(offset, binding.size));
|
||||||
UINT firstElement = offset / 4;
|
|
||||||
if (bindingInfo.visibility & wgpu::ShaderStage::Compute) {
|
if (bindingInfo.visibility & wgpu::ShaderStage::Compute) {
|
||||||
deviceContext1->CSSetUnorderedAccessViews(
|
deviceContext1->CSSetUnorderedAccessViews(
|
||||||
bindingSlot, 1, d3d11UAV.GetAddressOf(), &firstElement);
|
bindingSlot, 1, d3d11UAV.GetAddressOf(), nullptr);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
|
@ -303,9 +303,6 @@ TEST_P(DrawIndexedIndirectTest, ValidateMultipleDraws) {
|
||||||
// TODO(dawn:1549) Fails on Qualcomm-based Android devices.
|
// TODO(dawn:1549) Fails on Qualcomm-based Android devices.
|
||||||
DAWN_SUPPRESS_TEST_IF(IsAndroid() && IsQualcomm());
|
DAWN_SUPPRESS_TEST_IF(IsAndroid() && IsQualcomm());
|
||||||
|
|
||||||
// TODO(dawn:1791): Test fails with D3D11.
|
|
||||||
DAWN_SUPPRESS_TEST_IF(IsD3D11());
|
|
||||||
|
|
||||||
// It doesn't make sense to test invalid inputs when validation is disabled.
|
// It doesn't make sense to test invalid inputs when validation is disabled.
|
||||||
DAWN_SUPPRESS_TEST_IF(HasToggleEnabled("skip_validation"));
|
DAWN_SUPPRESS_TEST_IF(HasToggleEnabled("skip_validation"));
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue