LZ: RE: A new graphics routine
[Prev][Next][Index][Thread]
LZ: RE: A new graphics routine
On Monday, June 30, 1997 1:39 PM, Nicholas C Anderson[SMTP:greenlazer@juno.com] wrote:
> In my program (Orion Masters) I want to have a very simple and very small
> straight line routine. In Qbasic it would be like this:
>
> For X=0 to 127
> Pset(X,Y) 'Pick any Y you need
> next X
Since the screen mapped to memory, you just need to do this:
ld HL, VIDEO_MEM + Y * 16
ld D, H
ld E, L
ld (HL), $FF ;(a byte with all 1's in binary)
ld BC, 16 - 1
inc DE
ldir
You could also do it with a DJNZ.... I'm not sure which one's faster or smaller... it depends on whether you're going for size or speed.
>
> Also I have a 85I file that I want to convert to the smallest possible
> Usgard size but I only need 2 smaller screen sections to put the entire
> screen together. I want to do it by having a simple binary code set
> (10010011 draws a dot skips 2 a dot skips 2 then 2 dots).
This is actually how an 85I file is stored... Maybe you should copy the two smaller screen sections seperately, then you could store each graphic seperately, and you would save some memory (just make sure you're not using more memory than you save to use the copy-graph routine twice ;)
Sam
--
Sam Davies <sdavies@mail.trilogy.net>