POV-Ray : Newsgroups : povray.binaries.images : Gothic Splines : Re: Gothic Splines Server Time
14 Nov 2024 02:24:13 EST (-0500)
  Re: Gothic Splines  
From: Dan P
Date: 11 Apr 2004 23:27:48
Message: <407a0cb4$1@news.povray.org>
Lonster wrote:

> Yes!  Passing an array of vectors to a spline is exactly what I mean.
> Consider this:
> 

<snip:technical />

> #declare myspline=spline{
>   linear_spline
>   #declare index=0;
>   #while (index<100)
>     MyVectors[index]
>     #declare index=index+1;
>   #end
> }
> 
> This does NOT work!  It returns with ERROR: Spline must have at least one
> entry.  The work-around I have been using is to use Python to generate in
> it's shell window, copy them to the clipboard, and paste them into my POV
> code directly.  Clunky, but it works.

Aha! The problem is that you need a float value to specify which moment 
in time POV-Ray will assign the vector. Try this instead:

#declare myspline=spline{
   linear_spline
   #declare index=0;
   #while (index<100)
     index MyVectors[index]
     #declare index=index+1;
   #end
}

Note the "index" in front of the MyVectors[index].
-- 
Respectfully,
Dan P
http://<broken link>


Post a reply to this message

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