|
![](/i/fill.gif) |
In article <3a04ed21@news.povray.org>, "Mark Wagner"
<mar### [at] gte net> wrote:
> "all" makes more sense than "grey".
That is what I finally implemented it as. It took me a while to figure
out how to allow rgb, red, green, and blue to be used, though.
> The limit is 256 points -- enough for most uses, but why have a limit
> when there doesn't need to be one?
It looks to me like that was just a stopgap measure...it looks like you
could implement it mostly by adding code to the Insert_Spline_Entry()
function.
I don't have any experience with growing dynamically allocated
arrays...I tend to use linked lists for everything.
> >Also, it would be useful if you could access the control points, with
> >functions that behave similar to the array functions and an array-like
> >syntax.
> This might be very difficult to implement -- there are enough
> problems with the spline syntax as it is.
I think could get it working with functions, but I have no idea how to
do the array like syntax...
INT spline_points(SPLINE_IDENT) Retrieves the number of points in the
spline.
EXPRESS get_spline_point(INT_INDEX) Returns the corresponding point on
the spline.
BTW, I implemented the SPLINE_IDENT(T, TYPE) syntax. You can now do
something like this:
#declare Spl = spline {linear_spline ...}
#declare Val1 = Spl(T);
#declare Val2 = Spl(T, cubic_spline);
#declare Val3 = Spl(T, quadratic_spline);
I will send you the code soon.
--
Christopher James Huff
Personal: chr### [at] mac com, http://homepage.mac.com/chrishuff/
TAG: chr### [at] tag povray org, http://tag.povray.org/
<><
Post a reply to this message
|
![](/i/fill.gif) |