picogl.gpu.buffers.attributes
Attribute and layout specification handling module.
This module defines data structures for specifying attributes and layout descriptors in a graphical or geometrical context. These structures are used to describe how data is stored, accessed, and organized for rendering or processing purposes.
Classes
Attribute specification. |
|
Layout descriptor. |
|
Canonical Vertex Attrs |
|
VBO Attrs |
Functions
|
Build an AttributeSpec with aligned legacy role, vbo_type, and name. |
Module Contents
- picogl.gpu.buffers.attributes.legacy_attribute_spec(role: picogl.gpu.buffers.vertex.aliases.VertexBufferRole, index: int, *, size: int = 3, name: str | picogl.gpu.buffers.vertex.aliases.VertexBufferRole | None = None, type: picogl.backend.gl.enums.GLNumeric, normalized: bool = False, stride: int = 0, offset: int = 0) AttributeSpec[source]
Build an AttributeSpec with aligned legacy role, vbo_type, and name.
- class picogl.gpu.buffers.attributes.LayoutDescriptor[source]
Layout descriptor.
- attributes: List[AttributeSpec][source]
- _cache: dict[picogl.gpu.buffers.vertex.vbo.vbo_class.VBOType, AttributeSpec] | None = None[source]
- __getitem__(vbo_type: picogl.gpu.buffers.vertex.vbo.vbo_class.VBOType) AttributeSpec[source]
- get_attr(vbo_type: picogl.gpu.buffers.vertex.vbo.vbo_class.VBOType) AttributeSpec[source]
- has_attr(vbo_type: picogl.gpu.buffers.vertex.vbo.vbo_class.VBOType) bool[source]
- property attr_dict: dict[picogl.gpu.buffers.vertex.vbo.vbo_class.VBOType, AttributeSpec][source]
dict
- class picogl.gpu.buffers.attributes.CanonicalVertexAttrs[source]
Bases:
picogl.utils.strenum.StrEnumCanonical Vertex Attrs