distribute between certain points of a spline
-
On 26/04/2013 at 12:23, xxxxxxxx wrote:
User Information:
Cinema 4D Version: r14
Platform: Windows ;
Language(s) : C++ ;---------
hi there, can someone roughly tell me how i can distribute a bunch of objects between point A and point B of a spline? i know how to place objects along a spline using GetSplinePoint and i know how to get the position of the editable points of a spline by using static_cast<PointObject*>(spline)->GetPointW(). but how do i get the part of a spline between two edit points? for linear spline it shouldnt be a problem to calculate distributed positions but how do i do it by using the spline part between two of its edit points?hope this makes sense?
cheers,
Ello -
On 26/04/2013 at 13:15, xxxxxxxx wrote:
have you looked into splinehelp ? the sampling methods provided there offer a uniform position
offset parameter called realoffset, which might be what you are looking for. -
On 27/04/2013 at 00:15, xxxxxxxx wrote:
yes, i have looked into spline help, but i dont really understand which to use, for example i want to get the part of a spline between point 2 and 3, and after that i want to be able to get points similar to using GetSplinePoint...
-
On 27/04/2013 at 02:13, xxxxxxxx wrote:
well you could calculate your distribution for a linear spline and then convert these
none uniform offsets with one of the splinehelp methods into your needed vectors.
i am not 100% sure what non uniform offsets are meant for, but from my experiences
with splinehelp and the sdk, they are meant for that scenario.an alternative route you could take would be the underlying lineobject. convert your
spline indices into line indices. then search or interpolate your desired points between
these both line indices. -
On 27/04/2013 at 02:28, xxxxxxxx wrote:
ok, thanks so far for your input. i'll investigate those