diff options
author | Hans Goudey <h.goudey@me.com> | 2021-02-25 01:11:21 +0300 |
---|---|---|
committer | Hans Goudey <h.goudey@me.com> | 2021-02-25 01:11:21 +0300 |
commit | 17260c9b9a2c591e5269b5025f884630f7aa66c6 (patch) | |
tree | 2accfbc19adda09d318d19d53d5c297fef8da6db /source/blender/nodes/geometry | |
parent | 01e13e2c95132c92d37c832cbe9e814fae2007a2 (diff) |
Fix T85963: Combine and separate XYZ nodes don't work on instances
They were missing the `geometry_set_realize_instances` function used to
make any input instances real for writing.
Diffstat (limited to 'source/blender/nodes/geometry')
-rw-r--r-- | source/blender/nodes/geometry/nodes/node_geo_attribute_combine_xyz.cc | 2 | ||||
-rw-r--r-- | source/blender/nodes/geometry/nodes/node_geo_attribute_separate_xyz.cc | 2 |
2 files changed, 4 insertions, 0 deletions
diff --git a/source/blender/nodes/geometry/nodes/node_geo_attribute_combine_xyz.cc b/source/blender/nodes/geometry/nodes/node_geo_attribute_combine_xyz.cc index 564668af274..9c5c7e270b1 100644 --- a/source/blender/nodes/geometry/nodes/node_geo_attribute_combine_xyz.cc +++ b/source/blender/nodes/geometry/nodes/node_geo_attribute_combine_xyz.cc @@ -121,6 +121,8 @@ static void geo_node_attribute_combine_xyz_exec(GeoNodeExecParams params) { GeometrySet geometry_set = params.extract_input<GeometrySet>("Geometry"); + geometry_set = geometry_set_realize_instances(geometry_set); + if (geometry_set.has<MeshComponent>()) { combine_attributes(geometry_set.get_component_for_write<MeshComponent>(), params); } diff --git a/source/blender/nodes/geometry/nodes/node_geo_attribute_separate_xyz.cc b/source/blender/nodes/geometry/nodes/node_geo_attribute_separate_xyz.cc index 0ba89562ec1..55b933e8582 100644 --- a/source/blender/nodes/geometry/nodes/node_geo_attribute_separate_xyz.cc +++ b/source/blender/nodes/geometry/nodes/node_geo_attribute_separate_xyz.cc @@ -147,6 +147,8 @@ static void geo_node_attribute_separate_xyz_exec(GeoNodeExecParams params) { GeometrySet geometry_set = params.extract_input<GeometrySet>("Geometry"); + geometry_set = geometry_set_realize_instances(geometry_set); + if (geometry_set.has<MeshComponent>()) { separate_attribute(geometry_set.get_component_for_write<MeshComponent>(), params); } |