home *** CD-ROM | disk | FTP | other *** search
- LANGUAGE.DOC
-
- This is a brief description of the command line flags, and language
- of form. This file is updated very sporadically so I'm sorry about
- the lack of organisation to it.
-
- Latest revisions give:
- textures new keyword for POV support (see flagpole and webgood
- for examples) can be used almost anywhere after an object.
- Still in prototype stage.
-
- -float[+-] Turn use of floats on/off when rendering to the screen
- improved quality at the sake of time.
-
- -pov_version=[1|2] the version of POV you're using default 2
- -q[0|1|2|3|4|5] "Quality" I'm still working on this, default is -q0,
- try other options.
-
- -modex use VGA "ModeX" for 320x200 mode (-res1), required on
- some VGA cards. This mode is slightly slower than
- normal, and much faster than BIOS.
-
- -ems[+-] use/don't use ems for ZBUFFER if present this is
- sometimes a lot faster, and sometimes not at all.
-
- -angle=number command line flag for initial rotation around y axis
- scale number - scales the object by the number
- twistx number - like twist only around x axis
- twistz number - like twist only around z axis
- spin flag, command line only -spin=frames to use.
- Spins the scene through 360 degrees in the frames you specify.
- Not very useful without the -save= and -k- flags
- if -save specified Files are named with trailing digits, i.e.
- spin=9 takes save=abcdefgh and produces abcdefg#(.gif)
- spin=9999 creates abcd###(.gif)
-
- save as Gif flag -g[+-]
- and it's alias save as tga -t[-+], (SaveAs=GIF or TGA)
-
- save background as white -w[+-] flag (SaveBackgroundAsWhite=Yes|No)
-
- include directories -path=dir1;dir2... (path=dir1,dir2... in sstools.ini)
-
- Propellors when parsing a file, so you know it hasn't died!
- Each script is written to TEMP.FRM.
-
- WEB now has HOLE and EXCESS
-
- Pressing <ESC> during a display should stop the display
- Saving to TGA file, use -save=filename (default temp.tga for "-save")
-
- display at end using -display(1,2,3,4)
- type 1=wire 2=flat 3=gouraud 4=phong
-
- In the language new command "#include filename", verrrry crude and
- barely tested!
- NOTE: the statement "end" in an include file is ignored
- "end" is only understood in the first file.
-
- -k[+-] pause at end of display. I know I put this in for a good
- reason, something to do with Batch mode and saving, but I'm
- not too clear what. I've remembered ... see -spin above,
-
- -bios[+-] Super duper Bios compatability, use bios putpixel,
- and 320x200 bios mode switch, use on nasty notebooks.
-
- -vesa use a vesa driver if found for Video Control,
- the autodetect routines crash windows normally!
- steps:
- 1. load your vesa driver if need be
- 2. go into windows (if you want)
- 3. run "form -vesa" (the default)
- there isn't any apparent slowdown anyway
-
- You can load a Vesa driver such as "univesa".
-
- SSTOOLS.INI
- all the command line switches can be saved in the [FORM]
- section of an sstools.ini file somewhere on your path.
- (thanks Fractint!).
- see example sstools.ini file.
-
-
-
-
- usage:
- form [options] [file] [options]
- if [file] is ommited the form is read from stdin
- options are also read from the environment variable FORM, and sstools.ini
-
-
- options are:
-
- -pov[-|+|1|2|3]
- - : no temp.pov output file
- + : produce a temp.pov file (default)
- 1 : output file is made of individual objects
- 2 : output file is made using composites
- 3 : output file is made using #declares (default)
-
- -plg[-|+]
- - : no temp.plg output file
- + : produce a temp.plg file (default)
-
- -res[1|2|3]
- 1 : screen display is 320x200 (default)
- 2 : screen display is 640x400 or 640x480 depending on memory
- 3 : screen display is 1024x768
-
- -display[1|2|3|4]
- 1 : display at end Wireframe
- 2 : display at end Flat
- 3 : display at end Gouraud(default)
- 3 : display at end Phong
-
- -dump [-|+]
- Debug Dump at end
-
- -k[+-] pause at end of display. I know I put this in for a good
- reason, something to do with Batch mode and saving, but I'm
- not too clear what.
-
- -bios[+-] Super duper Bios compatability, use bios putpixel,
- and 320x200 bios mode switch.
-
- -vesa use a vesa driver if found for Video Control,
- the autodetect routines crash windows normally!
- steps:
- 1. load your vesa driver if need be
- 2. go into windows (if you want)
- 3. run "form -vesa" (is default)
- there isn't any apparent slowdown anyway
- -v [-|+]
- Overly Verbose and useless output
- -?
- Help
-
- ******* **** ***** ** **
- * * * * * * * * *
- **** * * ***** * * *
- * * * * * * *
- * * * * * * *
- * **** * * * *
-
-
-
- C style comments are allowed both /**/ and // forms
-
- SYMBOL is a standard C symbol ie. a-z followed by any of a-z 0-9 and _.
- NUMBERS are all real, converted to int wherever appropriate.
- NUMBERS can be expressions using +, -, *, /, ^, ().
- VECTORS are in the form "<" real "," real "," real ">"
- ANGLES are in degrees
-
-
- The form file essentially describes a scene.
- it has the shape of :-
-
- any number of: objectdefinitions
- any number of: debug flag assignments
- any number of: configurable item assignments
- any number of: output commands (currently only display!)
- at least ONE: object (usually only one)
- optionally terminated with the word "end" (meaning produce some output)
- simple end of file simply stops processing
-
-
- OBJECT
- ======
- an object is a set of part objects terminated by a ';'
-
- a (part) object is :
-
- an object followed by a FORM
- an object followed by a simple modifier
- an object followed by a FORM modifier
- a PRIMITIVE
- a DEFINED_OBJECT
- a DEFINED_OBJECT enclosed by "[ ]", this has the effect of rotating
- the object by 90 degrees
- an object "," object.
-
-
- OBJECT DEFINITION
- =================
- is a name (symbol) followed by "=" and then an object.
-
-
-
- COMMANDS
- ========
-
- DEBUG RELATED COMMANDS
- ----------------------
-
- these have no effect on the objects or output
-
- lexdebug <on|off> turns debug prinouts from lex on or off (default off)
-
- yaccdebug <on|off> turns debug prinouts from yacc on or off (default off)
-
- yydebug <on|off> turns internal yacc debug prints on or off (default off)
-
- OUTPUT RELATED COMMANDS
- -----------------------
- these affect the output not the shape
-
- plg scale = number;
- defines the plg scale used for output to plg - default 500
-
- old_pov_method;
- not used anymore
-
- screen_res = [1|2|3];
- equivalent to -res[1|2|3] command line option
-
- screen_scale = number;
- scale up the screen output, 1.2 is usually OK
-
- display [object] [save file name] [rendering style];
- will display object (default current object) in the
- rendering style specified. save file name is not
- actually implemented, it takes time but doesn't do
- anything. This does not in any way represent the
- views of the author to freeware, it's just I haven't
- done it yet!
-
-
- PRIMITIVES
- ==========
-
- sphere
- sphere radius
-
- ellipse
- ellipse width , height
- ellipse <vector> (vector gives x, y, z axis lengths)
-
- box
- box size
- box vector (vector gives x , y , z size)
-
- torus
- torus minradius , maxradius
-
-
-
- FORMS
- =====
-
- these take an object (list of objects) and create another object from
- a compound of these to which have been applied transformations
-
- STACK number_to_stack
- STACK number_to_stack IN space_of_number
- STACK number_to_stack IN space_percentage "%"
-
- This stacks number_to_stack objects with compression of:
- 1.0
- space_of_number / number_to_stack
- space_percentage / 100
-
- The resulting object is similar to that created by a list of objects
- i.e. sphere stack 2 is the same as sphere , sphere
-
- FAN number , angle [ , tightness]
-
- takes no_objs copies of object and fans them through 0 .. angle
- degrees in a sphere (angle usually 0 .. 180), optional tightness
- defaults to 1 gives a bunching effect, 0.1 shows what it does the
- result is a single object of height 0;
-
- web number1 WITH defined_object
- [SCALE(number2)] number3 [hole number] [excess number]
-
- uses number1 spokes of object webbed with number3 of defined object
- which are optionally scaled up by number2.!
- hole is the gap to leave in the middle (2 = 2 * length of a spoke)
- excess is amount to exceed by (proportions of a spoke)
- eg.
- spokeobject WEB 8 WITH webbing_object 3
- creates a sort of 8 spoked 3 ringed waggon-wheel.
-
- rib NYI
-
-
- MODIFIERS
- =========
-
- these are applied to an object and are used to change the shape
-
- SIMPLE MODIFIERS
- ----------------
-
- DELETE delete_range e.g delete 1 or delete 10 .. 5
- makes the x..y'th object in the list invisible.
-
- MOVE <vector>
- moves every object in the list by vector (remember Y is up)
-
- TEXTURE <texture name> eg texture "Metal pigment{White}"
- applies the POV texture from that point downwards.
-
- STACK MODIFIERS
- ---------------
-
- these give a warning if they do not follow a stack but will often
- work if there is a list of more than one object
-
- GROW size
-
- takes the stack and uniformly grows each object (about it's own
- center) by an amount: 1 for the first object, and size for the
- last.
-
- POWERED_GROW
- CENTERED_GROW
- POWERED_CENTERED_GROW
- slightly different in how they actually do the growing.
- Not too hot. Powered grow is the best of the lot, it isn't
- linear, that's all.
-
- BEND angle
-
- bends the stack fromthe vertical by angle. Bend of 360 gives one
- loop of a spiral, bend of 90 gives a quarter loop.
-
- TWIST angle [ , displacement]
-
- rotates each obj in stack around vertical axis by 0 .. angle
- degrees optional offset moves stack by displcement, rotates about
- original axis and then moves back. Gives a spiral effect
-
- TWISTX angle
- rotates each obj in stack around X axis by 0 .. angle.
-
- TWISTZ angle
- rotates each obj in stack around vertical axis by 0 .. angle.
- interesting effect when combined with BEND.
-
- incremental twist ILLEGAL
- incremental grow ILLEGAL
- incremental bend ILLEGAL
-
-
- OTHER VALID INPUT
- =================
-
- exists test token
-
- end marks EndOfFile, REQUIRED or you don't get any output!
-
-
- rummy@snaffle.demon.co.uk
-
- Andrew Rowbottom
-