From 1f94b56d774440d08eb92f2a7a47b9a6a7aa7b84 Mon Sep 17 00:00:00 2001 From: Jacques Lucke Date: Fri, 22 Jul 2022 15:39:41 +0200 Subject: Curves: support sculpting on deformed curves Previously, curves sculpt tools only worked on original data. This was very limiting, because one could effectively only sculpt the curves when all procedural effects were turned off. This patch adds support for curves sculpting while looking the result of procedural effects (like deformation based on the surface mesh). This functionality is also known as "crazy space" support in Blender. For more details see D15407. Differential Revision: https://developer.blender.org/D15407 --- source/blender/nodes/NOD_geometry_exec.hh | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'source/blender/nodes/NOD_geometry_exec.hh') diff --git a/source/blender/nodes/NOD_geometry_exec.hh b/source/blender/nodes/NOD_geometry_exec.hh index 0d5ba6cf5db..c5bc42b059d 100644 --- a/source/blender/nodes/NOD_geometry_exec.hh +++ b/source/blender/nodes/NOD_geometry_exec.hh @@ -163,6 +163,7 @@ class GeoNodeExecParams { } void check_input_geometry_set(StringRef identifier, const GeometrySet &geometry_set) const; + void check_output_geometry_set(const GeometrySet &geometry_set) const; /** * Get input as vector for multi input socket with the given identifier. @@ -231,6 +232,9 @@ class GeoNodeExecParams { #ifdef DEBUG this->check_output_access(identifier, type); #endif + if constexpr (std::is_same_v) { + this->check_output_geometry_set(value); + } GMutablePointer gvalue = provider_->alloc_output_value(type); new (gvalue.get()) StoredT(std::forward(value)); provider_->set_output(identifier, gvalue); -- cgit v1.2.3