POV-Ray : Newsgroups : povray.unofficial.patches : name for no interpolation : Re: name for no interpolation Server Time
8 Jul 2024 17:58:09 EDT (-0400)
  Re: name for no interpolation  
From: Christopher James Huff
Date: 11 Sep 2002 11:34:36
Message: <chrishuff-81E2AB.11335311092002@netplex.aussie.org>
In article <6uiunuc15f15ikpe3mdavli2tc3q5h8tg7@4ax.com>,
 ABX <abx### [at] abxartpl> wrote:

> > I find keywords much easier to read and write than numbers
> 
> POV's SDL doesn't help me to make decision. Patterns has names and internal
> functions hasn't.

Huh? The internal functions have names, they are just defined through 
the functions.inc file instead of being built-in. If you use the 
function ID numbers directly, you are doing it wrong, and your scene 
probably won't work in future versions.


> Type of interpolation for splines has names and types for
> interpolation for images hasn't.

And I can remember the keywords for spline types a lot easier than the 
numbers for image interpolation.


> Methods usually hasn't names.

Methods? POV doesn't have...oh, you mean like the media sampling methods?
That is one case where I might have used numbers. The only keywords I 
can think of are "random" or "monte_carlo" (which I'm not entirely sure 
is right), "even_spacing", and "supersampled", and none of them seem 
very appropriate. I would have used "sampling_method" instead of 
"method" though...or a completely different syntax, somethign like: 
sampling {type, PARAMS}


> Noise generator types have no names.

I don't like the way noise generators were done, either in syntax or in 
the way they were done internally. I think that feature was just a hack.
I would have used names such as perlin_noise, old_pov_noise, pov_noise, 
lewis_noise, etc, and a completely different syntax. There would be a 
global generator that could be set to any of these, but a noise 
generator could be defined in the file as a function, something like:

global_settings {
    noise_generator function {perlin_noise {}}
    noise_generator FUNCTION_IDENTIFIER
}
#declare myNoise = function {perlin_noise {range MIN, MAX ...}}

Patterns and other things that use noise would be able to use any 
function as the noise source.


> > I feel that you should only use a number for a numeric value.
> Then how to call two different algoithms for connections along torus fragments
> to make it readable ?

torus and torus2, torus1 and torus2, toroidal1 and 2, or something 
similar...it is done in other places: the spiral patterns, atan and 
atan2 functions, etc...
If keywords make sense, I think they should be used instead of numbers.

-- 
Christopher James Huff <cja### [at] earthlinknet>
http://home.earthlink.net/~cjameshuff/
POV-Ray TAG: chr### [at] tagpovrayorg
http://tag.povray.org/


Post a reply to this message

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