From cffd4a7ccf7dcf0d92d1b2392ac5adba9a965cdb Mon Sep 17 00:00:00 2001 From: Hans Goudey Date: Mon, 6 Sep 2021 20:43:21 -0500 Subject: Cleanup: Add comment about reusing span for input and output --- source/blender/nodes/geometry/nodes/node_geo_point_translate.cc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/source/blender/nodes/geometry/nodes/node_geo_point_translate.cc b/source/blender/nodes/geometry/nodes/node_geo_point_translate.cc index ad91cb2d377..48778532789 100644 --- a/source/blender/nodes/geometry/nodes/node_geo_point_translate.cc +++ b/source/blender/nodes/geometry/nodes/node_geo_point_translate.cc @@ -90,7 +90,9 @@ static void execute_on_component(GeometryComponent &component, /* Add an add operation field on top of the provided translation field, which can be evaluated * directly into the position virtual array. That way, any optimizations can be done more - * generally for the whole evaluation system. */ + * generally for the whole evaluation system. In the general case it may not work to share the + * same span for the input and output of an evaluation, but in this case there there is only one + * output, so it is fine. */ static const fn::CustomMF_SI_SI_SO add_fn = { "Add", [](float3 a, float3 b) { return a + b; }}; std::shared_ptr add_operation = std::make_shared( -- cgit v1.2.3