Implement 'baseVertex' in drawIndexed() on D3D12, Metal and Vulkan

This patch adds the support of the parameter 'baseVertex' of drawIndexed
on D3D12, Metal and Vulkan back-ends.

BUG=dawn:51
TEST=dawn_end2end_tests

Change-Id: Ibd25884ad2abceaaed744d74c4ee6b0ae6b3fa1b
Reviewed-on: https://dawn-review.googlesource.com/c/3221
Commit-Queue: Jiawei Shao <jiawei.shao@intel.com>
Reviewed-by: Kai Ninomiya <kainino@chromium.org>
This commit is contained in:
Jiawei Shao
2018-12-13 01:05:26 +00:00
committed by Commit Bot service account
parent 8d08d23a66
commit ff9562f792
13 changed files with 57 additions and 29 deletions

View File

@@ -164,7 +164,7 @@ void frame() {
pass.SetBindGroup(0, bindGroup);
pass.SetVertexBuffers(0, 1, &vertexBuffer, vertexBufferOffsets);
pass.SetIndexBuffer(indexBuffer, 0);
pass.DrawIndexed(3, 1, 0, 0);
pass.DrawIndexed(3, 1, 0, 0, 0);
pass.EndPass();
}