Arexx/JAH Notes 4/13/93 FractalPro 6.0's ARexx Port Name (for the ADDRESS command in ARexx) is FPRO The commands follow the menus and control panel buttons pretty closely. Most commands which are longer than 4 letters can be substituted with their first 4 letters. For example, you can use START or STAR, TOASTER or TOAS, RESET or RESE, BACKGROUND ON or BACK ON, RESO or RESOLUTION. The MoreRexx directory has a complete ARexxDemo ARexx program which you can run from a shell. It is almost identical to the ARexx program listing in the Tutorials booklet and follows Tutorials 1 - 5 from an ARexx point of view. Here are the ARexx/JAH commands for FractalPro6.0. **** OPENING AMIGA MODE SELECTION PANEL * ARexx commands for selecting Screen Resolutions and Image Types LoRes Width Selections - ECS & AGA - Firecracker support in 24-bit 320 Regular Amiga & 24-bit 320 (_x version 24-bit 640) 368 Medium Overscan Amiga & 24-bit 368 (_x version 24-bit 736) 384 Max Overscan Amiga & 24-bit 384 (_x version 24-bit 768) HiRes Width Selections - AGA ONLY - Firecracker support in 24-bit 640 Regular Amiga & 24-bit 640 736 Medium Overscan Amiga & 24-bit 736 768 Max Overscan Amiga & 24-bit 768 SuperHiRes Width Selections - AGA ONLY 1280 Regular Amiga & 24-bit 1280 1472 Medium Overscan Amiga & 24-bit 1472 1536 Maximum Overscan Amiga & 24-bit 1536 NTSC Non-Interlaced Heights 200 Regular Amiga & 24-bit 200 (Firecracker scan-doubled) 240 Overscan Amiga & 24-bit 240 (Firecracker scan-doubled) NTSC Interlaced Heights 400 Regular Amiga & 24-bit 400 480 Overscan Amiga & 24-bit 480 PAL Non-Interlaced Heights 256 Regular Amiga & 24-bit 256 (Firecracker scan-doubled) 296 Overscan Amiga & 24-bit 296 (Firecracker scan-doubled) PAL Interlaced Heights 512 Regular Amiga & 24-bit 512 592 Overscan Amiga & 24-bit 592 MultiSync Resolutions - AGA ONLY MULT 640x480 VGA Amiga & 24-bit 640x480 (Firecracker support) SUP1 1024x768 Super72 Amiga & 24-bit 1024x768 SUP2 1280x960 Super72 Amiga & 24-bit 1280x960 DBLN 640x800 DoubleNTSC Amiga & 24-bit 640x800 DBLP 640x1024 DoublePAL Amiga & 24-bit 640x1024 Special - ECS & AGA - Firecracker support in 24-bit TOAS 376x482 Amiga 376x482 24-bit 752x482 Image Color Types HAM6 Original HAM mode ECS & AGA HAM8 AGA-only new mode AGA ONLY 256C AGA-only new mode AGA ONLY START exit mode selection and start main control panel Synonym: OKAY **** MAIN CONTROL PANEL * ARexx commands for selecting Fractal Type: FRACTAL n n is a digit, 0-9 designating which fractal function is in use 0 - Mandelbrot Set 1 - Julia Set 2 - Cube Mandelbrot Set 3 - Cube Julia Set 4 - Cosh Mandelbrot Set 5 - Cosh Julia Set 6 - Wolf Function 1 Mandelbrot Set 7 - Wolf Function 1 Julia Set 8 - Quad Mandelbrot Set 9 - Quad Julia Set * ARexx commands for controlling Image Coloring SHADE col col is a three letter color designation, declaring which color shading mode is to be used (and, if necessary, causes the program to re-color the picture and load the appropriate color shading palette) RED GRN BLU NEGATIVE ON turns negative rendering ON NEGATIVE OFF turns negative rendering OFF 24BI ON turns on 24-bit mode 24BI OFF turns off 24-bit mode synonym: DEEP ON DEEP OFF SPECTRAL ON turns on spectral mode for drawing/saving/loading 24-bit pics SPECTRAL OFF turns off spectral mode for drawing/saving/loading 24-bit pics SCHEME2 ON turns on RBG color ordering instead of RGB ordering for 24-bit SCHEME2 OFF turns on RGB color ordering instead of RBG ordering for 24-bit * ARexx commands for Color Cycling Controls CYCLE n n is a number from 1 - 9 designating the color cycling speed THIS ALSO STARTS THE CYCLING PROCESS AND BRINGS THE AMIGA FRACTAL SCREEN TO THE FRONT. COLOR CYCLING IS MUCH LONGER THAN IN FractalPro EARLIER VERSIONS. YOU MAY STOP THE CYCLING BY CLICKING ON THE FRACTAL SCREEN. FORWARD ON sets color cycling 'forward' direction on FORWARD OFF sets color cycling 'forward' direction off REVERSE ON sets color cycling 'reverse' direction on REVERSE OFF sets color cycling 'reverse' direction off BACKGROUND ON sets color cycling to include background color BACKGROUND OFF sets color cycling to exclude background color STEP ON sets single step color cycling during sequencing on STEP OFF sets single step color cycling during sequencing off * ARexx commands for Loading/Saving Files PICNAME string sets the file name for saving/loading PICPATH string sets the file path for saving/loading NOTE that file path names should usually be enclosed in quotes: when using this command with ARexx, for example: PICPATH "df0:picdirectory/" NOTE also that file path names should either end in a colon (:) or a slash (/) character. The colon is appropriate if the file path is simply a disk (like df1:) or assigned directory (like FratalPro:). The slash is appropriate if the path is leads to a subdirectory (like df1:picsdirectory/). NOTE also that the quotes aren't required when using JAH to set up a file path name, for example: JAH FRACTALPRO PICNAME df0:picdirectory/ SAVE PIC saves current picture with current path and name settings also saves current FPRO.VIS file with same name and .VIS suffix SAVE XYW save only the XYW file from the current pic - adds .XYW suffix SAVE COL save only the palette from the current pic LOAD PIC loads picture with current path and name settings LOAD XYW loads coordinate file NOTE you should truly have the coordinate file correctly named using PICNAME (the name should end in .XYW, as coordinate files always do!), for example: PICPATH "FractalPro:Pics/" PICNAME PIC0.XYW LOAD XYW would be a sensible way to use LOAD XYW to load the coordinate file corresponding to PIC0 in the PICS directory on the FractalPro disk. FractalPro:Pics/Pic0.XYW would be the file loaded by this combination of commands. No image file would be loaded or even attempted. I separated the loading of PIC and .XYW files hence separate commands to separately load .XYW files and PIC files when you desire). LOAD COL Loads a palette file (if the PICNAME refers to one) or 'steals' a color palette (if possible) if PICNAME refers to a pic file QUIT causes program to exit immediately if program is in PAUSE mode * ARexx commands for the MATH features affecting image appearance: COUNT n n is the count value you desire n can be 64, 128, 256, 512, 1024, 2048, 4096, 8192, or 16384 remember that, when 24-bit is ON, these also serve to re-color the 24-bit picture to give you lots of flexibility over 24-bit coloring AFTER the 24-bit pic is finished. Most effective for use with Firecracker-equipped systems, these let you see many different ways of viewing and saving the finished 24-bit pic. BAND n n can be 1, 2, 4, or 8 Sets the Band Thickness (Math Menu) item value. synonym: CMOD n which is left over from FractalPro 5.0 for compatibility * ARexx commands for the Zooming and UnZooming: TOPEDGE n vertical positioning information for the virtual zoom window which corresponds to the distance from the top of the graphic screen where the zoom window would be placed if manually zooming n can range from 0 to 999 (larger than your screen height!) zoomwindow height varies with zoom window size (smaller for higher zoom factors) 0 would correspond to the virtual zoomwindow being right at the top of the graphic screen LEFTEDGE n horizontal position for the virtual zoom window corresponds to the distance from the left of the graphic screen where the zoom window would be placed if manually zooming n can range from 0 to 999 (larger than your screen width!) zoomwindow width varies with zoom window size (smaller for higher zoom factors) 0 would correspond to the virtual zoomwindow being at the leftmost edge of the graphic screen ZWIN n tells program to reset the coordinates for drawing the next image as if you had manually zoomed in by a factor of n, and according to a placement of the virtual zoom window by the TOPEDGE and LEFTEDGE commands n can be 1, 2, 4, 8, or 16 (just like the manual zoom factors) synonym: ZOOM n which is left over from FractalPro 5.0 for compatibility MAG2 sets coordinates shrinking the width by 2 and centered - behaves exactly as a centered 2X zoom in would and only affects the coordinates UNMAG n tells program to reset coordinates for drawing the next image by expanding the image's width around its current center point, by a factor of n (just like using the menu) and only affects the coordinates n can be 2, 4, 8, or 16 synonym: UNZOOM n which is left over from FractalPro 5.0 for compatibility * ARexx commands For Sequence Control SEQUENCE ON turns on sequencing mode for animation sequencing SEQUENCE OFF turns off sequencing mode for animation sequencing SLEN n n is the number of pics you desire in the animation sequence n can be 16, 32, 64, 128, 256, 512, or 999 (same as menu choices) synonym: ANIM n which is left over from FractalPro 5.0 for compatibility MOVE direction sets the animation motion type for sequencing direction can be one of twelve two-letter direction tokens: LE left RI right DO down UP up IN zoom in OU zoom out DL down & left diagonal UL up & left diagonal DR down & right diagonal UR up & right diagonal TW tween CA cascade INCREMENT n sets the motion increment for animation sequencing n can be: 32 same as 32/40 menu choice 16 same as 16/20 menu choice 8 same as 8/10 menu choice 4 same as 4/5 menu choice * ARexx commands for Other FractalPro Options and Controls RESOLUTION returns you to the resolution and mode selection opening screen - this destroys whatever current picture you're working on without any warning! TURBO ON turns on Turbo high speed Mandelbrot capability TURBO OFF turns off Turbo high speed Mandelbrot capability DEFAULT XY sets default XY coordinates for drawing next image RESET # forces reset of -xxx image number to -001 when next new image drawing begins AUTOSAVE ON turns on AUTOSAVE mode for automatically saving each image (and, if either VISTA mode is ON, the corresponding Vista DEM file) - most appropriate to use with SEQUENCE ON AUTOSAVE OFF turns off AUTOSAVE mode VISM ON turns on VISTA MOUNTAIN mode to create a FPro.VIS 'mountain' VISM OFF turns off the VISTA MOUNTAIN mode VISL ON turns on VISTA LAKE mode VISL OFF turns off VISTA LAKE mode NOTE that VISTA LAKE and VISTA MOUNTAIN can't both be ON at once, the last one you activate (VISM ON or VISL ON) will be the active one CORNER ON sets Vista DEM file to be lower left corner of the image CORNER OFF sets Vista DEM to be the center 258x258 pixel area of the image NOTE that CORNER ON/OFF doesn't really have any effect unless you also use VISM ON or VISL ON. It only affects Vista DEM creation, and only specifies which part of the next fully drawn image will become a FPro.VIS file (either the lower left corner if CORNER ON, or the center if CORNER OFF). SCRIPT ON turns on SCRIPT feature (ONLY IF STARTED FROM CLI) SCRIPT OFF turns off SCRIPT feature * ARexx commands for Drawing and Pausing: DRAW continues drawing image or starts a new one if appropriate PAUSE now implemented to PAUSE properly FROM JAH ONLY! PAUSE forces an 'error' in ARexx and STOPS your ARexx script! If you're clever you can continue it where it left off when you so desire. NEWD always begins drawing from a complete new image from the bottom of screen (instead of continuing where it left off) Synonym: DNEW How to Use These Commands All these commands work with ARexx or JAH. JAH is a AmigaDos command I've included here so you can have some remote control of FractalPro5.0 from an AmigaDos script even if you don't have or are unfamiliar with ARexx. JAH is simply a little command which can send a text message (like an ARexx command) to any program with a public (named) message port; like FractalPro's message port named FRACTALPRO (ALWAYS ALL UPPERCASE!). YOU SHOULD COPY JAH TO YOUR C: DIRECTORY (IT IS TINY, SO DON'T WORRY) FOR THE FOLLOWING EXAMPLE JAH SCRIPTS. JAH is NOT PUBLIC DOMAIN! Remember that all these commands should always be UPPER CASE only! AND that all these commands bypass all of FractalPro's Requesters! AND you can completely goof yourself up with these in ways which the menus normally prevent you from so doing! These commands won't prevent you from saving a picture with a set of coordinates which don't match the picture, for example - while the menus will try to 'ghost' themselves to prevent you from so doing. Just be careful and know what you're doing before using scripts to do your sequencing for you with AutoSave, etc.! AND to use ARexx scripts you need ARexx and you need to have the ARexx program activated by calling REXXMAST in your startup sequence or from a CLI before you try to use ARexx scripts with FractalPro! AND File Names and Path Names should be inside quotes ("") when using these commands with ARexx! DO NOT PUT COMMENTS ON THE SAME LINE AS A JAH COMMAND IN A SCRIPT (e.g. do NOT do this: JAH FPRO DRAW ;NOW DRAW JAH DOESN'T LIKE COMMENTS ON THE SAME LINE AS A JAH COMMAND 1. A Simple JAH Script First start up FractalPro6.0, load or draw an image, then use type these JAH commands into a CLI or Shell window, one after another. JAH FPRO DEEP OFF JAH FPRO TOPEDGE 50 JAH FPRO LEFTEDGE 50 JAH FPRO ZWIN 4 JAH FPRO COUNT 256 JAH FPRO NEWDRAW The first command simply tells FractalPro to only work in whatever Amiga coloring mode you've selected (turns 24-bit off). The next 3 commands set up a zoom operation and they happen quickly. The last command tells FractalPro to draw the zoomed picture. The CLI/Shell prompt won't return until the operation is completed (picture is fully drawn). You could also make this group of commands into an AmigaDos script and just execute it that way all at once. Here's another simple example which loads NICEM2 and color cycles it a bit: (works either with the FractalPro floppy disk or if you've installed the program on your hard disk and done the proper 'assign' of the FractalPro: directory) JAH FPRO PICPATH FRACTALPRO:PICS/ JAH FPRO PICNAME NICEM2 JAH FPRO LOAD PIC JAH FPRO FORWARD ON JAH FPRO REVERSE OFF JAH FPRO CYCLE 2 JAH FPRO FORWARD OFF JAH FPRO REVERSE ON JAH FPRO CYCLE 3 2. A simple ARexx Script ADDRESS FPRO DEEP OFF TOPEDGE 50 LEFTEDGE 50 ZWIN 4 COUNT 256 NEWDRAW That is just the ARexx way to doing the same thing as the first short JAH script above. FractalPro's ARexx Port Name is FPRO. Here's the second example JAH script in ARexx format. ADDRESS FPRO PICPATH "FRACTALPRO:PICS/" PICNAME "NICEM2" LOAD PIC FORWARD ON REVERSE OFF CYCLE 2 FORWARD OFF REVERSE ON CYCLE 3 There are two icons with these script examples ready-to-run on the floppy. 1. JahDemo - just double-click the icon! It will start up FractalPro and do a little JAH script combining the two short examples above. 2. RexxDemo - similar, but does a long ARexx (of course, you must have ARexx for this one!) demo. Excuses, Excuses There is no way to present here all the complexities and varieties you can arrange with ARexx and JAH scripts. Look for some examples elsewhere on this disk. Remember also that your FPro.SCR scripts (activated within FractalPro after an AutoSave'd image, see the Manual) can also call JAH or ARexx scripts. The script possibilities are limitless.