The autokey feature allows you to set up beautiful self-running demo "loops". You can set up hypnotic sequences to attract people to a booth, to generate sequences for special effects, to teach how Fractal exploring is done, etc.
A sample autokey file (DEMO.KEY) and a batch to run it (DEMO.BAT) are included with Fractint. Type "demo" at the DOS prompt to run it.
Autokey record mode is enabled with the command line parameter "AUTOKEY=RECORD". Keystrokes are saved in an intelligible text format in a file called AUTO.KEY. You can change the file name with the "AUTOKEYNAME=" parameter.
Playback is enabled with the parameter "AUTOKEY=PLAY". Playback can be terminated by pressing the [Esc] key.
After using record mode to capture an autokey file, you'll probably want to touch it up using your editor before playing it back.
Separate lines are not necessary but you'll probably find it easier to understand an autokey file if you put each command on a separate line. Autokey files can contain the following:
Quoted strings. Fractint reads whatever is between the quotes just as if you had typed it. For example, "t" "ifs" issues the "t" (type) command and then enters the letters "i", "f", and "s" to select the ifs type.
Symbols for function keys used to select a video mode. Examples:
Special keys: ENTER ESC F1 PAGEUP PAGEDOWN HOME END LEFT RIGHT UP DOWN INSERT DELETE TAB CTRL_RIGHT CTRL_LEFT CTRL_DOWN CTRL_UP CTRL_HOME CTRL_END
WAIT [nnn.n] -- wait nnn.n seconds before continuing
CALCWAIT -- pause until the current fractal calculation or file save or restore is finished. This command makes demo files more robust since calculation times depend on the speed of the machine running the demo - a "WAIT 10" command may allow enough time to complete a fractal on one machine, but not on another. The record mode does not generate this command - it should be added by hand to the autokey file whenever there is a process that should be allowed to run to completion.
GOTO target -- The autokey file continues to be read from the label "target". The label can be any word that does not duplicate a key word. It must be present somewhere in the autokey file with a colon after it. Example:
MESSAGE 2 This is executed once
start:
MESSAGE 2 This is executed repeatedly
GOTO start
GOTO is mainly useful for writing continuous loop demonstrations. It can also be useful when debugging an autokey file, to skip sections of it.
; -- A semi-colon indicates that the rest of the line containing it is a comment.
MESSAGE nn [Your message here] -- Places a message on the top of the screen for nn seconds
Making Fractint demos can be tricky. Here are some suggestions which may help:
Start Fractint with "fractint autokeyname=mydemo.key autokey=record". Use a unique name each time you run so that you don't overwrite prior files.
When in record mode, avoid using the cursor keys to select filenames, fractal types, formula names, etc. Instead, try to type in names. This will ensure that the exact item you want gets chosen during playback even if the list is different then.
Beware of video mode assumptions. It is safest to build a separate demo for different resolution monitors.
When in the record mode, try to type names quickly, then pause. If you pause partway through a name Fractint will break up the string in the .KEY file. E.g. if you paused in the middle of typing fract001, you might get:
"fract"
WAIT 2.2
"001"
No harm done, but messy to clean up. Fractint ignores pauses less than
about 1/2 second.
DO pause when you want the viewer to see what is happening during playback.
When done recording, clean up your mydemo.key file. Insert a CALCWAIT after each keystroke which triggers something that takes a variable amount of time (calculating a fractal, restoring a file, saving a file).
Add comments with ";" to the file so you know what is going on in future.
It is a good idea to use INSERT before a GOTO which restarts the demo. The [insert] key resets Fractint as if you exited the program and restarted it.
Warning: an autokey file built for this version of Fractint will probably require some retouching before it works with future releases of Fractint. We have no intention of making sure that the same sequence of keystrokes will have exactly the same effect from one version of Fractint to the next. That would require pretty much freezing Fractint development, and we just love to keep enhancing it!