home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Archive Magazine 1996
/
ARCHIVE_96.iso
/
discs
/
mag_discs
/
volume_8
/
issue_01
/
graphics
/
PRETTY
(
.txt
)
< prev
Wrap
RISC OS BBC BASIC V Source
|
1994-08-18
|
2KB
|
83 lines
>ColTest
" at line ";
"X480 Y352 C16M"
setcolour(0,0,0,0)
0,0,960,704
coloursquare
setcolour(r%,g%,b%,effect%)
colour%
%colour%=(b%<<24)+(g%<<16)+(r%<<8)
&40743,colour%,,,0,effect%
code% 1024
pass%=0
P%=code%
[OPT pass%
.screenbase
STMFD r13!,{r0-r1,r14}
ADR r0,input
ADR r1,output
SWI "OS_ReadVduVariables"
LDR r8,[r1]
LDR r9,[r1,#4]
MOV r0,#48
MUL r1,r8,r0
ADD r9,r9,r1
ADD r9,r9,#448
LDMFD r13!,{r0-r1,r15}
.input
EQUD 6
EQUD 149
EQUD -1
.output
EQUD 0
EQUD 0
EQUD 0
.setcolour
STMFD r13!,{r0-r4,r14}
MUL r3,r8,r1
ADD r3,r3,r9
ADD r3,r3,r0,LSL#2
12 MOV r0,r0 ; put the colour word into r0
R r0,r0,r1,LSL#8
R r0,r0,r2,LSL#16
STR r0,[r3]
LDMFD r13!,{r0-r4,r15}
.coloursquare
STMFD r13!,{r0-r9,r14}
BL screenbase
.bigloop
MOV r2,#255
.zloop1
MOV r1,#255
.yloop1
MOV r0,#255
.xloop1
BL setcolour
SUBS r0,r0,#1
BGE xloop1
SWI "OS_ReadEscapeState"
BCS end
SUBS r1,r1,#1
BGE yloop1
SUBS r2,r2,#4
BGE zloop1
MOV r2,#0
.zloop2
MOV r1,#255
.yloop2
MOV r0,#255
.xloop2
BL setcolour
SUBS r0,r0,#1
BGE xloop2
SWI "OS_ReadEscapeState"
BCS end
SUBS r1,r1,#1
BGE yloop2
ADD r2,r2,#4
CMP r2,#256
BLT zloop2
B bigloop
LDMFD r13!,{r0-r9,r15}
pass%