|
![](/i/fill.gif) |
Hi Mike,
Thanks a lot for replying my post.
Well, I'm understanding somethings.
First your code:
======================================
#declare S = function {
spline {
natural_spline
-1, < 0.5, 0, 0.0>,
-0.5, < 0.2, 0, 0.4>,
0.01, < 0.2, 1, 0.2>,
0.5, < 0.4, 0, 0.4>,
1, < 0.0, 0,-0.2>
}
}
isosurface {
function { y - S(x).x - S(z).z }
max_gradient 2
pigment { color Green }
translate <170, 5, -90>}
======================================
To make it larger I have to increse the number of point, isn't it?
And, if I want to reduce the height?
I want to create a surface like this:
======================================
#declare Q = function {y - 9*cos(x/3/8) - 3*sin(z/3/8)}
isosurface {
function { abs(Q(x,y,z)) - 1 }
max_gradient 2
contained_by{box{ <-36, -20, 147> <280, 20,150> }}
pigment { color Green}
finish { ambient 0.2 diffuse 0.8 phong 1 }
translate <10, -40, -116>
======================================
But it's only a simple sine and cosine function. I want a function to make
the surface go up and go down. I think a spline would be a good idea.
What do you think Mike?
Regards,
Oleguer
news:FRm### [at] econym demon co uk...
> Wasn't it Oleguer Vilella who wrote:
>>Hi,
>>
>>Can I modulate this isosurface using a linear_spline?
>
> It's not clear what you are trying to achieve with that code. It's
> possible to fix it in various different ways to achieve various
> different results. The main problem is that splines are three functions
> of one variable, not one function of three variables, so instead of
> S(x,y,z) you have to use the three functions S(?).x S(?).y and S(?).z,
> where "?" could be x, y or z.
>
> Take a look at the examples on these pages for some ideas of what can be
> achieved. I believe that all the examples work equally well if you
> change them to linear splines.
>
> http://www.econym.demon.co.uk/isotut/more.htm
> http://www.econym.demon.co.uk/isotut/splines.htm
>
> --
> Mike Williams
> Gentleman of Leisure
Post a reply to this message
|
![](/i/fill.gif) |