|
Blender V5.3
|
Public Types | |
| enum class | Status : int8_t { Unknown , Used , Unused } |
Public Member Functions | |
| UnusedIDsData (Main *bmain, const int id_tag, LibQueryUnusedIDsData ¶meters) | |
| void | reset (const bool do_local_ids, const bool do_linked_ids, const bool do_recursive, std::array< int, INDEX_ID_MAX > &num_total, std::array< int, INDEX_ID_MAX > &num_local, std::array< int, INDEX_ID_MAX > &num_linked) |
| void | set_id_status (ID &id, Status status) |
| Status | get_id_status (ID &id) const |
| void | tag_ids () const |
Public Attributes | |
| Main * | bmain |
| const int | id_tag |
| bool | do_local_ids |
| bool | do_linked_ids |
| bool | do_recursive |
| FunctionRef< bool(ID *id)> | filter_fn |
| std::array< int, INDEX_ID_MAX > * | num_total |
| std::array< int, INDEX_ID_MAX > * | num_local |
| std::array< int, INDEX_ID_MAX > * | num_linked |
Internal data for the common processing of the 'unused IDs' query functions.
While LibQueryUnusedIDsData is a subset of this internal struct, they need to be kept separate, since this struct is used with partially 'enforced' values for some parameters by the BKE_lib_query_unused_ids_amounts code. This allows the computation of predictive amounts for user feedback ('what would be the amounts of IDs detected as unused if this option was enabled').
Definition at line 705 of file lib_query.cc.
|
strong |
Possible statuses for an ID.
| Enumerator | |
|---|---|
| Unknown | |
| Used | |
| Unused | |
Definition at line 722 of file lib_query.cc.
|
inline |
Definition at line 732 of file lib_query.cc.
References bmain, do_linked_ids, do_local_ids, do_recursive, filter_fn, id_tag, num_linked, num_local, and num_total.
Return the current status of the given ID.
Definition at line 785 of file lib_query.cc.
References Unknown.
|
inline |
Reset all internal states, and update parameters.
Definition at line 746 of file lib_query.cc.
References do_linked_ids, do_local_ids, do_recursive, num_linked, num_local, and num_total.
Define the current status of the given ID.
Definition at line 763 of file lib_query.cc.
References blender::ID_FLAG_EMBEDDED_DATA, Unknown, Unused, and Used.
|
inline |
Tag all IDs in Main according to their current status.
Definition at line 795 of file lib_query.cc.
References blender::BKE_idtype_idcode_to_index(), FOREACH_MAIN_ID_BEGIN, FOREACH_MAIN_ID_END, ID_IS_LINKED, blender::INDEX_ID_NULL, Unknown, and Unused.
| Main* blender::UnusedIDsData::bmain |
Definition at line 707 of file lib_query.cc.
Referenced by UnusedIDsData().
| bool blender::UnusedIDsData::do_linked_ids |
Definition at line 712 of file lib_query.cc.
Referenced by reset(), and UnusedIDsData().
| bool blender::UnusedIDsData::do_local_ids |
Definition at line 711 of file lib_query.cc.
Referenced by reset(), and UnusedIDsData().
| bool blender::UnusedIDsData::do_recursive |
Definition at line 713 of file lib_query.cc.
Referenced by reset(), and UnusedIDsData().
| FunctionRef<bool(ID *id)> blender::UnusedIDsData::filter_fn |
Definition at line 715 of file lib_query.cc.
Referenced by UnusedIDsData().
| const int blender::UnusedIDsData::id_tag |
Definition at line 709 of file lib_query.cc.
Referenced by UnusedIDsData().
| std::array<int, INDEX_ID_MAX>* blender::UnusedIDsData::num_linked |
Definition at line 719 of file lib_query.cc.
Referenced by reset(), and UnusedIDsData().
| std::array<int, INDEX_ID_MAX>* blender::UnusedIDsData::num_local |
Definition at line 718 of file lib_query.cc.
Referenced by reset(), and UnusedIDsData().
| std::array<int, INDEX_ID_MAX>* blender::UnusedIDsData::num_total |
Definition at line 717 of file lib_query.cc.
Referenced by reset(), and UnusedIDsData().