Fix T71000: Statistics don't take collections hidden state into account
Simple fix, to mimic what we had pre-local collections. So this is not fully representative of the current load of the scene. I started a more complex route where we literally just count objects that are visible (taking object type restriction, local collections, local view, ...). But in the end it is a bit overkill considering that we have plans to change the statistics.
This commit is contained in:
parent
34902f2008
commit
9c4cec2de9
Notes:
blender-bot
2023-05-29 09:17:12 +02:00
Referenced by issue #71983, script_pyapi_idprop_datablock test fails Referenced by issue #71000, Scene statistics dont take hidden state into account (2.80 did)
|
@ -123,6 +123,10 @@ static bool stats_mesheval(Mesh *me_eval, bool is_selected, SceneStats *stats)
|
|||
|
||||
static void stats_object(Object *ob, SceneStats *stats, GSet *objects_gset)
|
||||
{
|
||||
if ((ob->base_flag & BASE_VISIBLE_VIEWLAYER) == 0) {
|
||||
return;
|
||||
}
|
||||
|
||||
const bool is_selected = (ob->base_flag & BASE_SELECTED) != 0;
|
||||
|
||||
stats->totobj++;
|
||||
|
|
Loading…
Reference in New Issue