2023-08-15 16:20:26 +02:00
|
|
|
/* SPDX-FileCopyrightText: 2023 Blender Authors
|
2023-05-31 16:19:06 +02:00
|
|
|
*
|
|
|
|
* SPDX-License-Identifier: GPL-2.0-or-later */
|
2020-08-17 09:20:12 +02:00
|
|
|
|
|
|
|
/** \file
|
|
|
|
* \ingroup python
|
|
|
|
*
|
|
|
|
* Functionality relating to Python setup & tear down.
|
|
|
|
*/
|
|
|
|
|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
struct bContext;
|
|
|
|
|
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
|
|
|
#endif
|
|
|
|
|
2020-08-17 09:21:11 +02:00
|
|
|
/* For 'FILE'. */
|
|
|
|
#include <stdio.h>
|
|
|
|
|
2023-07-31 03:50:54 +02:00
|
|
|
/* `bpy_interface.cc` */
|
2021-12-10 11:40:53 +01:00
|
|
|
|
|
|
|
/** Call #BPY_context_set first. */
|
2020-10-15 09:12:03 +02:00
|
|
|
void BPY_python_start(struct bContext *C, int argc, const char **argv);
|
2023-09-19 07:38:55 +02:00
|
|
|
void BPY_python_end(bool do_python_exit);
|
2020-08-17 09:20:12 +02:00
|
|
|
void BPY_python_reset(struct bContext *C);
|
|
|
|
void BPY_python_use_system_env(void);
|
2020-09-04 20:59:13 +02:00
|
|
|
void BPY_python_backtrace(FILE *fp);
|
2020-08-17 09:20:12 +02:00
|
|
|
|
2023-07-31 03:50:54 +02:00
|
|
|
/* `bpy_app.cc` */
|
2023-05-27 08:33:46 +02:00
|
|
|
|
|
|
|
/* Access `main_args_help_as_string` needed to resolve bad level call. */
|
2023-05-27 09:23:19 +02:00
|
|
|
extern char *(*BPY_python_app_help_text_fn)(bool all);
|
2023-05-27 08:33:46 +02:00
|
|
|
|
2020-08-17 09:20:12 +02:00
|
|
|
#ifdef __cplusplus
|
|
|
|
} /* extern "C" */
|
|
|
|
#endif
|