picogl.backend.gl.wrappers.draw
A module for OpenGL draw operations using PicoGL-specific enumerations or raw gl constants.
This module provides functions to issue OpenGL draw calls, including support for custom draw modes and index types. It simplifies the process of working with OpenGL by handling conversion between PicoGL enums and raw gl constants, as well as managing pointer data for indexed drawing.
Functions: - gl_draw_arrays: Wrapper for glDrawArrays supporting PicoGL enums or raw gl constants. - gl_draw_elements: Wrapper for glDrawElements with support for custom index pointers or offsets.
Functions
|
gl enum |
|
draw pointer |
|
Issue |
|
Issue |
Module Contents
- picogl.backend.gl.wrappers.draw._draw_pointer(pointer: Any | None, offset: int) Any[source]
draw pointer
- picogl.backend.gl.wrappers.draw.gl_draw_arrays(index_count: int, mode: picogl.backend.gl.enums.GLDrawMode | int, first: int = 0) None[source]
Issue
glDrawArrayswith PicoGL draw-mode enums or raw gl constants.
- picogl.backend.gl.wrappers.draw.gl_draw_elements(index_count: int, dtype: int | None = GLIndexType.UNSIGNED_INT, mode: picogl.backend.gl.enums.GLDrawMode | int | None = GLDrawMode.TRIANGLES, pointer: Any | None = None, offset: int = 0) None[source]
Issue
glDrawElements.pointer may be a client index array,
None(EBO bound), or omitted to use offset.