|
Blender
V2.93
|
#include "BLI_sys_types.h"Go to the source code of this file.
Classes | |
| struct | IDCacheKey |
| struct | IDTypeInfo |
Typedefs | |
| typedef struct IDCacheKey | IDCacheKey |
| typedef void(* | IDTypeInitDataFunction) (struct ID *id) |
| typedef void(* | IDTypeCopyDataFunction) (struct Main *bmain, struct ID *id_dst, const struct ID *id_src, const int flag) |
| typedef void(* | IDTypeFreeDataFunction) (struct ID *id) |
| typedef void(* | IDTypeMakeLocalFunction) (struct Main *bmain, struct ID *id, const int flags) |
| typedef void(* | IDTypeForeachIDFunction) (struct ID *id, struct LibraryForeachIDData *data) |
| typedef enum eIDTypeInfoCacheCallbackFlags | eIDTypeInfoCacheCallbackFlags |
| typedef void(* | IDTypeForeachCacheFunctionCallback) (struct ID *id, const struct IDCacheKey *cache_key, void **cache_p, uint flags, void *user_data) |
| typedef void(* | IDTypeForeachCacheFunction) (struct ID *id, IDTypeForeachCacheFunctionCallback function_callback, void *user_data) |
| typedef struct ID *(* | IDTypeEmbeddedOwnerGetFunction) (struct Main *bmain, struct ID *id) |
| typedef void(* | IDTypeBlendWriteFunction) (struct BlendWriter *writer, struct ID *id, const void *id_address) |
| typedef void(* | IDTypeBlendReadDataFunction) (struct BlendDataReader *reader, struct ID *id) |
| typedef void(* | IDTypeBlendReadLibFunction) (struct BlendLibReader *reader, struct ID *id) |
| typedef void(* | IDTypeBlendReadExpandFunction) (struct BlendExpander *expander, struct ID *id) |
| typedef void(* | IDTypeBlendReadUndoPreserve) (struct BlendLibReader *reader, struct ID *id_new, struct ID *id_old) |
| typedef void(* | IDTypeLibOverrideApplyPost) (struct ID *id_dst, struct ID *id_src) |
| typedef struct IDTypeInfo | IDTypeInfo |
Enumerations | |
| enum | { IDTYPE_FLAGS_NO_COPY = 1 << 0 , IDTYPE_FLAGS_NO_LIBLINKING = 1 << 1 , IDTYPE_FLAGS_NO_MAKELOCAL = 1 << 2 , IDTYPE_FLAGS_NO_ANIMDATA = 1 << 3 } |
| enum | eIDTypeInfoCacheCallbackFlags { IDTYPE_CACHE_CB_FLAGS_PERSISTENT = 1 << 0 } |
ID type structure, helping to factorize common operations and data for all data-block types.
Definition in file BKE_idtype.h.
| typedef struct IDCacheKey IDCacheKey |
| typedef void(* IDTypeBlendReadDataFunction) (struct BlendDataReader *reader, struct ID *id) |
Definition at line 103 of file BKE_idtype.h.
| typedef void(* IDTypeBlendReadExpandFunction) (struct BlendExpander *expander, struct ID *id) |
Definition at line 105 of file BKE_idtype.h.
| typedef void(* IDTypeBlendReadLibFunction) (struct BlendLibReader *reader, struct ID *id) |
Definition at line 104 of file BKE_idtype.h.
| typedef void(* IDTypeBlendReadUndoPreserve) (struct BlendLibReader *reader, struct ID *id_new, struct ID *id_old) |
Definition at line 107 of file BKE_idtype.h.
| typedef void(* IDTypeBlendWriteFunction) (struct BlendWriter *writer, struct ID *id, const void *id_address) |
Definition at line 100 of file BKE_idtype.h.
| typedef void(* IDTypeCopyDataFunction) (struct Main *bmain, struct ID *id_dst, const struct ID *id_src, const int flag) |
| flag | Copying options (see BKE_lib_id.h's LIB_ID_COPY_... flags for more). |
Definition at line 72 of file BKE_idtype.h.
Definition at line 94 of file BKE_idtype.h.
| typedef void(* IDTypeForeachCacheFunction) (struct ID *id, IDTypeForeachCacheFunctionCallback function_callback, void *user_data) |
Definition at line 94 of file BKE_idtype.h.
| typedef void(* IDTypeForeachCacheFunctionCallback) (struct ID *id, const struct IDCacheKey *cache_key, void **cache_p, uint flags, void *user_data) |
Definition at line 89 of file BKE_idtype.h.
| typedef void(* IDTypeForeachIDFunction) (struct ID *id, struct LibraryForeachIDData *data) |
Definition at line 82 of file BKE_idtype.h.
Definition at line 77 of file BKE_idtype.h.
| typedef struct IDTypeInfo IDTypeInfo |
Definition at line 69 of file BKE_idtype.h.
Definition at line 111 of file BKE_idtype.h.
| flag | See BKE_lib_id.h's LIB_ID_MAKELOCAL_... flags. |
Definition at line 80 of file BKE_idtype.h.
| anonymous enum |
| Enumerator | |
|---|---|
| IDTYPE_FLAGS_NO_COPY | Indicates that the given IDType does not support copying. |
| IDTYPE_FLAGS_NO_LIBLINKING | Indicates that the given IDType does not support linking/appending from a library file. |
| IDTYPE_FLAGS_NO_MAKELOCAL | Indicates that the given IDType does not support making a library-linked ID local. |
| IDTYPE_FLAGS_NO_ANIMDATA | Indicates that the given IDType does not have animation data. |
Definition at line 43 of file BKE_idtype.h.
| Enumerator | |
|---|---|
| IDTYPE_CACHE_CB_FLAGS_PERSISTENT | Indicates to the callback that that cache may be stored in the .blend file, so its pointer should not be cleared at read-time. |
Definition at line 84 of file BKE_idtype.h.
| bool BKE_idtype_cache_key_cmp | ( | const void * | key_a_v, |
| const void * | key_b_v | ||
| ) |
Definition at line 58 of file idtype.c.
References IDCacheKey::cache_v, IDCacheKey::id_session_uuid, and IDCacheKey::offset_in_ID.
Referenced by blo_cache_storage_init().
| uint BKE_idtype_cache_key_hash | ( | const void * | key_v | ) |
Definition at line 50 of file idtype.c.
References BLI_ghashutil_combine_hash(), BLI_ghashutil_ptrhash(), BLI_ghashutil_uinthash(), IDCacheKey::cache_v, hash, IDCacheKey::id_session_uuid, and IDCacheKey::offset_in_ID.
Referenced by blo_cache_storage_init().
| const struct IDTypeInfo* BKE_idtype_get_info_from_id | ( | const struct ID * | id | ) |
Referenced by BKE_id_copy_ex(), BKE_lib_id_make_local(), BKE_libblock_free_datablock(), BKE_libblock_init_empty(), blo_cache_storage_init(), blo_cache_storage_old_bmain_clear(), BLO_expand_main(), collection_duplicate_exec(), direct_link_id(), id_swap(), lib_link_all(), lib_query_unused_ids_tag_recurse(), library_foreach_ID_link(), outliner_collection_delete(), RNA_find_real_ID_and_path(), RNA_struct_override_apply(), and write_file_handle().
| const struct IDTypeInfo* BKE_idtype_get_info_from_idcode | ( | const short | id_code | ) |
Definition at line 131 of file idtype.c.
References ARRAY_SIZE, BKE_idtype_idcode_to_index(), id_types, and NULL.
Referenced by BKE_idtype_get_info_from_id(), BKE_idtype_id_foreach_cache(), BKE_idtype_idcode_is_linkable(), BKE_idtype_idcode_is_valid(), BKE_idtype_idcode_to_name(), BKE_idtype_idcode_to_name_plural(), BKE_idtype_idcode_to_translation_context(), BKE_libblock_get_alloc_info(), and id_type_can_have_animdata().
| void BKE_idtype_id_foreach_cache | ( | struct ID * | id, |
| IDTypeForeachCacheFunctionCallback | function_callback, | ||
| void * | user_data | ||
| ) |
Wrapper around IDTypeInfo foreach_cache that also handles embedded IDs.
Definition at line 480 of file idtype.c.
References BKE_idtype_get_info_from_id(), BKE_idtype_get_info_from_idcode(), IDTypeInfo::foreach_cache, GS, id, Collection::id, bNodeTree::id, ID_NT, ID_SCE, Scene::master_collection, ID::name, ntreeFromID(), NULL, scene, and user_data.
Referenced by blo_cache_storage_init(), blo_cache_storage_old_bmain_clear(), and direct_link_id().
| short BKE_idtype_idcode_from_idfilter | ( | const uint64_t | idfilter | ) |
Convert an idfilter into an idcode (e.g. FILTER_ID_OB -> ID_OB).
Definition at line 294 of file idtype.c.
References BR, CASE_IDFILTER, and LT.
| short BKE_idtype_idcode_from_index | ( | const int | index | ) |
Get an idcode from an index (e.g. INDEX_ID_OB -> ID_OB).
Definition at line 407 of file idtype.c.
References BR, CASE_IDCODE, ID_LINK_PLACEHOLDER, INDEX_ID_NULL, and LT.
Referenced by add_loose_object_data_to_scene(), BKE_idtype_idcode_iter_step(), library_link_clear_tag(), and outliner_orphans_purge_invoke().
| short BKE_idtype_idcode_from_name | ( | const char * | idtype_name | ) |
Convert an ID-type name into an idcode (ie. ID_SCE)
| idtype_name | The ID-type's "user visible name" to convert. |
Definition at line 208 of file idtype.c.
References BLI_assert, IDTypeInfo::id_code, idtype_get_info_from_name(), and NULL.
Referenced by groupname_to_code(), IMB_thumb_load_blend(), wm_link_append_exec(), and wm_link_append_item_poll().
| bool BKE_idtype_idcode_is_linkable | ( | const short | idcode | ) |
Return non-zero when an ID type is linkable.
| idcode | The code to check. |
Definition at line 232 of file idtype.c.
References BKE_idtype_get_info_from_idcode(), BLI_assert, IDTypeInfo::flags, IDTYPE_FLAGS_NO_LIBLINKING, and NULL.
Referenced by BKE_id_can_be_asset(), BKE_lib_override_library_create_from_tag(), BKE_library_make_local(), BLO_blendhandle_get_linkable_groups(), BLO_library_link_copypaste(), bpy_lib_enter(), bpy_lib_exit(), id_lib_extern(), id_lib_indirect_weak_link(), lib_id_expand_local_cb(), lib_relocate_do(), link_named_part(), read_file_bhead_idname_map_create(), read_library_linked_id(), wm_link_append_item_poll(), and write_libraries().
| bool BKE_idtype_idcode_is_valid | ( | const short | idcode | ) |
Return if the ID code is a valid ID code.
| idcode | The code to check. |
Definition at line 221 of file idtype.c.
References BKE_idtype_get_info_from_idcode(), and NULL.
Referenced by blo_bhead_is_id_valid_type(), BLO_blendhandle_get_linkable_groups(), and link_named_part().
| short BKE_idtype_idcode_iter_step | ( | int * | index | ) |
Return an ID code and steps the index forward 1.
| index | start as 0. |
Definition at line 472 of file idtype.c.
References ARRAY_SIZE, BKE_idtype_idcode_from_index(), and id_types.
Referenced by BKE_main_idmap_create(), bpy_lib_enter(), and bpy_lib_exit().
| uint64_t BKE_idtype_idcode_to_idfilter | ( | const short | idcode | ) |
Convert an idcode into an idfilter (e.g. ID_OB -> FILTER_ID_OB).
Definition at line 242 of file idtype.c.
References BR, CASE_IDFILTER, and LT.
Referenced by BLO_library_link_copypaste(), groupname_to_filter_id(), and previews_clear_exec().
| int BKE_idtype_idcode_to_index | ( | const short | idcode | ) |
Convert an idcode into an index (e.g. ID_OB -> INDEX_ID_OB).
Definition at line 345 of file idtype.c.
References BR, CASE_IDINDEX, ID_LINK_PLACEHOLDER, INDEX_ID_NULL, and LT.
Referenced by blender::deg::Depsgraph::add_id_node(), BKE_idtype_get_info_from_idcode(), BKE_lib_query_unused_ids_tag(), DEG_graph_id_type_tag(), DEG_id_type_any_exists(), DEG_id_type_updated(), lib_query_unused_ids_tag_recurse(), and tree_element_id_type_to_index().
| const char* BKE_idtype_idcode_to_name | ( | const short | idcode | ) |
Convert an idcode into a name.
| idcode | The code to convert. |
Definition at line 168 of file idtype.c.
References BKE_idtype_get_info_from_idcode(), BLI_assert, IDTypeInfo::name, and NULL.
Referenced by apply_objects_internal(), BKE_id_new(), BKE_id_new_name_validate(), BKE_id_new_nomain(), BKE_mesh_new_nomain(), BKE_pointcloud_new_nomain(), BLO_blendhandle_get_linkable_groups(), clear_keyframe(), datadropper_init(), delete_key_button_exec(), delete_keyframe(), filelist_readjob_main_assets(), pyrna_struct_keyframe_delete(), read_library_linked_id(), rna_id_write_error(), uiTemplatePreview(), and WM_operator_drop_load_path().
| const char* BKE_idtype_idcode_to_name_plural | ( | const short | idcode | ) |
Convert an idcode into a name (plural).
| idcode | The code to convert. |
Definition at line 182 of file idtype.c.
References BKE_idtype_get_info_from_idcode(), BLI_assert, IDTypeInfo::name_plural, and NULL.
Referenced by bpy_lib_enter(), bpy_lib_exit(), idp_repr_fn_recursive(), outliner_idcode_to_plural(), outliner_orphans_purge_invoke(), pyrna_prop_repr_ex(), pyrna_struct_repr(), RNA_path_full_ID_py(), and wm_drag_name().
| const char* BKE_idtype_idcode_to_translation_context | ( | const short | idcode | ) |
Convert an idcode into its translations' context.
| idcode | The code to convert. |
Definition at line 195 of file idtype.c.
References BKE_idtype_get_info_from_idcode(), BLI_assert, BLT_I18NCONTEXT_DEFAULT, NULL, and IDTypeInfo::translation_context.
| void BKE_idtype_init | ( | void | ) |
Definition at line 125 of file idtype.c.
References id_type_init().
Referenced by main(), BlendfileLoadingBaseTest::SetUpTestCase(), and blender::bke::tests::TEST().
|
extern |
|
extern |
Definition at line 311 of file armature.c.
|
extern |
|
extern |
|
extern |
Definition at line 123 of file cachefile.c.
|
extern |
|
extern |
|
extern |
Definition at line 368 of file collection.c.
|
extern |
|
extern |
|
extern |
|
extern |
|
extern |
|
extern |
|
extern |
Definition at line 93 of file lib_id.c.
Referenced by id_type_init().
|
extern |
Definition at line 87 of file lightprobe.c.
|
extern |
Definition at line 747 of file linestyle.c.
|
extern |
Definition at line 186 of file lattice.c.
Referenced by blender::bke::tests::test_lattice_deform_free(), and blender::bke::tests::test_lattice_deform_init().
|
extern |
Definition at line 254 of file material.c.
|
extern |
|
extern |
Definition at line 342 of file movieclip.c.
|
extern |
Definition at line 344 of file mesh.c.
Referenced by blender::bke::tests::test_lattice_deform_free(), and blender::bke::tests::test_lattice_deform_init().
|
extern |
|
extern |
|
extern |
Definition at line 1135 of file object.c.
Referenced by blender::bke::tests::test_lattice_deform_free(), and blender::bke::tests::test_lattice_deform_init().
|
extern |
Definition at line 491 of file particle.c.
|
extern |
|
extern |
|
extern |
Definition at line 170 of file pointcloud.cc.
|
extern |
Definition at line 1712 of file scene.c.
Referenced by blender::bke::tests::TEST().
|
extern |
|
extern |
Definition at line 152 of file simulation.cc.
|
extern |
Definition at line 200 of file blenkernel/intern/sound.c.
|
extern |
|
extern |
|
extern |
|
extern |
|
extern |
|
extern |
|
extern |
|
extern |
Definition at line 173 of file workspace.c.