POV-Ray : Newsgroups : povray.general : sphere sweep - possible bug with b_spline : Re: sphere sweep - possible bug with b_spline Server Time
4 Aug 2024 14:24:06 EDT (-0400)
  Re: sphere sweep - possible bug with b_spline  
From: Brendt Hess
Date: 11 Apr 2003 11:35:33
Message: <3e96e0c5@news.povray.org>
ABX wrote:
> On Thu, 10 Apr 2003 23:50:07 -0700, Brendt Hess <bre### [at] attbicom> wrote:
> 
>>When I placed in those sweeps, and did a quick test render, I was caught 
>>by surprise... the ends of the sweeps did not coincide with the 
>>previously plotted points!
> 
> As it is stated there only linera_spline is ineterpolation. b_spline and
> cubic_spline is aproximation. The property of interpolation is that if you have
> contol point given for some t parameter then
> 
>   Interpolation( t ) = Control_Point( t )
> 
> while in aproximation
> 
>   Interpolation( t ) <> Control_Point( t )
> 
> (Or perhaps I misunderstand your problem)
> 

No, you understand the problem.  I read that, but interpreted the 
paragraph differently, at least for the spline endpoints.  However, 
looking again this morning, I found this piece of documentation:

http://www.povray.org/documentation/view/51/#s03_04_04

"When using a b_spline, the resulting object is somewhat similar to the 
cubic sweep, but doesn't actually go through the control points. It lies 
somewhere between them."

With this, I now understand.  Of course, this is particularly hard to 
find in the documentation... mostly because hitting F1 while on the 
b_spline keyword takes you to section 6.5.1.10, which does not explaing 
this bit about the splines.  This is in section 3.4.4 only.

(Sec. 3.4.4 also notes that a Cubic spline passes through the control 
points.)  I'm still a bit surprised about the degree of imprecision on 
the endpoints (about +/-.25 Y units beyond the theoretical endpoints, 
with the X value precise).  Examining it, I guess that the decision 
about where the endpoint actually falls is something like when the X, Y, 
and Z values are all >= the designated control point location.  Hmmm... 
let's see if I can test that... Nope... the difference appears to be 
solely constrained by the distabce between the first and second control 
points.

For example, using my previous sample, the final point plotted is +/- 
.25y.  Changing the first control point's Y position to topy+22 places 
the end of the sweep off of the screen.  Pulling the camera back, the 
end looks to be about 9 or ten units +y.

Odd... perhaps this should be placed as an example in the documents 
(simplified, of course).  At least section 6.5.1.10 should reference 
3.4.4 for information about the spline types.


Post a reply to this message

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