b8

Unnamed repository; edit this file 'description' to name the repository.
git clone git://git.vgx.fr/b8
Log | Files | Refs

commit 664cfd2d39d367fbe5330c6c9d058b950641f5f3
parent 2c2770ea64e428a0f8c1f959e767a5009dffcd72
Author: Léo Villeveygoux <leo.villeveygoux@etu.u-bordeaux.fr>
Date:   Sun, 23 Jul 2017 20:08:18 +0200

draw.asm: add visual radius marker in palette mode

Diffstat:
Mdraw.asm | 45+++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 45 insertions(+), 0 deletions(-)

diff --git a/draw.asm b/draw.asm @@ -262,7 +262,52 @@ draw_palette: pop ecx loop .y_loop + + ; draw a point to show the radius + + mov edx, [coords] + push edx + + mov al, byte [selected] + push eax + + ; set point coords + mov dh, 7 + + mov dl, 7 + sub dl, al + sal dl, 5 + add dl, 8 + + mov [coords], edx + + ; set point color + + cmp al, 0 + jne .no_black + + mov al, 7 + jmp .store_selected + + .no_black: + + mov al, 0 + + .store_selected: + + mov byte [selected], al + + ; draw point + + call draw_point + + pop eax + mov byte [selected], al + + pop edx + mov [coords], edx + ret swap_palette_buffer: