home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Loadstar 128 28
/
q28.d81
/
t.cosmo
< prev
next >
Wrap
Text File
|
2022-08-28
|
6KB
|
123 lines
C O S M O
Program and Text by Tim George
I like to call COSMO a Galaxy Generator, but my friend Denny (ever the
minimalist) told me; "it looks like a doily maker". How about Crystal
Widget machine? Like most things, COSMO is whatever you want it to be.
COSMO is one of what I call math-graphics type software: programs that
run for many iterations through a loop of mathematic algorithms and plot
the results graphically to the screen. Fractal and landscape software are
the two most common types, but there are many different kinds, even some
that plot their results using audio.
The math in COSMO that does all the work is ridiculously simple but the
results are amazing. Very similar in look to Affine Transforms on LS #93
to watch forming. There is a surprising amount of variety between the
different patterns it can come up with. I found I got the best results by
turning my monitor's contrast all the way up and the brightness down just
below halfway.
Sometimes it will make a small pattern that stays in the middle of the
screen. Let these run for a while because when they finally expand they
are usually the most beautiful. Of course, some never do. Likewise,
although rare, sometimes a pattern will be so large the rows of dots shoot
off the screen and only draw around the edges. These can be the most
interesting if they come back (usually within 30 seconds). Again, though,
some go exponential and never return.
There isn't too much user control I could give in the loop. X/Y
scaling and color count both have a very narrow margin of settings before
the results turn useless. Even XOR has to be left on or the 8x2 color
cells become too obvious in the center of the screen and look ugly. The
following controls are available while COSMO is running.
R will redraw the same pattern, with the same pallette and reset the
timer if it's on.
T will activate the timer. The pattern will pause, the screen will
turn blue and you are in timer mode. Press 1-6 for the number of minutes a
pattern will draw before a new one begins. Any other key turns off the
timer. Setting the timer doesn't zero it out, so if you turn it on and
that amount of time has already passed, a new pattern will begin.
X will toggle the limit flag. The pattern will pause and the screen
will turn blue. Press X again to set the flag. Any other key will clear
it. When the flag is set, as soon as the X plot reaches 1200 in either
direction (well off the screen) a new pattern will begin. This has the
advantage of automatically drawing the next one, but unlike the timer, will
allow every pattern to finish filling the screen no matter how fast or slow
it does it. X and T are off when COSMO first starts and if neither are set
and no key is pressed the program will just keep looping until finally
(weeks?) the math would cause an overflow error.
P will turn the screen dark gray and pause the pattern. Any key will
continue. Pause does not stop the timer from counting but it will hold the
pattern if time runs out.
ESC will quit and return to LOADSTAR on any drive or exit to BASIC.
Any other key will start the next pattern. When a new pattern begins,
two 'seeds' are generated randomly. The numbers are (all approximate):
S1: any one of 100,000 numbers between 1 and 1.001
S2: any one of 100,000,000 numbers between -1.99 and -0.000008
The order of the colors in the pallette are also chosen at random. All
colors except black and dark gray are always used. Then the timer is
restarted.
COSMO 16K
---------
As written, COSMO requires 64K of VDC ram. Software Support
International (1-800-356-1179) still carries the 64K upgrade kit if you
have only 16K. If you have no interest in or need for it you can run
'cosmo 16k'. It's a stripped down but very similar monochrome version. It
has no color step or pallette and XOR is replaced by OR (there are no color
cells to show up).
All the keyboard controls above are the same with a new one, C. Each
time a new pattern begins a new single color, except black or dark gray, is
chosen at random for the whole screen. Pressing C will cycle through the
colors and back again, but every dot on the whole screen will turn the same
color. Hold down C for 'psychotic episode' mode.
Even if you have 64K check out COSMO 16K. It's not as spectacular, but
it's still interesting since the single color gives a very different 'feel'
to the look of the patterns.
I love writing these types of programs, and I hope you like it. If
you're just kicking around the house on a day off, set up your monitor in a
corner of the living room, put on your favorite Classical (or Zep), and
diverge.
TG
FENDER'S POSTMUMBLE: I like this program even more than Tim does. I've had
to ban myself from running it here at the Tower because I can't turn it off
and get any work done. I'll bet a lot of you out there get caught up in
the incredible beauty of its screens, too.
What IS the fascination of this kind of art? My theory is that there are
two kinds of people in the world: those that are more comfortable with
order, and those that are more comfortable with chaos. When it comes to
art, I guess I'm one of those "orderly" guys. I can walk through an art
gallery filled with pictures created by talented humans and get a mild
thrill, but when I see a picture painted by a dinky little formula, I'm
hooked -- especially when I can see the formula in action.
Both of the BASIC source codes are on the disk so if you want to experiment
by changing some of the parameters, feel free. For best results, after
changing the code and finding something you think is interesting, compile
the program for speed. We used Abacus' BASIC 128 Compiler but any compiler
should work.
\\\\\ RETURN - Menu \\\\\