[Mesa-dev] [PATCH 1/3] vbo: move vbo_draw_method into vbo_context.h
Mathias Fröhlich
Mathias.Froehlich at gmx.net
Mon May 7 22:19:55 PDT 2012
Hi,
On Tuesday, May 08, 2012 01:12:51 Marek Olšák wrote:
> AFAIK the "Enabled" flags aren't very useful in determining the final
> number of vertex elements, because if an array is not enabled, the
> corresponding zero-stride "current" attrib is used instead. So the
> quick check would depend solely on vertex shader inputs. If your
> definition of "enabled array" is that it's just used by the vertex
> shader, then sorry for stating the obvious. ;)
May be not in the current code, but the _mesa_array_object_get_enabled_*
bitmask tricks show how you can immediatly (with an O(1) bitmask operation -
no O(33) loop) see even for different aliasing situations which arrays are
enabled.
If you combine this by bit operations with the enabled shader inputs bitmask
you can update the array state incrementally using ffs based loops only doing
work on very few of the 33 client arrays.
Sigh, I hope to find some time to distil the proof of concept stuff into
something usable ...
Greetings
Mathias
More information about the mesa-dev
mailing list