iris: IndexFormat = size/2
authorChris Wilson <chris@chris-wilson.co.uk>
Fri, 8 Jun 2018 21:16:59 +0000 (22:16 +0100)
committerKenneth Graunke <kenneth@whitecape.org>
Thu, 21 Feb 2019 18:26:06 +0000 (10:26 -0800)
brw uses:
  IndexFormat = index_size >> 1

anv uses:
  IndexFromat = index_type[index_size]

src/gallium/drivers/iris/iris_state.c

index dcf5c62f9a8ef556d02b3aa48ca6ca7654d6cc7e..0f420d1d566abf0c0294ffde4493b60e81194722 100644 (file)
@@ -2511,7 +2511,7 @@ iris_upload_render_state(struct iris_context *ice,
       assert(!draw->has_user_indices);
 
       iris_emit_cmd(batch, GENX(3DSTATE_INDEX_BUFFER), ib) {
-         ib.IndexFormat = draw->index_size;
+         ib.IndexFormat = draw->index_size >> 1;
          ib.MOCS = MOCS_WB;
          ib.BufferSize = res->bo->size;
          ib.BufferStartingAddress = ro_bo(res->bo, 0);