Blender V5.0
bpy_capi_utils.hh
Go to the documentation of this file.
1/* SPDX-FileCopyrightText: 2023 Blender Authors
2 *
3 * SPDX-License-Identifier: GPL-2.0-or-later */
4
8
9#pragma once
10
11#include <Python.h>
12
13#if PY_VERSION_HEX < 0x030b0000
14# error "Python 3.11 or greater is required, you'll need to update your Python."
15#endif
16
17struct bContext;
18struct ReportList;
19
26short BPy_reports_to_error(struct ReportList *reports, PyObject *exception, bool clear);
30void BPy_reports_write_stdout(const struct ReportList *reports, const char *header);
31bool BPy_errors_to_report_ex(struct ReportList *reports,
32 const char *error_prefix,
33 bool use_full,
34 bool use_location);
44bool BPy_errors_to_report(struct ReportList *reports);
45
47
48extern void bpy_context_set(struct bContext *C, PyGILState_STATE *gilstate);
52extern void bpy_context_clear(struct bContext *C, const PyGILState_STATE *gilstate);
#define C
Definition RandGen.cpp:29
short BPy_reports_to_error(struct ReportList *reports, PyObject *exception, bool clear)
void bpy_context_clear(struct bContext *C, const PyGILState_STATE *gilstate)
void bpy_context_set(struct bContext *C, PyGILState_STATE *gilstate)
bool BPy_errors_to_report(struct ReportList *reports)
void BPy_reports_write_stdout(const struct ReportList *reports, const char *header)
bool BPy_errors_to_report_ex(struct ReportList *reports, const char *error_prefix, bool use_full, bool use_location)
struct bContext * BPY_context_get()
static void clear(Message &msg)
Definition msgfmt.cc:213