|
![](/i/fill.gif) |
I'd like to try adding a feature to POV-Ray, to let me use splines to
arbitrarily scale objects in a non-linear fashion. For a very simple
example, I'm thinking of something along the lines of:
#declare Spline1 = control_spline {
cubic_spline 5,
<0,-3>, <1,-2>, <1.5,0>, <1,2>, <0,3>,
}
box { <-2,-0.5,-0.5>, <2,0.5,0.5>
spline_scale y*Spline1
pigment { colour rgb <0,1,1> }
}
...which would produce a box with a top and bottom that curve outwards
in the middle (see http://www.gate.net/~shipbrk/raytrace/wishlist.jpg
for an example of what it would look like).
Unfortunately, I'm very bad at maths, and the POV-Ray source code is a
bit daunting; I don't have the foggiest idea where to begin. Would
anybody be willing to give me some pointers as to how I could accomplish
this (or even if it's possible)?
Many thanks,
--
Jeff Lee shi### [at] gate net http://www.gate.net/~shipbrk/
Post a reply to this message
|
![](/i/fill.gif) |