diff options
author | Marek Olšák <[email protected]> | 2020-02-12 18:02:24 -0500 |
---|---|---|
committer | Marek Olšák <[email protected]> | 2020-03-04 19:54:42 -0500 |
commit | 87085c673d593e6332ca2f3fb6737b77f7087f66 (patch) | |
tree | c54fb454a368b7c309e5f6266ee23a16a66ff57f /src/mesa/main/draw.h | |
parent | f38ffa4659aa985f5d1c78bdd5be5064b792b819 (diff) |
mesa: add index_size_shift = log2(index_size) into _mesa_index_buffer
for faster division
Reviewed-by: Pierre-Eric Pelloux-Prayer <[email protected]>
Reviewed-by: Ian Romanick <[email protected]>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4052>
Diffstat (limited to 'src/mesa/main/draw.h')
-rw-r--r-- | src/mesa/main/draw.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mesa/main/draw.h b/src/mesa/main/draw.h index 3a7dedea529..bf9a9ca06b0 100644 --- a/src/mesa/main/draw.h +++ b/src/mesa/main/draw.h @@ -71,7 +71,8 @@ struct _mesa_prim struct _mesa_index_buffer { GLuint count; - unsigned index_size; + uint8_t index_size; + uint8_t index_size_shift; /* logbase2(index_size) */ struct gl_buffer_object *obj; const void *ptr; }; |