From: uz Date: Sun, 17 Jul 2011 11:23:27 +0000 (+0000) Subject: Added a new flags byte to the TGI headers. Bumped the API version. X-Git-Tag: V2.13.3~378 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=4026a28c60eb69eca2582abb451c9202af887d7f;p=cc65 Added a new flags byte to the TGI headers. Bumped the API version. git-svn-id: svn://svn.cc65.org/cc65/trunk@5083 b7a2c559-68d2-44c3-8de9-860c34a00d81 --- diff --git a/asminc/tgi-kernel.inc b/asminc/tgi-kernel.inc index 56c56f943..9dd0dd453 100644 --- a/asminc/tgi-kernel.inc +++ b/asminc/tgi-kernel.inc @@ -44,9 +44,10 @@ YRES .word 1 ; Y resolution COLORCOUNT .byte 1 ; Number of available colors PAGECOUNT .byte 1 ; Number of screens available - FONTWIDTH .byte 1 ; System font width - FONTHEIGHT .byte 1 ; System font height + FONTWIDTH .byte 1 ; System font width in pixel + FONTHEIGHT .byte 1 ; System font height in pixel ASPECTRATIO .word 1 ; Fixed point 8.8 format + FLAGS .byte 1 ; TGI driver flags .endstruct JUMPTAB .struct INSTALL .addr ; INSTALL routine @@ -75,7 +76,14 @@ ;------------------------------------------------------------------------------ ; The TGI API version, stored at TGI_HDR_VERSION -TGI_API_VERSION = $03 +TGI_API_VERSION = $04 + +;------------------------------------------------------------------------------ +; Bitmapped tgi driver flags, stored in TGI_HDR::VARS::FLAGS. +; Beware: Some of the bits are tested using the BIT instruction, so do not +; change the values without checking the code! + +TGI_BM_FONT_FINESCALE = $80 ; Bitmap fonts are fine grained scalable ;------------------------------------------------------------------------------ ; Text constants diff --git a/libsrc/apple2/apple2-280-192-8.s b/libsrc/apple2/apple2-280-192-8.s index 6577474ef..b8e315f18 100644 --- a/libsrc/apple2/apple2-280-192-8.s +++ b/libsrc/apple2/apple2-280-192-8.s @@ -84,6 +84,7 @@ pages: .byte 2 ; Number of screens available .byte 7 ; System font X size .byte 8 ; System font Y size .word $00EA ; Aspect ratio (based on 4/3 display) + .byte 0 ; TGI driver flags ; Next comes the jump table. With the exception of IRQ, all entries must be ; valid and may point to an RTS for test versions (function not implemented). diff --git a/libsrc/apple2/apple2-40-48-16.s b/libsrc/apple2/apple2-40-48-16.s index 3f439cadc..135c883bc 100644 --- a/libsrc/apple2/apple2-40-48-16.s +++ b/libsrc/apple2/apple2-40-48-16.s @@ -54,6 +54,7 @@ Y2 := ptr4 .byte 8 ; System font X size .byte 8 ; System font Y size .word $0198 ; Aspect ratio (based on 4/3 display) + .byte 0 ; TGI driver flags ; Next comes the jump table. With the exception of IRQ, all entries must be ; valid and may point to an RTS for test versions (function not implemented). @@ -256,7 +257,7 @@ text: jsr HOME ; Done, reset the error code lda #TGI_ERR_OK beq :+ ; Branch always - + ; Done, set the error code err: lda #TGI_ERR_INV_ARG : sta ERROR diff --git a/libsrc/atari/atari_tgi_common.inc b/libsrc/atari/atari_tgi_common.inc index 3b716a632..9e9f74aa4 100644 --- a/libsrc/atari/atari_tgi_common.inc +++ b/libsrc/atari/atari_tgi_common.inc @@ -25,6 +25,7 @@ .byte 8 ; System font X size .byte 8 ; System font Y size .word aspect ; Aspect ratio + .byte 0 ; TGI driver flags ; Function table diff --git a/libsrc/atmos/atmos-240-200-2.s b/libsrc/atmos/atmos-240-200-2.s index 6c6a9bb99..80d9ec784 100644 --- a/libsrc/atmos/atmos-240-200-2.s +++ b/libsrc/atmos/atmos-240-200-2.s @@ -29,6 +29,7 @@ xsize: .byte 6 ; System font X size .byte 8 ; System font Y size .word $011C ; Aspect ratio (based on 4/3 display) + .byte 0 ; TGI driver flags ; Next comes the jump table. Currently all entries must be valid and may point ; to an RTS for test versions (function not implemented). diff --git a/libsrc/c128/c128-640-200-2.s b/libsrc/c128/c128-640-200-2.s index 118a93e6e..ecc4c8437 100644 --- a/libsrc/c128/c128-640-200-2.s +++ b/libsrc/c128/c128-640-200-2.s @@ -62,6 +62,7 @@ pages: .byte 1 ; Number of screens available .byte 8 ; System font X size .byte 8 ; System font Y size .word $006A ; Aspect ratio (based on 4/3 display) + .byte 0 ; TGI driver flags ; Next comes the jump table. Currently all entries must be valid and may point ; to an RTS for test versions (function not implemented). diff --git a/libsrc/c128/c128-640-480-2.s b/libsrc/c128/c128-640-480-2.s index bd9286221..021b95245 100644 --- a/libsrc/c128/c128-640-480-2.s +++ b/libsrc/c128/c128-640-480-2.s @@ -63,6 +63,7 @@ pages: .byte 0 ; Number of screens available .byte 8 ; System font X size .byte 8 ; System font Y size .word $0100 ; Aspect ratio (based on 4/3 display) + .byte 0 ; TGI driver flags ; Next comes the jump table. Currently all entries must be valid and may point ; to an RTS for test versions (function not implemented). diff --git a/libsrc/c64/c64-320-200-2.s b/libsrc/c64/c64-320-200-2.s index 0d66a6ea7..0ba4f6ef0 100644 --- a/libsrc/c64/c64-320-200-2.s +++ b/libsrc/c64/c64-320-200-2.s @@ -30,6 +30,7 @@ .byte 8 ; System font X size .byte 8 ; System font Y size .word $00D4 ; Aspect ratio (based on 4/3 display) + .byte 0 ; TGI driver flags ; Next comes the jump table. With the exception of IRQ, all entries must be ; valid and may point to an RTS for test versions (function not implemented). diff --git a/libsrc/geos/devel/geos-tgi.s b/libsrc/geos/devel/geos-tgi.s index 247920df1..8cbb332d3 100644 --- a/libsrc/geos/devel/geos-tgi.s +++ b/libsrc/geos/devel/geos-tgi.s @@ -49,6 +49,7 @@ pages: .byte 1 ; Number of screens available .byte 8 ; System font X size .byte 8 ; System font Y size aspect: .word $00D4 ; Aspect ratio (based on 4/3 display) + .byte 0 ; TGI driver flags ; Next comes the jump table. With the exception of IRQ, all entries must be ; valid, and may point to an RTS for test versions (function not implemented). diff --git a/libsrc/lynx/lynx-160-102-16.s b/libsrc/lynx/lynx-160-102-16.s index 4a4d6175b..5857a4f35 100644 --- a/libsrc/lynx/lynx-160-102-16.s +++ b/libsrc/lynx/lynx-160-102-16.s @@ -34,6 +34,7 @@ .byte 8 ; System font X size .byte 8 ; System font Y size .word $0100 ; Aspect ratio (square pixel LCD) + .byte TGI_BM_FONT_FINESCALE ; TGI driver flags ; Next comes the jump table. Currently all entries must be valid and may point ; to an RTS for test versions (function not implemented). A future version may diff --git a/libsrc/nes/nes-64-56-2.s b/libsrc/nes/nes-64-56-2.s index deeca5c44..8d824aeac 100644 --- a/libsrc/nes/nes-64-56-2.s +++ b/libsrc/nes/nes-64-56-2.s @@ -33,6 +33,7 @@ yres: .word 56 ; Max Y resolution .byte 2 ; System font X size .byte 2 ; System font Y size .word $100 ; Aspect ratio + .byte 0 ; TGI driver flags ; Next comes the jump table. Currently all entries must be valid and may point ; to an RTS for test versions (function not implemented). diff --git a/libsrc/tgi/tgi-kernel.s b/libsrc/tgi/tgi-kernel.s index a4316f8f1..bca86ebf3 100644 --- a/libsrc/tgi/tgi-kernel.s +++ b/libsrc/tgi/tgi-kernel.s @@ -55,6 +55,7 @@ _tgi_pagecount: .res 1 ; Number of available screen pages _tgi_fontwidth: .res 1 ; System font width in pixels _tgi_fontheight: .res 1 ; System font height in pixels _tgi_aspectratio: .res 2 ; Aspect ratio in 8.8 fixed point +_tgi_flags: .res 1 ; TGI driver flags .data