Blender V4.3
gpu_py_element.cc File Reference
#include <Python.h>
#include "GPU_index_buffer.hh"
#include "MEM_guardedalloc.h"
#include "../generic/py_capi_utils.hh"
#include "../generic/python_compat.hh"
#include "gpu_py.hh"
#include "gpu_py_element.hh"

Go to the source code of this file.

Functions

Public API
PyObject * BPyGPUIndexBuf_CreatePyObject (blender::gpu::IndexBuf *elem)
 

IndexBuf Type

PyTypeObject BPyGPUIndexBuf_Type
 
static PyObject * pygpu_IndexBuf__tp_new (PyTypeObject *, PyObject *args, PyObject *kwds)
 
static void pygpu_IndexBuf__tp_dealloc (BPyGPUIndexBuf *self)
 
 PyDoc_STRVAR (pygpu_IndexBuf__tp_doc, ".. class:: GPUIndexBuf(type, seq)\n" "\n" " Contains an index buffer.\n" "\n" " :arg type: The primitive type this index buffer is composed of.\n" " Possible values are [``POINTS``, ``LINES``, ``TRIS``, ``LINES_ADJ``, ``TRIS_ADJ``].\n" " :type type: str\n" " :arg seq: Indices this index buffer will contain.\n" " Whether a 1D or 2D sequence is required depends on the type.\n" " Optionally the sequence can support the buffer protocol.\n" " :type seq: Buffer | Sequence[int] | Sequence[Sequence[int]]\n")
 

Detailed Description

  • Use bpygpu_ for local API.
  • Use BPyGPU for public API.

Definition in file gpu_py_element.cc.

Function Documentation

◆ BPyGPUIndexBuf_CreatePyObject()

PyObject * BPyGPUIndexBuf_CreatePyObject ( blender::gpu::IndexBuf * elem)

Definition at line 251 of file gpu_py_element.cc.

References BPyGPUIndexBuf_Type, and self.

Referenced by pygpu_IndexBuf__tp_new().

◆ PyDoc_STRVAR()

PyDoc_STRVAR ( pygpu_IndexBuf__tp_doc ,
".. class:: GPUIndexBuf(type, seq)\n" "\n" " Contains an index buffer.\n" "\n" " :arg type: The primitive type this index buffer is composed of.\n" " Possible values are .\n" " :type type: str\n" " :arg seq: Indices this index buffer will contain.\n" " Whether a 1D or 2D sequence is required depends on the type.\n" " Optionally the sequence can support the buffer protocol.\n" " :type seq: Buffer | Sequence | Sequence]\n" [``POINTS``, ``LINES``, ``TRIS``, ``LINES_ADJ``, ``TRIS_ADJ``][int][Sequence[int] )

◆ pygpu_IndexBuf__tp_dealloc()

static void pygpu_IndexBuf__tp_dealloc ( BPyGPUIndexBuf * self)
static

Definition at line 173 of file gpu_py_element.cc.

References GPU_indexbuf_discard(), and self.

◆ pygpu_IndexBuf__tp_new()

Variable Documentation

◆ BPyGPUIndexBuf_Type

PyTypeObject BPyGPUIndexBuf_Type