-
Masks?
What is the best way to animate sprites... without using keyboard characters?!
My friend along time ago use to use a XOR mask... each character was stored in afile... that looekd like
0 0 1 0 0
0 1 0 1 0
0 1 0 1 0
0 0 1 0 0
where each 1 would be the color that was read, and inputed with PSET.
Anyone hird of this method?
-
You write them to a file, then read them into an array
Then you test each byte, if its a zero, dont draw it, else, pset it
-
Ohhh ya its all coming back to me, thank you!
..I just thought there was something elsem ore to it... hmmm... isent psetting the values every time a slow process?
-
What's really slow is testing it for zero, not pset
HOwever, u can speed things up further by using poke
'Example
DEF SEG = &HA000
FOR I& = 0 TO 65535
POKE I&,INT(RND*255)
NEXT
DEF SEG
This is still very slow, try using ASM codes
FYI, indeed u need to pset every bit, if u need to use MASK
Otherwise, you could just move them in blocks to the destination
You could use REP MOVSD in ASM codes to move them
quickly