home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
DP Tool Club 18
/
CD_ASCQ_18_111294_W.iso
/
dos
/
prg
/
pas
/
gfxfx
/
raster.pas
< prev
next >
Wrap
Pascal/Delphi Source File
|
1994-04-21
|
4KB
|
132 lines
{$g+}
program raster;
{ First 'raster', Try Copper5 instead, by Bas van Gaalen, Holland, PD }
const
rgb : array[0..299] of longint = (
$00000000,$00000000,$00000000,$00010000,$00020000,
$00030000,$00040000,$00050000,$00060000,$00070000,
$00080000,$00090000,$000a0000,$000b0000,$000c0000,
$000d0000,$000e0000,$000f0000,$00100000,$00110000,
$00120000,$00130000,$00140000,$00150000,$00160000,
$00170000,$00180000,$00190000,$001a0000,$001b0000,
$001c0000,$001d0000,$001e0000,$001f0000,$00200000,
$00210000,$00220000,$00230000,$00240000,$00250000,
$00260000,$00270000,$00280000,$00290000,$002a0000,
$002b0000,$002c0000,$002d0000,$002e0000,$002f0000,
$00300000,$00310000,$00320000,$00330000,$00340000,
$00350000,$00360000,$00370000,$00380000,$00390000,
$003a0000,$003b0000,$003c0000,$003d0000,$003e0000,
$003f0000,$003f0100,$003e0200,$003d0300,$003c0400,
$003b0500,$003a0600,$00390700,$00380800,$00370900,
$00360a00,$00350b00,$00340c00,$00330d00,$00320e00,
$00310f00,$00301000,$002f1100,$002e1200,$002d1300,
$002c1400,$002b1500,$002a1600,$00291700,$00281800,
$00271900,$00261a00,$00251b00,$00241c00,$00231d00,
$00221e00,$00211f00,$00202000,$001f2100,$001e2200,
$001d2300,$001c2400,$001b2500,$001a2600,$00192700,
$00182800,$00172900,$00162a00,$00152b00,$00142c00,
$00132d00,$00122e00,$00112f00,$00103000,$000f3100,
$000e3200,$000d3300,$000c3400,$000b3500,$000a3600,
$00093700,$00083800,$00073900,$00063a00,$00053b00,
$00043c00,$00033d00,$00023e00,$00013f00,$00003f01,
$00003e02,$00003d03,$00003c04,$00003b05,$00003a06,
$00003907,$00003808,$00003709,$0000360a,$0000350b,
$0000340c,$0000330d,$0000320e,$0000310f,$00003010,
$00002f11,$00002e12,$00002d13,$00002c14,$00002b15,
$00002a16,$00002917,$00002818,$00002719,$0000261a,
$0000251b,$0000241c,$0000231d,$0000221e,$0000211f,
$00002020,$00001f21,$00001e22,$00001d23,$00001c24,
$00001b25,$00001a26,$00001927,$00001828,$00001729,
$0000162a,$0000152b,$0000142c,$0000132d,$0000122e,
$0000112f,$00001030,$00000f31,$00000e32,$00000d33,
$00000c34,$00000b35,$00000a36,$00000937,$00000838,
$00000739,$0000063a,$0000053b,$0000043c,$0000033d,
$0000023e,$0000013f,$0000003f,$0000003e,$0000003d,
$0000003c,$0000003b,$0000003a,$00000039,$00000038,
$00000037,$00000036,$00000035,$00000034,$00000033,
$00000032,$00000031,$00000030,$0000002f,$0000002e,
$0000002d,$0000002c,$0000002b,$0000002a,$00000029,
$00000028,$00000027,$00000026,$00000025,$00000024,
$00000023,$00000022,$00000021,$00000020,$0000001f,
$0000001e,$0000001d,$0000001c,$0000001b,$0000001a,
$00000019,$00000018,$00000017,$00000016,$00000015,
$00000014,$00000013,$00000012,$00000011,$00000010,
$0000000f,$0000000e,$0000000d,$0000000c,$0000000b,
$0000000a,$00000009,$00000008,$00000007,$00000006,
$00000005,$00000004,$00000003,$00000002,$00000001,
$00000000,$00000000,$00000000,$00000000,$00000000,
$00000000,$00000000,$00000000,$00000000,$00000000,
$00000000,$00000000,$00000000,$00000000,$00000000,
$00000000,$00000000,$00000000,$00000000,$00000000,
$00000000,$00000000,$00000000,$00000000,$00000000,
$00000000,$00000000,$00000000,$00000000,$00000000,
$00000000,$00000000,$00000000,$00000000,$00000000,
$00000000,$00000000,$00000000,$00000000,$00000000,
$00000000,$00000000,$00000000,$00000000,$00000000);
var
i : word;
begin
asm
cli
@l0:
mov dx,03dah
@l1:
in al,dx
test al,8
jnz @l1
@l2:
in al,dx
test al,8
jz @l2
mov cx,300
@l3:
mov dx,03c8h
xor al,al
out dx,al
inc dx
mov si,cx
shl si,2
mov al,byte ptr rgb[si]
out dx,al
inc si
mov al,byte ptr rgb[si]
out dx,al
push dx
mov dx,03dah
@l4:
in al,dx
test al,1
jnz @l4
@l5:
in al,dx
test al,1
jz @l5
pop dx
inc si
mov al,byte ptr rgb[si]
out dx,al
loop @l3
mov dx,03c8h
xor al,al
out dx,al
inc dx
out dx,al
out dx,al
out dx,al
mov dx,60h
in al,dx
cmp al,1
jne @l0
sti
end;
end.