Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJacques Lucke <jacques@blender.org>2021-09-03 12:55:22 +0300
committerJacques Lucke <jacques@blender.org>2021-09-03 12:55:22 +0300
commit32f101c6038b83256fc505b5f06018296f4fe446 (patch)
tree7e1413199f6534db3f972f52a4d276dd13a3ac17 /source/blender/functions
parent2feed5ce338610eb49a74eb2f0b2e187222450bb (diff)
add initial Attribute Freeze node
Diffstat (limited to 'source/blender/functions')
-rw-r--r--source/blender/functions/FN_field.hh11
1 files changed, 11 insertions, 0 deletions
diff --git a/source/blender/functions/FN_field.hh b/source/blender/functions/FN_field.hh
index d639b355ab9..29bb2cc25ba 100644
--- a/source/blender/functions/FN_field.hh
+++ b/source/blender/functions/FN_field.hh
@@ -307,6 +307,17 @@ class FieldEvaluator : NonMovable, NonCopyable {
return this->add_with_destination(GField(std::move(field)), generic_dst_hint);
}
+ int add(GField field, const GVArray **varray_ptr)
+ {
+ const int field_index = fields_to_evaluate_.append_and_get_index(std::move(field));
+ dst_hints_.append(nullptr);
+ output_pointer_infos_.append(OutputPointerInfo{
+ varray_ptr, [](void *dst, const GVArray &varray, ResourceScope &UNUSED(scope)) {
+ *(const GVArray **)dst = &varray;
+ }});
+ return field_index;
+ }
+
/**
* \param field: Field to add to the evaluator.
* \param varray_ptr: Once #evaluate is called, the resulting virtual array will be will be