You are not logged in.
Pages: 1
Hi,
I currently use a CatmullRom type of spline formula in a 3D world to interpolate between control points. I had like to be able to insert control points exactly on the spline for more detail on the y-axis. I found that this results into a nasty bending on the x,z axis as well. Anyone knows of a spline formula that will allow me to do this which will keep the curve shape on the x,z axis the same? Or perhaps is there way to use the catmull-Rom formula for this by using a specific "tension" value?
Any help much appreciated!
Regards,
Raoul
Offline
Hi safra;
Not very familiar with that type of spline. So I am asking you a question. Wouldn't you have to recompute the spline again with the new control points?
In mathematics, you don't understand things. You just get used to them.
If it ain't broke, fix it until it is.
Always satisfy the Prime Directive of getting the right answer above all else.
Offline
Hi bobbym,
Yes, that is the idea, recalculate the spline using the new control points. The x,z shape should stay the same as the new control point is located exactly on the existing spline curve.
Offline
Hi;
Again, I am learning from you. When you recalculated the spline. Did it pass through all the control points like it is supposed to?
In mathematics, you don't understand things. You just get used to them.
If it ain't broke, fix it until it is.
Always satisfy the Prime Directive of getting the right answer above all else.
Offline
Thanks for replying bobbym!
Yes, it does pass through all control points. The formula I use calculates the curve between 2 control points by using 2 outer control points. So each curve between 2 control points is based on the position of 4 control points. That said, inserting a control point (even if exactly on the current spline shape) will lead to a different shape! Something I do not want to happen.
Offline
Hi safra;
Don't thank me, actually you have told me more than I have told you. Is that usual that adding 1 more point changes the output? Is it a large change?
In mathematics, you don't understand things. You just get used to them.
If it ain't broke, fix it until it is.
Always satisfy the Prime Directive of getting the right answer above all else.
Offline
It is a small change yet very noticable.
Offline
Hi safra;
If you are sure that your spline fitting is correct. And I have no reason to believe that you are making an error there. That change might be unavoidable. It is not unusual when adding more points to any interpolation for extra features of the curve to be revealed. I think that is what is happening to you.
I am not saying grin and bear it but a curve that is sampled by a small number of points might look very different when sampled by just a few more.
In mathematics, you don't understand things. You just get used to them.
If it ain't broke, fix it until it is.
Always satisfy the Prime Directive of getting the right answer above all else.
Offline
Pages: 1