POV-Ray : Newsgroups : povray.general : long syntax : Re: long syntax Server Time
5 Aug 2024 22:19:16 EDT (-0400)
  Re: long syntax  
From: Christopher James Huff
Date: 23 Jul 2002 22:18:54
Message: <chrishuff-424F5B.21114323072002@netplex.aussie.org>
In article <Xns### [at] 204213191226>,
 "Rafal 'Raf256' Maj" <raf### [at] raf256com> wrote:

> so, how about at least shorten some names, i.e. add keywoed "brill" that 
> works same as "brilliance". 

No thanks.


> Don't You agree that brilliance, reflection, diffuse, ambient are keywords 
> that are used very common (if scene have meany diffrent textures), and ther 
> is probably no reason to not have shorten versions. 

No thanks. The disadvantages far outweigh the advantages in my opinion. 
"ambient" has 7 characters, it takes a fraction of a second to type.


> Something like "color" and "colour" keywords - the second is in fact aliast 
> of 1st, and it is added to make SDL comfortalbe.

That is an entirely different situation...both are valid spellings for 
the word.


> This ~10 keywords, maybe with diff and itner will make typing quicker, and 
> will not make code less clear IMHO

They are also polluting an already crowded namespace, and will make code 
less clear, adding more stuff to memorize, sprinkling odd characters and 
keywords through the files whose meanings are not obvious.


> > The only benefit would be for obfuscated and shortest code contests. If 
> > you really just want to save typing, I would recommend you find a good 
> > editor...you could also use the existing #macro feature:
> > #macro supell(E, N) superellipsoid {E, N #end
> > supell(0.1, 0.5)
> >     texture {...}
> > }
> 
> but it's usless in i.e. finish, normal, pigment, blob, mesh etc

I don't see how blobs or meshes are any different. And for the texture 
stuff, it isn't useless, just put the stuff you use most often as a 
parameter. You could also leave off the ending bracket to be closed 
outside the macro call.

#macro Fin(Dif, Amb, Spec, Rough, Refl)
    finish {
        diffuse Dif
        ambient Amb
        specular Spec
        roughness Rough
        reflection Refl
    }
#end

You could put these in an include and make things as short and hard to 
read as you want. ;-)
My point is that there is already a feature that can be used to do what 
you want, and the proposed feature has so many drawbacks that it is very 
unlikely you will find anyone willing to waste the time to implement it.

-- 
Christopher James Huff <chr### [at] maccom>
POV-Ray TAG e-mail: chr### [at] tagpovrayorg
TAG web site: http://tag.povray.org/


Post a reply to this message

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