Blender V4.3

ID and Library types, which are fundamental for SDNA. More...

#include "DNA_ID_enums.h"
#include "DNA_defs.h"
#include "DNA_listBase.h"

Go to the source code of this file.

Classes

struct  DrawData
 
struct  DrawDataList
 
struct  IDPropertyUIData
 
struct  IDPropertyUIDataEnumItem
 
struct  IDPropertyUIDataInt
 
struct  IDPropertyUIDataBool
 
struct  IDPropertyUIDataFloat
 
struct  IDPropertyUIDataString
 
struct  IDPropertyUIDataID
 
struct  IDPropertyData
 
struct  IDProperty
 
struct  IDOverrideLibraryPropertyOperation
 
struct  IDOverrideLibraryProperty
 
struct  IDOverrideLibraryRuntime
 
struct  IDOverrideLibrary
 
struct  ID_Runtime_Remap
 
struct  ID_Runtime
 
struct  ID
 
struct  Library_Runtime
 
struct  Library
 
struct  LibraryWeakReference
 
struct  PreviewImage
 

Macros

#define MAX_IDPROP_NAME   64
 
#define DEFAULT_ALLOC_FOR_NULL_STRINGS   64
 
#define MAX_ID_NAME   66
 
#define ID_FAKE_USERS(id)   ((((const ID *)id)->flag & ID_FLAG_FAKEUSER) ? 1 : 0)
 
#define ID_EXTRA_USERS(id)   (((const ID *)id)->tag & ID_TAG_EXTRAUSER ? 1 : 0)
 
#define ID_EXTRA_REAL_USERS(id)   (((const ID *)id)->tag & ID_TAG_EXTRAUSER_SET ? 1 : 0)
 
#define ID_REAL_USERS(id)   (((const ID *)id)->us - ID_FAKE_USERS(id))
 
#define ID_REFCOUNTING_USERS(id)   (ID_REAL_USERS(id) - ID_EXTRA_REAL_USERS(id))
 
#define ID_CHECK_UNDO(id)    ((GS((id)->name) != ID_SCR) && (GS((id)->name) != ID_WM) && (GS((id)->name) != ID_WS))
 
#define ID_BLEND_PATH(_bmain, _id)    ((_id)->lib ? (_id)->lib->runtime.filepath_abs : BKE_main_blendfile_path((_bmain)))
 
#define ID_BLEND_PATH_FROM_GLOBAL(_id)    ((_id)->lib ? (_id)->lib->runtime.filepath_abs : BKE_main_blendfile_path_from_global())
 
#define ID_MISSING(_id)   ((((const ID *)(_id))->tag & ID_TAG_MISSING) != 0)
 
#define ID_IS_LINKED(_id)   (((const ID *)(_id))->lib != NULL)
 
#define ID_TYPE_SUPPORTS_ASSET_EDITABLE(id_type)   ELEM(id_type, ID_BR, ID_TE, ID_NT, ID_IM, ID_PC)
 
#define ID_IS_EDITABLE(_id)
 
#define ID_IS_OVERRIDABLE_LIBRARY_HIERARCHY(_id)
 
#define ID_IS_OVERRIDABLE_LIBRARY(_id)    (ID_IS_OVERRIDABLE_LIBRARY_HIERARCHY((_id)) && (((const ID *)(_id))->tag & ID_TAG_EXTERN) != 0)
 
#define ID_IS_OVERRIDE_LIBRARY_REAL(_id)
 
#define ID_IS_OVERRIDE_LIBRARY_VIRTUAL(_id)    ((((const ID *)(_id))->flag & ID_FLAG_EMBEDDED_DATA_LIB_OVERRIDE) != 0)
 
#define ID_IS_OVERRIDE_LIBRARY(_id)    (ID_IS_OVERRIDE_LIBRARY_REAL(_id) || ID_IS_OVERRIDE_LIBRARY_VIRTUAL(_id))
 
#define ID_IS_OVERRIDE_LIBRARY_HIERARCHY_ROOT(_id)
 
#define ID_IS_ASSET(_id)   (((const ID *)(_id))->asset_data != NULL)
 
#define ID_TYPE_USE_COPY_ON_EVAL(_id_type)    (!ELEM(_id_type, ID_LI, ID_IP, ID_SCR, ID_VF, ID_BR, ID_WM, ID_PAL, ID_PC, ID_WS, ID_IM))
 
#define ID_TYPE_SUPPORTS_PARAMS_WITHOUT_COW(id_type)   ELEM(id_type, ID_ME)
 
#define ID_TYPE_IS_DEPRECATED(id_type)   ELEM(id_type, ID_IP)
 
#define GS(a)   (CHECK_TYPE_ANY(a, char *, const char *), (ID_Type)(*((const short *)(a))))
 
#define ID_NEW_SET(_id, _idn)
 
#define ID_NEW_REMAP(a)
 
#define ID_TAG_KEEP_ON_UNDO   (ID_TAG_EXTRAUSER | ID_TAG_MISSING | ID_TAG_RUNTIME)
 
#define FILTER_ID_AC   (1ULL << 0)
 
#define FILTER_ID_AR   (1ULL << 1)
 
#define FILTER_ID_BR   (1ULL << 2)
 
#define FILTER_ID_CA   (1ULL << 3)
 
#define FILTER_ID_CU_LEGACY   (1ULL << 4)
 
#define FILTER_ID_GD_LEGACY   (1ULL << 5)
 
#define FILTER_ID_GR   (1ULL << 6)
 
#define FILTER_ID_IM   (1ULL << 7)
 
#define FILTER_ID_LA   (1ULL << 8)
 
#define FILTER_ID_LS   (1ULL << 9)
 
#define FILTER_ID_LT   (1ULL << 10)
 
#define FILTER_ID_MA   (1ULL << 11)
 
#define FILTER_ID_MB   (1ULL << 12)
 
#define FILTER_ID_MC   (1ULL << 13)
 
#define FILTER_ID_ME   (1ULL << 14)
 
#define FILTER_ID_MSK   (1ULL << 15)
 
#define FILTER_ID_NT   (1ULL << 16)
 
#define FILTER_ID_OB   (1ULL << 17)
 
#define FILTER_ID_PAL   (1ULL << 18)
 
#define FILTER_ID_PC   (1ULL << 19)
 
#define FILTER_ID_SCE   (1ULL << 20)
 
#define FILTER_ID_SPK   (1ULL << 21)
 
#define FILTER_ID_SO   (1ULL << 22)
 
#define FILTER_ID_TE   (1ULL << 23)
 
#define FILTER_ID_TXT   (1ULL << 24)
 
#define FILTER_ID_VF   (1ULL << 25)
 
#define FILTER_ID_WO   (1ULL << 26)
 
#define FILTER_ID_PA   (1ULL << 27)
 
#define FILTER_ID_CF   (1ULL << 28)
 
#define FILTER_ID_WS   (1ULL << 29)
 
#define FILTER_ID_LP   (1ULL << 31)
 
#define FILTER_ID_CV   (1ULL << 32)
 
#define FILTER_ID_PT   (1ULL << 33)
 
#define FILTER_ID_VO   (1ULL << 34)
 
#define FILTER_ID_SIM   (1ULL << 35)
 
#define FILTER_ID_KE   (1ULL << 36)
 
#define FILTER_ID_SCR   (1ULL << 37)
 
#define FILTER_ID_WM   (1ULL << 38)
 
#define FILTER_ID_LI   (1ULL << 39)
 
#define FILTER_ID_GP   (1ULL << 40)
 
#define FILTER_ID_IP   (1ULL << 41)
 
#define FILTER_ID_ALL
 
#define INDEX_ID_MAX   (INDEX_ID_NULL + 1)
 

Typedefs

typedef struct PreviewImageRuntimeHandle PreviewImageRuntimeHandle
 
typedef void(* DrawDataInitCb) (struct DrawData *engine_data)
 
typedef void(* DrawDataFreeCb) (struct DrawData *engine_data)
 
typedef struct DrawData DrawData
 
typedef struct DrawDataList DrawDataList
 
typedef struct IDPropertyUIData IDPropertyUIData
 
typedef struct IDPropertyUIDataEnumItem IDPropertyUIDataEnumItem
 
typedef struct IDPropertyUIDataInt IDPropertyUIDataInt
 
typedef struct IDPropertyUIDataBool IDPropertyUIDataBool
 
typedef struct IDPropertyUIDataFloat IDPropertyUIDataFloat
 
typedef struct IDPropertyUIDataString IDPropertyUIDataString
 
typedef struct IDPropertyUIDataID IDPropertyUIDataID
 
typedef struct IDPropertyData IDPropertyData
 
typedef struct IDProperty IDProperty
 
typedef struct IDOverrideLibraryPropertyOperation IDOverrideLibraryPropertyOperation
 
typedef struct IDOverrideLibraryProperty IDOverrideLibraryProperty
 
typedef struct IDOverrideLibraryRuntime IDOverrideLibraryRuntime
 
typedef struct IDOverrideLibrary IDOverrideLibrary
 
typedef struct ID_Runtime_Remap ID_Runtime_Remap
 
typedef struct ID_Runtime ID_Runtime
 
typedef struct ID ID
 
typedef struct Library_Runtime Library_Runtime
 
typedef struct Library Library
 
typedef struct LibraryWeakReference LibraryWeakReference
 
typedef struct PreviewImage PreviewImage
 
typedef enum IDRecalcFlag IDRecalcFlag
 
typedef enum eID_Index eID_Index
 

Enumerations

enum  {
  LIBOVERRIDE_OP_NOOP = 0 , LIBOVERRIDE_OP_REPLACE = 1 , LIBOVERRIDE_OP_ADD = 101 , LIBOVERRIDE_OP_SUBTRACT = 102 ,
  LIBOVERRIDE_OP_MULTIPLY = 103 , LIBOVERRIDE_OP_INSERT_AFTER = 201 , LIBOVERRIDE_OP_INSERT_BEFORE = 202
}
 
enum  { LIBOVERRIDE_OP_FLAG_MANDATORY = 1 << 0 , LIBOVERRIDE_OP_FLAG_LOCKED = 1 << 1 , LIBOVERRIDE_OP_FLAG_IDPOINTER_MATCH_REFERENCE = 1 << 8 , LIBOVERRIDE_OP_FLAG_IDPOINTER_ITEM_USE_ID = 1 << 9 }
 
enum  { LIBOVERRIDE_PROP_OP_TAG_UNUSED = 1 << 0 , LIBOVERRIDE_PROP_TAG_NEEDS_RETORE = 1 << 1 }
 
enum  { LIBOVERRIDE_TAG_NEEDS_RELOAD = 1 << 0 , LIBOVERRIDE_TAG_NEEDS_RESTORE = 1 << 1 , LIBOVERRIDE_TAG_RESYNC_ISOLATED_FROM_ROOT = 1 << 2 , LIBOVERRIDE_TAG_NEED_RESYNC_ORIGINAL = 1 << 3 }
 
enum  { LIBOVERRIDE_FLAG_NO_HIERARCHY = 1 << 0 , LIBOVERRIDE_FLAG_SYSTEM_DEFINED = 1 << 1 }
 
enum  { ID_REMAP_IS_LINKED_DIRECT = 1 << 0 , ID_REMAP_IS_USER_ONE_SKIPPED = 1 << 1 }
 
enum  eLibrary_Tag { LIBRARY_TAG_RESYNC_REQUIRED = 1 << 0 , LIBRARY_ASSET_EDITABLE = 1 << 1 , LIBRARY_ASSET_FILE_WRITABLE = 1 << 2 , LIBRARY_IS_ASSET_EDIT_FILE = 1 << 3 }
 
enum  ePreviewImage_Flag { PRV_CHANGED = (1 << 0) , PRV_USER_EDITED = (1 << 1) , PRV_RENDERING = (1 << 2) }
 
enum  { PRV_TAG_DEFFERED_RENDERING = (1 << 1) , PRV_TAG_DEFFERED_DELETE = (1 << 2) }
 
enum  {
  ID_FLAG_FAKEUSER = 1 << 9 , ID_FLAG_EMBEDDED_DATA = 1 << 10 , ID_FLAG_INDIRECT_WEAK_LINK = 1 << 11 , ID_FLAG_EMBEDDED_DATA_LIB_OVERRIDE = 1 << 12 ,
  ID_FLAG_LIB_OVERRIDE_RESYNC_LEFTOVER = 1 << 13 , ID_FLAG_CLIPBOARD_MARK = 1 << 14
}
 
enum  {
  ID_TAG_LOCAL = 0 , ID_TAG_EXTERN = 1 << 0 , ID_TAG_INDIRECT = 1 << 1 , ID_TAG_RUNTIME = 1 << 2 ,
  ID_TAG_MISSING = 1 << 3 , ID_TAG_EXTRAUSER = 1 << 4 , ID_TAG_EXTRAUSER_SET = 1 << 5 , ID_TAG_LIBOVERRIDE_REFOK = 1 << 6 ,
  ID_TAG_LIBOVERRIDE_AUTOREFRESH = 1 << 7 , ID_TAG_LIBOVERRIDE_NEED_RESYNC = 1 << 8 , ID_TAG_NEW = 1 << 12 , ID_TAG_PRE_EXISTING = 1 << 13 ,
  ID_TAG_NEED_EXPAND = 1 << 14 , ID_TAG_ID_LINK_PLACEHOLDER = 1 << 15 , ID_TAG_NEED_LINK = 1 << 16 , ID_TAG_UNDO_OLD_ID_REUSED_UNCHANGED = 1 << 17 ,
  ID_TAG_UNDO_OLD_ID_REUSED_NOUNDO = 1 << 18 , ID_TAG_UNDO_OLD_ID_REREAD_IN_PLACE = 1 << 19 , ID_TAG_TEMP_MAIN = 1 << 20 , ID_TAG_NO_MAIN = 1 << 21 ,
  ID_TAG_LOCALIZED = 1 << 22 , ID_TAG_COPIED_ON_EVAL = 1 << 23 , ID_TAG_COPIED_ON_EVAL_FINAL_RESULT = 1 << 24 , ID_TAG_NO_USER_REFCOUNT = 1 << 25 ,
  ID_TAG_NOT_ALLOCATED = 1 << 26 , ID_TAG_DOIT = 1u << 31
}
 
enum  IDRecalcFlag {
  ID_RECALC_TRANSFORM = (1 << 0) , ID_RECALC_GEOMETRY = (1 << 1) , ID_RECALC_ANIMATION = (1 << 2) , ID_RECALC_PSYS_REDO = (1 << 3) ,
  ID_RECALC_PSYS_RESET = (1 << 4) , ID_RECALC_PSYS_CHILD = (1 << 5) , ID_RECALC_PSYS_PHYS = (1 << 6) , ID_RECALC_SHADING = (1 << 7) ,
  ID_RECALC_SELECT = (1 << 9) , ID_RECALC_BASE_FLAGS = (1 << 10) , ID_RECALC_POINT_CACHE = (1 << 11) , ID_RECALC_EDITORS = (1 << 12) ,
  ID_RECALC_SYNC_TO_EVAL = (1 << 13) , ID_RECALC_SEQUENCER_STRIPS = (1 << 14) , ID_RECALC_FRAME_CHANGE = (1 << 15) , ID_RECALC_AUDIO_FPS = (1 << 16) ,
  ID_RECALC_AUDIO_VOLUME = (1 << 17) , ID_RECALC_AUDIO_MUTE = (1 << 18) , ID_RECALC_AUDIO_LISTENER = (1 << 19) , ID_RECALC_AUDIO = (1 << 20) ,
  ID_RECALC_PARAMETERS = (1 << 21) , ID_RECALC_SOURCE = (1 << 23) , ID_RECALC_TAG_FOR_UNDO = (1 << 24) , ID_RECALC_NTREE_OUTPUT = (1 << 25) ,
  ID_RECALC_HIERARCHY = (1 << 26) , ID_RECALC_PROVISION_27 = (1 << 27) , ID_RECALC_PROVISION_28 = (1 << 28) , ID_RECALC_PROVISION_29 = (1 << 29) ,
  ID_RECALC_PROVISION_30 = (1 << 30) , ID_RECALC_PROVISION_31 = (1u << 31) , ID_RECALC_ANIMATION_NO_FLUSH = ID_RECALC_SYNC_TO_EVAL , ID_RECALC_GEOMETRY_ALL_MODES = ID_RECALC_GEOMETRY | ID_RECALC_SYNC_TO_EVAL ,
  ID_RECALC_ALL = (0xffffffff) , ID_RECALC_PSYS_ALL
}
 
enum  eID_Index {
  INDEX_ID_LI = 0 , INDEX_ID_IP , INDEX_ID_AC , INDEX_ID_GD_LEGACY ,
  INDEX_ID_NT , INDEX_ID_VF , INDEX_ID_TXT , INDEX_ID_SO ,
  INDEX_ID_MSK , INDEX_ID_IM , INDEX_ID_MC , INDEX_ID_TE ,
  INDEX_ID_MA , INDEX_ID_LS , INDEX_ID_WO , INDEX_ID_CF ,
  INDEX_ID_PA , INDEX_ID_KE , INDEX_ID_AR , INDEX_ID_ME ,
  INDEX_ID_CU_LEGACY , INDEX_ID_MB , INDEX_ID_CV , INDEX_ID_PT ,
  INDEX_ID_VO , INDEX_ID_LT , INDEX_ID_LA , INDEX_ID_CA ,
  INDEX_ID_SPK , INDEX_ID_LP , INDEX_ID_GP , INDEX_ID_OB ,
  INDEX_ID_GR , INDEX_ID_PAL , INDEX_ID_PC , INDEX_ID_BR ,
  INDEX_ID_SCE , INDEX_ID_SCR , INDEX_ID_WS , INDEX_ID_WM ,
  INDEX_ID_NULL
}
 

Detailed Description

ID and Library types, which are fundamental for SDNA.

Definition in file DNA_ID.h.

Macro Definition Documentation

◆ DEFAULT_ALLOC_FOR_NULL_STRINGS

#define DEFAULT_ALLOC_FOR_NULL_STRINGS   64

Definition at line 186 of file DNA_ID.h.

Referenced by IDP_New(), and IDP_NewStringMaxSize().

◆ FILTER_ID_AC

#define FILTER_ID_AC   (1ULL << 0)

Definition at line 1164 of file DNA_ID.h.

◆ FILTER_ID_ALL

#define FILTER_ID_ALL
Value:
#define FILTER_ID_GD_LEGACY
Definition DNA_ID.h:1169
#define FILTER_ID_SCR
Definition DNA_ID.h:1200
#define FILTER_ID_OB
Definition DNA_ID.h:1181
#define FILTER_ID_MC
Definition DNA_ID.h:1177
#define FILTER_ID_SPK
Definition DNA_ID.h:1185
#define FILTER_ID_WM
Definition DNA_ID.h:1201
#define FILTER_ID_CF
Definition DNA_ID.h:1192
#define FILTER_ID_AC
Definition DNA_ID.h:1164
#define FILTER_ID_MA
Definition DNA_ID.h:1175
#define FILTER_ID_CA
Definition DNA_ID.h:1167
#define FILTER_ID_SO
Definition DNA_ID.h:1186
#define FILTER_ID_PT
Definition DNA_ID.h:1196
#define FILTER_ID_CU_LEGACY
Definition DNA_ID.h:1168
#define FILTER_ID_BR
Definition DNA_ID.h:1166
#define FILTER_ID_WS
Definition DNA_ID.h:1193
#define FILTER_ID_MB
Definition DNA_ID.h:1176
#define FILTER_ID_VF
Definition DNA_ID.h:1189
#define FILTER_ID_LA
Definition DNA_ID.h:1172
#define FILTER_ID_GR
Definition DNA_ID.h:1170
#define FILTER_ID_TE
Definition DNA_ID.h:1187
#define FILTER_ID_LT
Definition DNA_ID.h:1174
#define FILTER_ID_LS
Definition DNA_ID.h:1173
#define FILTER_ID_PA
Definition DNA_ID.h:1191
#define FILTER_ID_CV
Definition DNA_ID.h:1195
#define FILTER_ID_ME
Definition DNA_ID.h:1178
#define FILTER_ID_AR
Definition DNA_ID.h:1165
#define FILTER_ID_SIM
Definition DNA_ID.h:1198
#define FILTER_ID_MSK
Definition DNA_ID.h:1179
#define FILTER_ID_PC
Definition DNA_ID.h:1183
#define FILTER_ID_GP
Definition DNA_ID.h:1203
#define FILTER_ID_PAL
Definition DNA_ID.h:1182
#define FILTER_ID_KE
Definition DNA_ID.h:1199
#define FILTER_ID_IM
Definition DNA_ID.h:1171
#define FILTER_ID_SCE
Definition DNA_ID.h:1184
#define FILTER_ID_LI
Definition DNA_ID.h:1202
#define FILTER_ID_LP
Definition DNA_ID.h:1194
#define FILTER_ID_VO
Definition DNA_ID.h:1197
#define FILTER_ID_WO
Definition DNA_ID.h:1190
#define FILTER_ID_IP
Definition DNA_ID.h:1204
#define FILTER_ID_NT
Definition DNA_ID.h:1180
#define FILTER_ID_TXT
Definition DNA_ID.h:1188

Definition at line 1206 of file DNA_ID.h.

Referenced by BKE_library_id_can_use_filter_id(), blo_do_versions_300(), filelist_setfilter_options(), fileselect_ensure_updated_asset_params(), blender::ed::asset::list::AssetList::setup(), and blender::ed::asset::types_supported_as_filter_flags().

◆ FILTER_ID_AR

#define FILTER_ID_AR   (1ULL << 1)

Definition at line 1165 of file DNA_ID.h.

Referenced by libblock_remap_data_preprocess_ob().

◆ FILTER_ID_BR

#define FILTER_ID_BR   (1ULL << 2)

Definition at line 1166 of file DNA_ID.h.

Referenced by get_type_info().

◆ FILTER_ID_CA

#define FILTER_ID_CA   (1ULL << 3)

Definition at line 1167 of file DNA_ID.h.

◆ FILTER_ID_CF

#define FILTER_ID_CF   (1ULL << 28)

Definition at line 1192 of file DNA_ID.h.

◆ FILTER_ID_CU_LEGACY

#define FILTER_ID_CU_LEGACY   (1ULL << 4)

Definition at line 1168 of file DNA_ID.h.

◆ FILTER_ID_CV

#define FILTER_ID_CV   (1ULL << 32)

Definition at line 1195 of file DNA_ID.h.

◆ FILTER_ID_GD_LEGACY

#define FILTER_ID_GD_LEGACY   (1ULL << 5)

Definition at line 1169 of file DNA_ID.h.

Referenced by get_type_info(), and image_id_remap().

◆ FILTER_ID_GP

#define FILTER_ID_GP   (1ULL << 40)

Definition at line 1203 of file DNA_ID.h.

◆ FILTER_ID_GR

#define FILTER_ID_GR   (1ULL << 6)

Definition at line 1170 of file DNA_ID.h.

Referenced by blo_do_versions_300(), get_type_info(), and preview_filter_to_idfilter().

◆ FILTER_ID_IM

#define FILTER_ID_IM   (1ULL << 7)

◆ FILTER_ID_IP

#define FILTER_ID_IP   (1ULL << 41)

Definition at line 1204 of file DNA_ID.h.

◆ FILTER_ID_KE

#define FILTER_ID_KE   (1ULL << 36)

Definition at line 1199 of file DNA_ID.h.

◆ FILTER_ID_LA

#define FILTER_ID_LA   (1ULL << 8)

Definition at line 1172 of file DNA_ID.h.

Referenced by preview_filter_to_idfilter().

◆ FILTER_ID_LI

#define FILTER_ID_LI   (1ULL << 39)

Definition at line 1202 of file DNA_ID.h.

◆ FILTER_ID_LP

#define FILTER_ID_LP   (1ULL << 31)

Definition at line 1194 of file DNA_ID.h.

◆ FILTER_ID_LS

#define FILTER_ID_LS   (1ULL << 9)

Definition at line 1173 of file DNA_ID.h.

Referenced by get_type_info().

◆ FILTER_ID_LT

#define FILTER_ID_LT   (1ULL << 10)

Definition at line 1174 of file DNA_ID.h.

◆ FILTER_ID_MA

#define FILTER_ID_MA   (1ULL << 11)

◆ FILTER_ID_MB

#define FILTER_ID_MB   (1ULL << 12)

Definition at line 1176 of file DNA_ID.h.

◆ FILTER_ID_MC

#define FILTER_ID_MC   (1ULL << 13)

Definition at line 1177 of file DNA_ID.h.

Referenced by clip_id_remap(), get_type_info(), and view3d_id_remap().

◆ FILTER_ID_ME

#define FILTER_ID_ME   (1ULL << 14)

Definition at line 1178 of file DNA_ID.h.

◆ FILTER_ID_MSK

#define FILTER_ID_MSK   (1ULL << 15)

Definition at line 1179 of file DNA_ID.h.

Referenced by clip_id_remap(), get_type_info(), and image_id_remap().

◆ FILTER_ID_NT

◆ FILTER_ID_OB

#define FILTER_ID_OB   (1ULL << 17)

◆ FILTER_ID_PA

#define FILTER_ID_PA   (1ULL << 27)

Definition at line 1191 of file DNA_ID.h.

◆ FILTER_ID_PAL

#define FILTER_ID_PAL   (1ULL << 18)

Definition at line 1182 of file DNA_ID.h.

Referenced by get_type_info().

◆ FILTER_ID_PC

#define FILTER_ID_PC   (1ULL << 19)

Definition at line 1183 of file DNA_ID.h.

◆ FILTER_ID_PT

#define FILTER_ID_PT   (1ULL << 33)

Definition at line 1196 of file DNA_ID.h.

◆ FILTER_ID_SCE

#define FILTER_ID_SCE   (1ULL << 20)

Definition at line 1184 of file DNA_ID.h.

Referenced by get_type_info(), and preview_filter_to_idfilter().

◆ FILTER_ID_SCR

#define FILTER_ID_SCR   (1ULL << 37)

Definition at line 1200 of file DNA_ID.h.

◆ FILTER_ID_SIM

#define FILTER_ID_SIM   (1ULL << 35)

Definition at line 1198 of file DNA_ID.h.

◆ FILTER_ID_SO

#define FILTER_ID_SO   (1ULL << 22)

Definition at line 1186 of file DNA_ID.h.

Referenced by get_type_info().

◆ FILTER_ID_SPK

#define FILTER_ID_SPK   (1ULL << 21)

Definition at line 1185 of file DNA_ID.h.

◆ FILTER_ID_TE

#define FILTER_ID_TE   (1ULL << 23)

Definition at line 1187 of file DNA_ID.h.

Referenced by preview_filter_to_idfilter().

◆ FILTER_ID_TXT

#define FILTER_ID_TXT   (1ULL << 24)

Definition at line 1188 of file DNA_ID.h.

Referenced by get_type_info(), and paste_material_exec().

◆ FILTER_ID_VF

#define FILTER_ID_VF   (1ULL << 25)

Definition at line 1189 of file DNA_ID.h.

◆ FILTER_ID_VO

#define FILTER_ID_VO   (1ULL << 34)

Definition at line 1197 of file DNA_ID.h.

◆ FILTER_ID_WM

#define FILTER_ID_WM   (1ULL << 38)

Definition at line 1201 of file DNA_ID.h.

◆ FILTER_ID_WO

#define FILTER_ID_WO   (1ULL << 26)

Definition at line 1190 of file DNA_ID.h.

Referenced by get_type_info(), and preview_filter_to_idfilter().

◆ FILTER_ID_WS

#define FILTER_ID_WS   (1ULL << 29)

Definition at line 1193 of file DNA_ID.h.

◆ GS

#define GS ( a)    (CHECK_TYPE_ANY(a, char *, const char *), (ID_Type)(*((const short *)(a))))

Definition at line 705 of file DNA_ID.h.

◆ ID_BLEND_PATH

◆ ID_BLEND_PATH_FROM_GLOBAL

◆ ID_CHECK_UNDO

#define ID_CHECK_UNDO ( id)     ((GS((id)->name) != ID_SCR) && (GS((id)->name) != ID_WM) && (GS((id)->name) != ID_WS))

Definition at line 644 of file DNA_ID.h.

Referenced by operator_button_property_finish(), and ui_but_is_rna_undo().

◆ ID_EXTRA_REAL_USERS

#define ID_EXTRA_REAL_USERS ( id)    (((const ID *)id)->tag & ID_TAG_EXTRAUSER_SET ? 1 : 0)

Amount of real 'extra' shallow, runtime-only usages of this ID (typically from UI). Always 0 or 1.

Note
Actual number of usages added to ID.us by these extra usages. May be 0 even if there are some 'extra' usages of this ID, when there are also other 'normal' reference-counting usages of it.

Definition at line 632 of file DNA_ID.h.

◆ ID_EXTRA_USERS

#define ID_EXTRA_USERS ( id)    (((const ID *)id)->tag & ID_TAG_EXTRAUSER ? 1 : 0)

Amount of defined 'extra' shallow, runtime-only usages of this ID (typically from UI). Always 0 or 1.

Warning
May not actually be part of the total ID.us count, see ID_EXTRA_REAL_USERS.

Definition at line 623 of file DNA_ID.h.

Referenced by blender::ed::object::base_free_and_unlink(), BKE_brush_delete(), blender::ed::object::object_delete_exec(), blender::ed::outliner::outliner_batch_delete_object_tag(), and blender::ed::outliner::outliner_object_delete_fn().

◆ ID_FAKE_USERS

◆ ID_IS_ASSET

◆ ID_IS_EDITABLE

#define ID_IS_EDITABLE ( _id)
Value:
((((const ID *)(_id))->lib == NULL) || \
((((const ID *)(_id))->lib->runtime.tag & LIBRARY_ASSET_EDITABLE) && \
ID_TYPE_SUPPORTS_ASSET_EDITABLE(GS((((const ID *)(_id))->name)))))
#define GS(a)
Definition DNA_ID.h:705
@ LIBRARY_ASSET_EDITABLE
Definition DNA_ID.h:549
#define NULL
Definition DNA_ID.h:413
static DynamicLibrary lib

Definition at line 658 of file DNA_ID.h.

Referenced by animfilter_action(), blender::ed::object::apply_objects_internal(), armature_bone_select_poll(), BKE_collection_add_from_collection(), BKE_collection_object_add_from(), BKE_collection_parent_editable_find_recursive(), BKE_constraint_apply_for_object(), BKE_constraint_apply_for_pose(), BKE_constraint_copy_for_object(), BKE_constraint_copy_for_pose(), BKE_id_can_be_asset(), BKE_id_is_editable(), BKE_mball_properties_copy(), BKE_packedfile_id_unpack(), BKE_packedfile_pack_all(), BKE_view_layer_rename_lightgroup(), bone_collection_add_poll(), bone_collection_assign_poll(), bone_collection_create_and_assign_poll(), blender::ed::object::collection_drop_exec(), blender::ed::outliner::collection_drop_init(), blender::ed::outliner::collection_duplicate_exec(), blender::ed::outliner::collection_edit_in_active_scene_poll(), blender::ed::object::collection_link_exec(), blender::ed::outliner::collection_link_exec(), blender::ed::outliner::collection_new_exec(), blender::ed::outliner::collection_parent_from_ID(), blender::ed::object::collection_remove_exec(), createTransCursor_view3d(), blender::ed::object::data_transfer_exec(), blender::ed::object::data_transfer_exec_is_object_valid(), blender::ed::object::data_transfer_exec_preprocess_objects(), blender::ed::object::datalayout_transfer_exec(), blender::ed::outliner::do_item_rename(), ED_add_action_channel(), ED_add_action_group_channel(), ED_add_action_layered_channel(), ED_add_fcurve_channel(), ED_id_rename(), ED_image_save_all_modified_info(), ED_operator_camera_poll(), ED_operator_editable_mesh(), ED_operator_object_active_editable_font(), ED_operator_object_active_editable_mesh(), ED_operator_objectmode(), ED_paint_proj_mesh_data_check(), ED_view3d_camera_lock_check(), blender::ed::object::edit_constraint_poll_generic(), blender::ed::object::editmode_enter_ex(), blender::ed::object::editmode_toggle_poll(), blender::nodes::socket_items::ops::get_active_node_to_operate_on(), icon_preview_startjob_all_sizes(), image_from_context_editable_has_data_poll_active_tile(), image_paint_poll_ex(), image_unpack_exec(), image_unpack_invoke(), blender::ed::object::join_shapes_poll(), layers_poll(), lib_id_preview_editing_poll(), blender::ed::outliner::material_drop_poll(), mesh_customdata_mask_clear_poll(), mesh_customdata_skin_state(), blender::ed::sculpt_paint::vwpaint::mode_toggle_poll_test(), blender::ed::object::modifier_copy_to_selected_exec(), modifier_panel_get_property_pointers(), blender::ed::object::move_to_collection_exec(), move_to_collection_poll(), nlaedit_apply_scale_exec(), blender::ed::space_node::node_default_group_width_set_poll(), blender::nodes::node_geo_bake_cc::node_layout(), blender::nodes::node_geo_bake_cc::node_layout_ex(), blender::nodes::node_geo_simulation_cc::node_layout_ex(), blender::ed::object::object_convert_poll(), blender::ed::object::object_join_poll(), object_materials_supported_poll_ex(), blender::ed::object::object_origin_set_exec(), blender::ed::object::object_remesh_poll(), blender::ed::object::object_transfer_mode_invoke(), operator_rigidbody_constraints_editable_poll(), operator_rigidbody_editable_poll(), blender::ed::outliner::outliner_collection_delete(), blender::ed::outliner::outliner_draw_mode_column_toggle(), blender::ed::outliner::outliner_id_remap_exec(), palette_poll(), particle_edit_toggle_poll(), previews_id_ensure(), project_paint_prepare_all_faces(), ptcache_add_remove_poll(), ptcache_poll(), remove_particle_systems_from_object(), rename_anim_channels(), RNA_property_anim_editable(), rna_property_editable_do(), scene_collections_object_remove(), screen_ctx_sel_actions_impl(), sequencer_strip_editable_poll(), blender::nodes::inverse_eval::set_rna_property(), blender::ed::object::shade_poll(), shaderfx_panel_header(), blender::ed::object::shape_key_poll(), sound_unpack_exec(), sound_unpack_invoke(), template_add_button_search_menu(), template_ID(), template_id_def_new_but(), texture_paint_toggle_poll(), UI_context_copy_to_selected_list(), ui_drop_material_poll(), uiTemplateColorRamp(), uiTemplateConstraintHeader(), uiTemplateCurveMapping(), uiTemplateCurveProfile(), blender::ed::outliner::unlink_collection_fn(), blender::ed::outliner::unlink_material_fn(), blender::ed::outliner::unlink_object_fn(), blender::ed::object::vertex_group_select_exec(), blender::ed::object::vertex_group_supported_poll_ex(), and view3d_mat_drop_poll().

◆ ID_IS_LINKED

#define ID_IS_LINKED ( _id)    (((const ID *)(_id))->lib != NULL)

Definition at line 654 of file DNA_ID.h.

Referenced by ANIM_armature_bonecoll_is_editable(), ANIM_armature_bonecoll_new(), animdata_copy_id_action(), animfilter_action_slot(), animfilter_action_slots(), are_ids_from_different_mains_matching(), blender::bke::asset_reload(), blender::bke::bake::BakeDataBlockID::BakeDataBlockID(), BKE_animdata_blend_read_data(), BKE_blendfile_append(), BKE_blendfile_library_relocate(), BKE_blendfile_override(), BKE_bpath_foreach_path_id(), BKE_brush_tag_unsaved_changes(), BKE_collection_add_from_object(), BKE_collection_duplicate(), BKE_collection_parent_editable_find_recursive(), BKE_constraint_blend_read_data(), BKE_gpencil_blend_read_data(), BKE_gpencil_modifier_blend_read_data(), BKE_id_copy_for_duplicate(), BKE_id_copy_in_lib(), BKE_id_free_us(), BKE_id_full_name_get(), BKE_id_move_to_same_lib(), BKE_id_new_name_validate(), BKE_id_to_unique_string_key(), BKE_lib_id_make_local_generic(), BKE_lib_override_id_tag_on_deg_tag_from_user(), BKE_lib_override_library_create_from_id(), BKE_lib_override_library_create_from_tag(), BKE_lib_override_library_init(), BKE_lib_override_library_main_operations_create(), BKE_lib_override_library_main_operations_restore(), BKE_lib_override_library_main_proxy_convert(), BKE_lib_override_library_main_resync(), BKE_lib_override_library_proxy_convert(), BKE_libblock_relink_to_newid(), BKE_library_indirectly_used_data_tag_clear(), BKE_library_main_rebuild_hierarchy(), BKE_library_make_local(), BKE_main_id_refcount_recompute(), BKE_main_id_repair_duplicate_names_listbase(), BKE_main_lib_objects_recalc_all(), BKE_modifier_blend_read_data(), BKE_modifier_path_relbase(), BKE_modifiers_persistent_uid_init(), BKE_nla_blend_read_data(), BKE_object_duplicate(), BKE_object_is_libdata(), BKE_object_obdata_is_libdata(), BKE_packedfile_count_all(), BKE_packedfile_pack_all(), BKE_packedfile_unpack_all(), BKE_paint_brush_set(), BKE_pose_blend_read_after_liblink(), BKE_scene_can_be_removed(), BKE_scene_duplicate(), BKE_shaderfx_blend_read_data(), blend_write(), blend_write(), blend_write(), blend_write(), blo_cache_storage_init(), blo_cache_storage_old_bmain_clear(), blo_do_versions_250(), blo_do_versions_260(), blo_do_versions_300(), blo_do_versions_pre250(), BLO_main_validate_libraries(), BLO_main_validate_shapekeys(), blender::ed::sculpt_paint::brush_asset_delete_invoke(), blender::ed::sculpt_paint::brush_asset_delete_poll(), brush_make_local(), camera_blend_read_data(), check_missing_files_foreach_path_cb(), blender::ed::object::clear_override_library_exec(), blender::ed::object::collection_exporter_common_check(), con_extern_cb(), blender::ed::space_node::NodeClipboard::copy_add_node(), direct_link_id_common(), do_version_collection_propagate_lib_to_children(), do_version_layers_to_collections(), do_versions_after_linking_400(), do_versions_rename_id(), ED_add_action_slot_channel(), filelist_readjob_main_assets_add_items(), foreach_libblock_link_append_common_processing(), id_delete(), id_lib_extern(), id_lib_indirect_weak_link(), blender::ed::outliner::id_local_fn(), blender::ed::outliner::id_override_library_clear_single(), blender::ed::outliner::id_override_library_create_hierarchy(), blender::ed::outliner::id_override_library_create_hierarchy_pre_process(), blender::ed::outliner::id_override_library_create_hierarchy_process(), blender::ed::outliner::id_override_library_delete_hierarchy(), blender::ed::outliner::id_override_library_reset(), blender::ed::outliner::id_override_library_resync(), id_refcount_recompute_callback(), id_search_add(), id_sort_by_name(), image_file_browse_exec(), image_file_browse_invoke(), layer_collection_sync(), lib_id_copy_ensure_local(), lib_id_expand_local_cb(), lib_id_override_editable_toggle_poll(), lib_link_cb(), lib_override_cleanup_after_resync(), lib_override_group_tag_data_object_to_collection_init_collection_process(), lib_override_library_create_from(), lib_override_library_create_post_process(), lib_override_library_main_resync_on_library_indirect_level(), lib_override_library_operations_create(), lib_override_library_resync(), lib_override_library_resync_build_missing_ids_data(), lib_override_linked_group_tag(), lib_override_linked_group_tag_recursive(), lib_override_resync_id_lib_level_is_valid(), lib_override_sort_libraries_func(), lib_query_unused_ids_tag(), lib_query_unused_ids_tag_id(), lib_query_unused_ids_tag_recurse(), libblock_relink_to_newid_prepare_data(), library_foreach_ID_link(), library_make_local_copying_check(), loose_data_instantiate_process_check(), blender::ed::object::make_local_all__instance_indirect_unused(), blender::ed::object::make_override_library_exec(), blender::ed::object::make_override_library_invoke(), blender::ed::object::make_override_library_object_overridable_check(), blender::ed::object::make_override_library_poll(), memfile_undosys_step_id_reused_cb(), blender::nodes::node_group_declare(), blender::bke::node_type_is_undefined(), ntree_version_245(), blender::draw::overlay::Origins::object_sync(), oldnewmap_liblookup(), blender::ed::outliner::outliner_draw_overrides_restrictbuts(), blender::ed::outliner::outliner_draw_userbuts(), OVERLAY_object_center(), override_idtemplate_clear_exec(), override_idtemplate_make_exec(), override_idtemplate_menu_poll(), override_idtemplate_poll(), override_idtemplate_reset_exec(), override_library_is_valid(), read_bone_collections(), read_undo_remap_noundo_data(), rebuild_hierarchy_best_parent_find(), blender::ed::object::reset_clear_override_library_poll(), blender::ed::object::reset_override_library_exec(), reuse_bmain_data_invalid_local_usages_fix(), reuse_bmain_data_invalid_local_usages_fix_cb(), reuse_editable_asset_bmain_data_for_blendfile(), rna_id_itemf(), RNA_path_full_ID_py(), rna_property_override_check_resync(), scene_blend_read_after_liblink(), scene_render_name_get(), scene_undo_depsgraph_gen_key(), setup_app_data(), blender::ed::object::single_data_needs_duplication(), blender::ed::object::single_object_users_collection(), sort_linked_ids(), swap_old_bmain_data_for_blendfile(), blender::ed::object::tag_localizable_objects(), template_ID(), template_id_liboverride_hierarchy_collection_root_find_recursive(), template_id_liboverride_hierarchy_collections_tag_recursive(), template_id_liboverride_hierarchy_make(), blender::ed::outliner::tselem_draw_icon(), UI_icon_from_library(), ui_rna_collection_search_update_fn(), ui_template_id_liboverride_hierarchy_make(), ui_tooltip_data_from_button_or_extra_icon(), ui_tooltip_data_from_search_item_tooltip_data(), unpin_file_local_grease_pencil_brush_materials(), workspace_blend_read_after_liblink(), workspace_blend_read_data(), write_file_handle(), write_id_direct_linked_data_process_cb(), and write_renderinfo().

◆ ID_IS_OVERRIDABLE_LIBRARY

◆ ID_IS_OVERRIDABLE_LIBRARY_HIERARCHY

#define ID_IS_OVERRIDABLE_LIBRARY_HIERARCHY ( _id)
Value:
(ID_IS_LINKED(_id) && !ID_MISSING(_id) && \
!ELEM(GS(((ID *)(_id))->name), ID_SCE))
@ IDTYPE_FLAGS_NO_LIBLINKING
Definition BKE_idtype.hh:32
const IDTypeInfo * BKE_idtype_get_info_from_id(const ID *id)
Definition idtype.cc:150
#define ELEM(...)
#define ID_IS_LINKED(_id)
Definition DNA_ID.h:654
#define ID_MISSING(_id)
Definition DNA_ID.h:652
@ ID_SCE
uint32_t flags

Definition at line 665 of file DNA_ID.h.

Referenced by BKE_lib_override_library_proxy_convert(), blender::ed::outliner::id_override_library_create_hierarchy_pre_process(), and ui_template_id_liboverride_hierarchy_make().

◆ ID_IS_OVERRIDE_LIBRARY

#define ID_IS_OVERRIDE_LIBRARY ( _id)     (ID_IS_OVERRIDE_LIBRARY_REAL(_id) || ID_IS_OVERRIDE_LIBRARY_VIRTUAL(_id))

Definition at line 683 of file DNA_ID.h.

Referenced by action_new_exec(), action_pushdown_exec(), action_stash_create_exec(), action_stash_exec(), ANIM_armature_bonecoll_is_editable(), ANIM_armature_bonecoll_new(), animfilter_action(), animfilter_action_slot(), animfilter_action_slots(), animrecord_check_state(), blender::ed::object::apply_objects_internal(), armature_bone_select_poll(), BKE_animdata_copy_id_action(), BKE_collection_add_from_collection(), BKE_collection_object_add_from(), BKE_collection_parent_editable_find_recursive(), BKE_constraint_is_nonlocal_in_liboverride(), BKE_id_can_be_asset(), BKE_id_full_name_ui_prefix_get(), BKE_lib_override_id_tag_on_deg_tag_from_user(), BKE_lib_override_library_copy(), BKE_lib_override_library_id_is_user_deletable(), BKE_lib_override_library_is_system_defined(), BKE_lib_override_library_is_user_edited(), BKE_lib_override_library_main_tag(), BKE_lib_override_library_main_unused_cleanup(), BKE_lib_override_library_make_local(), BKE_lib_override_rna_property_find(), BKE_modifier_is_nonlocal_in_liboverride(), BKE_nlatrack_is_nonlocal_in_liboverride(), BKE_shaderfx_is_nonlocal_in_liboverride(), blend_write(), blend_write(), blend_write(), blend_write(), BLO_main_validate_embedded_liboverrides(), bone_collection_assign_poll(), bone_collection_create_and_assign_poll(), camera_background_image_remove_exec(), blender::ed::outliner::collection_drop_init(), blender::ed::outliner::collection_duplicate_exec(), blender::ed::outliner::collection_edit_in_active_scene_poll(), blender::ed::object::collection_exporter_common_check(), blender::ed::object::collection_link_exec(), blender::ed::outliner::collection_link_exec(), blender::ed::outliner::collection_new_exec(), blender::ed::outliner::collection_parent_from_ID(), blender::ed::object::collection_remove_exec(), blender::ed::object::collection_unlink_exec(), blender::ed::object::collection_unlink_poll(), blender::ed::object::data_transfer_exec(), blender::ed::object::data_transfer_exec_is_object_valid(), blender::ed::object::data_transfer_exec_preprocess_objects(), blender::ed::object::datalayout_transfer_exec(), blender::ed::outliner::do_item_rename(), ED_add_action_channel(), ED_add_action_group_channel(), ED_add_action_layered_channel(), ED_add_action_slot_channel(), ED_add_fcurve_channel(), ED_operator_editable_mesh(), ED_operator_object_active_editable_font(), ED_operator_object_active_editable_mesh(), ED_operator_object_active_local_editable(), ED_operator_object_active_local_editable_ex(), ED_operator_object_active_local_editable_posemode_exclusive(), ED_paint_proj_mesh_data_check(), blender::ed::object::edit_shaderfx_poll_generic(), blender::ed::object::editmode_enter_ex(), blender::ed::object::editmode_toggle_poll(), blender::ed::outliner::id_delete_tag(), blender::ed::outliner::id_is_in_override_hierarchy(), blender::ed::outliner::id_override_library_clear_single(), blender::ed::outliner::id_override_library_create_hierarchy(), blender::ed::outliner::id_override_library_create_hierarchy_pre_process(), image_blend_write(), image_paint_poll_ex(), blender::ed::object::join_shapes_poll(), layer_collection_sync(), layers_poll(), lib_id_preview_editing_poll(), lib_override_cleanup_after_resync(), lib_override_hierarchy_dependencies_skip_check(), lib_override_library_create_post_process(), lib_override_library_resync(), lib_override_overrides_group_tag_recursive(), lib_override_root_find(), blender::ed::object::make_override_library_poll(), blender::ed::outliner::material_drop_poll(), mesh_blend_write(), mesh_customdata_mask_clear_poll(), mesh_customdata_skin_state(), blender::ed::object::modifier_apply_poll(), blender::ed::object::move_to_collection_exec(), move_to_collection_poll(), nlaedit_add_actionclip_exec(), nlaedit_add_sound_exec(), nlaedit_add_tracks_empty(), nlaedit_add_tracks_existing(), nlaedit_apply_scale_exec(), nlaedit_duplicate_exec(), nlaedit_move_down_exec(), nlaedit_move_up_exec(), nlaedit_snap_exec(), nlaedit_swap_exec(), nlatracks_pushdown_exec(), blender::ed::object::object_convert_poll(), blender::ed::object::object_join_poll(), object_materials_supported_poll_ex(), blender::ed::object::object_origin_set_exec(), blender::ed::object::object_remesh_poll(), blender::ed::object::object_speaker_add_exec(), blender::ed::object::object_transfer_mode_invoke(), operator_rigidbody_constraints_editable_poll(), operator_rigidbody_editable_poll(), blender::ed::outliner::outliner_collection_delete(), blender::ed::outliner::outliner_draw_overrides_restrictbuts(), palette_poll(), particle_edit_toggle_poll(), project_paint_prepare_all_faces(), property_collection_liboverride_editable(), rearrange_nla_tracks(), recalcData_nla(), remove_particle_systems_from_object(), rename_anim_channels(), blender::ed::object::reset_clear_override_library_poll(), RNA_property_anim_editable(), RNA_property_driver_editable(), rna_property_editable_do(), RNA_property_overridden(), RNA_property_override_library_status(), scene_collections_object_remove(), blender::ed::object::shade_poll(), blender::ed::object::shape_key_poll(), shapekey_blend_write(), blender::ed::object::skin_edit_poll(), sound_blend_write(), template_ID(), template_id_cb(), texture_paint_toggle_poll(), ui_drop_material_poll(), UI_icon_from_library(), ui_template_id_liboverride_hierarchy_make(), blender::ed::outliner::unlink_collection_fn(), blender::ed::outliner::unlink_material_fn(), blender::ed::outliner::unlink_object_fn(), blender::ed::object::vertex_group_select_exec(), blender::ed::object::vertex_group_supported_poll_ex(), vfont_blend_write(), view3d_mat_drop_poll(), and volume_blend_write().

◆ ID_IS_OVERRIDE_LIBRARY_HIERARCHY_ROOT

#define ID_IS_OVERRIDE_LIBRARY_HIERARCHY_ROOT ( _id)
Value:
((ID *)(_id))->override_library->hierarchy_root == ((ID *)(_id)))
#define ID_IS_OVERRIDE_LIBRARY_REAL(_id)
Definition DNA_ID.h:676

Definition at line 686 of file DNA_ID.h.

Referenced by blender::ed::outliner::collection_collect_data_to_edit(), and blender::ed::outliner::outliner_collect_objects_to_delete().

◆ ID_IS_OVERRIDE_LIBRARY_REAL

#define ID_IS_OVERRIDE_LIBRARY_REAL ( _id)
Value:
(((const ID *)(_id))->override_library != NULL && \
((const ID *)(_id))->override_library->reference != NULL)

Definition at line 676 of file DNA_ID.h.

Referenced by BKE_blendfile_library_relocate(), BKE_blendfile_override(), BKE_lib_override_library_create_from_tag(), BKE_lib_override_library_delete(), BKE_lib_override_library_id_hierarchy_reset(), BKE_lib_override_library_id_reset(), BKE_lib_override_library_id_unused_cleanup(), BKE_lib_override_library_is_hierarchy_leaf(), BKE_lib_override_library_is_user_edited(), BKE_lib_override_library_main_hierarchy_root_ensure(), BKE_lib_override_library_main_operations_create(), BKE_lib_override_library_main_operations_restore(), BKE_lib_override_library_operations_restore(), BKE_lib_override_library_operations_store_end(), BKE_lib_override_library_operations_store_start(), BKE_lib_override_library_status_check_local(), BKE_lib_override_library_status_check_reference(), BKE_lib_override_library_update(), BKE_libblock_copy_in_lib(), BKE_library_id_can_use_filter_id(), BKE_library_make_local(), BKE_modifiers_persistent_uid_init(), blo_do_versions_300(), blender::ed::outliner::collection_collect_data_to_edit(), foreachid_is_hierarchy_leaf_fn(), blender::ed::outliner::TreeElementOverridesBase::get_warning(), blender::ed::outliner::id_delete_tag(), blender::ed::outliner::id_local_fn(), blender::ed::outliner::id_override_library_clear_single(), blender::ed::outliner::id_override_library_create_hierarchy(), blender::ed::outliner::id_override_library_create_hierarchy_pre_process(), blender::ed::outliner::id_override_library_create_hierarchy_process(), blender::ed::outliner::id_override_library_delete_hierarchy(), blender::ed::outliner::id_override_library_reset(), blender::ed::outliner::id_override_library_resync(), lib_id_override_editable_toggle_poll(), lib_override_library_create_do(), lib_override_library_id_hierarchy_recursive_reset(), lib_override_library_main_resync_id_skip_check(), lib_override_library_main_resync_on_library_indirect_level(), lib_override_library_operations_create(), lib_override_library_resync(), lib_override_overrides_group_tag(), lib_override_overrides_group_tag_recursive(), lib_override_prefill_newid_from_existing_overrides(), lib_override_resync_tagging_finalize_recurse(), lib_override_root_find(), lib_override_root_hierarchy_set(), blender::ed::object::make_override_library_exec(), blender::ed::object::make_override_library_invoke(), blender::ed::outliner::outliner_collect_objects_to_delete(), blender::ed::outliner::outliner_draw_mode_column_toggle(), override_idtemplate_menu_poll(), override_idtemplate_poll(), override_idtemplate_reset_exec(), ptcache_add_remove_poll(), ptcache_poll(), blender::ed::object::reset_override_library_exec(), reuse_bmain_data_invalid_local_usages_fix(), reuse_bmain_data_invalid_local_usages_fix_cb(), rna_property_override_check_resync(), template_id_liboverride_hierarchy_collection_root_find_recursive(), UI_icon_from_library(), ui_template_id_liboverride_hierarchy_make(), and write_file_handle().

◆ ID_IS_OVERRIDE_LIBRARY_VIRTUAL

◆ ID_MISSING

#define ID_MISSING ( _id)    ((((const ID *)(_id))->tag & ID_TAG_MISSING) != 0)

◆ ID_NEW_REMAP

#define ID_NEW_REMAP ( a)
Value:
if ((a) && (a)->id.newid) { \
*(void **)&(a) = (a)->id.newid; \
} \
((void)0)

Definition at line 711 of file DNA_ID.h.

Referenced by blender::ed::object::single_obdata_users(), and blender::ed::object::single_object_users().

◆ ID_NEW_SET

◆ ID_REAL_USERS

#define ID_REAL_USERS ( id)    (((const ID *)id)->us - ID_FAKE_USERS(id))

◆ ID_REFCOUNTING_USERS

#define ID_REFCOUNTING_USERS ( id)    (ID_REAL_USERS(id) - ID_EXTRA_REAL_USERS(id))

Amount of 'normal' reference-counting usages of this ID (i.e. excluding the 'fake user' one, and a potential 'extra' shallow/runtime usage).

Definition at line 642 of file DNA_ID.h.

Referenced by blender::ed::outliner::TreeDisplayIDOrphans::build_tree(), and blender::animrig::tests::TEST_F().

◆ ID_TAG_KEEP_ON_UNDO

#define ID_TAG_KEEP_ON_UNDO   (ID_TAG_EXTRAUSER | ID_TAG_MISSING | ID_TAG_RUNTIME)

Most of ID tags are cleared on file write (i.e. also when storing undo steps), since they either have of very short lifetime (not expected to exist across undo steps), or are info that will be re-generated when reading undo steps.

However a few of these need to be explicitly preserved across undo steps.

Definition at line 1013 of file DNA_ID.h.

Referenced by direct_link_id_common(), id_buffer_init_from_id(), and read_libblock_undo_restore_identical().

◆ ID_TYPE_IS_DEPRECATED

#define ID_TYPE_IS_DEPRECATED ( id_type)    ELEM(id_type, ID_IP)

◆ ID_TYPE_SUPPORTS_ASSET_EDITABLE

#define ID_TYPE_SUPPORTS_ASSET_EDITABLE ( id_type)    ELEM(id_type, ID_BR, ID_TE, ID_NT, ID_IM, ID_PC)

◆ ID_TYPE_SUPPORTS_PARAMS_WITHOUT_COW

#define ID_TYPE_SUPPORTS_PARAMS_WITHOUT_COW ( id_type)    ELEM(id_type, ID_ME)

◆ ID_TYPE_USE_COPY_ON_EVAL

◆ INDEX_ID_MAX

◆ MAX_ID_NAME

#define MAX_ID_NAME   66

ID is the first thing included in all serializable types. It provides a common handle to place all data in double-linked lists.

Definition at line 377 of file DNA_ID.h.

Referenced by ANIM_OT_keyframe_delete_by_name(), ANIM_OT_keyframe_insert_by_name(), BKE_blendfile_append(), BKE_blendfile_library_path_explode(), BKE_id_new_name_validate(), BKE_mask_new(), BKE_mball_basis_find(), BKE_mball_is_same_group(), BKE_mball_properties_copy(), BKE_scene_undo_depsgraphs_restore(), Freestyle::BlenderStrokeRenderer::BlenderStrokeRenderer(), blendfile_library_relocate_remap(), bone_mouse_select_menu(), blender::ed::object::collection_create_exec(), blender::ed::object::collection_exporter_add_exec(), blender::ed::object::COLLECTION_OT_create(), blender::ed::object::COLLECTION_OT_exporter_add(), blender::animrig::convert_to_layered_action(), do_version_layers_to_collections(), do_versions_after_linking_280(), find_bhead_from_code_name(), get_default_collection_name(), blender::ed::greasepencil::GREASE_PENCIL_OT_stroke_material_set(), blender::ed::greasepencil::grease_pencil_stroke_material_set_exec(), Uniqueness_Key::hash(), image_new_exec(), IMAGE_OT_new(), IMAGE_OT_unpack(), image_unpack_exec(), blender::io::usd::import_startjob(), init_meta(), ipo_to_animdata(), keyingset_get_from_op_with_error(), lib_override_library_create_from(), lib_override_library_resync(), mask_layer_new_exec(), mask_new_exec(), MASK_OT_layer_new(), MASK_OT_new(), blender::ed::space_node::new_node_tree_exec(), Freestyle::BlenderStrokeRenderer::NewMesh(), blender::nodes::node_composite_render_layer_cc::node_composit_buts_viewlayers(), blender::ed::space_node::NODE_OT_new_node_tree(), object_mouse_select_menu(), blender::ed::object::OBJECT_OT_collection_instance_add(), blender::ed::object::OBJECT_OT_select_same_collection(), blender::ed::object::OBJECT_OT_transform_to_mouse(), blender::ed::object::object_select_same_collection_exec(), blender::ed::outliner::outliner_buttons(), palette_join_exec(), PALETTE_OT_join(), proj_paint_image_create(), RENDER_OT_render(), render_result_exr_file_cache_path(), rna_def_font(), rna_def_ID(), RNA_def_main_masks(), rna_def_mask_layer(), rna_def_maskParent(), rna_def_trackingObject(), rna_def_trackingPlaneTrack(), rna_def_trackingTrack(), scene_undo_depsgraph_gen_key(), screen_render_single_layer_set(), screen_state_to_nonnormal(), seq_disk_cache_get_dir(), SOUND_OT_unpack(), sound_unpack_exec(), blender::bke::tests::TEST(), texture_paint_add_texture_paint_slot_invoke(), unpack_item_exec(), updateDuplicateCustomBoneShapes(), UV_OT_unwrap(), WM_operator_drop_load_path(), WM_operator_properties_id_lookup(), WM_operator_properties_id_lookup_from_name_or_session_uid(), workspace_append_activate_exec(), and WORKSPACE_OT_append_activate().

◆ MAX_IDPROP_NAME

Typedef Documentation

◆ DrawData

typedef struct DrawData DrawData

◆ DrawDataFreeCb

typedef void(* DrawDataFreeCb) (struct DrawData *engine_data)

Definition at line 40 of file DNA_ID.h.

◆ DrawDataInitCb

typedef void(* DrawDataInitCb) (struct DrawData *engine_data)

Definition at line 39 of file DNA_ID.h.

◆ DrawDataList

typedef struct DrawDataList DrawDataList

◆ eID_Index

typedef enum eID_Index eID_Index

This enum defines the index assigned to each type of IDs in the array returned by set_listbasepointers, and by extension, controls the default order in which each ID type is processed during standard 'foreach' looping over all IDs of a Main data-base.

About Order:

This is (loosely) defined with a relationship order in mind, from lowest level (ID types using, referencing almost no other ID types) to highest level (ID types potentially using many other ID types).

So e.g. it ensures that this dependency chain is respected: Material <- Mesh <- Object <- Collection <- Scene

Default order of processing of IDs in 'foreach' macros (FOREACH_MAIN_ID_BEGIN and the like), built on top of set_listbasepointers, is actually reversed compared to the order defined here, since processing usually needs to happen on users before it happens on used IDs (when freeing e.g.).

DO NOT rely on this order as being full-proofed dependency order, there are many cases were it can be violated (most obvious cases being custom properties and drivers, which can reference any other ID types).

However, this order can be considered as an optimization heuristic, especially when processing relationships in a non-recursive pattern: in typical cases, a vast majority of those relationships can be processed fine in the first pass, and only few additional passes are required to address all remaining relationship cases. See e.g. how BKE_library_unused_linked_data_set_tag is doing this.

◆ ID

typedef struct ID ID

◆ ID_Runtime

typedef struct ID_Runtime ID_Runtime

◆ ID_Runtime_Remap

typedef struct ID_Runtime_Remap ID_Runtime_Remap

Status used and counters created during id-remapping.

◆ IDOverrideLibrary

typedef struct IDOverrideLibrary IDOverrideLibrary

◆ IDOverrideLibraryProperty

typedef struct IDOverrideLibraryProperty IDOverrideLibraryProperty

A single overridden property, contain all operations on this one.

◆ IDOverrideLibraryPropertyOperation

typedef struct IDOverrideLibraryPropertyOperation IDOverrideLibraryPropertyOperation

◆ IDOverrideLibraryRuntime

typedef struct IDOverrideLibraryRuntime IDOverrideLibraryRuntime

◆ IDProperty

typedef struct IDProperty IDProperty

◆ IDPropertyData

typedef struct IDPropertyData IDPropertyData

◆ IDPropertyUIData

typedef struct IDPropertyUIData IDPropertyUIData

◆ IDPropertyUIDataBool

typedef struct IDPropertyUIDataBool IDPropertyUIDataBool

For IDP_UI_DATA_TYPE_BOOLEAN Use int8_t because DNA does not support bool.

◆ IDPropertyUIDataEnumItem

typedef struct IDPropertyUIDataEnumItem IDPropertyUIDataEnumItem

◆ IDPropertyUIDataFloat

typedef struct IDPropertyUIDataFloat IDPropertyUIDataFloat

◆ IDPropertyUIDataID

typedef struct IDPropertyUIDataID IDPropertyUIDataID

◆ IDPropertyUIDataInt

typedef struct IDPropertyUIDataInt IDPropertyUIDataInt

◆ IDPropertyUIDataString

typedef struct IDPropertyUIDataString IDPropertyUIDataString

◆ IDRecalcFlag

typedef enum IDRecalcFlag IDRecalcFlag

◆ Library

typedef struct Library Library

For each library file used, a Library struct is added to Main.

◆ Library_Runtime

typedef struct Library_Runtime Library_Runtime

◆ LibraryWeakReference

typedef struct LibraryWeakReference LibraryWeakReference

A weak library/ID reference for local data that has been appended, to allow re-using that local data instead of creating a new copy of it in future appends.

NOTE: This is by design a week reference, in other words code should be totally fine and perform a regular append if it cannot find a valid matching local ID.

NOTE: There should always be only one single ID in current Main matching a given linked reference.

◆ PreviewImage

typedef struct PreviewImage PreviewImage

This type allows shallow copies. Use BKE_previewimg_free() to release contained resources. Don't call this for shallow copies (or the original instance will have dangling pointers).

◆ PreviewImageRuntimeHandle

Definition at line 22 of file DNA_ID.h.

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
LIBOVERRIDE_OP_NOOP 
LIBOVERRIDE_OP_REPLACE 
LIBOVERRIDE_OP_ADD 
LIBOVERRIDE_OP_SUBTRACT 
LIBOVERRIDE_OP_MULTIPLY 
LIBOVERRIDE_OP_INSERT_AFTER 
LIBOVERRIDE_OP_INSERT_BEFORE 

Definition at line 225 of file DNA_ID.h.

◆ anonymous enum

anonymous enum
Enumerator
LIBOVERRIDE_OP_FLAG_MANDATORY 

User cannot remove that override operation.

LIBOVERRIDE_OP_FLAG_LOCKED 

User cannot change that override operation.

LIBOVERRIDE_OP_FLAG_IDPOINTER_MATCH_REFERENCE 

For overrides of ID pointers: this override still matches (follows) the hierarchy of the reference linked data.

LIBOVERRIDE_OP_FLAG_IDPOINTER_ITEM_USE_ID 

For overrides of ID pointers within RNA collections: this override is using the ID pointer in addition to the item name (to fully disambiguate the reference, since IDs from different libraries can have a same name).

Definition at line 245 of file DNA_ID.h.

◆ anonymous enum

anonymous enum
Enumerator
LIBOVERRIDE_PROP_OP_TAG_UNUSED 

This override property (operation) is unused and should be removed by cleanup process.

LIBOVERRIDE_PROP_TAG_NEEDS_RETORE 

This override property is forbidden and should be restored to its linked reference value.

Definition at line 291 of file DNA_ID.h.

◆ anonymous enum

anonymous enum
Enumerator
LIBOVERRIDE_TAG_NEEDS_RELOAD 

This override needs to be reloaded.

LIBOVERRIDE_TAG_NEEDS_RESTORE 

This override contains properties with forbidden changes, which should be restored to their linked reference value.

LIBOVERRIDE_TAG_RESYNC_ISOLATED_FROM_ROOT 

This override is detected as being cut from its hierarchy root. Temporarily used during resync process.

LIBOVERRIDE_TAG_NEED_RESYNC_ORIGINAL 

This override was detected as needing resync outside of the resync process (it is a 'really need resync' case, not a 'need resync for hierarchy reasons' one). Temporarily used during resync process.

Definition at line 307 of file DNA_ID.h.

◆ anonymous enum

anonymous enum
Enumerator
LIBOVERRIDE_FLAG_NO_HIERARCHY 

The override data-block should not be considered as part of an override hierarchy (generally because it was created as an single override, outside of any hierarchy consideration).

LIBOVERRIDE_FLAG_SYSTEM_DEFINED 

The override ID is required for the system to work (because of ID dependencies), but is not seen as editable by the user.

Definition at line 357 of file DNA_ID.h.

◆ anonymous enum

anonymous enum

ID_Runtime_Remap.status

Enumerator
ID_REMAP_IS_LINKED_DIRECT 

new_id is directly linked in current .blend.

ID_REMAP_IS_USER_ONE_SKIPPED 

There was some skipped 'user_one' usages of old_id.

Definition at line 380 of file DNA_ID.h.

◆ anonymous enum

anonymous enum
Enumerator
PRV_TAG_DEFFERED_RENDERING 

Deferred preview is being loaded.

PRV_TAG_DEFFERED_DELETE 

Deferred preview should be deleted asap.

Definition at line 589 of file DNA_ID.h.

◆ anonymous enum

anonymous enum

id->flag (persistent).

Enumerator
ID_FLAG_FAKEUSER 

Don't delete the data-block even if unused.

ID_FLAG_EMBEDDED_DATA 

The data-block is a sub-data of another one. Direct persistent references are not allowed.

ID_FLAG_INDIRECT_WEAK_LINK 

Data-block is from a library and linked indirectly, with ID_TAG_INDIRECT tag set. But the current .blend file also has a weak pointer to it that we want to restore if possible, and silently drop if it's missing.

ID_FLAG_EMBEDDED_DATA_LIB_OVERRIDE 

The data-block is a sub-data of another one, which is an override. Note that this also applies to shape-keys, even though they are not 100% embedded data.

ID_FLAG_LIB_OVERRIDE_RESYNC_LEFTOVER 

The override data-block appears to not be needed anymore after resync with linked data, but it was kept around (because e.g. detected as user-edited).

ID_FLAG_CLIPBOARD_MARK 

This id was explicitly copied as part of a clipboard copy operation. When reading the clipboard back, this can be used to check which ID's are intended to be part of the clipboard, compared with ID's that were indirectly referenced.

While the flag is typically cleared, a saved file may have this set for some data-blocks, so it must be treated as dirty.

Definition at line 718 of file DNA_ID.h.

◆ anonymous enum

anonymous enum

id->tag (runtime-only).

Those tags belong to three different categories, which have different expected handling in code:

  • RESET_BEFORE_USE: piece of code that wants to use such flag has to ensure they are properly 'reset' first.
  • RESET_AFTER_USE: piece of code that wants to use such flag has to ensure they are properly 'reset' after usage (though 'lifetime' of those flags is a bit fuzzy, e.g. _RECALC ones are reset on depsgraph evaluation...).
  • RESET_NEVER: these flags are 'status' ones, and never actually need any reset (except on initialization during .blend file reading).
Note
These tags are purely runtime, so changing there value is not an issue. When adding new tags, please put them in the relevant category and always keep their values strictly increasing.
Enumerator
ID_TAG_LOCAL 

Long-life tags giving important info about general ID management.

These tags are typically not changed often, if ever, during an ID's life. ID is from current .blend file.

RESET_NEVER

ID_TAG_EXTERN 

ID is from a library, but is used (linked) directly by current .blend file.

RESET_NEVER

ID_TAG_INDIRECT 

ID is from a library, and is only used (linked) indirectly through other libraries.

RESET_NEVER

ID_TAG_RUNTIME 

ID is considered as runtime, and should not be saved when writing .blend file, nor influence (in)direct status of linked data.

Only meaningful for IDs belonging to regular Main database, all other cases are implicitly considered runtime-only.

RESET_NEVER

ID_TAG_MISSING 

ID is a place-holder, an 'empty shell' (because the real one could not be linked from its library e.g.).

RESET_NEVER

ID_TAG_EXTRAUSER 

ID has an extra virtual user (aka 'ensured real', as set by e.g. some editors, not to be confused with the ID_FLAG_FAKEUSER flag).

RESET_NEVER

Note
This tag does not necessarily mean the actual user count of the ID is increased, this is defined by ID_TAG_EXTRAUSER_SET.
ID_TAG_EXTRAUSER_SET 

ID actually has increased user-count for the extra virtual user.

RESET_NEVER

ID_TAG_LIBOVERRIDE_REFOK 

ID is up-to-date regarding its reference (only for library overrides).

RESET_NEVER

ID_TAG_LIBOVERRIDE_AUTOREFRESH 

ID needs an auto-diffing execution, if enabled (only for library overrides).

RESET_NEVER

ID_TAG_LIBOVERRIDE_NEED_RESYNC 

ID is a library override that needs re-sync to its linked reference.

Note
Also used by readfile code when creating a missing ID placeholder if it is detected as being a linked liboverride ID.

RESET_NEVER

ID_TAG_NEW 

Short-life tags used during specific processes, like blend-file reading. ID is newly duplicated/copied (see ID_NEW_SET macro above).

RESET_AFTER_USE

Note
Also used internally in readfile.cc to mark data-blocks needing do_versions.
ID_TAG_PRE_EXISTING 

ID is already existing. Set before linking, to distinguish between existing data-blocks and newly linked ones.

RESET_AFTER_USE

ID_TAG_NEED_EXPAND 

Tag used internally in readfile.cc, to mark IDs needing to be expanded (only done once).

RESET_AFTER_USE

ID_TAG_ID_LINK_PLACEHOLDER 

Tag used internally in readfile.cc, to mark ID placeholders for linked data-blocks needing to be read.

RESET_AFTER_USE

ID_TAG_NEED_LINK 

Tag used internally in readfile.cc, to mark IDs needing to be 'lib-linked', i.e. to get their pointers to other data-blocks updated from the 'UID' values stored in .blend files to the new, actual pointers.

RESET_AFTER_USE

ID_TAG_UNDO_OLD_ID_REUSED_UNCHANGED 

ID is being re-used from the old Main (instead of read from memfile), during memfile undo processing, because it was detected as unchanged.

Note
Also means that such ID does not need to be lib-linked during undo readfile process.

RESET_AFTER_USE

ID_TAG_UNDO_OLD_ID_REUSED_NOUNDO 

ID is being re-used from the old Main (instead of read from memfile), during memfile undo processing, because it is a 'NO_UNDO' type of ID.

Note
Also means that such ID does not need to be lib-linked during undo readfile process. It does need to be relinked in a different way however, doing a session_uid-based lookup into the newly read main database.

RESET_AFTER_USE

ID_TAG_UNDO_OLD_ID_REREAD_IN_PLACE 

ID has be re-read in-place, the ID address is the same as in the old main, but the content is different.

RESET_AFTER_USE

ID_TAG_TEMP_MAIN 

Tags for special kind of IDs, not living in regular BMain data-base.

IDs with such tags have typically a short life. ID is part of a temporary Main which is expected to be freed in a short time-frame.

RESET_NEVER

Don't allow assigning this to non-temporary members (since it's likely to cause errors). When set ID.session_uid isn't initialized, since the data isn't part of the session.

ID_TAG_NO_MAIN 

General ID management info, for freeing or copying behavior e.g. ID is not listed/stored in any Main database.

RESET_NEVER

ID_TAG_LOCALIZED 

ID is fully outside of any ID management area, and should be considered as a purely independent data.

RESET_NEVER

Note
Only used by node-trees currently.
ID_TAG_COPIED_ON_EVAL 

ID is an evaluated/localized version.

RESET_NEVER

Warning
This should not be cleared on existing data. If support for this is needed, see #88026 as this flag controls memory ownership of physics shared pointers.
ID_TAG_COPIED_ON_EVAL_FINAL_RESULT 

ID is not the original evaluated ID created by the depsgraph, but has been re-allocated during the evaluation process of another ID.

RESET_NEVER

Typical example is object data, when evaluating the object's modifier stack the final obdata can be different than the evaluated initial obdata ID.

ID_TAG_NO_USER_REFCOUNT 

ID management status tags related to non-standard BMain IDs. Datablock does not refcount usages of other IDs.

RESET_NEVER

ID_TAG_NOT_ALLOCATED 

ID was not allocated by standard system (BKE_libblock_alloc), do not free its memory (usual type-specific freeing is called though).

RESET_NEVER

ID_TAG_DOIT 

Free to use tag, often used in BKE code to mark IDs to be processed.

RESET_BEFORE_USE

Todo
Make it a RESET_AFTER_USE too.

Definition at line 770 of file DNA_ID.h.

◆ eID_Index

enum eID_Index

This enum defines the index assigned to each type of IDs in the array returned by set_listbasepointers, and by extension, controls the default order in which each ID type is processed during standard 'foreach' looping over all IDs of a Main data-base.

About Order:

This is (loosely) defined with a relationship order in mind, from lowest level (ID types using, referencing almost no other ID types) to highest level (ID types potentially using many other ID types).

So e.g. it ensures that this dependency chain is respected: Material <- Mesh <- Object <- Collection <- Scene

Default order of processing of IDs in 'foreach' macros (FOREACH_MAIN_ID_BEGIN and the like), built on top of set_listbasepointers, is actually reversed compared to the order defined here, since processing usually needs to happen on users before it happens on used IDs (when freeing e.g.).

DO NOT rely on this order as being full-proofed dependency order, there are many cases were it can be violated (most obvious cases being custom properties and drivers, which can reference any other ID types).

However, this order can be considered as an optimization heuristic, especially when processing relationships in a non-recursive pattern: in typical cases, a vast majority of those relationships can be processed fine in the first pass, and only few additional passes are required to address all remaining relationship cases. See e.g. how BKE_library_unused_linked_data_set_tag is doing this.

Enumerator
INDEX_ID_LI 
INDEX_ID_IP 
INDEX_ID_AC 
INDEX_ID_GD_LEGACY 
INDEX_ID_NT 
INDEX_ID_VF 
INDEX_ID_TXT 
INDEX_ID_SO 
INDEX_ID_MSK 
INDEX_ID_IM 
INDEX_ID_MC 
INDEX_ID_TE 
INDEX_ID_MA 
INDEX_ID_LS 
INDEX_ID_WO 
INDEX_ID_CF 
INDEX_ID_PA 
INDEX_ID_KE 
INDEX_ID_AR 
INDEX_ID_ME 
INDEX_ID_CU_LEGACY 
INDEX_ID_MB 
INDEX_ID_CV 
INDEX_ID_PT 
INDEX_ID_VO 
INDEX_ID_LT 
INDEX_ID_LA 
INDEX_ID_CA 
INDEX_ID_SPK 
INDEX_ID_LP 
INDEX_ID_GP 
INDEX_ID_OB 
INDEX_ID_GR 
INDEX_ID_PAL 
INDEX_ID_PC 
INDEX_ID_BR 
INDEX_ID_SCE 
INDEX_ID_SCR 
INDEX_ID_WS 
INDEX_ID_WM 
INDEX_ID_NULL 

Definition at line 1246 of file DNA_ID.h.

◆ eLibrary_Tag

#Library.runtime.tag

Enumerator
LIBRARY_TAG_RESYNC_REQUIRED 

Automatic recursive re-synchronize was needed when linking/loading data from that library.

LIBRARY_ASSET_EDITABLE 

Data-blocks from this library are editable in the UI despite being linked. Used for asset that can be temporarily or permanently edited. Currently all data-blocks from this library will be edited. In the future this may need to become per data-block to handle cases where a library is both used for editable assets and linked into the blend file for other reasons.

LIBRARY_ASSET_FILE_WRITABLE 

The blend file of this library is writable for asset editing.

LIBRARY_IS_ASSET_EDIT_FILE 

The blend file of this library has the G_FILE_ASSET_EDIT_FILE flag set (refer to it for more info).

Definition at line 539 of file DNA_ID.h.

◆ ePreviewImage_Flag

Enumerator
PRV_CHANGED 
PRV_USER_EDITED 

If user-edited, do not auto-update this anymore!

PRV_RENDERING 

Definition at line 580 of file DNA_ID.h.

◆ IDRecalcFlag

Enumerator
ID_RECALC_TRANSFORM 
ID_RECALC_GEOMETRY 
ID_RECALC_ANIMATION 
ID_RECALC_PSYS_REDO 
ID_RECALC_PSYS_RESET 
ID_RECALC_PSYS_CHILD 
ID_RECALC_PSYS_PHYS 
ID_RECALC_SHADING 
ID_RECALC_SELECT 
ID_RECALC_BASE_FLAGS 
ID_RECALC_POINT_CACHE 
ID_RECALC_EDITORS 
ID_RECALC_SYNC_TO_EVAL 
ID_RECALC_SEQUENCER_STRIPS 
ID_RECALC_FRAME_CHANGE 
ID_RECALC_AUDIO_FPS 
ID_RECALC_AUDIO_VOLUME 
ID_RECALC_AUDIO_MUTE 
ID_RECALC_AUDIO_LISTENER 
ID_RECALC_AUDIO 
ID_RECALC_PARAMETERS 
ID_RECALC_SOURCE 
ID_RECALC_TAG_FOR_UNDO 
ID_RECALC_NTREE_OUTPUT 
ID_RECALC_HIERARCHY 
ID_RECALC_PROVISION_27 
ID_RECALC_PROVISION_28 
ID_RECALC_PROVISION_29 
ID_RECALC_PROVISION_30 
ID_RECALC_PROVISION_31 
ID_RECALC_ANIMATION_NO_FLUSH 
ID_RECALC_GEOMETRY_ALL_MODES 
ID_RECALC_ALL 
ID_RECALC_PSYS_ALL 

Definition at line 1016 of file DNA_ID.h.