1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
|
/***************************************************************************
AC1 video driver by Miodrag Milanovic
15/01/2009 Preliminary driver.
****************************************************************************/
#include "emu.h"
#include "includes/ac1.h"
#define AC1_VIDEO_MEMORY 0x1000
const gfx_layout ac1_charlayout =
{
6, 8, /* 6x8 characters */
256, /* 256 characters */
1, /* 1 bits per pixel */
{0}, /* no bitplanes; 1 bit per pixel */
{7, 6, 5, 4, 3, 2},
{0 * 8, 1 * 8, 2 * 8, 3 * 8, 4 * 8, 5 * 8, 6 * 8, 7 * 8},
8*8 /* size of one char */
};
VIDEO_START( ac1 )
{
}
SCREEN_UPDATE_IND16( ac1 )
{
int x,y;
address_space *space = screen.machine().device("maincpu")->memory().space(AS_PROGRAM);
for(y = 0; y < 16; y++ )
{
for(x = 0; x < 64; x++ )
{
int code = space->read_byte(AC1_VIDEO_MEMORY + x + y*64);
drawgfx_opaque(bitmap, cliprect, screen.machine().gfx[0], code , 0, 0,0, 63*6-x*6,15*8-y*8);
}
}
return 0;
}
SCREEN_UPDATE_IND16( ac1_32 )
{
int x,y;
address_space *space = screen.machine().device("maincpu")->memory().space(AS_PROGRAM);
for(y = 0; y < 32; y++ )
{
for(x = 0; x < 64; x++ )
{
int code = space->read_byte(AC1_VIDEO_MEMORY + x + y*64);
drawgfx_opaque(bitmap, cliprect, screen.machine().gfx[0], code , 0, 0,0, 63*6-x*6,31*8-y*8);
}
}
return 0;
}
|