home *** CD-ROM | disk | FTP | other *** search
/ Esprit de Apple Corps / EDAC-2.iso / Graphics / Apps / Programs / TransMog / TM.Doc < prev    next >
Encoding:
Text File  |  1991-03-17  |  4.6 KB  |  107 lines

  1.                                  TransMog
  2.  
  3.                              by Glen E. Bredon
  4.  
  5.  
  6. This download contains the following files:
  7.  
  8. TransMog      - the main BASIC program, a "Cellular automoton".
  9. TM.Pallets    - a variables file used by TransMog and TM.Editor.
  10. TM.Editor     - a BASIC program allowing alteration of the 10 super
  11.                 hires pallets used by TransMog.
  12. SHR           - machine language program used by the above.
  13. SLOAD         - ditto.
  14. TM.Fast       - ditto - this is the one that does the work.
  15. TM.Slow       - ditto - same for slow mode.
  16. TM.Doc        - this doc file.
  17.  
  18. You should copy these files to a directory containing some super hires
  19. screen images (filetype PIC = $C1), which then can be used by the program.
  20.  
  21. This is a "cellular automoton" which is fancy language for a program
  22. having a number of "cells", such as screen pixels, and a rule for changing
  23. a cell based on its contents and those of its neighbors.  The granddad of
  24. such programs is the "game of life" by Conway.  The current program is that
  25. described in Scientific American Computer recreations, August 1988, and
  26. called there "the hodgepodge machine."
  27.  
  28. Each cell has a value of 0 to 120.  Value 0 represents a "healthy" cell
  29. (shown in white in supplied pallets).  Value 120 represents an "ill" cell
  30. (black).  Values between represent infected cells (colors).  An ill cell
  31. becomes healthy at the next stage.  A healthy cell takes the value
  32.  
  33.     [#infected neighbors/K1] + [#ill neighbors/K2]
  34.  
  35. An infected cell takes the value
  36.  
  37.     Min([Sum of neighboring values/# infected] + virulence, 120)
  38.  
  39. Square brackets represent "integer part" of the number contained within.
  40. In this implementation, I keep the variables K1 and K2 fixed at the values
  41. 2 and 3 as in the example in that article.  The virulence is settable.
  42. The maximum value for a cell is taken to be 120 rather than 100 as in the
  43. article.  None of that need concern the casual user - this is mainly just
  44. a program that produces some nice pictures from existing pictures or random
  45. patterns.
  46.  
  47. P. Brinkley has written some very nice programs of this type.  I wanted
  48. more speed, a lot of it, and that is the reason for writing this version.
  49.  
  50. Operation of the program
  51. ------------------------
  52.  
  53. After entering the program you are asked whether you want Slow or Fast
  54. mode.  The slow mode operates at about 4 seconds/frame but in full 320x200
  55. super-hires resolution.  Fast mode operates at 1 second/frame but with a
  56. resolution half of that of slow mode in both directions, 160x100.  Fast
  57. mode also has an option of full screen (with a chunky appearance because
  58. of the low resolution) or quarter screen.  The latter shows 4 stages at
  59. once, rotating clockwise around the screen, but without the chunkiness of
  60. the full screen mode.
  61.  
  62. You are then asked for the virulence which affects the algorithm producing
  63. the next screen from the present one.  A value of 5 to 30 or so is best.
  64.  
  65. You then select Random or Picture.  In the latter case you are given the
  66. opportunity of choosing from a list of the PIC files in the directory
  67. containing the program.  (There must be at least one such file.)
  68.  
  69. Then you choose the "masking", High or Low.  The program works with an
  70. array of values for each cell which goes from 0 to 120.  Since the graphics
  71. screen has only 16 values for each pixel, there must be a choice of how the
  72. 121 possible values of a cell is represented on the screen by the 16 values
  73. possible on the screen.  This is done one of two ways:
  74.  
  75. 1. Masking off the low bits.  This has the effect of nearby values for two
  76.    cells giving the same color on the screen, i.e., of spreading the colors.
  77.  
  78. 2. Masking off the high bits.  This has the effect of giving nearby values
  79.    different colors and cycling the colors when they are used up.
  80.  
  81. Low masking is preferred in most cases (based on quality of picture produced)
  82. but High masking is better for random screens with low virulence.  The program
  83. shows the default that is generally best for the parameters chosen.
  84.  
  85. Commands during operation:
  86. --------------------------
  87.  
  88. While the pictures are being generated you can issue several commands:
  89.  
  90. Keys   Effects
  91. ----   -------
  92. 0-9    Change to one of the 10 program pallets.
  93. *      Revert to initial pallet (the pictures pallets in picture mode,
  94.           and pallet 0 in random mode).
  95. H      Switch to high masking.
  96. L      Switch to low masking.
  97. ESC    Stop plotting.
  98.  
  99. After the ESC key, you are given the option of saving the screen.  Then
  100. you are given the option of doing another, of starting over (the only way
  101. to change the Fast, Slow option), or of quitting.
  102.  
  103. You should always terminate by the normal ESC key provision.  Otherwise
  104. the memory used by the program may not be released back to the system.
  105.  
  106. Enjoy!
  107.