Previous 15994 Revisions Next

r2057 Saturday 22nd March, 2008 at 15:56:20 UTC by Wilbert Pol
[T1000] Removed cga code dependency from the t1000 video code.
[src/mess/video]pc_t1t.c

src/mess/video/pc_t1t.c
r2056r2057
1010
1111#include "driver.h"
1212#include "pc_t1t.h"
13#include "pc_cga.h" // cga monitor palette
1413#include "video/mc6845.h"
1514
1615
r2056r2057
4342   MDRV_SCREEN_ADD(T1000_SCREEN_NAME, RASTER)
4443   MDRV_SCREEN_FORMAT(BITMAP_FORMAT_INDEXED16)
4544   MDRV_SCREEN_RAW_PARAMS(XTAL_14_31818MHz,912,0,640,262,0,200)
46   MDRV_PALETTE_LENGTH( CGA_PALETTE_SETS * 16 )
45   MDRV_PALETTE_LENGTH( 16 )
4746   MDRV_PALETTE_INIT(pcjr)
4847
4948   MDRV_DEVICE_ADD(T1000_MC6845_NAME, MC6845)
r2056r2057
6362/* Initialise the cga palette */
6463static PALETTE_INIT( pcjr )
6564{
65   const static unsigned char tga_palette[16][3] = {
66      { 0x00, 0x00, 0x00 }, { 0x00, 0x00, 0xaa }, { 0x00, 0xaa, 0x00 }, { 0x00, 0xaa, 0xaa },
67      { 0xaa, 0x00, 0x00 }, { 0xaa, 0x00, 0xaa }, { 0xaa, 0x55, 0x00 }, { 0xaa, 0xaa, 0xaa },
68      { 0x55, 0x55, 0x55 }, { 0x55, 0x55, 0xff }, { 0x55, 0xff, 0x55 }, { 0x55, 0xff, 0xff },
69      { 0xff, 0x55, 0x55 }, { 0xff, 0x55, 0xff }, { 0xff, 0xff, 0x55 }, { 0xff, 0xff, 0xff }
70   };
6671   int i;
67   for(i = 0; i < CGA_PALETTE_SETS * 16; i++)
68      palette_set_color_rgb(machine, i, cga_palette[i][0], cga_palette[i][1], cga_palette[i][2]);
72
73   for(i = 0; i < 16; i++)
74      palette_set_color_rgb(machine, i, tga_palette[i][0], tga_palette[i][1], tga_palette[i][2]);
6975}
7076
7177static struct {

Previous 15994 Revisions Next


© 1998-2018 The MESS Team