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:
authorHans Goudey <h.goudey@me.com>2022-08-31 00:49:24 +0300
committerHans Goudey <h.goudey@me.com>2022-08-31 00:49:24 +0300
commitd94a11ed79b3c89176c7d436cacdc2767b4e7a4d (patch)
tree84fae6213d9b86729ddabe80aae30cd916c02f61
parent4c91c24bc7cbe2c4f97be373025a672928a5676d (diff)
Curves: Avoid unnecessarily initializing new positions layer
When creating a curves data-block, one is expected to set the new position values. We can slightly improve performance by avoiding doing that redundantly. Similar to cccc6d6905be7ac32cb.
-rw-r--r--source/blender/blenkernel/intern/curves_geometry.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/blenkernel/intern/curves_geometry.cc b/source/blender/blenkernel/intern/curves_geometry.cc
index 618ff8fa97a..3f549b39a00 100644
--- a/source/blender/blenkernel/intern/curves_geometry.cc
+++ b/source/blender/blenkernel/intern/curves_geometry.cc
@@ -58,7 +58,7 @@ CurvesGeometry::CurvesGeometry(const int point_num, const int curve_num)
CustomData_add_layer_named(&this->point_data,
CD_PROP_FLOAT3,
- CD_SET_DEFAULT,
+ CD_CONSTRUCT,
nullptr,
this->point_num,
ATTR_POSITION.c_str());