Home » Personal collection » Commodore disks » disk50a2_progs1.d64 » raytrace

raytrace

This website contains an archive of files for the Acorn Electron, BBC Micro, Acorn Archimedes, Commodore 16 and Commodore 64 computers, which Dominic Ford has rescued from his private collection of floppy disks and cassettes.

Some of these files were originally commercial releases in the 1980s and 1990s, but they are now widely available online. I assume that copyright over them is no longer being asserted. If you own the copyright and would like files to be removed, please contact me.

Tape/disk: Home » Personal collection » Commodore disks » disk50a2_progs1.d64
Filename: raytrace
Read OK:
File size: 00DC bytes
Load address: 0801
Exec address: 0000
File contents
     5 PRINT"<clr>"
    10 X=0:Y=0:Z=0
    20 THETA=75:ALPHA=45
    30 X=X+COS(π*TH/180)*COS(π*AL/180)
    40 Y=Y+SIN(π*TH/180)*COS(π*AL/180)
    50 Z=Z+SIN(π*AL/180)*COS(π*TH/180)
    60 REMPRINTX;Y;Z
    62 POKE211,INT(Y+.5)
    63 POKE214,INT(X+.5):SYS58732
    64 PRINT"*"
    70 GOTO 30

�"�"
X�0:Y�0:Z�00THETA�75:ALPHA�45PX�X��(��TH�180)��(��AL�180)p(Y�Y��(��TH�180)��(��AL�180)�2Z�Z��(��AL�180)��(��TH�180)�<�PRINTX;Y;Z�>�211,�(Y�.5)�?�214,�(X�.5):�58732�@�"*"�F� 30
JHE@."."@ZHJ@x.0:y.0:z.0@0HT@theta.75:alpha.45@pH.@x.x..(..th.180)..(..al.180)@PH(@y.y..(..th.180)..(..al.180)@.H2@z.z..(..al.180)..(..th.180)@.H<@.printx;y;z@.H>@.211,.(y..5)@.H?@.214,.(x..5):.58732@.H@@."*"@.Hf@. 30@@@
00000000  0a 08 05 00 99 22 93 22  00 1a 08 0a 00 58 b2 30  |.....".".....X.0|
00000010  3a 59 b2 30 3a 5a b2 30  00 30 08 14 00 54 48 45  |:Y.0:Z.0.0...THE|
00000020  54 41 b2 37 35 3a 41 4c  50 48 41 b2 34 35 00 50  |TA.75:ALPHA.45.P|
00000030  08 1e 00 58 b2 58 aa be  28 ff ac 54 48 ad 31 38  |...X.X..(..TH.18|
00000040  30 29 ac be 28 ff ac 41  4c ad 31 38 30 29 00 70  |0)..(..AL.180).p|
00000050  08 28 00 59 b2 59 aa bf  28 ff ac 54 48 ad 31 38  |.(.Y.Y..(..TH.18|
00000060  30 29 ac be 28 ff ac 41  4c ad 31 38 30 29 00 90  |0)..(..AL.180)..|
00000070  08 32 00 5a b2 5a aa bf  28 ff ac 41 4c ad 31 38  |.2.Z.Z..(..AL.18|
00000080  30 29 ac be 28 ff ac 54  48 ad 31 38 30 29 00 a0  |0)..(..TH.180)..|
00000090  08 3c 00 8f 50 52 49 4e  54 58 3b 59 3b 5a 00 b1  |.<..PRINTX;Y;Z..|
000000a0  08 3e 00 97 32 31 31 2c  b5 28 59 aa 2e 35 29 00  |.>..211,.(Y..5).|
000000b0  c9 08 3f 00 97 32 31 34  2c b5 28 58 aa 2e 35 29  |..?..214,.(X..5)|
000000c0  3a 9e 35 38 37 33 32 00  d2 08 40 00 99 22 2a 22  |:.58732...@.."*"|
000000d0  00 db 08 46 00 89 20 33  30 00 00 00              |...F.. 30...|
000000dc