Blender  V3.3
Macros | Functions | Variables
bpy_app_sdl.c File Reference
#include "BLI_utildefines.h"
#include <Python.h>
#include "bpy_app_sdl.h"
#include "../generic/py_capi_utils.h"

Go to the source code of this file.

Macros

#define SetStrItem(str)   PyStructSequence_SET_ITEM(sdl_info, pos++, PyUnicode_FromString(str))
 
#define SetObjItem(obj)   PyStructSequence_SET_ITEM(sdl_info, pos++, obj)
 

Functions

static PyObject * make_sdl_info (void)
 
PyObject * BPY_app_sdl_struct (void)
 

Variables

static PyTypeObject BlenderAppSDLType
 
static PyStructSequence_Field app_sdl_info_fields []
 
static PyStructSequence_Desc app_sdl_info_desc
 

Macro Definition Documentation

◆ SetObjItem

#define SetObjItem (   obj)    PyStructSequence_SET_ITEM(sdl_info, pos++, obj)

◆ SetStrItem

#define SetStrItem (   str)    PyStructSequence_SET_ITEM(sdl_info, pos++, PyUnicode_FromString(str))

Function Documentation

◆ BPY_app_sdl_struct()

PyObject* BPY_app_sdl_struct ( void  )

Definition at line 114 of file bpy_app_sdl.c.

References app_sdl_info_desc, BlenderAppSDLType, make_sdl_info(), NULL, and ret.

Referenced by make_app_info().

◆ make_sdl_info()

static PyObject* make_sdl_info ( void  )
static

Definition at line 52 of file bpy_app_sdl.c.

References BlenderAppSDLType, NULL, pos, PyC_Tuple_Pack_I32, SetObjItem, SetStrItem, and UNLIKELY.

Referenced by BPY_app_sdl_struct().

Variable Documentation

◆ app_sdl_info_desc

PyStructSequence_Desc app_sdl_info_desc
static
Initial value:
= {
"bpy.app.sdl",
"This module contains information about SDL blender is linked against",
}
#define ARRAY_SIZE(arr)
static PyStructSequence_Field app_sdl_info_fields[]
Definition: bpy_app_sdl.c:34

Definition at line 45 of file bpy_app_sdl.c.

Referenced by BPY_app_sdl_struct().

◆ app_sdl_info_fields

PyStructSequence_Field app_sdl_info_fields[]
static
Initial value:
= {
{"supported", ("Boolean, True when Blender is built with SDL support")},
{"version", ("The SDL version as a tuple of 3 numbers")},
{"version_string", ("The SDL version formatted as a string")},
{"available",
("Boolean, True when SDL is available. This is False when "
"either *supported* is False, or *dynload* is True and "
"Blender cannot find the correct library.")},
{NULL},
}

Definition at line 34 of file bpy_app_sdl.c.

◆ BlenderAppSDLType

PyTypeObject BlenderAppSDLType
static

Definition at line 32 of file bpy_app_sdl.c.

Referenced by BPY_app_sdl_struct(), and make_sdl_info().