src/mess/video/fmtowns.c
| r7007 | r7008 | |
| 113 | 113 | static UINT8 towns_kanji_code_h; |
| 114 | 114 | static UINT8 towns_kanji_code_l; |
| 115 | 115 | static rectangle towns_crtc_layerscr[2]; // each layer has independent sizes |
| 116 | static UINT8 towns_display_plane; |
| 117 | static UINT8 towns_display_page_sel; |
| 116 | 118 | |
| 117 | 119 | extern UINT32* towns_vram; |
| 118 | 120 | extern UINT8* towns_gfxvram; |
| r7007 | r7008 | |
| 260 | 262 | return towns_crtc_mix; |
| 261 | 263 | case 0x01: // read/write plane select (bit 0-3 write, bit 6-7 read) |
| 262 | 264 | return ((towns_vram_rplane << 6) & 0xc0) | towns_vram_wplane; |
| 265 | case 0x02: // display planes (bits 0-2,5), display page select (bit 4) |
| 266 | return towns_display_plane | towns_display_page_sel; |
| 263 | 267 | case 0x03: // VRAM page select (bit 5) |
| 264 | 268 | if(towns_vram_page_sel != 0) |
| 265 | 269 | return 0x10; |
| r7007 | r7008 | |
| 300 | 304 | towns_update_video_banks(space); |
| 301 | 305 | logerror("VGA: VRAM wplane select = 0x%02x\n",towns_vram_wplane); |
| 302 | 306 | break; |
| 307 | case 0x02: // display plane (bits 0-2), display page select (bit 4) |
| 308 | towns_display_plane = data & 0x27; |
| 309 | towns_display_page_sel = data & 0x10; |
| 310 | break; |
| 303 | 311 | case 0x03: // VRAM page select (bit 4) |
| 304 | 312 | towns_vram_page_sel = data & 0x10; |
| 305 | 313 | break; |
| r7007 | r7008 | |
| 814 | 822 | else |
| 815 | 823 | linesize = towns_crtc_reg[24] * 4; |
| 816 | 824 | |
| 825 | if(towns_display_page_sel != 0) |
| 826 | off = 0x20000; |
| 817 | 827 | if(layer != 0) |
| 818 | 828 | { |
| 819 | 829 | if(!(towns_video_reg[0] & 0x10)) |
| r7007 | r7008 | |
| 883 | 893 | UINT8 colour; |
| 884 | 894 | int hzoom = 1; |
| 885 | 895 | |
| 886 | | if(towns_vram_page_sel != 0) |
| 896 | if(towns_display_page_sel != 0) |
| 887 | 897 | off = 0x20000; |
| 888 | 898 | if(layer != 0) |
| 889 | 899 | { |
| r7007 | r7008 | |
| 947 | 957 | int hzoom = 1; |
| 948 | 958 | int linesize; |
| 949 | 959 | |
| 950 | | // if(towns_vram_page_sel != 0) |
| 951 | | // off = 0x20000; |
| 960 | if(towns_display_page_sel != 0) |
| 961 | off = 0x20000; |
| 952 | 962 | if(layer == 0) |
| 953 | 963 | linesize = towns_crtc_reg[20] * 4; |
| 954 | 964 | else |
src/mess/drivers/fmtowns.c
| r7007 | r7008 | |
| 1759 | 1759 | AM_RANGE(0x41fc,0x41ff) AM_READ8(towns_41ff_r,0xff000000) |
| 1760 | 1760 | // CRTC / Video (again) |
| 1761 | 1761 | AM_RANGE(0xfd90,0xfda3) AM_READWRITE8(towns_video_fd90_r, towns_video_fd90_w, 0xffffffff) |
| 1762 | | AM_RANGE(0xff80,0xff83) AM_READWRITE8(towns_video_ff81_r, towns_video_ff81_w, 0x0000ff00) |
| 1762 | AM_RANGE(0xff80,0xffff) AM_READWRITE8(towns_video_cff80_r,towns_video_cff80_w,0xffffffff) |
| 1763 | 1763 | |
| 1764 | 1764 | ADDRESS_MAP_END |
| 1765 | 1765 | |