|
Blender V4.5
|
Go to the source code of this file.
Classes | |
| struct | AssetTypeInfo |
| struct | AssetTagEnsureResult |
Typedefs | |
| using | PreSaveFn = void (*)(void *asset_ptr, AssetMetaData *asset_data) |
| using | OnMarkAssetFn = void (*)(void *asset_ptr, AssetMetaData *asset_data) |
| using | OnClearAssetDataFn = void (*)(void *asset_ptr, AssetMetaData *asset_data) |
| using OnClearAssetDataFn = void (*)(void *asset_ptr, AssetMetaData *asset_data) |
Definition at line 26 of file BKE_asset.hh.
| using OnMarkAssetFn = void (*)(void *asset_ptr, AssetMetaData *asset_data) |
Definition at line 25 of file BKE_asset.hh.
| using PreSaveFn = void (*)(void *asset_ptr, AssetMetaData *asset_data) |
Definition at line 24 of file BKE_asset.hh.
| void BKE_asset_catalog_path_list_add_path | ( | ListBase & | catalog_path_list, |
| const char * | catalog_path ) |
Definition at line 174 of file asset_weak_reference.cc.
References BKE_asset_catalog_path_list_add_path(), BLI_addtail(), BLI_strdup(), MEM_callocN(), and AssetCatalogPathLink::path.
Referenced by BKE_asset_catalog_path_list_add_path(), BKE_asset_metadata_catalog_id_set(), BKE_preferences_asset_shelf_settings_ensure_catalog_path_enabled(), and blender::ed::asset::shelf::settings_set_catalog_path_enabled().
| void BKE_asset_catalog_path_list_blend_read_data | ( | BlendDataReader * | reader, |
| ListBase & | catalog_path_list ) |
Definition at line 158 of file asset_weak_reference.cc.
References BKE_asset_catalog_path_list_blend_read_data(), BLO_read_string(), BLO_read_struct_list, and LISTBASE_FOREACH.
Referenced by BKE_asset_catalog_path_list_blend_read_data(), BKE_asset_metadata_catalog_id_set(), read_userdef(), and blender::ed::asset::shelf::settings_blend_read_data().
| void BKE_asset_catalog_path_list_blend_write | ( | BlendWriter * | writer, |
| const ListBase & | catalog_path_list ) |
Definition at line 149 of file asset_weak_reference.cc.
References BKE_asset_catalog_path_list_blend_write(), BLO_write_string(), BLO_write_struct, and LISTBASE_FOREACH.
Referenced by BKE_asset_catalog_path_list_blend_write(), BKE_asset_metadata_catalog_id_set(), blender::ed::asset::shelf::settings_blend_write(), and write_userdef().
Definition at line 135 of file asset_weak_reference.cc.
References BKE_asset_catalog_path_list_duplicate(), BLI_addtail(), BLI_strdup(), LISTBASE_FOREACH, MEM_callocN(), and AssetCatalogPathLink::path.
Referenced by BKE_asset_catalog_path_list_duplicate(), and BKE_asset_metadata_catalog_id_set().
| void BKE_asset_catalog_path_list_free | ( | ListBase & | catalog_path_list | ) |
Definition at line 126 of file asset_weak_reference.cc.
References BKE_asset_catalog_path_list_free(), BLI_assert, BLI_freelinkN(), BLI_listbase_is_empty(), and LISTBASE_FOREACH_MUTABLE.
Referenced by BKE_asset_catalog_path_list_free(), BKE_asset_metadata_catalog_id_set(), BKE_blender_userdef_data_free(), and blender::ed::asset::shelf::settings_clear_enabled_catalogs().
| bool BKE_asset_catalog_path_list_has_path | ( | const ListBase & | catalog_path_list, |
| const char * | catalog_path ) |
Definition at line 167 of file asset_weak_reference.cc.
References BKE_asset_catalog_path_list_has_path(), BLI_findstring_ptr(), and offsetof.
Referenced by BKE_asset_catalog_path_list_has_path(), BKE_asset_metadata_catalog_id_set(), BKE_preferences_asset_shelf_settings_is_catalog_path_enabled(), blender::ed::asset::shelf::settings_is_catalog_path_enabled(), and blender::ed::asset::shelf::settings_set_catalog_path_enabled().
| void BKE_asset_library_reference_init_default | ( | AssetLibraryReference * | library_ref | ) |
Definition at line 149 of file asset.cc.
References BKE_asset_library_reference_init_default(), and DNA_struct_default_get.
Referenced by BKE_asset_library_reference_init_default(), BKE_asset_metadata_catalog_id_set(), blo_do_versions_300(), and workspace_init_data().
| void BKE_asset_metadata_catalog_id_clear | ( | AssetMetaData * | asset_data | ) |
Clean up the catalog ID (white-spaces removed, length reduced, etc.) and assign it.
Definition at line 154 of file asset.cc.
References BKE_asset_metadata_catalog_id_clear(), BLI_uuid_nil(), AssetMetaData::catalog_id, and AssetMetaData::catalog_simple_name.
Referenced by BKE_asset_metadata_catalog_id_clear(), BKE_asset_metadata_tag_add(), and blender::bke::tests::TEST().
| void BKE_asset_metadata_catalog_id_set | ( | AssetMetaData * | asset_data, |
| bUUID | catalog_id, | ||
| const char * | catalog_simple_name ) |
References ATTR_WARN_UNUSED_RESULT, BKE_asset_catalog_path_list_add_path(), BKE_asset_catalog_path_list_blend_read_data(), BKE_asset_catalog_path_list_blend_write(), BKE_asset_catalog_path_list_duplicate(), BKE_asset_catalog_path_list_free(), BKE_asset_catalog_path_list_has_path(), BKE_asset_library_reference_init_default(), BKE_asset_metadata_catalog_id_set(), BKE_asset_metadata_idprop_ensure(), BKE_asset_metadata_idprop_find(), BKE_asset_metadata_preview_get_from_id(), BKE_asset_metadata_read(), BKE_asset_metadata_write(), BKE_asset_weak_reference_read(), and BKE_asset_weak_reference_write().
Referenced by BKE_asset_metadata_catalog_id_set(), BKE_asset_metadata_catalog_id_set(), blender::ed::sculpt_paint::brush_asset_edit_metadata_exec(), blender::ed::sculpt_paint::brush_asset_save_as_exec(), blender::ed::animrig::create_pose_asset_local(), blender::ed::animrig::create_pose_asset_user_library(), blender::ed::asset_browser::AssetCatalogDropTarget::drop_assets_into_catalog(), and blender::bke::tests::TEST().
| AssetMetaData * BKE_asset_metadata_copy | ( | const AssetMetaData * | source | ) |
Create a copy of the AssetMetaData so that it can be assigned to another asset.
The caller becomes the owner of the returned pointer.
Definition at line 44 of file asset.cc.
References BKE_asset_metadata_copy().
Referenced by BKE_asset_metadata_copy(), BKE_libblock_copy_in_lib(), blender::ed::sculpt_paint::brush_asset_save_as_exec(), and blender::ed::asset::copy_to_id().
| AssetMetaData * BKE_asset_metadata_create | ( | ) |
Definition at line 32 of file asset.cc.
References BKE_asset_metadata_create(), and DNA_struct_default_get.
Referenced by BKE_asset_metadata_create(), blender::ed::asset::index::init_indexer_entry_from_value(), and blender::ed::asset::mark_id().
| void BKE_asset_metadata_free | ( | AssetMetaData ** | asset_data | ) |
Definition at line 38 of file asset.cc.
References BKE_asset_metadata_free().
Referenced by BKE_asset_metadata_free(), BKE_lib_id_clear_library_data(), BKE_libblock_free_data(), BLO_datablock_info_free(), blender::ed::sculpt_paint::brush_asset_save_as_exec(), blender::ed::asset::clear_id(), and blender::ed::asset::copy_to_id().
| void BKE_asset_metadata_idprop_ensure | ( | AssetMetaData * | asset_data, |
| IDProperty * | prop ) |
Definition at line 168 of file asset.cc.
References BKE_asset_metadata_idprop_ensure(), blender::bke::idprop::create_group(), IDP_ReplaceInGroup(), and AssetMetaData::properties.
Referenced by blender::bke::action_asset_metadata_ensure(), BKE_asset_metadata_catalog_id_set(), BKE_asset_metadata_idprop_ensure(), brush_asset_metadata_ensure(), blender::bke::node_update_asset_metadata(), and object_asset_metadata_ensure().
| IDProperty * BKE_asset_metadata_idprop_find | ( | const AssetMetaData * | asset_data, |
| const char * | name ) |
Definition at line 179 of file asset.cc.
References BKE_asset_metadata_idprop_find(), IDP_GetPropertyFromGroup(), and AssetMetaData::properties.
Referenced by BKE_asset_metadata_catalog_id_set(), BKE_asset_metadata_idprop_find(), blender::ed::geometry::build_catalog_tree(), blender::ed::object::build_catalog_tree(), blender::ed::space_node::build_catalog_tree(), blender::ed::space_node::node_group_drop_poll(), blender::ed::geometry::run_node_group_depends_on_cursor(), blender::ed::space_node::search_link_ops_for_asset_metadata(), view3d_geometry_nodes_drop_poll(), and view3d_ob_drop_on_enter().
| PreviewImage * BKE_asset_metadata_preview_get_from_id | ( | const AssetMetaData * | asset_data, |
| const ID * | owner_id ) |
Definition at line 189 of file asset.cc.
References BKE_asset_metadata_preview_get_from_id(), and BKE_previewimg_id_get().
Referenced by BKE_asset_metadata_catalog_id_set(), BKE_asset_metadata_preview_get_from_id(), and filelist_readjob_main_assets_add_items().
| void BKE_asset_metadata_read | ( | BlendDataReader * | reader, |
| AssetMetaData * | asset_data ) |
Definition at line 215 of file asset.cc.
References AssetMetaData::author, BKE_asset_metadata_read(), BLI_assert, BLI_listbase_count(), BLO_read_string(), BLO_read_struct, BLO_read_struct_list, AssetMetaData::copyright, AssetMetaData::description, IDP_BlendDataRead, AssetMetaData::license, AssetMetaData::local_type_info, AssetMetaData::properties, AssetMetaData::tags, and AssetMetaData::tot_tags.
Referenced by BKE_asset_metadata_catalog_id_set(), BKE_asset_metadata_read(), blo_read_asset_data_block(), and direct_link_id_common().
| AssetTag * BKE_asset_metadata_tag_add | ( | AssetMetaData * | asset_data, |
| const char * | name ) |
References ATTR_NONNULL, BKE_asset_metadata_catalog_id_clear(), BKE_asset_metadata_tag_add(), BKE_asset_metadata_tag_ensure(), and BKE_asset_metadata_tag_remove().
Referenced by BKE_asset_metadata_tag_add(), BKE_asset_metadata_tag_add(), and blender::ed::asset::index::init_indexer_entry_from_value().
| AssetTag AssetTagEnsureResult BKE_asset_metadata_tag_ensure | ( | AssetMetaData * | asset_data, |
| const char * | name ) |
Make sure there is a tag with name name, create one if needed.
Definition at line 118 of file asset.cc.
References asset_metadata_tag_add(), BKE_asset_metadata_tag_ensure(), BLI_findstring(), offsetof, result, and AssetMetaData::tags.
Referenced by BKE_asset_metadata_tag_add(), and BKE_asset_metadata_tag_ensure().
| void BKE_asset_metadata_tag_remove | ( | AssetMetaData * | asset_data, |
| AssetTag * | tag ) |
Definition at line 140 of file asset.cc.
References BKE_asset_metadata_tag_remove(), BLI_assert, BLI_findindex(), BLI_freelinkN(), BLI_listbase_count(), AssetMetaData::tags, and AssetMetaData::tot_tags.
Referenced by BKE_asset_metadata_tag_add(), and BKE_asset_metadata_tag_remove().
| void BKE_asset_metadata_write | ( | BlendWriter * | writer, |
| AssetMetaData * | asset_data ) |
Definition at line 197 of file asset.cc.
References AssetMetaData::author, BKE_asset_metadata_write(), BLO_write_string(), BLO_write_struct, AssetMetaData::copyright, AssetMetaData::description, IDP_BlendWrite(), AssetMetaData::license, LISTBASE_FOREACH, AssetMetaData::properties, and AssetMetaData::tags.
Referenced by BKE_asset_metadata_catalog_id_set(), BKE_asset_metadata_write(), and BKE_id_blend_write().
| void BKE_asset_weak_reference_read | ( | BlendDataReader * | reader, |
| AssetWeakReference * | weak_ref ) |
Definition at line 120 of file asset_weak_reference.cc.
References AssetWeakReference::asset_library_identifier, BKE_asset_weak_reference_read(), BLO_read_string(), and AssetWeakReference::relative_asset_identifier.
Referenced by BKE_asset_metadata_catalog_id_set(), BKE_asset_weak_reference_read(), and BKE_paint_blend_read_data().
| void BKE_asset_weak_reference_write | ( | BlendWriter * | writer, |
| const AssetWeakReference * | weak_ref ) |
Definition at line 113 of file asset_weak_reference.cc.
References AssetWeakReference::asset_library_identifier, BKE_asset_weak_reference_write(), BLO_write_string(), BLO_write_struct, and AssetWeakReference::relative_asset_identifier.
Referenced by BKE_asset_metadata_catalog_id_set(), BKE_asset_weak_reference_write(), and BKE_paint_blend_write().