Defined in pyglet.graphics.vertexdomain
create_attribute_usage
(format)¶Create an attribute and usage pair from a format string. The format string is as documented in pyglet.graphics.vertexattribute, with the addition of an optional usage component:
usage ::= attribute ( '/' ('static' | 'dynamic' | 'stream' | 'none') )?
If the usage is not given it defaults to ‘dynamic’. The usage corresponds
to the OpenGL VBO usage hint, and for static
also indicates a
preference for interleaved arrays. If none
is specified a buffer
object is not created, and vertex data is stored in system memory.
Some examples:
v3f/stream
c4b/static
Returns: | attribute, usage |
---|