mesa: Factor out index function that will have multiple use.
authorMathias Fröhlich <mathias.froehlich@web.de>
Wed, 3 Apr 2019 10:33:37 +0000 (12:33 +0200)
committerMathias Fröhlich <mathias.froehlich@web.de>
Sat, 4 May 2019 05:39:18 +0000 (07:39 +0200)
commit60076a6171931b92dcdda53c2962666cc27fda2d
treeea203933c95925791f4e0a2ad36f7e19a09efcac
parent91899495a14568e9f23fa64d4bf4f5ef3f017fb9
mesa: Factor out index function that will have multiple use.

For access to glArrayElement methods factor out a function to
get the table lookup index for normalized/integer/double access.
The function will be used in the next patch at least twice.

v2: Use vertex_format_to_index instead of NORM_IDX.

Reviewed-by: Brian Paul <brianp@vmware.com>
Signed-off-by: Mathias Fröhlich <Mathias.Froehlich@web.de>
src/mesa/main/api_arrayelt.c