Page MenuHome

Geometry Nodes: Fields version of Curve to Points node
ClosedPublic

Authored by Hans Goudey (HooglyBoogly) on Oct 16 2021, 12:01 AM.

Details

Summary

This patch adds an updated version of the curve to points that
supports fields. Only the position and radius attributes are transferred
by default now, which should improve performance. The other outputs
like tangent and rotation are outputted with anonymous attributes.

I took the opportunity to change a few other small things about the node:

  • Name geometry sockets "Curve" and "Points" like other nodes.
  • Remove the radius multiple of 0.1. In retrospect I don't think this is worth the confusion.

Thanks to @Johnny Matthews (guitargeek) for an initial version of this patch!


Diff Detail

Repository
rB Blender
Branch
arcpatch-D12887 (branched from master)
Build Status
Buildable 17953
Build 17953: arc lint + arc unit

Event Timeline

Johnny Matthews (guitargeek) requested review of this revision.Oct 16 2021, 12:01 AM
Johnny Matthews (guitargeek) created this revision.
  • small work, still crashes
  • Still Unworking Code Crashes at line 166 of node_geo_curve_to_points.cc
source/blender/nodes/geometry/nodes/node_geo_curve_to_points.cc
156–170

If this code is intended to stay, it should be creating the new attributes on the result points with the anonymous attributes IDs in the attribute_outputs. (Except position, which is a builtin attribute).

That said, the specific code for copying over radii and tilts can be removed, because we don't want to copy over attributes that are builtin on curves but not builtin on points.

180

There is a crash here because the normal_id above was not created, because the output was not necessary.

  • Merge branch 'master' into arcpatch-D12887
  • Fix crash on anonymous attributes
  • remove tilt and radii attributes
  • More work on attrbutes. still WIP

Finish off the work started by Johnny

Hans Goudey (HooglyBoogly) retitled this revision from Geometry Nodes: Curve to Points Node Update - WIP to Geometry Nodes: Fields version of Curve to Points node.Oct 19 2021, 7:33 PM
Hans Goudey (HooglyBoogly) edited the summary of this revision. (Show Details)

LGTM, besides the comment mentioned below.

source/blender/nodes/geometry/nodes/node_geo_curve_to_points.cc
90

Don't use extract_input because this may be called more than once. Same below.

This revision is now accepted and ready to land.Oct 20 2021, 2:46 PM