mirror of
https://github.com/cc65/cc65.git
synced 2024-12-25 17:29:50 +00:00
new TGI driver for interlaced VDC 640x480 mode
git-svn-id: svn://svn.cc65.org/cc65/trunk@1830 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
parent
e2e2b02c3d
commit
578443610d
@ -37,6 +37,7 @@
|
|||||||
TGI_MODE_320_200_2 = 1 ; 320x200, 2 colors (b/w)
|
TGI_MODE_320_200_2 = 1 ; 320x200, 2 colors (b/w)
|
||||||
TGI_MODE_160_200_4 = 2 ; 160x200, 4 colors
|
TGI_MODE_160_200_4 = 2 ; 160x200, 4 colors
|
||||||
TGI_MODE_640_200_2 = 3 ; 640x200, 2 colors (b/w)
|
TGI_MODE_640_200_2 = 3 ; 640x200, 2 colors (b/w)
|
||||||
|
TGI_MODE_640_480_2 = 4 ; 640x480, 2 colors (b/w)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -48,6 +48,7 @@
|
|||||||
#define TGI_MODE_320_200_2 1U /* 320x200, 2 colors (b/w) */
|
#define TGI_MODE_320_200_2 1U /* 320x200, 2 colors (b/w) */
|
||||||
#define TGI_MODE_160_200_4 2U /* 160x200, 4 colors */
|
#define TGI_MODE_160_200_4 2U /* 160x200, 4 colors */
|
||||||
#define TGI_MODE_640_200_2 3U /* 640x200, 2 colors (b/w) */
|
#define TGI_MODE_640_200_2 3U /* 640x200, 2 colors (b/w) */
|
||||||
|
#define TGI_MODE_640_480_2 4U /* 640x480, 2 colors (b/w) */
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -145,6 +145,7 @@ c128lib:
|
|||||||
cp c128/*.emd .
|
cp c128/*.emd .
|
||||||
cp c128/*.joy .
|
cp c128/*.joy .
|
||||||
cp c128/c128-640-200-2.tgi c128-vdc.tgi
|
cp c128/c128-640-200-2.tgi c128-vdc.tgi
|
||||||
|
cp c128/c128-640-480-2.tgi c128-vdc2.tgi
|
||||||
|
|
||||||
#-----------------------------------------------------------------------------
|
#-----------------------------------------------------------------------------
|
||||||
# Commdore P500 / CBM 5x0
|
# Commdore P500 / CBM 5x0
|
||||||
|
@ -51,7 +51,7 @@ EMDS = c128-georam.emd c128-ram.emd c128-ramcart.emd c128-reu.emd c128-vdc.emd
|
|||||||
|
|
||||||
JOYS = c128-stdjoy.joy
|
JOYS = c128-stdjoy.joy
|
||||||
|
|
||||||
TGIS = c128-640-200-2.tgi
|
TGIS = c128-640-200-2.tgi c128-640-480-2.tgi
|
||||||
|
|
||||||
#--------------------------------------------------------------------------
|
#--------------------------------------------------------------------------
|
||||||
# Targets
|
# Targets
|
||||||
|
@ -1,17 +1,14 @@
|
|||||||
;
|
;
|
||||||
; Graphics driver for the 640x200x2 mode on the C128 VDC
|
; Graphics driver for the 640x200x2 mode on the C128 VDC
|
||||||
; Maciej 'YTM/Elysium' Witkowiak <ytm@friko.onet.pl>
|
; Maciej 'YTM/Elysium' Witkowiak <ytm@elysium.pl>
|
||||||
; 22.12.2002
|
; 23.12.2002
|
||||||
;
|
;
|
||||||
; NOTES:
|
; NOTES:
|
||||||
|
; On the real machine there are some additional pixels appearing (probably bad reads)
|
||||||
|
; VICE emulator does not show them. Needs further investigation.
|
||||||
;
|
;
|
||||||
; Only DONE routine contains C128-mode specific stuff, everything else will work in
|
; Only DONE routine contains C128-mode specific stuff, everything else will work in
|
||||||
; C64-mode of C128.
|
; C64-mode of C128 (C64 needs full VDC init then).
|
||||||
;
|
|
||||||
; All Y-axis calculations are 16-bit, so this driver will support 640x400 (interlaced)
|
|
||||||
; mode only with gfx-mode initialization changed.
|
|
||||||
; (is the above true? I can't remember if interlace skips lines or takes them from two
|
|
||||||
; different places (same offset, different base))
|
|
||||||
;
|
;
|
||||||
; X-axis resolution can be changed by manipulating xres header field so
|
; X-axis resolution can be changed by manipulating xres header field so
|
||||||
; any resolution 8..708 is possible only with gfx-mode initialization and CALC changed.
|
; any resolution 8..708 is possible only with gfx-mode initialization and CALC changed.
|
||||||
@ -428,7 +425,7 @@ SETDRAWPAGE:
|
|||||||
ror
|
ror
|
||||||
ror
|
ror
|
||||||
sta SCRBASE
|
sta SCRBASE
|
||||||
rts
|
rts
|
||||||
|
|
||||||
; ------------------------------------------------------------------------
|
; ------------------------------------------------------------------------
|
||||||
; SETCOLOR: Set the drawing color (in A). The new color is already checked
|
; SETCOLOR: Set the drawing color (in A). The new color is already checked
|
||||||
@ -1142,13 +1139,10 @@ OUTTEXT:
|
|||||||
rts
|
rts
|
||||||
|
|
||||||
; ------------------------------------------------------------------------
|
; ------------------------------------------------------------------------
|
||||||
; Calculate all variables to plot the pixel at X1/Y1. If the point is out
|
; Calculate all variables to plot the pixel at X1/Y1.
|
||||||
; of range, a carry is returned and INRANGE is set to a value !0 zero. If
|
|
||||||
; the coordinates are valid, INRANGE is zero and the carry clear.
|
|
||||||
|
|
||||||
;------------------------
|
;------------------------
|
||||||
;< X1,Y1 - pixel
|
;< X1,Y1 - pixel
|
||||||
;> ADDR - address of card, INRANGE
|
;> ADDR - address of card
|
||||||
;> X - bit number (X1 & 7)
|
;> X - bit number (X1 & 7)
|
||||||
CALC:
|
CALC:
|
||||||
lda Y1+1
|
lda Y1+1
|
||||||
@ -1253,6 +1247,8 @@ VDCSetSourceAddr:
|
|||||||
sta VDC_DATA_REG
|
sta VDC_DATA_REG
|
||||||
dex
|
dex
|
||||||
tya
|
tya
|
||||||
|
@L1: bit VDC_ADDR_REG
|
||||||
|
bpl @L1
|
||||||
stx VDC_ADDR_REG
|
stx VDC_ADDR_REG
|
||||||
sta VDC_DATA_REG
|
sta VDC_DATA_REG
|
||||||
rts
|
rts
|
||||||
|
1287
libsrc/c128/c128-640-480-2.s
Normal file
1287
libsrc/c128/c128-640-480-2.s
Normal file
File diff suppressed because it is too large
Load Diff
@ -18,4 +18,5 @@
|
|||||||
|
|
||||||
_tgi_mode_table:
|
_tgi_mode_table:
|
||||||
.byte TGI_MODE_640_200_2, "c128-vdc.tgi", 0
|
.byte TGI_MODE_640_200_2, "c128-vdc.tgi", 0
|
||||||
|
.byte TGI_MODE_640_480_2, "c128-vdc2.tgi", 0
|
||||||
.byte 0 ; End marker
|
.byte 0 ; End marker
|
||||||
|
Loading…
Reference in New Issue
Block a user