tobe wrote:Blitter can be slower with small copies because you need to load its registers. So don't forget some registers doesn't need to be reloaded each time. For example, the word count ($FFFF8A36) is reset to the original value after each line, so at the end of the copy operation its value is the same than before the op. You can store your source bitplans splitted, and use the source/destination increments so you don't need to reload the source and destination registers for each bitplan, etc...
you right
Actually, to do blitting you need to reload only two registers "Y COUNT" and $FFFF8A3D, e.g.:
prefill blitters registers:
Code: Select all
lea halftone,a0
lea $ffff8a00.w,a1
move.l (a0)+,(a1)+
move.l (a0)+,(a1)+
move.l (a0)+,(a1)+
move.l (a0)+,(a1)+
move.l (a0)+,(a1)+
move.l (a0)+,(a1)+
move.l (a0)+,(a1)+
move.l (a0)+,(a1)+
clr.l (a1)+
move.l #kolory,(a1)+
move.l #$ffffffff,(a1)+
move.w #$ffff,(a1)+
clr.l (a1)+
move.l #$ffff8240,(a1)+
move.w #$1,(a1)+
move.w #$1,(a1)+
move.b #$1,(a1)+
move.b #$3,(a1)+
move.b #$0,(a1)+
move.w #128*50,d0
move.w #$c0,d1
lea $ffff8a38.w,a0
lea $ffff8a3c.w,a1
halftone
dc.w $0f00, $00f0, $000f, $0ff0, $0f0f, $00ff, $0c00, $00c0
dc.w $000c, $0cc0, $0c0c, $00cc, $0fff, $0555, $0aaa, $0000
kolory
dc.w $000f, $0007, $000e, $0006, $000d, $0005, $000d, $0004
dc.w $000c, $0003, $000b, $0002, $000a, $0001, $0008, $0000
do blitting:
do blitting again:
and again:
As we can see, biggest part is prefilling register, but you do not need touch all of it., e.g. you can leave halftone. And do blitting (many times as you need) takes two instuctions.
Then you need only 16 cycles per start blitting.