[Bf-blender-cvs] [fb470c256aa] master: Fix T93256: Instances to points node broken after recent commit

Hans Goudey noreply at git.blender.org
Sun Nov 21 17:37:42 CET 2021


Commit: fb470c256aac5dc8834cf113ca1f2beab373b8da
Author: Hans Goudey
Date:   Sun Nov 21 11:37:35 2021 -0500
Branches: master
https://developer.blender.org/rBfb470c256aac5dc8834cf113ca1f2beab373b8da

Fix T93256: Instances to points node broken after recent commit

When 97533eede444217 added the instance domain, it didn't change
the domain that instance attributes are read from in this node.

===================================================================

M	source/blender/nodes/geometry/nodes/node_geo_instances_to_points.cc

===================================================================

diff --git a/source/blender/nodes/geometry/nodes/node_geo_instances_to_points.cc b/source/blender/nodes/geometry/nodes/node_geo_instances_to_points.cc
index c3955426e69..f8c146833ba 100644
--- a/source/blender/nodes/geometry/nodes/node_geo_instances_to_points.cc
+++ b/source/blender/nodes/geometry/nodes/node_geo_instances_to_points.cc
@@ -51,9 +51,8 @@ static void convert_instances_to_points(GeometrySet &geometry_set,
 {
   const InstancesComponent &instances = *geometry_set.get_component_for_read<InstancesComponent>();
 
-  const AttributeDomain attribute_domain = ATTR_DOMAIN_POINT;
-  GeometryComponentFieldContext field_context{instances, attribute_domain};
-  const int domain_size = instances.attribute_domain_size(attribute_domain);
+  GeometryComponentFieldContext field_context{instances, ATTR_DOMAIN_INSTANCE};
+  const int domain_size = instances.attribute_domain_size(ATTR_DOMAIN_INSTANCE);
 
   fn::FieldEvaluator selection_evaluator{field_context, domain_size};
   selection_evaluator.add(std::move(selection_field));



More information about the Bf-blender-cvs mailing list