I wanted to express a concern about Linas' position that VRML should
be purely declarative.
I hope that VRML will at least have variables and the ability to
define interpreted procedures and iterators so that
regular geometric objects can be described efficiently over the net?
If I have variables in the language don't I need a verb in the language
to set the variable?
It seems to me that there would be a great loss in efficiency
without an ability to express structures in a procedural fashion.
For example, in tsipp (a tcl extension) I can write:
set metal_dull [SippShaderStrauss 0.4 0.2 0.9 {0.6 0.33 0.27}]
set cornerBlock [SippBlock {.5 .5 5} $metal_dull WORLD]
SippObjectMove $cornerBlock {-3.75 -2.25 0}
set cornerBlock [SippObjectInstance $cornerBlock]
SippObjectMove $cornerBlock {3.75 -2.25 0}
which uses variables and procedures to describe two dull-metal blocks.
How can I do this efficiently without them?
What aspects of procedural languages in general do you see as a
problem in VRML? Is it just a concern about the readability of stack
based languages such as postscript?
BTW. I support the idea that VRML should be an interpreted language,
but aren't there many possible interpreted procedural languages that
aren't stack based? e.g. tcl, python, perl, rexx (presumably with 3d extensions)
-----------------------------------------------------
> From: [email protected] (Linas Vepstas)
>
> > It looks like a language, it smells like a language...
>
> A common categorization of languages is this:
>
> 1) "Descriptive" or "declarative" languages -- These have
> only nouns that desribe things. E.G. "circle {red,
> radius { 3 inches}}". HTML is an example of a declarative
> language. I'm hoping VRML will be declarative. These
> lang's rarely have compilers, almost always have interpreters.
> (It's usually not worth writing a compiler).
>
>
> 2) "Proceedural" languages -- These have nouns and verbs,
> describing how to do things. "add this to that, if
> this equals that". C, C++, FORTRAN, BASIC, COBOL
> are all of this type. So is Postscript. Ditto Forth.
> Subclasses include stack-based (Postscript, Forth),
> structured (C, F77 but not F66), and object oriented (C++).
> Most have compilers.
>
> BTW, Brown Univeristy's 3D language is this kind of
> a language, so is Kaleida's ScriptX. I personally do
> NOT want VRML to be proceedural.
>
>
> 3) "Evaluative" or "constructive" languages. The language
> allows you to build expressions which are true or false.
> Evaluating the expessions doesn't "do" anything. It merely
> "proves" the expression to be true or false. (Of course,
> the side effects of the proof, e.g. what is printed out
> while the "proof" or evaluation is happing, can be very,
> very interesting). Mathematicians tend to like these
> because the result of a program can be "proven" to be correct.
> Examples include LISP, (based on Church's Lambda Calculus),
> and Prolog.
>
> Usually, compilers are too hard to develop for these.
> Interesting ... but inappropriate for VRML.
>
> --linas
>