POV-Ray : Newsgroups : povray.beta-test : splines and negative values : Re: splines and negative values Server Time
28 Apr 2024 04:03:32 EDT (-0400)
  Re: splines and negative values  
From: clipka
Date: 13 May 2013 07:22:27
Message: <5190ccf3$1@news.povray.org>
Am 13.05.2013 02:06, schrieb TreeLimb Jim:

> B) Parser displays this possible error around the vnormalize() function in
> Spline_Trans()
>     Possible Parse Error: Normalizing zero-length vector.
> See code snips and #debug trace--- I can't see where the code would be
> normalizing a zero-length vector.
> I got reasonable and acceptable results.

> #declare NrSamples = 100;
> #for( Nr, 0, 1, 1/NrSamples )
>   #debug concat ( "Loc=", VStr(<0,0,0>+Spline(Nr) )," LocNext=",
> VStr(<0,0,0>+Spline(Nr+0.1)), "\n" )
>   Spline_Trans( Bad_Spline, Nr, y, 0.1, 0.5 )
> #end

Spline_Trans also uses the vector Spline(Nr)-Spline(Nr-0.1) (via the 
VProject_Plane macro); you might want to check those as well.


Post a reply to this message

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