As described in T92474 and T91650, this patch adds two features to the
sample curve node. First is an index input, to allow choosing the curve to
sample for each point. Second is a custom field input, which is evaluated
on the control points of the curve and then sampled like the other outputs.
There is an "All Curves" option for the old behavior which takes the length
of all curves into account.
For invalid curve indices, the node outputs zeros (default values).
Invalid lengths and factors are clamped.
Internally there is some room for improvement (making the code a bit
more generic, etc.), but I tried to keep the change as small as possible.
There have been various discussions about splitting the node up more,
but I think this is an intuitive combination of options and will work well
enough for current use cases. The node can be generalized more in the
future.
Keep in mind that the source field is evaluated on curve control points,
not the evaluated points used for sampling. This is necessary so that
fields like "Index" work as expected.
