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-02-16 14:07:10 +0300
committerJacques Lucke <jacques@blender.org>2021-02-16 14:07:10 +0300
commit21de1f91480ac2165517a4ba244fa0708a939baf (patch)
tree6be424f6019f0ebe0bba08fbda667270c7f9be42 /source/blender/nodes
parent39f60e6909e61b8b7982e637a2091a84d618ddd7 (diff)
Geometry Nodes: move geometry set instance handling to separate file
In an upcoming commit I'll also move the make-instances-real functionality to this file. This code is not essential to working with geometry sets in general, so it makes sense to move it to a separate header.
Diffstat (limited to 'source/blender/nodes')
-rw-r--r--source/blender/nodes/geometry/node_geometry_util.cc4
-rw-r--r--source/blender/nodes/geometry/node_geometry_util.hh3
2 files changed, 5 insertions, 2 deletions
diff --git a/source/blender/nodes/geometry/node_geometry_util.cc b/source/blender/nodes/geometry/node_geometry_util.cc
index 08de467cd55..daee693c24f 100644
--- a/source/blender/nodes/geometry/node_geometry_util.cc
+++ b/source/blender/nodes/geometry/node_geometry_util.cc
@@ -26,6 +26,8 @@
namespace blender::nodes {
+using bke::GeometryInstanceGroup;
+
void gather_attribute_info(Map<std::string, AttributeInfo> &attributes,
const GeometryComponentType component_type,
Span<GeometryInstanceGroup> set_groups,
@@ -261,7 +263,7 @@ GeometrySet geometry_set_realize_instances(const GeometrySet &geometry_set)
GeometrySet new_geometry_set;
- Vector<GeometryInstanceGroup> set_groups = BKE_geometry_set_gather_instances(geometry_set);
+ Vector<GeometryInstanceGroup> set_groups = bke::geometry_set_gather_instances(geometry_set);
join_instance_groups_mesh(set_groups, new_geometry_set);
join_instance_groups_pointcloud(set_groups, new_geometry_set);
join_instance_groups_volume(set_groups, new_geometry_set);
diff --git a/source/blender/nodes/geometry/node_geometry_util.hh b/source/blender/nodes/geometry/node_geometry_util.hh
index 687763b4728..78418b37011 100644
--- a/source/blender/nodes/geometry/node_geometry_util.hh
+++ b/source/blender/nodes/geometry/node_geometry_util.hh
@@ -25,6 +25,7 @@
#include "DNA_node_types.h"
+#include "BKE_geometry_set_instances.hh"
#include "BKE_node.h"
#include "BLT_translation.h"
@@ -61,7 +62,7 @@ struct AttributeInfo {
*/
void gather_attribute_info(Map<std::string, AttributeInfo> &attributes,
const GeometryComponentType component_type,
- Span<GeometryInstanceGroup> set_groups,
+ Span<bke::GeometryInstanceGroup> set_groups,
const Set<std::string> &ignored_attributes);
} // namespace blender::nodes