Blender V4.5
BKE_duplilist.hh File Reference
#include "BKE_geometry_set.hh"
#include "BKE_instances.hh"

Go to the source code of this file.

Classes

struct  DupliObject

Functions

ListBaseobject_duplilist (Depsgraph *depsgraph, Scene *sce, Object *ob, blender::Set< const Object * > *include_objects=nullptr)
ListBaseobject_duplilist_preview (Depsgraph *depsgraph, Scene *scene, Object *ob, const ViewerPath *viewer_path)
void free_object_duplilist (ListBase *lb)
blender::bke::Instances object_duplilist_legacy_instances (Depsgraph &depsgraph, Scene &scene, Object &ob)
bool BKE_object_dupli_find_rgba_attribute (const Object *ob, const DupliObject *dupli, const Object *dupli_parent, const char *name, float r_value[4])
bool BKE_view_layer_find_rgba_attribute (const Scene *scene, const ViewLayer *layer, const char *name, float r_value[4])

Variables

constexpr int MAX_DUPLI_RECUR = 8

Function Documentation

◆ BKE_object_dupli_find_rgba_attribute()

bool BKE_object_dupli_find_rgba_attribute ( const Object * ob,
const DupliObject * dupli,
const Object * dupli_parent,
const char * name,
float r_value[4] )

Look up the RGBA value of a uniform shader attribute.

Returns
true if the attribute was found; if not, r_value is also set to zero.

Definition at line 2072 of file object_dupli.cc.

References copy_v4_fl(), Object::data, find_geonode_attribute_rgba(), find_rna_property_rgba(), Object::id, ParticleSettings::id, ParticleSystem::part, and DupliObject::particle_system.

Referenced by lookup_instance_property().

◆ BKE_view_layer_find_rgba_attribute()

bool BKE_view_layer_find_rgba_attribute ( const Scene * scene,
const ViewLayer * layer,
const char * name,
float r_value[4] )

Look up the RGBA value of a view layer/scene/world shader attribute.

Returns
true if the attribute was found; if not, r_value is also set to zero.

Definition at line 2113 of file object_dupli.cc.

References copy_v4_fl(), find_rna_property_rgba(), Scene::id, World::id, RNA_pointer_create_discrete(), and Scene::world.

◆ free_object_duplilist()

◆ object_duplilist()

◆ object_duplilist_legacy_instances()

blender::bke::Instances object_duplilist_legacy_instances ( Depsgraph & depsgraph,
Scene & scene,
Object & ob )

Get the legacy instances of this object. That includes instances coming from these sources:

  • Particles
  • Dupli Verts
  • Dupli Faces
  • "Objects as Font"

This does not include collection instances which are not considered legacy and should be treated properly at a higher level.

Also see get_dupli_generator for the different existing dupli generators.

Definition at line 1872 of file object_dupli.cc.

References VectorSet< Key, InlineBufferCapacity, ProbingStrategy, Hash, IsEqual, Slot, Allocator >::add(), blender::bke::Instances::add_new_reference(), blender::Vector< T, InlineBufferCapacity, Allocator >::append(), blender::bke::Instances::attributes_for_write(), BLI_assert, depsgraph, DupliContext::duplilist, blender::bke::SpanAttributeWriter< T >::finish(), free_object_duplilist(), DupliContext::gen, gen_dupli_geometry_set, gen_dupli_particles, i, VectorSet< Key, InlineBufferCapacity, ProbingStrategy, Hash, IsEqual, Slot, Allocator >::index_of(), init_context(), blender::bke::Instance, LISTBASE_FOREACH, blender::bke::MutableAttributeAccessor::lookup_or_add_for_write_only_span(), DupliGenerator::make_duplis, DupliObject::mat, MEM_callocN(), DupliObject::ob, DupliObject::persistent_id, blender::bke::Instances::reference_handles_for_write(), blender::bke::Instances::resize(), blender::Vector< T, InlineBufferCapacity, Allocator >::size(), blender::bke::SpanAttributeWriter< T >::span, and blender::bke::Instances::transforms_for_write().

Referenced by BPy_GeometrySet_static_from_evaluated_object().

◆ object_duplilist_preview()

Variable Documentation

◆ MAX_DUPLI_RECUR