POV-Ray : Newsgroups : povray.binaries.images : Fixed cosinespline : Re: Why cubic spline sucks Server Time
2 Oct 2024 16:27:53 EDT (-0400)
  Re: Why cubic spline sucks  
From: Greg M  Johnson
Date: 14 Apr 2000 10:46:58
Message: <38F72E4E.642E2640@my-dejanews.com>
Peter Popov wrote:

> But... but... you only need to scale the spline so that the range
> [0,0] to [1,1] maps onto the rectangle formed by a point and the next
> one you want your spline to pass through...

Please find enclosed a photo comparing the cubic spline, the #init_spline, and
the COSINE SPLINE.

The cubic spline is a pain because:
1) You have to make up two points before and after: in coding something like a
walk cycle, that's about another 12-16 points that have to be retyped every time
you make a little tweak.
2) It wildly varies from the range of the points.  Look at the image: if I were
keyframing a walk cycle with a cubic spline, I'd have a leg that sometimes bends
backwards +45 degrees, when I had coded in a range of [-10,-125]. It would be a
herculean effort to get this not to violate the range--and then it would be a
bear to edit as I gradually improved the walk cycle--a process that might
involve dozens of iterations. Not only do I have to type in extra numbers, but
it varies from the range in ways that makes it useless unless you are:

A) in need of a perfectly smooth, elegant camera path.
B) really making a curve that is replaceable by the cosine function itself.


Post a reply to this message


Attachments:
Download 'cossplinevscubic.jpg' (27 KB)

Preview of image 'cossplinevscubic.jpg'
cossplinevscubic.jpg


 

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.