npiet-foogol - a foogol to piet compiler |
npiet-foogol [ -v | -d ] [ -w <n> ] [ -b <n> ] inputfile |
npiet-foogol translates foogol input to a piet program. So npiet-foogol creates a picture from foogol source. The picture is, well should be, a valid piet program and can be executed, eg. by the npiet interpreter. |
-h |
print usage help and exit. |
-v |
be somewhat verbose. |
-d |
print debug output (lot's of more or less cryptic and mostly useless blurb). |
-w <n> |
Sets a wrap-width in pixel. This gives the compiler a hint
about a block width to use when generating expressions or
statements. Usually code is generated left to right until the wrap-width is reached and then to the left. To avoid codel overlaps in loops and conditionals, code is generated with a virtual left border, but this wrap-width too. Here is lot of optimisation possible. |
-b <n> |
Sets the base used by generating a number. The default is 7
and a value greater or equal of 2 is acceptable. In a piet program the number of codels (here pixels) of a color block represents a number. To be able to push a large number on the stack without wasting a lot of ink, the number is calculated and the given base is used to do so. |
-o <filename> Sets the output filename. Default is npiet-foogol.png. |
inputfile |
The foogol program to read. Use a - to read from <stdin>. |
npiet-foogol.png - default name of the piet program file to write. It is overwritten if it exists. |
Erik Schoenfelder <schoenfr@web.de>. |
Surely lots. |
npiet(1), npietedit(1) http://www.bertnase.de/npiet/ http://www.gaertner.de/html/foogol.html |