Home » Personal collection » Commodore disks » disk50a2_progs1.d64 » 3d rotation
3d rotation
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: | 3d rotation |
Read OK: | ✔ |
File size: | 04B6 bytes |
Load address: | 0801 |
Exec address: | 0000 |
File contents
40 S=16:B=3:C=8:SM=1024:DI=5000 45 POKE53272,(PEEK(53272) AND 15) OR S 50 POKE56578,PEEK(56578) OR 3 55 POKE56576,(PEEK(56576) AND 252) ORB 60 BT=C*1024:H=INT(BT/256):L=BT-256*H 65 POKE51,L:POKE52,H 70 POKE55,L:POKE56,H 75 POKE53272,(PEEK(53272) AND 241) ORC 80 POKE53265,PEEK(53265) OR 32 85 FOR J=SM TO SM+999 90 POKEJ,1 95 NEXT 100 FOR J=BT TO BT+7999 105 POKE J,0 110 NEXT 115 DIMP(50,4):READN:FORD=0TON-1:READP(D,0),P(D,1),P(D,2) 120 P(D,3)=150-(P(D,0)*2500/(DI-P(D,2)))/6 122 P(D,4)=100-(P(D,1)*2500/(DI-P(D,2)))/6:NEXT 125 READN:IFN<>-1 THEN PRINT"INCORRECT NO OF POINTS":GOTO180 130 READN:FORD=0TON-1:READPA,PB:X1=P(PA-1,3):X2=P(PB-1,3):Y1=P(PA-1,4) 140 Y2=P(PB-1,4):GOSUB1020:NEXT 150 GOTO150 175 GETK$:IFK$<>" "THEN175 180 POKE53265,PEEK(53265) AND 223 185 POKE53272,(PEEK(53272) AND 240) OR4 190 STOP 1000 BYTE=BT+7687-320*INT(Y/8)-(YAND7)+INT(X/8)*8 1005 BIT=7-(XAND7) 1010 POKE BYTE,PEEK(BYTE) OR 2^BIT 1015 RETURN 1020 IF X1<>X2 THEN M=(Y2-Y1)/(X2-X1):C=Y1-M*X1 1030 IF ABS(X2-X1)<ABS(Y2-Y1)THEN1100 1040 IF X1=X2 THEN RETURN 1050 FORX=X1 TO X2 STEP 2*SGN(X2-X1) 1060 Y=M*X+C 1070 GOSUB1000 1080 NEXT:X1=X2:Y1=Y2 1090 RETURN 1100 FORY=Y1 TO Y2 STEP SGN(Y2-Y1) 1110 X=X1:IF X1<>X2 THEN X=(Y-C)/M 1120 GOSUB1000 1130 NEXT:X1=X2:Y1=Y2 1140 RETURN 1150 DATA 8,-500,500,500,500,500,500,500,-500,500,-500,-500,500 1160 DATA -500,500,-500,500,500,-500,500,-500,-500,-500,-500,-500,-1 1170 DATA 12,1,2,2,3,3,4,4,1,1,5,2,6,3,7,4,8,5,6,6,7,7,8,8,5
"( S�16:B�3:C�8:SM�1024:DI�5000 A- �53272,(�(53272) � 15) � S Y2 �56578,�(56578) � 3 x7 �56576,(�(56576) � 252) �B �<