POV-Ray : Newsgroups : povray.advanced-users : Spline length/constant speed along spline. : Re: Spline length/constant speed along spline. Server Time
30 Jul 2024 02:14:21 EDT (-0400)
  Re: Spline length/constant speed along spline.  
From: Chris Colefax
Date: 19 May 2000 09:40:29
Message: <3925444d@news.povray.org>
Edward Coffey <e.c### [at] ugradunimelbeduau> wrote:
> A while back there were a couple of posts about splines and how to measure
> the length of bezier splines, find points at particular distances along
> them, and move along them at constant speed without resorting to
> approximation - was that problem solved?  How is it done for UV mapping in
> MegaPOV, approximation?
> I've found a related bit of calculus which shouldn't take too long to
adapt
> and convert to simple formula if no-one has done this yet.

Are you suggesting a formula that returns the distance of a cubic spline at
a particular point?  If so, it's my understanding (after a lot of research
and many attempts while developing my Spline Macro File -
http://www.geocities.com/ccolefax/spline) that there is no known analytical
solution to this problem.  If you have indeed found one, I for one would be
very interested!

For my macro file I settled on sampling points along the spline and using
the linear distances between them (both for length and constant speed
calculations).  In some areas I've also used an approximation of the segment
lengths based on the linear distance between the end points and the length
of the segment's constraining hull.  Of course, it would be far more
preferable to use an exact and neat solution, if calculus can offer one...


Post a reply to this message

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