|
Blender V4.5
|
#include "BLI_string_ref.hh"Go to the source code of this file.
Classes | |
| struct | blender::bke::library::LibraryRuntime |
Namespaces | |
| namespace | blender |
| namespace | blender::bke |
| namespace | blender::bke::library |
Enumerations | |
| 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 } |
Functions | |
| Library * | blender::bke::library::search_filepath_abs (ListBase *libraries, blender::StringRef filepath_abs) |
| void | BKE_library_filepath_set (Main *bmain, Library *lib, const char *filepath) |
| void | BKE_library_main_rebuild_hierarchy (Main *bmain) |
API to manage Library data-blocks.
Definition in file BKE_library.hh.
| enum eLibrary_Tag |
#LibraryRuntime.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 60 of file BKE_library.hh.
Definition at line 171 of file library.cc.
References BKE_main_blendfile_path(), BLI_path_abs(), BLI_path_is_rel(), lib, and STRNCPY().
Referenced by BLO_main_validate_libraries(), library_foreach_path(), blender::ed::outliner::namebutton_fn(), and blender::bke::tests::TEST_F().
| void BKE_library_main_rebuild_hierarchy | ( | Main * | bmain | ) |
Rebuild the hierarchy of libraries, after e.g. deleting or relocating one, often some indirectly linked libraries lose their 'parent' pointer, making them wrongly directly used ones.
Definition at line 270 of file library.cc.
References blender::Set< Key, InlineBufferCapacity, ProbingStrategy, Hash, IsEqual, Slot, Allocator >::add(), blender::Vector< T, InlineBufferCapacity, Allocator >::append(), BKE_main_relations_create(), BKE_main_relations_free(), BLI_assert, BLI_ghash_lookup(), blender::Set< Key, InlineBufferCapacity, ProbingStrategy, Hash, IsEqual, Slot, Allocator >::contains(), FOREACH_MAIN_ID_BEGIN, FOREACH_MAIN_ID_END, MainIDRelationsEntry::from_ids, ID_IS_LINKED, blender::Vector< T, InlineBufferCapacity, Allocator >::last(), ID::lib, Main::libraries, LISTBASE_FOREACH, MainIDRelationsEntryItem::next, rebuild_hierarchy_best_parent_find(), Main::relations, MainIDRelations::relations_from_pointers, Library::runtime, and blender::Vector< T, InlineBufferCapacity, Allocator >::size().
Referenced by BKE_id_free_us(), blendfile_relocate_postprocess_liboverrides(), and id_delete().