26 pygpu_platform_vendor_get_doc,
27 ".. function:: vendor_get()\n"
31 " :return: Vendor name.\n"
42 pygpu_platform_renderer_get_doc,
43 ".. function:: renderer_get()\n"
45 " Get GPU to be used for rendering.\n"
47 " :return: GPU name.\n"
58 pygpu_platform_version_get_doc,
59 ".. function:: version_get()\n"
61 " Get GPU driver version.\n"
63 " :return: Driver version.\n"
74 pygpu_platform_device_type_get_doc,
75 ".. function:: device_type_get()\n"
77 " Get GPU device type.\n"
79 " :return: Device type ('APPLE', 'NVIDIA', 'AMD', 'INTEL', 'SOFTWARE', 'QUALCOMM', "
109 return PyUnicode_FromString(device);
114 pygpu_platform_backend_type_get_doc,
115 ".. function:: backend_type_get()\n"
117 " Get actuve GPU backend.\n"
119 " :return: Backend type ('OPENGL', 'VULKAN', 'METAL', 'NONE', 'UNKNOWN').\n"
125 const char *backend =
"UNKNOWN";
146 return PyUnicode_FromString(backend);
157# pragma clang diagnostic push
158# pragma clang diagnostic ignored "-Wcast-function-type"
160# pragma GCC diagnostic push
161# pragma GCC diagnostic ignored "-Wcast-function-type"
169 pygpu_platform_vendor_get_doc},
173 pygpu_platform_renderer_get_doc},
177 pygpu_platform_version_get_doc},
181 pygpu_platform_device_type_get_doc},
185 pygpu_platform_backend_type_get_doc},
186 {
nullptr,
nullptr, 0,
nullptr},
191# pragma clang diagnostic pop
193# pragma GCC diagnostic pop
199 pygpu_platform__tp_doc,
200 "This module provides access to GPU Platform definitions.");
204 pygpu_platform__tp_doc,
GPUBackendType GPU_backend_get_type()
#define BPYGPU_IS_INIT_OR_ERROR_OBJ