Blender V5.3
gpu_py_platform.cc File Reference
#include <Python.h>
#include "GPU_context.hh"
#include "GPU_platform.hh"
#include "gpu_py.hh"
#include "gpu_py_platform.hh"

Go to the source code of this file.

Namespaces

namespace  blender
 BMesh Iterators.

Functions

Functions
 blender::PyDoc_STRVAR (pygpu_platform_vendor_get_doc, ".. function:: vendor_get()\n" "\n" " Get GPU vendor.\n" "\n" " :return: Vendor name.\n" " :rtype: str\n")
static PyObject * blender::pygpu_platform_vendor_get (PyObject *)
 blender::PyDoc_STRVAR (pygpu_platform_renderer_get_doc, ".. function:: renderer_get()\n" "\n" " Get GPU to be used for rendering.\n" "\n" " :return: GPU name.\n" " :rtype: str\n")
static PyObject * blender::pygpu_platform_renderer_get (PyObject *)
 blender::PyDoc_STRVAR (pygpu_platform_version_get_doc, ".. function:: version_get()\n" "\n" " Get GPU driver version.\n" "\n" " :return: Driver version.\n" " :rtype: str\n")
static PyObject * blender::pygpu_platform_version_get (PyObject *)
 blender::PyDoc_STRVAR (pygpu_platform_device_type_get_doc, ".. function:: device_type_get()\n" "\n" " Get GPU device type.\n" "\n" " :return: Device type ('APPLE', 'NVIDIA', 'AMD', 'INTEL', 'SOFTWARE', 'QUALCOMM', " "'UNKNOWN').\n" " :rtype: str\n")
static PyObject * blender::pygpu_platform_device_type_get (PyObject *)
 blender::PyDoc_STRVAR (pygpu_platform_backend_type_get_doc, ".. function:: backend_type_get()\n" "\n" " Get active GPU backend.\n" "\n" " :return: Backend type ('OPENGL', 'VULKAN', 'METAL', 'NONE', 'UNKNOWN').\n" " :rtype: str\n")
static PyObject * blender::pygpu_platform_backend_type_get (PyObject *)
 blender::PyDoc_STRVAR (pygpu_platform_devices_get_doc, ".. function:: devices_get()\n" "\n" " Get all available GPU devices.\n" "\n" " :return: List of :class:`GPUDevice` objects for each device.\n" " :rtype: list\n")
static PyObject * blender::pygpu_platform_devices_get (PyObject *)

GPU Device Type

static PyGetSetDef blender::pygpu_device_getseters []
PyTypeObject blender::BPyGPU_DeviceType
 blender::PyDoc_STRVAR (pygpu_device_index_doc, "Device index.\n" "\n" ":type: int\n")
static PyObject * blender::pygpu_device_index_get (BPyGPUDevice *self, void *)
 blender::PyDoc_STRVAR (pygpu_device_identifier_doc, "Device identifier.\n" "\n" ":type: str\n")
static PyObject * blender::pygpu_device_identifier_get (BPyGPUDevice *self, void *)
 blender::PyDoc_STRVAR (pygpu_device_name_doc, "Device name.\n" "\n" ":type: str\n")
static PyObject * blender::pygpu_device_name_get (BPyGPUDevice *self, void *)
static PyObject * blender::pygpu_device__tp_repr (BPyGPUDevice *self)
static PyObject * blender::pygpu_device__tp_richcmp (BPyGPUDevice *self, PyObject *other, int op)
 blender::PyDoc_STRVAR (pygpu_device__tp_doc, ".. class:: GPUDevice\n" "\n" " Represents a GPU device.\n" "\n" " :ivar index: Device index.\n" " :type index: int\n" " :ivar identifier: Device identifier.\n" " :type identifier: str\n" " :ivar name: Device name.\n" " :type name: str\n")
static BPyGPUDevice * blender::pygpu_device_new (int index, const char *identifier, const char *name)

Module

static PyMethodDef blender::pygpu_platform__tp_methods []
static PyModuleDef blender::pygpu_platform_module_def
 blender::PyDoc_STRVAR (pygpu_platform__tp_doc, "This module provides access to GPU Platform definitions.")
PyObject * blender::bpygpu_platform_init ()

Detailed Description

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

Definition in file gpu_py_platform.cc.