Connect Curve Splines Node #89216

Open
opened 2021-06-16 22:01:46 +02:00 by Hans Goudey · 4 comments
Member


This node join splines from the input geometry sets into a single spline, depending on the merge settings.

Details

  • The use cases are building and later filling a single shape from multiple curve primitives, creating a single spline from multiple objects, and other options where connecting splines is useful like in edit mode.
  • If end points of two splines are within the "Merge Threshold", they will be connected, just like in curve edit mode with the F shortcut.
  • If "Add Segments" is off, the node will not create new segments, only join end points and start points. (This corresponds to F and then deleting one control point in edit mode.
  • If the spline types do not match, a poly spline will be used for the result of that set of the input splines, in evaluated form. Poly splines are a good choice because they are the "base" of curve functionality.
  • If three end points are inside the merge threshold, the closest points will be connected, and as a fallback a choice could be made based on index.

Related Nodes
*

Further Questions

  • Naming: "Concatenate Curves" or "Join Splines" or "Connect Curves" are other name possibilities.

Implementation
A first pass should find which start and end points are within a merge threshold. Keeping this operation from having N^2 runtime will be important. Then >2-way intersections should be dealt with, then data should be copied to the result, or possible moved with std::move if no connections were made to a spline.

![](https://archive.blender.org/developer/F10175900/image.png) ![](https://archive.blender.org/developer/F10175899/image.png) This node join splines from the input geometry sets into a single spline, depending on the merge settings. **Details** * The use cases are building and later filling a single shape from multiple curve primitives, creating a single spline from multiple objects, and other options where connecting splines is useful like in edit mode. * If end points of two splines are within the "Merge Threshold", they will be connected, just like in curve edit mode with the `F` shortcut. * If "Add Segments" is off, the node will not create new segments, only join end points and start points. (This corresponds to `F` and then deleting one control point in edit mode. * If the spline types do not match, a poly spline will be used for the result of that set of the input splines, in evaluated form. Poly splines are a good choice because they are the "base" of curve functionality. * If three end points are inside the merge threshold, the closest points will be connected, and as a fallback a choice could be made based on index. **Related Nodes** * **Further Questions** * Naming: "Concatenate Curves" or "Join Splines" or "Connect Curves" are other name possibilities. **Implementation** A first pass should find which start and end points are within a merge threshold. Keeping this operation from having N^2 runtime will be important. Then >2-way intersections should be dealt with, then data should be copied to the result, or possible moved with `std::move` if no connections were made to a spline.
Author
Member

Changed status from 'Needs Triage' to: 'Confirmed'

Changed status from 'Needs Triage' to: 'Confirmed'
Author
Member

Added subscriber: @HooglyBoogly

Added subscriber: @HooglyBoogly

Added subscriber: @GeorgiaPacific

Added subscriber: @GeorgiaPacific
Philipp Oeser removed the
Interest
Nodes & Physics
label 2023-02-10 08:44:47 +01:00

Partially, this can be done now. By using Points to Curves:

image

image image

Main limitaion for now:

  • Different curves can not be processed in separate way, here is lack of Select Curve Type node.
  • Its not possible to handle curves attributes without manual sampling. Even with using Groups Statistic to join attributes from multiple curves. But this might can be solved via Drop Domain node (for example, to adapt all attributes from curves to points). This will allow us to handle all curves attributes as points attributes in separate graph branch. After this, Drop Domain again will move all attributes to curves domain back, with it value averaging.
  • This not real issues, i just not too sure. Do we have general way to change all curves types to Poly type without topology changing. This required for process all curves as poly splines -> points of poly splines.
Partially, this can be done now. By using `Points to Curves`: ![image](/attachments/ad0cf8a7-3cb9-4b19-92a9-3a47ec097259) | | | | -- | -- | | ![image](/attachments/1128071b-5b99-4612-8024-352d70b83179) | ![image](/attachments/8dd2a5c8-cbe6-47a9-a42a-88db55bb6101) | Main limitaion for now: - Different curves can not be processed in separate way, here is lack of `Select Curve Type` node. - Its not possible to handle curves attributes without manual sampling. Even with using Groups Statistic to join attributes from multiple curves. But this might can be solved via `Drop Domain` node (for example, to adapt all attributes from curves to points). This will allow us to handle all curves attributes as points attributes in separate graph branch. After this, `Drop Domain` again will move all attributes to curves domain back, with it value averaging. - This not real issues, i just not too sure. Do we have general way to change all curves types to Poly type without topology changing. This required for process all curves as poly splines -> points of poly splines.
Sign in to join this conversation.
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset Browser
Interest
Asset Browser Project Overview
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
EEVEE & Viewport
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
EEVEE & Viewport
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
3 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender#89216
No description provided.