CalcSplineV [SOLVED]
-
On 07/04/2015 at 13:44, xxxxxxxx wrote:
Is there a way to change the type of spline that is calculated with c4d._<_gs_<_gs_>_gs>_/gs>_rk">.CalcSplineV. Currently it seems that it uses a Bezier interpolation?
EDIT:
Here is some code. Python tag _WARE_mark">on a null with a float slider user data.
_FTWARE_mark">def _SOFTWARE_mark">main() : obj = op.GetObject() Pos = obj[c4d.ID_USERDATA,1] SL = [c4d.Vector(-200,0,0),c4d.Vector(-100,0,100),c4d.Vector(0,0,0),c4d.Vector(-100,0,-100)] Spot = c4d.utils.CalcSplineV(Pos, SL) _78c6-69b1-40a8-9818-76d76b09a739" ="GINGER_SOFTWARE_mark">obj_"cc0878c6-69b1-40a8-9818-76d76b09a739" ="GINGER_SOFTWARE_mark">[c4d.ID_BASEOBJECT_REL_POSITION] = Spot
-
On 08/04/2015 at 07:45, xxxxxxxx wrote:
Hi ShawnFrueh,
Sorry, there's no way to change the equation it uses within c4d.utils.CalcSplineV() to change the type of spline that is calculated. I'm curious to know what you'd rather it do? In any case, you'd have to code whatever replacement algorithm you prefer and use the raw data you created to calculate what you want.
Joey Gaspe
SDK Support Engineer -
On 08/04/2015 at 09:16, xxxxxxxx wrote:
Thanks for the info Joey.
I would like it to be able to use the different types of spline interpolation that Cinema offers. Do you happen to know the type of algorithm CalcSplineV(_<_gs_>_) uses?
-
On 09/04/2015 at 08:40, xxxxxxxx wrote:
Hi Shawn,
Sorry, we're generally not allowed to divulge how Cinema 4D implements its features in public, especially in terms of algorithms, as it's not always clear what would be harmless or turn out to be a leaked secret or clue to an overall secret.
All I can say is that you'll have to test the different types of interpolation that C4D offers and choose the one that best fits your needs.
Joey Gaspe
SDK Support Engineer -
On 09/04/2015 at 09:28, xxxxxxxx wrote:
No problem. It never hurts to go learn some new math
Thanks for replying.
-
On 09/04/2015 at 09:56, xxxxxxxx wrote:
OK, I'll tag the topic as solved.
Joey Gaspe
SDK Support Engineer