From: uz Date: Tue, 17 Aug 2010 21:14:30 +0000 (+0000) Subject: Updated GEOS TGI driver by Maciej Witkowiak. X-Git-Tag: V2.13.3~636 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=1708ec318bedf25b923f3a08441d30c6c367be75;p=cc65 Updated GEOS TGI driver by Maciej Witkowiak. git-svn-id: svn://svn.cc65.org/cc65/trunk@4815 b7a2c559-68d2-44c3-8de9-860c34a00d81 --- diff --git a/libsrc/geos/devel/geos-tgi.s b/libsrc/geos/devel/geos-tgi.s index a16307bf9..a53d34ad6 100644 --- a/libsrc/geos/devel/geos-tgi.s +++ b/libsrc/geos/devel/geos-tgi.s @@ -71,9 +71,9 @@ pages: .byte 1 ; Number of screens available .word GETPIXEL .word LINE .word BAR - .word CIRCLE .word TEXTSTYLE .word OUTTEXT + .word 0 ; IRQ entry is unused ; ------------------------------------------------------------------------ ; Data. @@ -85,20 +85,6 @@ X1 = ptr1 Y1 = ptr2 X2 = ptr3 Y2 = ptr4 -RADIUS = tmp1 - -ADDR = tmp1 -TEMP = tmp3 -TEMP2 = tmp4 -TEMP3 = sreg -TEMP4 = sreg+1 - -; Circle stuff -XX = ptr3 ; (2) CIRCLE -YY = ptr4 ; (2) CIRCLE -MaxO = sreg ; (overwritten by TEMP3+TEMP4, but restored from OG/OU anyway) -XS = regsave ; (2) CIRCLE -YS = regsave+2 ; (2) CIRCLE ; Absolute variables used in the code @@ -113,7 +99,7 @@ BITMASK: .res 1 ; $00 = clear, $01 = set pixels OLDCOLOR: .res 1 ; colors before entering gfx mode -; Line routine stuff (combined with CIRCLE to save space) +; Line routine stuff OGora: .res 2 OUkos: .res 2 @@ -505,31 +491,6 @@ GETDEFPALETTE: ; Must set an error code: NO ; -SETPIXELCLIP: - lda Y1+1 - bmi @finito ; y<0 - lda X1+1 - bmi @finito ; x<0 - lda X1 - ldx X1+1 - sta ADDR - stx ADDR+1 - ldx #ADDR - lda xres - ldy xres+1 - jsr icmp ; ( x < xres ) ... - bcs @finito - lda Y1 - ldx Y1+1 - sta ADDR - stx ADDR+1 - ldx #ADDR - lda yres - ldy yres+1 - jsr icmp ; ... && ( y < yres ) - bcc SETPIXEL -@finito:rts - SETPIXEL: lda X1 ldx X1+1 @@ -623,213 +584,6 @@ BAR: sty r2H jmp Rectangle -; ------------------------------------------------------------------------ -; CIRCLE: Draw a circle around the center X1/Y1 (= ptr1/ptr2) with the -; radius in tmp1 and the current drawing color. -; -; Must set an error code: NO -; - -CIRCLE: - lda RADIUS - bne @L1 - jmp SETPIXELCLIP ; Plot as a point - -@L1: sta XX - ; x = r; - lda #0 - sta XX+1 - sta YY - sta YY+1 - sta MaxO - sta MaxO+1 - ; y =0; mo=0; - lda X1 - ldx X1+1 - sta XS - stx XS+1 - lda Y1 - ldx Y1+1 - sta YS - stx YS+1 ; XS/YS to remember the center - - ; while (y