|
 |
"Bald Eagle" <cre### [at] netscape net> wrote:
> The docs show:
>
> #declare foo2 = function {
> spline {
> linear_spline
> 0.0, <0,0,0>
> 0.5, <1,0,0>
> 1.0, <0,0,0>
> }
> }
>
> #declare myvector2 = foo2(0.7);
>
>
> I am testing code that has:
>
> #declare SPL2_PX = spline{
> linear_spline
> #for(S_K, 0, S_NSites2D-1)
> S_K, A1D_V_P2D[S_K].x,
> #end
> }
>
> #declare S_PX2 = function {SPL2_PX}
>
> Parse Error: Expected 'operand', spline identifier found instead
>
> Unless I'm doing something wrong. Which is rather often the case.
>
> - BE
I found it! The function can not use a predefined spline so if you want a
function to use a spline define the spline in the function
#declare S_PX2 = function {
spline{
linear_spline
#for(S_K, 0, S_NSites2D-1)
S_K, A1D_V_P2D[S_K].x,
#end
}}
Works for me!
Have Fun!
Post a reply to this message
|
 |