Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Fill Routine
#16
I'm also wondering which one is faster! Tongue
Except for the inc b/dec b (used to update pixel coords in BC for later use), which sub is faster?
e.g. Here is DRAW incY:
Notes: Line 292 (inc b) can be removed out, this is a DRAW requirement and can be done outside the sub
The routine sets Carry on F', to signal the ATTR position must be also updated.
Code:
288     ;; Given an HL screen position, calculates
289     ;; the above position
290     ;; Also updates BC coords
291 __INCY:
292     inc b
293     ld a, h
294     dec h
295     and 7
296     ret nz
297     ex af, af'  ; Sets carry on F'
298     scf         ; which flags ATTR must be updated
299     ex af, af'
300     ld a, 8
301     add a, h
302     ld h, a
303     ld a, l
304     sub 32
305     ld l, a
306     ret nc
307     ld a, h
308     sub 8
309     ld h, a
310     ret
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 2 Guest(s)