|
Blender V4.3
|
#include <Python.h>#include "../generic/py_capi_utils.hh"#include "../generic/python_compat.hh"#include "gpu_py.hh"#include "gpu_py_vertex_format.hh"Go to the source code of this file.
Functions | |
Public API | |
| PyObject * | BPyGPUVertFormat_CreatePyObject (GPUVertFormat *fmt) |
Variables | |
Enum Conversion | |
Use with PyArg_ParseTuple's "O&" formatting. | |
| static PyC_StringEnumItems | pygpu_vertcomptype_items [] |
| static PyC_StringEnumItems | pygpu_vertfetchmode_items [] |
VertFormat Type | |
| static PyMethodDef | pygpu_vertformat__tp_methods [] |
| PyTypeObject | BPyGPUVertFormat_Type |
| static PyObject * | pygpu_vertformat__tp_new (PyTypeObject *, PyObject *args, PyObject *kwds) |
| PyDoc_STRVAR (pygpu_vertformat_attr_add_doc, ".. method:: attr_add(id, comp_type, len, fetch_mode)\n" "\n" " Add a new attribute to the format.\n" "\n" " :arg id: Name the attribute. Often `position`, `normal`, ...\n" " :type id: str\n" " :arg comp_type: The data type that will be used store the value in memory.\n" " Possible values are `I8`, `U8`, `I16`, `U16`, `I32`, `U32`, `F32` and `I10`.\n" " :type comp_type: str\n" " :arg len: How many individual values the attribute consists of\n" " (e.g. 2 for uv coordinates).\n" " :type len: int\n" " :arg fetch_mode: How values from memory will be converted when used in the shader.\n" " This is mainly useful for memory optimizations when you want to store values with\n" " reduced precision. E.g. you can store a float in only 1 byte but it will be\n" " converted to a normal 4 byte float when used.\n" " Possible values are `FLOAT`, `INT`, `INT_TO_FLOAT_UNIT` and `INT_TO_FLOAT`.\n" " :type fetch_mode: str\n") | |
| static PyObject * | pygpu_vertformat_attr_add (BPyGPUVertFormat *self, PyObject *args, PyObject *kwds) |
| static void | pygpu_vertformat__tp_dealloc (BPyGPUVertFormat *self) |
| PyDoc_STRVAR (pygpu_vertformat__tp_doc, ".. class:: GPUVertFormat()\n" "\n" " This object contains information about the structure of a vertex buffer.\n") | |
bpygpu_ for local API.BPyGPU for public API. Definition in file gpu_py_vertex_format.cc.
| PyObject * BPyGPUVertFormat_CreatePyObject | ( | GPUVertFormat * | fmt | ) |
Definition at line 215 of file gpu_py_vertex_format.cc.
References BPyGPUVertFormat_Type, and self.
Referenced by pygpu_shader_format_calc(), and pygpu_vertformat__tp_new().
| PyDoc_STRVAR | ( | pygpu_vertformat__tp_doc | , |
| ".. class:: GPUVertFormat()\n" "\n" " This object contains information about the structure of a vertex buffer.\n" | ) |
| PyDoc_STRVAR | ( | pygpu_vertformat_attr_add_doc | , |
| ".. method:: attr_add(id, comp_type, len, fetch_mode)\n" "\n" " Add a new attribute to the format.\n" "\n" " :arg id: Name the attribute. Often `position` | , | ||
| `normal` | , | ||
| ...\n" " :type id:str\n" " :arg comp_type:The data type that will be used store the value in memory.\n" " Possible values are `I8` | , | ||
| `U8` | , | ||
| `I16` | , | ||
| `U16` | , | ||
| `I32` | , | ||
| `U32` | , | ||
| `F32` and `I10`.\n" " :type comp_type:str\n" " :arg len:How many individual values the attribute consists of\n" "(e.g. 2 for uv coordinates).\n" " :type len:int\n" " :arg fetch_mode:How values from memory will be converted when used in the shader.\n" " This is mainly useful for memory optimizations when you want to store values with\n" " reduced precision. E.g. you can store a float in only 1 byte but it will be\n" " converted to a normal 4 byte float when used.\n" " Possible values are `FLOAT` | , | ||
| `INT` | , | ||
| `INT_TO_FLOAT_UNIT` and `INT_TO_FLOAT`.\n" " :type fetch_mode:str\n" | ) |
|
static |
Definition at line 146 of file gpu_py_vertex_format.cc.
References self.
|
static |
Definition at line 52 of file gpu_py_vertex_format.cc.
References BPYGPU_IS_INIT_OR_ERROR_OBJ, and BPyGPUVertFormat_CreatePyObject().
|
static |
Definition at line 84 of file gpu_py_vertex_format.cc.
References attr_id, GPU_COMP_I8, GPU_FETCH_FLOAT, GPU_VERT_ATTR_MAX_LEN, GPU_vertformat_attr_add(), len, PY_ARG_PARSER_HEAD_COMPAT, PyC_ParseStringEnum(), pygpu_vertcomptype_items, pygpu_vertfetchmode_items, self, STRINGIFY, and PyC_StringEnum::value_found.
| PyTypeObject BPyGPUVertFormat_Type |
Definition at line 157 of file gpu_py_vertex_format.cc.
Referenced by bpygpu_types_init(), BPyGPUVertFormat_CreatePyObject(), and pygpu_vertbuf__tp_new().
|
static |
Definition at line 26 of file gpu_py_vertex_format.cc.
Referenced by pygpu_vertformat_attr_add().
|
static |
Definition at line 38 of file gpu_py_vertex_format.cc.
Referenced by pygpu_vertformat_attr_add().
|
static |
Definition at line 134 of file gpu_py_vertex_format.cc.