|
Blender V4.3
|
#include <BKE_global.hh>
Public Attributes | ||
| Main * | main | |
| Main * | pr_main | |
| char | filepath_last_image [1024] | |
| char | filepath_last_library [1024] | |
| ListBase | recent_files | |
| bool | is_break | |
| bool | background | |
| bool | quiet | |
| bool | factory_startup | |
| short | moving | |
| bool | is_rendering | |
| short | debug_value | |
| int | f | |
| struct { | ||
| int level | ||
| void * file | ||
| } | log | |
| int | debug | |
| bool | randomize_geometry_element_order | |
| int | fileflags | |
| char | autoexec_fail [200] | |
| bool | opengl_deprecation_usage_detected | |
| const char * | opengl_deprecation_usage_filename | |
| int | opengl_deprecation_usage_lineno | |
| char | gpu_debug_scope_name [200] | |
Global data, typically accessed from G. See: BKE_blender_globals_init & BKE_blender_globals_clear.
Definition at line 26 of file BKE_global.hh.
| char Global::autoexec_fail[200] |
Message to show when loading a .blend file attempts to execute a Python script or driver-expression when doing so is disallowed.
Set when (G.f & G_FLAG_SCRIPT_AUTOEXEC_FAIL) == 0, so users can be alerted to the reason why the file may not be behaving as expected. Typically Python drivers.
Definition at line 168 of file BKE_global.hh.
| bool Global::background |
Blender is running without any Windows or OpenGLES context. Typically set by the --background command-line argument.
Also enabled when build defines WITH_PYTHON_MODULE or WITH_HEADLESS are set (which use background mode by definition).
Definition at line 66 of file BKE_global.hh.
| int Global::debug |
Debug flag, G_DEBUG, G_DEBUG_PYTHON & friends, set via:
--debug, --debug-memory ... etc.bpy.app.debug, bpy.app.debug_memory ... etc. Definition at line 141 of file BKE_global.hh.
| short Global::debug_value |
Debug value, can be set from the UI and python, used for testing nonstandard features. DO NOT abuse it with generic checks like if (G.debug_value > 0). Do not use it as bitflags. Only precise specific values should be checked for, to avoid unpredictable side-effects. Please document here the value(s) you are using (or a range of values reserved to some area):
Definition at line 113 of file BKE_global.hh.
| int Global::f |
Saved to the blend file as FileGlobal.globalf
Definition at line 121 of file BKE_global.hh.
Referenced by BKE_blender_globals_init().
| bool Global::factory_startup |
Skip reading the startup file and user preferences. Also disable saving the preferences on exit (see G_FLAG_USERPREF_NO_SAVE_ON_EXIT), see via the command line argument: --factory-startup.
Definition at line 81 of file BKE_global.hh.
| void* Global::file |
FILE handle or use stderr (we own this so close when done). Set via --log-file command line argument.
Definition at line 133 of file BKE_global.hh.
Referenced by BKE_blender_free().
| int Global::fileflags |
Control behavior of file reading/writing.
This variable is written to / read from FileGlobal.fileflags. See: G_FILE_COMPRESS and related flags.
Definition at line 158 of file BKE_global.hh.
| char Global::filepath_last_image[1024] |
Last saved location for images.
Definition at line 43 of file BKE_global.hh.
Referenced by BKE_blender_globals_init().
| char Global::filepath_last_library[1024] |
Last used location for library link/append.
Definition at line 45 of file BKE_global.hh.
| char Global::gpu_debug_scope_name[200] |
Triggers a GPU capture if the name matches a DebugScope. Set using --debug-gpu-scope-capture "debug_scope".
Definition at line 181 of file BKE_global.hh.
| bool Global::is_break |
Set when Escape been pressed or Ctrl-C pressed in background mode. Used for render quit and some other background tasks such as baking.
Definition at line 57 of file BKE_global.hh.
| bool Global::is_rendering |
To indicate render is busy, prevent render-window events, animation playback etc.
Definition at line 90 of file BKE_global.hh.
| int Global::level |
Logging vars (different loggers may use). Set via --log-level command line argument.
Definition at line 128 of file BKE_global.hh.
Referenced by BKE_blender_globals_init().
| struct { ... } Global::log |
Referenced by BKE_blender_free(), and BKE_blender_globals_init().
| Main* Global::main |
Data for the current active blend file.
Note that CTX_data_main(C) should be used where possible. Otherwise access via G_MAIN.
Definition at line 34 of file BKE_global.hh.
| short Global::moving |
Set when the user is interactively moving (transforming) content. see: G_TRANSFORM_OBJ and related flags.
Definition at line 87 of file BKE_global.hh.
| bool Global::opengl_deprecation_usage_detected |
Has there been an opengl deprecation call detected when running on a none OpenGL backend.
Definition at line 173 of file BKE_global.hh.
| const char* Global::opengl_deprecation_usage_filename |
Definition at line 174 of file BKE_global.hh.
| int Global::opengl_deprecation_usage_lineno |
Definition at line 175 of file BKE_global.hh.
| Main* Global::pr_main |
Preview main is stored to avoid loading the preview file in multiple scenarios. It is actually shared between shader node previews and asset previews.
Definition at line 40 of file BKE_global.hh.
| bool Global::quiet |
When true, suppress any non-error print messages such as files saves, loaded, quitting etc. This is used so command line tools can control output without unnecessary noise.
Definition at line 74 of file BKE_global.hh.
| bool Global::randomize_geometry_element_order |
When true, various geometry processing algorithms randomize the order of elements (e.g. vertices or edges) in the output. In many cases, we don't make guarantees about the exact order of elements. So if users depend on the indices with e.g. geometry nodes, their file can break in a different Blender version. Explicitly turning on randomization can help protect oneself against such breakages.
Definition at line 150 of file BKE_global.hh.
| ListBase Global::recent_files |
Strings of recently opened files to show in the file menu. A list of RecentFile read from BLENDER_HISTORY_FILE.
Definition at line 51 of file BKE_global.hh.