Allow SetBindGroup command to be skipped with dynamic offsets.

Fixes a bug where SetBindGroup command would fail to be skipped.

BUG=dawn:256

Change-Id: I9815c9d31aa88f6881274a1873cabe17379cc2e0
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/13800
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Bryan Bernhart <bryan.bernhart@intel.com>
This commit is contained in:
Bryan Bernhart 2019-11-18 23:09:38 +00:00 committed by Commit Bot service account
parent d0c07f112e
commit 9c81f8738a

View File

@ -254,9 +254,12 @@ namespace dawn_native {
commands->NextCommand<SetBlendColorCmd>();
break;
case Command::SetBindGroup:
commands->NextCommand<SetBindGroupCmd>();
break;
case Command::SetBindGroup: {
SetBindGroupCmd* cmd = commands->NextCommand<SetBindGroupCmd>();
if (cmd->dynamicOffsetCount > 0) {
commands->NextData<uint32_t>(cmd->dynamicOffsetCount);
}
} break;
case Command::SetIndexBuffer:
commands->NextCommand<SetIndexBufferCmd>();