home *** CD-ROM | disk | FTP | other *** search
AMOS Source Code | 1994-01-01 | 21.4 KB | 793 lines |
- On Error Goto HANDLE
- THE_START:
- Change Mouse 4
- Screen Open 0,320,256,2,Lowres : Curs Off
- Locate 0,0
- Screen Open 2,704,310,8,Hires : Curs Off
- Screen Display 2,112,40,,
- Palette $0,$0,$0
- Cls 0
- Y#=256.0
- X#=320.0
- _MODE=$0
- MAG#=100
- XMIN#=-2.25
- XMAX#=0.75
- YMIN#=-1.5
- YMAX#=1.5
- SCRX#=320.0
- SCRY#=256.0
- _MODE=0
- DEPTH=32
- LDED=False
- If LDED=True
- Screen 2
- Ink 0,, : Bar 0,200 To 704,256
- Locate 0,29 : Centre "Graphics Loaded Into Work Areas"
- End If
- If LDED=False
- Screen 2
- Ink 0,, : Bar 0,200 To 704,256
- Locate 0,29 : Centre "No Graphics Loaded Into Work Areas"
- End If
- K=31
- Global SCRX#,SCRY#,XMIN#,YMIN#,XMAX#,YMAX#,Y#,X#,MAG#,K,_MODE,SCX#,SCY#,DEPTH,LDED
- Colour Back 0
- MEN
- Limit Mouse
- Do
- Loop
- Procedure CALCULATE
- KOLOURS=K+1
- SCX#=SCRX#
- SCY#=SCRY#
- XS#=X#
- YS#=Y#
- Screen Open 0,SCRX#,SCRY#,K+1,_MODE : Curs Off : Flash Off
- Cls 0
- Screen Open 3,704,24,2,Hires : Curs Off
- Screen Display 3,112,275,,
- Cls 0 : Palette $0,$FFF
- TMP$="X min:"+Str$(XMIN#)+", X max:"+Str$(XMAX#)
- TMP$=TMP$+", Y min:"+Str$(YMIN#)+", Y max:"+Str$(YMAX#)+", "+Str$(K+1)+" Colours"
- Centre TMP$ : Print
- TMP$="Re-Iteration Level:"+Str$(MAG#)
- Centre TMP$ : Print
- TMP$="Screen Size:"
- TMP$=TMP$+Str$(SCRX#)+" x "+Str$(SCRY#)
- If DEPTH=500
- TMP$=TMP$+" Deep Scanning Mode Enabled"
- End If
- Centre TMP$
- Screen 0
- Hide : Menu Off
- Y#=SCRY# : X#=SCRX#
- H#=(XMAX#-XMIN#)/(SCRX#-1)
- V#=(YMAX#-YMIN#)/(SCRY#-1)
- LDED=True
- For Q#=0.0 To SCRY#
- For P#=0.0 To SCRX#
- M#=XMIN#+P#*H#
- N#=YMIN#+Q#*V#
- C=0 : X#=0 : Y#=0
- STP2:
- W#=X#*X# : Y2#=Y#*Y# : R#=W#+Y2#
- Y#=2*X#*Y#+N#
- X#=W#-Y2#+M#
- Inc C
- If R#<MAG# and C<DEPTH-1
- Goto STP2
- End If
- XU=P# : YU=Q#
- C=C and K
- Ink C : Plot XU,YU
- Bchg %1,$BFE001
- If Mouse Key
- Screen Open 4,640,20,2,Hires : Curs Off : Palette $0,$FFF
- Screen Display 4,132,200,,
- Input "Are You You Sure You Want To Abort ";AB$
- If AB$="y"
- Q#=SCRY#+1.0
- P#=SCRX#+1.0
- LDED=False
- End If
- Screen Close 4
- Screen 0
- End If
- Next P#
- Next Q#
- Menu On
- If LDED=True
- Screen 2
- Ink 0,, : Bar 0,200 To 704,256
- Locate 0,29 : Centre "Graphics Loaded Into Work Areas"
- End If
- If LDED=False
- Screen 2
- Ink 0,, : Bar 0,200 To 704,256
- Locate 0,29 : Centre "No Graphics Loaded Into Work Areas"
- End If
- Screen To Front 2 : Screen 2
- On Menu On
- Show
- SCRX#=SCX#
- SCRY#=SCY#
- Y#=YS#
- X#=XS#
- End Proc
- Procedure CALCULATEMINIBROT
- KOLOURS=K+1
- SCX#=SCRX#
- SCY#=SCRY#
- XS#=X#
- YS#=Y#
- Screen Open 0,SCRX#,SCRY#,KOLOURS,_MODE : Curs Off : Flash Off
- ACROSS=(SCRX#/2)-50
- Cls 0
- Screen Open 3,704,30,2,Hires : Curs Off
- Screen Display 3,112,275,,
- Cls 0 : Palette $0,$FFF
- TMP$="X min:"+Str$(XMIN#)+", X max:"+Str$(XMAX#)
- TMP$=TMP$+", Y min:"+Str$(YMIN#)+", Y max:"+Str$(YMAX#)+", "+Str$(K+1)+" Colours"
- Centre TMP$ : Print
- TMP$="Re-Iteration Level:"+Str$(MAG#)
- Centre TMP$ : Print
- TMP$="Preview Screen ( 50 x 50 )"
- If DEPTH=500
- TMP$=TMP$+" Deep Scanning Mode Enabled"
- End If
- Centre TMP$
- Screen 0
- Hide : Menu Off
- Y#=SCRY# : X#=SCRX#
- H#=(XMAX#-XMIN#)/(49.0)
- V#=(YMAX#-YMIN#)/(49.0)
- LDED=True
- For Q#=0.0 To 50.0
- For P#=0.0 To 50.0
- M#=XMIN#+P#*H#
- N#=YMIN#+Q#*V#
- C=0 : X#=0 : Y#=0
- LABEL2:
- W#=X#*X# : Y2#=Y#*Y# : R#=W#+Y2#
- Y#=2*X#*Y#+N#
- X#=W#-Y2#+M#
- Inc C
- If R#<MAG# and C<DEPTH-1
- Goto LABEL2
- End If
- XU=P# : YU=Q#
- C=C and K
- Ink C : Plot ACROSS+XU,120+YU
- Bchg %1,$BFE001
- If Mouse Key
- Screen Open 4,640,20,2,Hires : Curs Off : Palette $0,$FFF
- Screen Display 4,132,200,,
- Input "Are You You Sure You Want To Abort ";AB$
- If AB$="y"
- LDED=False
- Q#=SCRY#+1.0
- P#=SCRX#+1.0
- End If
- Screen Close 4
- Screen 0
- End If
- Next P#
- Next Q#
- Menu On
- On Menu On
- Show
- Screen To Front 2
- Screen 2
- SCRX#=SCX#
- SCRY#=SCY#
- Y#=YS#
- X#=XS#
- If LDED=True
- Screen 2
- Ink 0,, : Bar 0,200 To 704,256
- Locate 0,29 : Centre "Graphics Loaded Into Work Areas"
- End If
- If LDED=False
- Screen 2
- Ink 0,, : Bar 0,200 To 704,256
- Locate 0,29 : Centre "No Graphics Loaded Into Work Areas"
- End If
- End Proc
- Procedure SETCOORDS
- If Choice(2)=1
- Screen Open 1,640,24,2,Hires : Cls 0
- Screen Display 1,132,55,,
- Palette $0,$999
- Input "Enter Minimum X Value: ";XMIN#
- Screen Close 1
- End If
- If Choice(2)=2
- Screen Open 1,640,24,2,Hires : Cls 0
- Screen Display 1,132,55,,
- Palette $0,$999
- Input "Enter Maximum X Value: ";XMAX#
- Screen Close 1
- End If
- If Choice(2)=3
- Screen Open 1,640,24,2,Hires : Cls 0
- Screen Display 1,132,55,,
- Palette $0,$999
- Input "Enter Minimum Y Value: ";YMIN#
- Screen Close 1
- End If
- If Choice(2)=4
- Screen Open 1,640,24,2,Hires : Cls 0
- Screen Display 1,132,55,,
- Palette $0,$999
- Input "Enter Maximum Y Value: ";YMAX#
- Screen Close 1
- End If
- If Choice(2)=5
- Screen Open 1,640,24,2,Hires : Cls 0
- Screen Display 1,132,55,,
- Palette $0,$999
- Input "Enter Re-Iteration Value: ";MAG#
- Screen Close 1
- End If
- If Choice(2)=6
- Screen Open 1,640,150,2,Hires : Cls 0
- Screen Display 1,132,55,,
- Palette $0,$999
- Input "Enter Re-Iteration Value: ";MAG#
- Input "Enter Minimum X Value: ";XMIN#
- Input "Enter Maximum X Value: ";XMAX#
- Input "Enter Minimum Y Value: ";YMIN#
- Input "Enter Maximum Y Value: ";YMAX#
- Screen Close 1
- End If
- If Choice(3)=1
- Bell
- SCRX#=320.0 : SCRY#=256.0
- _MODE=0
- K=31
- End If
- If Choice(3)=2
- Bell
- SCRX#=640.0 : SCRY#=256.0
- _MODE=$8000
- K=15
- End If
- If Choice(3)=3
- Bell
- SCRX#=352.0 : SCRY#=256.0
- _MODE=0
- K=31
- End If
- If Choice(3)=4
- Bell
- SCRX#=704.0 : SCRY#=256.0
- _MODE=$8000
- K=15
- End If
- If Choice(3)=5
- Bell
- SCRX#=320.0 : SCRY#=256.0
- _MODE=0
- K=15
- End If
- If Choice(3)=6
- Bell
- SCRX#=352.0 : SCRY#=256.0
- _MODE=0
- K=15
- End If
- Menu On
- On Menu On
- End Proc
- Procedure SETCOLS
- Bell
- If Choice(2)=1
- Screen 0
- Palette $0,$100,$300,$500,$700,$900,$A00,$C00,$E00,$F00,$F11,$F33,$F55,$F77,$F99,$FBB,$FDD,$FFF,$300,$500,$700,$900,$A00,$C00,$E00,$F00,$F11,$F33,$F55,$F77,$F99
- End If
- If Choice(2)=2
- Bell
- Screen 0
- Palette $0,$10,$30,$50,$70,$90,$A0,$C0,$E0,$F0,$1F1,$3F3,$5F5,$7F7,$9F9,$BFB,$DFD,$FFF,$0,$10,$30,$50,$70,$90,$A0,$C0,$E0,$F0,$1F1,$3F3,$5F5
- End If
- If Choice(2)=3
- Bell
- Screen 0
- Palette $0,$1,3,5,7,9,$A,$C,$E,$F,$11F,$33F,$55F,$77F,$99F,$BBF,$DDF,$EEF,$0,$1,3,5,7,9,$A,$C,$E,$F,$11F,$33F,$55F
- End If
- If Choice(2)=4
- Bell
- Screen 0
- Palette $0,$111,$333,$555,$777,$999,$BBB,$DDD,$FFF,$222,$444,$666,$888,$AAA,$CCC,$EEE,$0,$111,$333,$555,$777,$999,$BBB,$DDD,$FFF,$222,$444,$666,$888,$AAA,$CCC
- End If
- If Choice(2)=5
- Bell
- Screen 0
- For A=0 To 30 Step 2
- Colour A,0 : Colour A+1,$FFF
- Next
- End If
- If Choice(2)=6
- Bell
- Screen 0
- Palette $0,2,4,6,9,$B,$D,$F,$FFF,$DDF,$BBF,$99F,$67F,$45F,$22F,$F,$200,$400,$600,$800,$900,$B00,$D00,$F00,$F20,$F40,$F60,$F70,$F90,$FB0,$FD0,$FF0
- End If
- If Choice(2)=7
- Bell
- Screen 0
- Palette $0,$FF0,$FC0,$FA0,$F70,$F50,$F20,$0,$FFF,$BDB,$8B8,$595,$373,$151,$30,$10,$100,$300,$511,$733,$955,$B88,$DBB,$FFF,$FFF,$BBD,$88B,$559,$337,$115,$3
- End If
- If Choice(2)=8
- Bell
- Screen 0
- Palette $0,$200,$410,$620,$830,$950,$B80,$DB0,$FF0,$DB0,$B80,$950,$830,$620,$410,$200,$400,$510,$720,$840,$A50,$C70,$DA0,$FD0,$DA0,$C70,$A50,$840,$720,$510,$400,$200
- End If
- If Choice(2)=9
- Bell
- Screen 0
- If K+1=32
- If CFLAG=True
- Colour 31,$FFF
- CFLAG=False
- Goto OOT
- End If
- If CFLAG=False
- Colour 31,$0
- CFLAG=True
- Goto OOT
- End If
- End If
- End If
- If K+1=16
- If CFLAG=True
- Colour 15,$FFF
- CFLAG=False
- Goto OOT
- End If
- If CFLAG=False
- Colour 15,$0
- CFLAG=True
- Goto OOT
- End If
- End If
- OOT:
- Screen To Front 2 : Screen 2
- Menu On
- On Menu On
- End Proc
- Procedure QUIT
- If Choice(2)=1
- Screen Hide 0
- Ink 0,, : Bar 0,200 To 704,256
- Screen Open 1,704,256,4,Hires : Flash Off : Curs Off : Cls 0
- Palette $0,$0,$8E : Hide
- Screen Display 1,112,-100,,
- Screen 1
- Locate 0,0
- Centre "From Scientific Order To Dynamic Chaos."
- Print : Centre " "
- Print : Centre "An Experiment In MandelBrots And Fractal Geometry"
- Print : Centre " "
- Print : Centre "Coded By G.Shilvock & M.Norman (c) 1991"
- Print : Print : Centre "NOTE: The Info Screen WILL NOT affect The Main Screen "
- Print : Centre "The Data will be Plotted Beneath It."
- Print : Print : Centre "- 512k Version -" : Print
- Print : Print : Centre "Press Mouse Button To Continue."
- For A=40 To 0 Step -1
- Screen Display 2,112,A,,
- Wait Vbl
- Next
- For A=-100 To 100 Step 3
- Screen Display 1,112,A,,
- Wait Vbl
- Next
- Fade 1 : Wait 15
- Fade 1,$0,$0,$8E : Wait 15
- Repeat
- Until Mouse Key
- Fade 1 : Wait 15
- Screen Close 1
- For A=0 To 40
- Screen Display 2,112,A,,
- Wait Vbl
- Next
- Screen To Front 2 : Screen 2
- Show
- If LDED=True
- Screen 2
- Ink 0,, : Bar 0,200 To 704,256
- Locate 0,29 : Centre "Graphics Loaded Into Work Areas"
- End If
- If LDED=False
- Screen 2
- Ink 0,, : Bar 0,200 To 704,256
- Locate 0,29 : Centre "No Graphics Loaded Into Work Areas"
- End If
- End If
- If Choice(2)=2
- Dir$="df0:"
- Rem shut down system areas
- CLI
- End
- End If
- If Choice(2)=3
- NAME$=Fsel$("Df0:","","Save IFF File.")
- If NAME$=""
- Goto ABORT
- End If
- Screen 2 :
- Ink 0,, : Bar 0,200 To 704,256
- Locate 0,29 : Centre "Saving Data As IFF File."
- Screen To Front 0
- Screen 0
- Change Mouse 6
- Save Iff NAME$,0
- Change Mouse 4
- If LDED=True
- Screen 2
- Ink 0,, : Bar 0,200 To 704,256
- Locate 0,29 : Centre "Graphics Loaded Into Work Areas"
- End If
- If LDED=False
- Screen 2
- Ink 0,, : Bar 0,200 To 704,256
- Locate 0,29 : Centre "No Graphics Loaded Into Work Areas"
- End If
- Screen To Front 2 : Screen 2
- End If
- If Choice(2)=4
- A$="Df0:Iff"
- B$="Df1:Iff"
- C$="Df0:Lo-res"
- D$="Df1:Lo-res"
- Dir$="df0:"
- If Exist(A$)
- Dir$=A$
- End If
- If Exist(B$)
- Dir$=B$ : Rem check for the existance
- End If
- If Exist(C$)
- Dir$=C$ : Rem of possible IFF directories
- End If
- If Exist(D$)
- Dir$=D$
- End If
- NAME$=Fsel$("","","Load IFF File.")
- If NAME$=""
- Goto ABORT
- End If
- Screen 2
- Ink 0,, : Bar 0,200 To 704,256
- Locate 0,29 : Centre "Loading Data As IFF File."
- Change Mouse 6
- Load Iff NAME$,0
- Change Mouse 4
- Screen To Front 0
- LDED=True
- If LDED=True
- Screen 2
- Ink 0,, : Bar 0,200 To 704,256
- Locate 0,29 : Centre "Graphics Loaded Into Work Areas"
- End If
- If LDED=False
- Screen 2
- Ink 0,, : Bar 0,200 To 704,256
- Locate 0,29 : Centre "No Graphics Loaded Into Work Areas"
- End If
- PASS=False
- Hide
- Repeat
- If Mouse Key
- PASS=True
- End If
- WHICHKEY$=Inkey$
- If WHICHKEY$<>""
- PASS=True
- End If
- Until PASS=True
- Show
- End If
- If Choice(2)=5
- HELP
- End If
- ABORT:
- Screen Show 0
- Screen To Front 2
- Screen 2
- Menu On
- On Menu On
- End Proc
- Procedure MEN
- Locate 0,0 : Ink 2 : Set Text 6 : Text 0,8," MandelBrot Generator V1.85 (c) 1991 G.Shilvock/M.Norman. "
- Set Text 0
- Menu$(1)=" Misc"
- Menu$(1,1)=" About."
- Menu$(1,2)=" Quit. "
- Menu$(1,3)=" Save IFF File. "
- Menu$(1,4)=" Load IFF File. "
- Menu$(1,5)=" Instructions. "
- Menu$(2)=" Variables"
- Menu$(2,1)=" Set X Min. "
- Menu$(2,2)=" Set X Max. "
- Menu$(2,3)=" Set Y Min. "
- Menu$(2,4)=" Set Y Max. "
- Menu$(2,5)=" Set Re-Iteration Level."
- Menu$(2,6)=" Set All Values. "
- Menu$(2,7)=" Set Resolution. "
- Menu$(2,7,1)=" 320 x 256 Low Res "
- Menu$(2,7,2)=" 640 x 256 High Res "
- Menu$(2,7,3)=" 352 x 256 Low Res Overscan "
- Menu$(2,7,4)=" 704 x 256 High Res Overscan"
- Menu$(2,7,5)=" 320 x 256 Low res 16 Cols. "
- Menu$(2,7,6)=" 352 x 256 Low res 16 Cols. "
- Menu$(3)=" Palettes "
- Menu$(3,1)=" Red "
- Menu$(3,2)=" Green "
- Menu$(3,3)=" Blue "
- Menu$(3,4)=" Grey "
- Menu$(3,5)=" MonoChrome "
- Menu$(3,6)=" MultiColour 1 "
- Menu$(3,7)=" MultiColour 2 "
- Menu$(3,8)=" Brown "
- Menu$(3,9)=" Invert Centre "
- Menu$(4)=" Calculate "
- Menu$(4,1)=" Full Screen MandelBrot. "
- Menu$(4,2)=" 50 x 50 Preview. "
- Menu$(5)=" Scan Depth "
- Menu$(5,1)=" Low "
- Menu$(5,2)=" Deep "
- Menu$(6)=" Examples "
- Menu$(6,1)=" Example I "
- Menu$(6,2)=" Example II "
- Menu$(6,3)=" Example III "
- Menu$(6,4)=" Example IV "
- Menu$(6,5)=" Example V"
- Menu$(7)=" Display "
- Menu$(7,1)=" View Current "
- On Menu Proc QUIT,SETCOORDS,SETCOLS,CALC,DEEP,EXAMPS,CURRENT
- Menu On
- On Menu On
- Screen To Front 2 : Screen 2
- Fade 2,$0,$357,$FFF
- End Proc
- Procedure CURRENT
- Hide
- Screen To Front 0 : View
- Repeat
- Until Mouse Key
- Show
- Screen To Front 2
- Menu On
- On Menu On
- End Proc
- Procedure HELP
- Ink 0,, : Bar 0,200 To 704,256
- For A=40 To 0 Step -1
- Screen Display 2,112,A,,
- Wait Vbl
- Next
- Fade 1,$357,$FFF,$FFF,$FFF : Wait 15
- Screen Close 0
- Screen Close 2
- Screen Open 1,640,256,2,Hires : Curs Off : Flash Off : Hide
- Palette $357,$FFF,$0
- Locate 0,0
- Centre "Instructions For MandelBrot Generator"
- Print
- Centre "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~"
- Print : Print "This Program was developed using the following books:"
- Print "Our many thanks to the authors for providing "
- Print "us with invaluable background information."
- Print : Print "'The Beauty Of Fractals.' By H.O.Peitgen & P.H. Richter."
- Print "(ISBN 3-540-15851-0) "
- Print "and 'Fractals.' By Jens Feder. (ISBN 0-306-42851-2)"
- Print : Print "This program was coded using AMOS Basic (c) 1990 Mandarin Jawx."
- Print "Thanks to Francois Lionet & Mandarin"
- Print : Print "The menu options on the first menu are all self-explanatary, "
- Print "so those will be skipped." : Print
- PAWS
- Print
- Print "The Variables Menu"
- Print "~~~~~~~~~~~~~~~~~~"
- Print "Xmin, Xmax, Ymin, Ymax determine where the 'window' over the MandelBrot"
- Print "will be placed (i.e. Which part of the MandelBrot you will see),"
- Print "And Are Grid Co-Ordinates relative to 0"
- Print "Examples"
- Print "~~~~~~~~"
- Print "Xmin Xmax Ymin Ymax"
- Print "-2.25 0.75 -1.5 1.5"
- Print "-0.19920 -0.12954 1.01480 1.06707"
- Print "-0.713 -0.4082 0.49216 0.71429"
- Print "-1.781 -1.764 0.0 0.013"
- Print : Print : Print
- PAWS : Print : Print
- Print "As you can see, all the values are quite close to zero, otherwise"
- Print "the MandelBrot doesn't vary much. The time it takes to compute a full "
- Print "MandelBrot increases with the depth, therefore a basic MandelBrot could take"
- Print "say, 10 Minutes to compute, whereas a MandelBrot computed at very deep levels"
- Print "will be infinitly more complex and beautiful (Brot7.Iff in the "
- Print "IFF Folder on this disk took nearly 16 hours to compute.(Un-compiled version))"
- Print "The Re-Iteration Value is used as a trigger so that a recursive loop"
- Print "doesn't occur. A value of 100 is recommened.)"
- Print "The screen resolution can also be changed, But be warned:- "
- Print "The higher resolutions take quite a while to produce."
- Print "(A HAM Mode Was Originly Included, But Computing time was much to great"
- Print "to justify the end result.)"
- Print "The 'Set All Values' is simply a shortcut from choosing individual menu options "
- Print "if you want to enter a complete set of new data."
- Print "The Palettes Option is used after a MandelBrot has been computed."
- Print "The Invert Centre option is purely cosmetic and is used to "
- Print "invert the middle of the MandelBrot. (some look good with white centres,"
- Print ".....some don't.)"
- Print : Print : Print : Print
- PAWS
- Print
- Print "Calculate!"
- Print "~~~~~~~~~~"
- Print "The Calculate option is used to compute a full screen MandelBrot,"
- Print : Print "Use the Preview option to create a smaller version of the"
- Print "MandelBrot ( 50 pixels x 50 pixels.....a wait of 1 - 2 minutes at most )"
- Print "This is to save you having to wait 5 Hours to find you have"
- Print "created a totally black screen."
- Print "If You Choose 'Calculate' or 'Preview' once the program is loaded."
- Print "A Full MandelBrot will be drawn using some pre-sets I have"
- Print "already entered."
- Print "Once a MandelBrot has been drawn the Program returns to the menu."
- Print "Choose 'View Current' to see the MandelBrot (Mouse Key returns to menu)"
- Print "Depth"
- Print "~~~~~"
- Print "This is a little more complex, because this is how 'detailed' the MandelBrot"
- Print "will be. A 'LOW' setting is faster, but useless at deeper levels, whereas 'DEEP'"
- Print "is very slow but very accurate."
- Print "Try The Co-ordinates on a 'LOW' setting first, and if you get a blank screen,"
- Print "abort the MandelBrot and change to 'DEEP'"
- Print : Print "To use the examples, choose the one you want from the menu, and choose"
- Print "a 'Calcuate' option...(Depth etc are all pre-set.)"
- Print : Print : Print : Print : PAWS : Print
- Print "Fine Tuning (Only Available on 1 Meg version.)"
- Print "~~~~~~~~~~~"
- Print "Backup - Takes a copy of the current image and copies it to another area"
- Print "Restore - Copies a previously saved image to the current image"
- Print "Zero Area - Does the equivalent of a 'Fill' in colour 0 to"
- Print "black out areas of the MandelBrot."
- Print "The Left button will zero an area, The Right button to finish."
- Print : Print : Print : Print
- PAWS
- DUN:
- Fade 1 : Wait 45
- Screen Close 1
- Screen Open 0,320,256,2,Lowres : Curs Off : Cls 0
- Locate 0,0
- Screen Open 2,704,310,8,Hires : Curs Off : Cls 0
- Screen Display 2,112,40,,
- Locate 0,0 : Ink 2 : Set Text 6 : Text 0,8," MandelBrot Generator V1.85 (c) 1991 G.Shilvock/M.Norman. "
- Set Text 0
- Palette $0,$0,$0
- Screen Show 0
- Menu On
- On Menu On
- Fade 1,0,$357,$FFF
- For A=0 To 40
- Screen Display 2,112,A,,
- Wait Vbl
- Next
- Screen To Front 2 : Screen 2
- Show
- If LDED=True
- Screen 2
- Ink 0,, : Bar 0,200 To 704,256
- Locate 0,29 : Centre "Graphics Loaded Into Work Areas"
- End If
- If LDED=False
- Screen 2
- Ink 0,, : Bar 0,200 To 704,256
- Locate 0,29 : Centre "No Graphics Loaded Into Work Areas"
- End If
- End Proc
- Procedure CALC
- If Choice(2)=1
- CALCULATE
- End If
- If Choice(2)=2
- CALCULATEMINIBROT
- End If
- Screen To Front 2
- Menu On
- On Menu On
- End Proc
- Procedure DEEP
- If Choice(2)=1
- Bell
- DEPTH=32
- End If
- If Choice(2)=2
- Bell
- DEPTH=500
- End If
- Menu On
- On Menu On
- Screen To Front 2 : Screen 2
- End Proc
- Procedure EXAMPS
- If Choice(2)=1
- XMIN#=-1.25402
- XMAX#=-1.25286
- YMIN#=0.046251
- YMAX#=0.047125
- DEPTH=500
- Bell
- End If
- If Choice(2)=2
- XMIN#=-2.25
- XMAX#=0.75
- YMIN#=-1.5
- YMAX#=1.5
- DEPTH=32
- Bell
- End If
- If Choice(2)=3
- XMIN#=-0.746541
- XMAX#=-0.746378
- YMIN#=0.107574
- YMAX#=0.107678
- DEPTH=32
- Bell
- End If
- If Choice(2)=4
- XMIN#=-0.1992
- XMAX#=-0.4082
- YMIN#=0.49216
- YMAX#=0.71429
- DEPTH=500
- Bell
- End If
- If Choice(2)=5
- XMIN#=-1.781
- XMAX#=-1.764
- YMIN#=0.0
- YMAX#=0.013
- DEPTH=500
- Bell
- End If
- Menu On
- On Menu On
- Screen To Front 2 : Screen 2
- End Proc
- Procedure CLI
- Bell
- Rem shut down system areas
- Screen Close 0
- Screen 2 : Fade 2 : Wait 45
- Screen Close 2
- End Proc
- Procedure ABORT
- Bell
- Rem shut down system areas
- Screen Close 0
- End
- End Proc
- Procedure PAWS
- Locate 0,29 : Centre "Press Any Key To Continue."
- Wait Key
- Cls 0
- End Proc
- '
- '
- '
- '
- '
- '
- HANDLE:
- Boom
- Screen Open 4,640,16,2,Hires : Palette $0,$0 : Cls 0 : Curs Off
- Screen Display 4,132,200,,
- Locate 0,0
- Centre "Error! Command Ignored."
- Fade 1,$0,$FAC
- Wait 200 : Fade 1 : Wait 45 : Screen Close 4
- '
- ' This is where structured programming goes out the window!
- '
- Goto THE_START