Blender V4.3
LibQueryUnusedIDsData Struct Reference

#include <BKE_lib_query.hh>

Public Attributes

bool do_local_ids = false
 
bool do_linked_ids = false
 
bool do_recursive = false
 
blender::FunctionRef< bool(ID *id)> filter_fn = nullptr
 
std::array< int, INDEX_ID_MAXnum_total
 
std::array< int, INDEX_ID_MAXnum_local
 
std::array< int, INDEX_ID_MAXnum_linked
 

Detailed Description

Parameters and result data structure for the 'unused IDs' functions below.

Definition at line 400 of file BKE_lib_query.hh.

Member Data Documentation

◆ do_linked_ids

bool LibQueryUnusedIDsData::do_linked_ids = false

Process linked data-blocks.

Definition at line 404 of file BKE_lib_query.hh.

Referenced by bpy_orphans_purge().

◆ do_local_ids

◆ do_recursive

bool LibQueryUnusedIDsData::do_recursive = false

Process all actually unused data-blocks, including these that are currently only used by other unused data-blocks, and 'dependency islands' of several data-blocks using each-other, without any external valid user.

Definition at line 410 of file BKE_lib_query.hh.

Referenced by bpy_orphans_purge().

◆ filter_fn

blender::FunctionRef<bool(ID *id)> LibQueryUnusedIDsData::filter_fn = nullptr

Callback filter, if defined and it returns true, the given id may be considered as unused, otherwise it will always be considered as used.

Allows for more complex handling of which IDs should be deleted, on top of the basic local/linked choices.

Definition at line 419 of file BKE_lib_query.hh.

◆ num_linked

std::array<int, INDEX_ID_MAX> LibQueryUnusedIDsData::num_linked

Amount of detected as unused linked data-blocks, per type and total as the last value of the array (INDEX_ID_NULL).

Note
Return value, set by the executed function.

Definition at line 441 of file BKE_lib_query.hh.

◆ num_local

std::array<int, INDEX_ID_MAX> LibQueryUnusedIDsData::num_local

Amount of detected as unused local data-blocks, per type and total as the last value of the array (INDEX_ID_NULL).

Note
Return value, set by the executed function.

Definition at line 434 of file BKE_lib_query.hh.

◆ num_total

std::array<int, INDEX_ID_MAX> LibQueryUnusedIDsData::num_total

Amount of detected as unused data-blocks, per type and total as the last value of the array (INDEX_ID_NULL).

Note
Return value, set by the executed function.

Definition at line 427 of file BKE_lib_query.hh.

Referenced by bpy_orphans_purge().


The documentation for this struct was generated from the following file: