|
![](/i/fill.gif) |
Elias Pschernig <elias at users sf net> wrote:
> I was just wondering, does anyone know about the origin of the grammar used
> for describing the SDL throughout the pov docs?
It's a kind of BNF derivative. The BNF notation is quite common in
many places as it's a formal way to define the syntax of things.
> I started playing around with some python code to parse simple .pov scripts
> based on SDL grammar snippets from the docs - so now I was wondering if
> there's somewhere the complete grammar, and maybe even a utility to
> generate a parser based on it? (Else I have to copy&paste it all out of the
> docs..)
I think yacc and lex are often used to create language parsers with
some BNF-style syntax.
--
#macro M(A,N,D,L)plane{-z,-9pigment{mandel L*9translate N color_map{[0rgb x]
[1rgb 9]}scale<D,D*3D>*1e3}rotate y*A*8}#end M(-3<1.206434.28623>70,7)M(
-1<.7438.1795>1,20)M(1<.77595.13699>30,20)M(3<.75923.07145>80,99)// - Warp -
Post a reply to this message
|
![](/i/fill.gif) |