summaryrefslogtreecommitdiffstatshomepage
path: root/src/mame
diff options
context:
space:
mode:
author Miodrag Milanovic <mmicko@gmail.com>2016-05-25 08:19:21 +0200
committer Miodrag Milanovic <mmicko@gmail.com>2016-05-25 08:19:21 +0200
commit68785dccfee3208163c8169abc5c6d01becf36d4 (patch)
treed6967331fd0e938981777aa32b5f246e04fb701b /src/mame
parentc1230f8b9bf4373d396ecb970c966ec2ce6dfc15 (diff)
Cleanups and version bumpmame0174
Diffstat (limited to 'src/mame')
-rw-r--r--src/mame/drivers/1942.cpp6
-rw-r--r--src/mame/drivers/1943.cpp2
-rw-r--r--src/mame/drivers/alpha68k.cpp2
-rw-r--r--src/mame/drivers/altos486.cpp1
-rw-r--r--src/mame/drivers/apple2e.cpp20
-rw-r--r--src/mame/drivers/bfm_ad5.cpp2
-rw-r--r--src/mame/drivers/crgolf.cpp75
-rw-r--r--src/mame/drivers/cybiko.cpp2
-rw-r--r--src/mame/drivers/dec0.cpp2
-rw-r--r--src/mame/drivers/deco_ld.cpp4
-rw-r--r--src/mame/drivers/fcscsi.cpp14
-rw-r--r--src/mame/drivers/gba.cpp6
-rw-r--r--src/mame/drivers/goldstar.cpp26
-rw-r--r--src/mame/drivers/harddriv.cpp2
-rw-r--r--src/mame/drivers/hh_tms1k.cpp16
-rw-r--r--src/mame/drivers/hk68v10.cpp8
-rw-r--r--src/mame/drivers/hp9845.cpp788
-rw-r--r--src/mame/drivers/icatel.cpp4
-rw-r--r--src/mame/drivers/igspoker.cpp6
-rw-r--r--src/mame/drivers/itt3030.cpp2
-rw-r--r--src/mame/drivers/jack.cpp20
-rw-r--r--src/mame/drivers/lwings.cpp2
-rw-r--r--src/mame/drivers/macs.cpp2
-rw-r--r--src/mame/drivers/mcr68.cpp2
-rw-r--r--src/mame/drivers/merit.cpp6
-rw-r--r--src/mame/drivers/metlfrzr.cpp80
-rw-r--r--src/mame/drivers/mpu4.cpp2
-rw-r--r--src/mame/drivers/mvme147.cpp397
-rw-r--r--src/mame/drivers/neogeo.cpp107
-rw-r--r--src/mame/drivers/neopcb.cpp33
-rw-r--r--src/mame/drivers/seattle.cpp8
-rw-r--r--src/mame/drivers/skylncr.cpp2
-rw-r--r--src/mame/drivers/thomson.cpp6
-rw-r--r--src/mame/drivers/ticalc1x.cpp4
-rw-r--r--src/mame/drivers/tourvis.cpp2
-rw-r--r--src/mame/drivers/unixpc.cpp22
-rw-r--r--src/mame/drivers/vegas.cpp8
-rw-r--r--src/mame/includes/alesis.h2
-rw-r--r--src/mame/includes/asteroid.h1
-rw-r--r--src/mame/includes/astrocde.h1
-rw-r--r--src/mame/includes/chihiro.h2
-rw-r--r--src/mame/includes/dassault.h2
-rw-r--r--src/mame/includes/ladybug.h2
-rw-r--r--src/mame/includes/madmotor.h2
-rw-r--r--src/mame/includes/megadrvb.h2
-rw-r--r--src/mame/includes/midzeus.h1
-rw-r--r--src/mame/includes/model1.h270
-rw-r--r--src/mame/includes/mw8080bw.h2
-rw-r--r--src/mame/includes/neogeo.h35
-rw-r--r--src/mame/includes/redclash.h2
-rw-r--r--src/mame/includes/snes.h2
-rw-r--r--src/mame/layout/fidel_csc.lay22
-rw-r--r--src/mame/layout/mdndclab.lay6
-rw-r--r--src/mame/machine/awboard.cpp2
-rw-r--r--src/mame/machine/deco146.cpp6
-rw-r--r--src/mame/machine/decocrpt.h1
-rw-r--r--src/mame/machine/gamecom.cpp2
-rw-r--r--src/mame/machine/macadb.h1
-rw-r--r--src/mame/machine/pgmprot_igs025_igs028.h2
-rw-r--r--src/mame/mame.lst2
-rw-r--r--src/mame/video/chihiro.cpp20
-rw-r--r--src/mame/video/crgolf.cpp2
-rw-r--r--src/mame/video/holeland.cpp2
-rw-r--r--src/mame/video/ladybug.cpp1
-rw-r--r--src/mame/video/model1.cpp1322
-rw-r--r--src/mame/video/model3.cpp52
-rw-r--r--src/mame/video/mw8080bw.cpp6
-rw-r--r--src/mame/video/neogeo_spr.cpp12
-rw-r--r--src/mame/video/neogeo_spr.h4
69 files changed, 1732 insertions, 1750 deletions
diff --git a/src/mame/drivers/1942.cpp b/src/mame/drivers/1942.cpp
index a558ff74380..d2b324dfcf5 100644
--- a/src/mame/drivers/1942.cpp
+++ b/src/mame/drivers/1942.cpp
@@ -794,9 +794,9 @@ ROM_END
/* set contained only three program ROMs, other ROMs should be checked against a real PCB */
ROM_START( 1942h )
ROM_REGION( 0x20000, "maincpu", ROMREGION_ERASEFF ) /* 64k for code + 3*16k for the banked ROMs images */
- ROM_LOAD( "Supercharger_1942_#3.m3", 0x00000, 0x4000, CRC(ec70785f) SHA1(2010a945e1d5c984a14cf7f47a883d04bd71567d) ) /* label confirmed from auction post */
- ROM_LOAD( "Supercharger_1942_#4.m4", 0x04000, 0x4000, CRC(cc11355f) SHA1(44fceb449f406f657494eeee4e6b43bf063f2013) ) /* label confirmed from auction post */
- ROM_LOAD( "Supercharger_1942_#5.m5", 0x10000, 0x4000, CRC(42746d75) SHA1(ede6919b84653b94fddeb40b3004e44336880ba2) ) /* label confirmed from auction post */
+ ROM_LOAD( "Supercharger_1942_#3.m3", 0x00000, 0x4000, CRC(ec70785f) SHA1(2010a945e1d5c984a14cf7f47a883d04bd71567d) ) /* label confirmed from auction post */
+ ROM_LOAD( "Supercharger_1942_#4.m4", 0x04000, 0x4000, CRC(cc11355f) SHA1(44fceb449f406f657494eeee4e6b43bf063f2013) ) /* label confirmed from auction post */
+ ROM_LOAD( "Supercharger_1942_#5.m5", 0x10000, 0x4000, CRC(42746d75) SHA1(ede6919b84653b94fddeb40b3004e44336880ba2) ) /* label confirmed from auction post */
ROM_LOAD( "srb-06.m6", 0x14000, 0x2000, CRC(466f8248) SHA1(2ccc8fc59962d3001fbc10e8d2f20a254a74f251) )
ROM_LOAD( "srb-07.m7", 0x18000, 0x4000, CRC(0d31038c) SHA1(b588eaf6fddd66ecb2d9832dc197f286f1ccd846) )
diff --git a/src/mame/drivers/1943.cpp b/src/mame/drivers/1943.cpp
index 99b8bdda240..c741f83e4b4 100644
--- a/src/mame/drivers/1943.cpp
+++ b/src/mame/drivers/1943.cpp
@@ -334,7 +334,7 @@ static MACHINE_CONFIG_START( 1943, _1943_state )
// sound hardware
MCFG_SPEAKER_STANDARD_MONO("mono")
-
+
MCFG_GENERIC_LATCH_8_ADD("soundlatch")
MCFG_SOUND_ADD("ym1", YM2203, XTAL_24MHz/16) /* verified on pcb */
diff --git a/src/mame/drivers/alpha68k.cpp b/src/mame/drivers/alpha68k.cpp
index 1817a2c4d16..1650f88828d 100644
--- a/src/mame/drivers/alpha68k.cpp
+++ b/src/mame/drivers/alpha68k.cpp
@@ -2140,7 +2140,7 @@ static MACHINE_CONFIG_START( alpha68k_II, alpha68k_state )
/* sound hardware */
MCFG_SPEAKER_STANDARD_MONO("mono")
-
+
MCFG_GENERIC_LATCH_8_ADD("soundlatch")
MCFG_SOUND_ADD("ym1", YM2203, 3000000)
diff --git a/src/mame/drivers/altos486.cpp b/src/mame/drivers/altos486.cpp
index d9b4aa81a6e..60589ecde69 100644
--- a/src/mame/drivers/altos486.cpp
+++ b/src/mame/drivers/altos486.cpp
@@ -220,4 +220,3 @@ ROM_START( altos486 )
ROM_END
COMP( 1984, altos486, 0, 0, altos486, 0, driver_device, 0, "Altos Computer Systems", "Altos 486", MACHINE_NOT_WORKING | MACHINE_NO_SOUND)
-
diff --git a/src/mame/drivers/apple2e.cpp b/src/mame/drivers/apple2e.cpp
index c324800df82..f9d8f382cce 100644
--- a/src/mame/drivers/apple2e.cpp
+++ b/src/mame/drivers/apple2e.cpp
@@ -1946,34 +1946,34 @@ READ8_MEMBER(apple2e_state::c300_int_r) { return read_int_rom(space, 0x300, off
READ8_MEMBER(apple2e_state::c300_int_bank_r) { return read_int_rom(space, 0x4300, offset); }
WRITE8_MEMBER(apple2e_state::c300_w) { write_slot_rom(space, 3, offset, data); }
READ8_MEMBER(apple2e_state::c400_r) { return read_slot_rom(space, 4, offset); }
-READ8_MEMBER(apple2e_state::c400_int_r)
-{
+READ8_MEMBER(apple2e_state::c400_int_r)
+{
if ((offset < 0x100) && (m_mockingboard4c))
{
return read_slot_rom(space, 4, offset);
}
- return read_int_rom(space, 0x400, offset);
+ return read_int_rom(space, 0x400, offset);
}
-READ8_MEMBER(apple2e_state::c400_int_bank_r)
-{
+READ8_MEMBER(apple2e_state::c400_int_bank_r)
+{
if ((offset < 0x100) && (m_mockingboard4c))
{
return read_slot_rom(space, 4, offset);
}
- return read_int_rom(space, 0x4400, offset);
+ return read_int_rom(space, 0x4400, offset);
}
-WRITE8_MEMBER(apple2e_state::c400_w)
-{
+WRITE8_MEMBER(apple2e_state::c400_w)
+{
if ((m_isiic) && (offset < 0x100))
{
m_mockingboard4c = true;
}
- write_slot_rom(space, 4, offset, data);
+ write_slot_rom(space, 4, offset, data);
}
READ8_MEMBER(apple2e_state::c800_r)
@@ -3457,7 +3457,7 @@ static MACHINE_CONFIG_DERIVED( apple2c, apple2ee )
MCFG_RS232_CTS_HANDLER(DEVWRITELINE(IIC_ACIA2_TAG, mos6551_device, write_cts))
// TODO: populate the IIc's other virtual slots with ONBOARD_ADD
- MCFG_A2BUS_ONBOARD_ADD("a2bus", "sl4", A2BUS_MOCKINGBOARD, NOOP ) // Mockingboard 4C
+ MCFG_A2BUS_ONBOARD_ADD("a2bus", "sl4", A2BUS_MOCKINGBOARD, NOOP ) // Mockingboard 4C
MCFG_A2BUS_ONBOARD_ADD("a2bus", "sl6", A2BUS_DISKIING, NOOP)
MCFG_A2EAUXSLOT_SLOT_REMOVE("aux")
diff --git a/src/mame/drivers/bfm_ad5.cpp b/src/mame/drivers/bfm_ad5.cpp
index 3374a24c2c1..ec3073b7540 100644
--- a/src/mame/drivers/bfm_ad5.cpp
+++ b/src/mame/drivers/bfm_ad5.cpp
@@ -86,4 +86,4 @@ MACHINE_CONFIG_START( bfm_ad5, adder5_state )
/* unknown sound */
MACHINE_CONFIG_END
-#include "bfm_ad5sw.hxx" \ No newline at end of file
+#include "bfm_ad5sw.hxx"
diff --git a/src/mame/drivers/crgolf.cpp b/src/mame/drivers/crgolf.cpp
index 03057b92740..52545910579 100644
--- a/src/mame/drivers/crgolf.cpp
+++ b/src/mame/drivers/crgolf.cpp
@@ -48,41 +48,41 @@
Pin 19 - Pin 22 of F1 (2764 on cpu/sound board), Output
Pin 20 - VCC
- -------------------------------------------------------------------
+ -------------------------------------------------------------------
- Master's Golf is a different PCB, but appears to operate in a similar way
+ Master's Golf is a different PCB, but appears to operate in a similar way
-
- PCB X-081-PC-A
- contains a large box marked
+ PCB X-081-PC-A
+ contains a large box marked
- |-----------------------\_/--------------------|
- | NASCO-9000 |
- | |
- | /- NASCO -\ |
- | /\ | ORIGINAL | |
- | NASCO\/YUVO \- 0001941 -/ |
- | |
- | PAT.P |
- | |---------------------------------------| |
- | | MASTER'S GOLF vers JAPAN | |
- | | | |
- | | CUSTOM BOARD | |
- | |---------------------------------------| |
- | |
- | YUVO CO., LTD |
- |-----------------------------------------------
- next to rom M-GF_A10.12K
- the box must contain at least a Z80
+ |-----------------------\_/--------------------|
+ | NASCO-9000 |
+ | |
+ | /- NASCO -\ |
+ | /\ | ORIGINAL | |
+ | NASCO\/YUVO \- 0001941 -/ |
+ | |
+ | PAT.P |
+ | |---------------------------------------| |
+ | | MASTER'S GOLF vers JAPAN | |
+ | | | |
+ | | CUSTOM BOARD | |
+ | |---------------------------------------| |
+ | |
+ | YUVO CO., LTD |
+ |-----------------------------------------------
+
+ next to rom M-GF_A10.12K
+ the box must contain at least a Z80
DASM Notes:
-- main CPU currently stalls with a RAM buffer check ($63fe), then it
-tries to see if $612c onward has a "MASTERJ" string on it, resets itself
+- main CPU currently stalls with a RAM buffer check ($63fe), then it
+tries to see if $612c onward has a "MASTERJ" string on it, resets itself
otherwise.
-During irq routines it also checks if bit 7 is active for $640a-$6415,
+During irq routines it also checks if bit 7 is active for $640a-$6415,
modifies this area if condition is true.
Neither of above matches what we have in the rom data banks, so it's either
protected or a snippet should do the aforementioned string copy.
@@ -289,7 +289,7 @@ WRITE8_MEMBER(crgolf_state::crgolfhi_sample_w)
WRITE8_MEMBER(crgolf_state::screen_select_w)
{
-// if (data & 0xfe) printf("vram_page_select_w %02x\n", data);
+// if (data & 0xfe) printf("vram_page_select_w %02x\n", data);
m_vrambank->set_bank(data & 0x1);
}
@@ -354,14 +354,14 @@ ADDRESS_MAP_END
static ADDRESS_MAP_START( mastrglf_io, AS_IO, 8, crgolf_state )
ADDRESS_MAP_GLOBAL_MASK(0xff)
-
+
AM_RANGE(0x03, 0x03) AM_WRITEONLY AM_SHARE("color_select")
AM_RANGE(0x04, 0x04) AM_WRITEONLY AM_SHARE("screen_flip")
AM_RANGE(0x05, 0x05) AM_WRITE( screen_select_w )
AM_RANGE(0x06, 0x06) AM_WRITEONLY AM_SHARE("screenb_enable")
AM_RANGE(0x07, 0x07) AM_WRITEONLY AM_SHARE("screena_enable")
-// AM_RANGE(0x20, 0x20) AM_WRITE( main_to_sound_w )
+// AM_RANGE(0x20, 0x20) AM_WRITE( main_to_sound_w )
AM_RANGE(0x40, 0x40) AM_WRITE( main_to_sound_w )
AM_RANGE(0xa0, 0xa0) AM_READ( sound_to_main_r )
ADDRESS_MAP_END
@@ -391,7 +391,6 @@ READ8_MEMBER(crgolf_state::unk_sub_07_r)
WRITE8_MEMBER(crgolf_state::unk_sub_0c_w)
{
-
}
@@ -571,7 +570,7 @@ ROM_START( crgolf ) // 834-5419-04
ROM_LOAD( "crwnc1.1c", 0x00000, 0x2000, CRC(3246e405) SHA1(f6018029317ac96df5866ca6a2bb2135edbd7e77) )
ROM_LOAD( "crwna1.1a", 0x02000, 0x2000, CRC(b9a936e2) SHA1(cebf67d9c42627fbb39648674012a6cf8cb287b5) )
- ROM_REGION( 0x20000, "maindata", 0 )
+ ROM_REGION( 0x20000, "maindata", 0 )
ROM_LOAD( "epr-5880.6b", 0x00000, 0x2000, CRC(4d6d8dad) SHA1(1530f81ad0097eadc75884ff8690b60b85ae451b) )
ROM_LOAD( "epr-5885.5e", 0x0e000, 0x2000, CRC(fac6d56c) SHA1(67dc1918d5ab2443e967359e51d49dd134cdf25d) )
ROM_LOAD( "epr-5881.6f", 0x10000, 0x2000, CRC(dd48dc1f) SHA1(d4560a88d872bd5f401344e3adb25f8486caca11) )
@@ -601,7 +600,7 @@ ROM_START( crgolfa ) // 834-5419-03
ROM_LOAD( "epr-6143.1c", 0x00000, 0x2000, CRC(4b301360) SHA1(2a7dd4876f4448b4b59b6dd02e55eb2d0126b777) )
ROM_LOAD( "epr-6142.1a", 0x02000, 0x2000, CRC(8fc5e67f) SHA1(6563db94c55cfc7d2270daccaab57fc7b422b9f9) )
- ROM_REGION( 0x20000, "maindata", 0 )
+ ROM_REGION( 0x20000, "maindata", 0 )
ROM_LOAD( "epr-5880.6b", 0x00000, 0x2000, CRC(4d6d8dad) SHA1(1530f81ad0097eadc75884ff8690b60b85ae451b) )
ROM_LOAD( "epr-5885.5e", 0x0e000, 0x2000, CRC(fac6d56c) SHA1(67dc1918d5ab2443e967359e51d49dd134cdf25d) )
ROM_LOAD( "epr-5881.6f", 0x10000, 0x2000, CRC(dd48dc1f) SHA1(d4560a88d872bd5f401344e3adb25f8486caca11) )
@@ -632,7 +631,7 @@ ROM_START( crgolfb )
ROM_LOAD( "epr-5879b.1c", 0x00000, 0x2000, CRC(927be359) SHA1(d534f7e3ef4ced8eea882ae2b8425df4c5842833) ) // 5879b.
ROM_LOAD( "epr-5878.1a", 0x02000, 0x2000, CRC(65fd0fa0) SHA1(de95ff95c9f981cd9eadf8b028ee5373bc69007b) ) // 5878.
- ROM_REGION( 0x20000, "maindata", 0 )
+ ROM_REGION( 0x20000, "maindata", 0 )
ROM_LOAD( "epr-5880.6b", 0x00000, 0x2000, CRC(4d6d8dad) SHA1(1530f81ad0097eadc75884ff8690b60b85ae451b) ) // crnsgolf.c
ROM_LOAD( "epr-5885.5e", 0x0e000, 0x2000, CRC(fac6d56c) SHA1(67dc1918d5ab2443e967359e51d49dd134cdf25d) ) // crnsgolf.h
ROM_LOAD( "epr-5881.6f", 0x10000, 0x2000, CRC(dd48dc1f) SHA1(d4560a88d872bd5f401344e3adb25f8486caca11) ) // crnsgolf.d
@@ -660,7 +659,7 @@ ROM_START( crgolfc )
ROM_LOAD( "15.1a", 0x00000, 0x2000, CRC(e6194356) SHA1(78eec53a0658b552e6a8af109d9c9754e4ddadcb) )
ROM_LOAD( "16.1c", 0x02000, 0x2000, CRC(f50412e2) SHA1(5a50fb1edfc26072e921447bd157fe996f707e05) )
- ROM_REGION( 0x20000, "maindata", 0 )
+ ROM_REGION( 0x20000, "maindata", 0 )
ROM_LOAD( "cg.1", 0x00000, 0x2000, CRC(ad7d537a) SHA1(deff74074a8b16ea91a0fa72d97ec36336c87b97) ) // 1.6a
ROM_LOAD( "epr-5885.5e", 0x0e000, 0x2000, CRC(fac6d56c) SHA1(67dc1918d5ab2443e967359e51d49dd134cdf25d) ) // 6.5a
ROM_LOAD( "epr-5881.6f", 0x10000, 0x2000, CRC(dd48dc1f) SHA1(d4560a88d872bd5f401344e3adb25f8486caca11) ) // 2.6b
@@ -688,7 +687,7 @@ ROM_START( crgolfbt )
ROM_LOAD( "epr-5879b.1c", 0x00000, 0x2000, CRC(927be359) SHA1(d534f7e3ef4ced8eea882ae2b8425df4c5842833) )
ROM_LOAD( "epr-5878.1a", 0x02000, 0x2000, CRC(65fd0fa0) SHA1(de95ff95c9f981cd9eadf8b028ee5373bc69007b) )
- ROM_REGION( 0x20000, "maindata", 0 )
+ ROM_REGION( 0x20000, "maindata", 0 )
ROM_LOAD( "cg.1", 0x00000, 0x2000, CRC(ad7d537a) SHA1(deff74074a8b16ea91a0fa72d97ec36336c87b97) )
ROM_LOAD( "epr-5885.5e", 0x0e000, 0x2000, CRC(fac6d56c) SHA1(67dc1918d5ab2443e967359e51d49dd134cdf25d) ) // cg.6
ROM_LOAD( "epr-5881.6f", 0x10000, 0x2000, CRC(dd48dc1f) SHA1(d4560a88d872bd5f401344e3adb25f8486caca11) ) // cg.2
@@ -716,7 +715,7 @@ ROM_START( crgolfhi )
ROM_LOAD( "cpu.c1", 0x00000, 0x2000, CRC(8b101085) SHA1(a59c369be3e7e645d8b20032998a778a2056b7d7) )
ROM_LOAD( "cpu.a1", 0x02000, 0x2000, CRC(f48a8ee8) SHA1(cc07c7258caf251e9cb52f12be779cb02fca0b0a) )
- ROM_REGION( 0x20000, "maindata", 0 )
+ ROM_REGION( 0x20000, "maindata", 0 )
ROM_LOAD( "main.b6", 0x00000, 0x2000, CRC(5b0336c6) SHA1(86e2c197f23a2f2f7666448b74611150ca15a2af) )
ROM_LOAD( "main.b5", 0x02000, 0x2000, CRC(7b80149a) SHA1(c802a79b1430b15d166f5fca11d2ed4e65bc65a9) )
ROM_LOAD( "main.c6", 0x04000, 0x2000, CRC(7804cb1c) SHA1(487f979f47a0f40fa35331c71a66dc8428387a26) )
@@ -757,7 +756,7 @@ ROM_START( mastrglf )
ROM_LOAD( "M-GF_A5.10A.27256.ROM2", 0x18000, 0x08000, CRC(4397c8a0) SHA1(deb9de1cf7ce6ddc69addf18ff5bf2f25ed11602) )
ROM_LOAD( "M-GF_A6.12A.27256.ROM1", 0x20000, 0x08000, CRC(b1fccecf) SHA1(8fb5e40f34596d9faa73255afc2c2635e9008954) )
ROM_LOAD( "M-GF_A7.13A.27256.ROM0", 0x28000, 0x08000, CRC(06075e41) SHA1(3426f4ede8449288519e25bc8a1d679bb5137279) )
-
+
ROM_REGION( 0x10000, "audiocpu", 0 ) // next to large module
ROM_LOAD( "M-GF_A10.12K.27256", 0x00000, 0x08000, CRC(d145b144) SHA1(52370d56106f0280c52266b5a727493a3396a8e3) )
@@ -765,7 +764,7 @@ ROM_START( mastrglf )
ROM_LOAD( "M-GF_A8.15A.27256", 0x00000, 0x08000, CRC(9ea9183b) SHA1(55f54575cd662b6194f69532baa25c9b2272760f) )
ROM_LOAD( "M-GF_A9.16A.27256", 0x08000, 0x08000, CRC(61ab715f) SHA1(6b9cccaa83a9a9e44a46bae796e2f9eaa9f9c951) )
- ROM_REGION( 0x0300, "proms", 0 )
+ ROM_REGION( 0x0300, "proms", 0 )
ROM_LOAD( "tbp24s10n.1", 0x0000, 0x0100, NO_DUMP )
ROM_LOAD( "tbp24s10n.2", 0x0100, 0x0100, NO_DUMP )
ROM_LOAD( "tbp24s10n.2", 0x0200, 0x0100, NO_DUMP )
diff --git a/src/mame/drivers/cybiko.cpp b/src/mame/drivers/cybiko.cpp
index a6abc4389f1..16501fbb581 100644
--- a/src/mame/drivers/cybiko.cpp
+++ b/src/mame/drivers/cybiko.cpp
@@ -60,7 +60,7 @@ ToDo:
static ADDRESS_MAP_START( cybikov1_mem, AS_PROGRAM, 16, cybiko_state )
AM_RANGE( 0x000000, 0x007fff ) AM_ROM
AM_RANGE( 0x600000, 0x600001 ) AM_READWRITE( cybiko_lcd_r, cybiko_lcd_w )
-// AM_RANGE( 0xe00000, 0xe07fff ) AM_READ( cybikov1_key_r )
+// AM_RANGE( 0xe00000, 0xe07fff ) AM_READ( cybikov1_key_r )
ADDRESS_MAP_END
/*
diff --git a/src/mame/drivers/dec0.cpp b/src/mame/drivers/dec0.cpp
index b78e1ca8b45..6e4e753b928 100644
--- a/src/mame/drivers/dec0.cpp
+++ b/src/mame/drivers/dec0.cpp
@@ -1303,7 +1303,7 @@ static MACHINE_CONFIG_START( dec0_base, dec0_state )
MCFG_DEVICE_ADD("spritegen", DECO_MXC06, 0)
MCFG_DECO_MXC06_GFX_REGION(3)
MCFG_DECO_MXC06_GFXDECODE("gfxdecode")
-
+
MCFG_GENERIC_LATCH_8_ADD("soundlatch")
MACHINE_CONFIG_END
diff --git a/src/mame/drivers/deco_ld.cpp b/src/mame/drivers/deco_ld.cpp
index 3765aa5230e..5c2c1a5a282 100644
--- a/src/mame/drivers/deco_ld.cpp
+++ b/src/mame/drivers/deco_ld.cpp
@@ -494,10 +494,10 @@ static MACHINE_CONFIG_START( rblaster, deco_ld_state )
/* sound hardware */
/* TODO: mixing */
MCFG_SPEAKER_STANDARD_STEREO("lspeaker", "rspeaker")
-
+
MCFG_GENERIC_LATCH_8_ADD("soundlatch")
MCFG_GENERIC_LATCH_8_ADD("soundlatch2")
-
+
MCFG_SOUND_ADD("ay1", AY8910, 1500000)
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "lspeaker", 0.25)
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "rspeaker", 0.25)
diff --git a/src/mame/drivers/fcscsi.cpp b/src/mame/drivers/fcscsi.cpp
index 2c3f696b341..ea7083a46e7 100644
--- a/src/mame/drivers/fcscsi.cpp
+++ b/src/mame/drivers/fcscsi.cpp
@@ -1,7 +1,7 @@
// license:BSD-3-Clause
// copyright-holders:Joakim Larsson Edstrom
/***************************************************************************
- * Interrupt scheme and dmac hookup shamelessly based on esq5505.cpp
+ * Interrupt scheme and dmac hookup shamelessly based on esq5505.cpp
*
* 11/04/2016
* Force SYS68K ISCSI-1 driver - This driver will be converted into a slot device once the VME bus driver exists.
@@ -15,7 +15,7 @@
* ----------------------------------------------------------
* 00 0000 - 00 0007 Initialisation vectors from system EPROM
* 00 0008 - 00 1FFF Local SRAM
- * 00 2000 - 01 FFFF Dynamic Dual Port RAM
+ * 00 2000 - 01 FFFF Dynamic Dual Port RAM
* C4 0000 - C4 001F SCSIbus controller
* C8 0000 - C8 00FF DMAC
* CC 0000 - CC 0007 FDC
@@ -160,7 +160,7 @@ READ16_MEMBER (fcscsi1_state::bootvect_r){
return m_sysrom [offset];
}
-/* The Control Register - descretelly implemented on the PCB
+/* The Control Register - descretelly implemented on the PCB
Bit #: 7 6 5 4 3 2 1 0
\ \ \ \ \ \ \ \ Floppy Disk Side Select
\ \ \ \ \ \ \ Floppy Disk Drive Select 0
@@ -169,7 +169,7 @@ Bit #: 7 6 5 4 3 2 1 0
\ \ \ \ Floppy Disk Drive Select 3
\ \ \ ISCSI-l I.D. Bit #0
\ \ ISCSI-l I.D. Bit #1
- \ ISCSI-l 1.D. Bit #2
+ \ ISCSI-l 1.D. Bit #2
*/
READ8_MEMBER (fcscsi1_state::tcr_r){
@@ -257,7 +257,7 @@ WRITE8_MEMBER (fcscsi1_state::not_implemented_w){
/*
----------------------------------------------------
- IRQ IRQ
+ IRQ IRQ
Level Source B4l inserted B4l removed (Def)
-----------------------------------------------------
1 P3 Pin #13 AV1 Autovector AV1 Autovector
@@ -265,10 +265,10 @@ Level Source B4l inserted B4l removed (Def)
3 SCSIBC AV3 Autovector AV3 Autovector
4 FDC AV4 Autovector AV4 Autovector
5 PI/T Timer PI/T Timer Vect PI/T Timer Vect
- 6 -- -- --
+ 6 -- -- --
7 PI/T Port PI/T Port Vect PI/T Port Vect
------------------------------------------------------
-Default configuration: B41 jumper removed
+Default configuration: B41 jumper removed
The PI/T port interrupt can be used under software control to
cause non-maskable (Level 7) interrupts if the watchdog timer
diff --git a/src/mame/drivers/gba.cpp b/src/mame/drivers/gba.cpp
index 64620d1f156..4a8cae101e5 100644
--- a/src/mame/drivers/gba.cpp
+++ b/src/mame/drivers/gba.cpp
@@ -2109,7 +2109,7 @@ void gba_state::machine_start()
m_maincpu->space(AS_PROGRAM).install_read_bank(0x08000000, 0x09ffffff, 0, 0, "rom1");
m_maincpu->space(AS_PROGRAM).install_read_bank(0x0a000000, 0x0bffffff, 0, 0, "rom2");
m_maincpu->space(AS_PROGRAM).install_read_bank(0x0c000000, 0x0cffffff, 0, 0, "rom3");
-
+
std::string region_tag;
memory_region *cart_rom = memregion(region_tag.assign(m_cart->tag()).append(GBASLOT_ROM_REGION_TAG).c_str());
@@ -2118,7 +2118,7 @@ void gba_state::machine_start()
membank("rom2")->set_base(cart_rom->base());
membank("rom3")->set_base(cart_rom->base());
-
+
// add nvram to save state
m_cart->save_nvram();
@@ -2151,7 +2151,7 @@ void gba_state::machine_start()
memory_region *cart_romhlp = memregion(region_tag.assign(m_cart->tag()).append(GBAHELP_ROM_REGION_TAG).c_str());
membank("rom1")->set_base(cart_romhlp->base());
}
-
+
}
save_item(NAME(m_DISPSTAT));
diff --git a/src/mame/drivers/goldstar.cpp b/src/mame/drivers/goldstar.cpp
index aed5c928dbe..508435f122a 100644
--- a/src/mame/drivers/goldstar.cpp
+++ b/src/mame/drivers/goldstar.cpp
@@ -887,16 +887,16 @@ static ADDRESS_MAP_START( flaming7_map, AS_PROGRAM, 8, goldstar_state )
AM_RANGE(0x9000, 0x97ff) AM_RAM_WRITE(goldstar_fg_atrram_w) AM_SHARE("fg_atrram")
AM_RANGE(0x9800, 0x99ff) AM_RAM_WRITE(goldstar_reel1_ram_w) AM_SHARE("reel1_ram")
-// AM_RANGE(0x9a00, 0x9fff) AM_RAM
+// AM_RANGE(0x9a00, 0x9fff) AM_RAM
AM_RANGE(0xa000, 0xa1ff) AM_RAM_WRITE(goldstar_reel2_ram_w) AM_SHARE("reel2_ram")
-// AM_RANGE(0xa200, 0xa7ff) AM_RAM
+// AM_RANGE(0xa200, 0xa7ff) AM_RAM
AM_RANGE(0xa800, 0xa9ff) AM_RAM_WRITE(goldstar_reel3_ram_w) AM_SHARE("reel3_ram")
-// AM_RANGE(0xaa00, 0xafff) AM_RAM
+// AM_RANGE(0xaa00, 0xafff) AM_RAM
-// AM_RANGE(0xb000, 0xb03f) AM_RAM
+// AM_RANGE(0xb000, 0xb03f) AM_RAM
AM_RANGE(0xb040, 0xb07f) AM_RAM AM_SHARE("reel1_scroll")
AM_RANGE(0xb080, 0xb0bf) AM_RAM AM_SHARE("reel2_scroll")
-// AM_RANGE(0xb0c0, 0xb0ff) AM_RAM
+// AM_RANGE(0xb0c0, 0xb0ff) AM_RAM
AM_RANGE(0xb100, 0xb17f) AM_RAM AM_SHARE("reel3_scroll")
AM_RANGE(0xb180, 0xb7ff) AM_RAM
@@ -908,12 +908,12 @@ static ADDRESS_MAP_START( flaming7_map, AS_PROGRAM, 8, goldstar_state )
AM_RANGE(0xb850, 0xb850) AM_WRITE(p1_lamps_w)
AM_RANGE(0xb860, 0xb860) AM_WRITE(p2_lamps_w)
AM_RANGE(0xb870, 0xb870) AM_DEVWRITE("snsnd", sn76489_device, write) /* sound */
-// AM_RANGE(0xc000, 0xd3ff) AM_RAM
+// AM_RANGE(0xc000, 0xd3ff) AM_RAM
AM_RANGE(0xf800, 0xffff) AM_RAM
ADDRESS_MAP_END
/*
W 9A00-B7FF FF
- RW B000-B7FF 00
+ RW B000-B7FF 00
*/
@@ -8179,7 +8179,7 @@ static MACHINE_CONFIG_DERIVED( flaming7, lucky8 )
/* basic machine hardware */
MCFG_CPU_MODIFY("maincpu")
MCFG_CPU_PROGRAM_MAP(flaming7_map)
-// MCFG_CPU_IO_MAP(flaming7_readport)
+// MCFG_CPU_IO_MAP(flaming7_readport)
MACHINE_CONFIG_END
@@ -10827,7 +10827,7 @@ ROM_END
/*
New Lucky 8 Lines / New Super 8 Lines (W-4, Witch Bonus)
-
+
CPUs
1x Z80 (11b) - 8-bit Microprocessor - main (missing).
3x iD8255A-5 (7b, 8b, 9b) - Programmable Peripheral Interface.
@@ -10836,7 +10836,7 @@ ROM_END
1x uPC1181 (0a) - Audio Amplifier - sound.
ROMs
- 4x AM27C64 (1-4) dumped.
+ 4x AM27C64 (1-4) dumped.
4x M27C256B (5-8) dumped.
3x AM27S21APC (1, 2, 3) dumped.
3x N82S123AN (4, 5) dumped.
@@ -10991,11 +10991,11 @@ ROM_END
Silkscreened: LUCKY97-1.
06/07/1993.
TAIWAN.
-
+
GFX ROMs 1, 2, 3, 4 are double size. Each half matches the set ns8lines.
GFX ROMs 5, 6, 7 match the ns8lines set.
- Program ROM is different.
+ Program ROM is different.
*/
ROM_START( ns8linesa )
ROM_REGION( 0x8000, "maincpu", 0 )
@@ -14072,7 +14072,7 @@ ROM_END
graphics sets in their respective order...
-------------------------------------------------------------------
-
+
Tech Notes:
PCB has some hacks...
diff --git a/src/mame/drivers/harddriv.cpp b/src/mame/drivers/harddriv.cpp
index d8212707109..983517a5acc 100644
--- a/src/mame/drivers/harddriv.cpp
+++ b/src/mame/drivers/harddriv.cpp
@@ -5010,7 +5010,7 @@ void harddriv_state::init_racedrivc_panorama_side()
// m_gsp->space(AS_PROGRAM).install_write_handler(0xfff76f60, 0xfff76f6f, write16_delegate(FUNC(harddriv_state::rdgsp_speedup1_w), this));
// m_gsp->space(AS_PROGRAM).install_read_handler(0xfff76f60, 0xfff76f6f, read16_delegate(FUNC(harddriv_state::rdgsp_speedup1_r), this));
// m_gsp_speedup_pc = 0xfff43a00;
-// m_gsp_speedup_addr[0] = (UINT16 *)(m_gsp_vram + ((0xfff76f60 - 0xffc00000) >> 3));
+// m_gsp_speedup_addr[0] = (UINT16 *)(m_gsp_vram + ((0xfff76f60 - 0xffc00000) >> 3));
/* set up adsp speedup handlers */
m_adsp->space(AS_DATA).install_read_handler(0x1fff, 0x1fff, read16_delegate(FUNC(harddriv_state::hdadsp_speedup_r), this));
diff --git a/src/mame/drivers/hh_tms1k.cpp b/src/mame/drivers/hh_tms1k.cpp
index d86910a77f8..16c189ca360 100644
--- a/src/mame/drivers/hh_tms1k.cpp
+++ b/src/mame/drivers/hh_tms1k.cpp
@@ -3626,7 +3626,7 @@ MACHINE_CONFIG_END
* TMS1000NLL MP3208 (die label 1000C, MP3208)
* SN75494N (acting as inverters), SN76477 sound
* 4 sliding buttons, light bulb
-
+
This is a 2-player electronic board game. It still needs game pieces like the
original Battleship board game.
@@ -3653,7 +3653,7 @@ WRITE16_MEMBER(bship_state::write_r)
{
// R0-R10: input mux
m_inp_mux = data;
-
+
// R4: 75494 to R12 33K to SN76477 pin 20
m_sn->slf_res_w((data & 0x10) ? RES_INF : RES_K(33));
}
@@ -3664,7 +3664,7 @@ WRITE16_MEMBER(bship_state::write_o)
// O0: SN76477 pin 9
m_sn->enable_w(data & 1);
-
+
// O1: 75494 to R4 100K to SN76477 pin 18
// O2: 75494 to R3 150K to SN76477 pin 18
double o12 = RES_INF;
@@ -3676,19 +3676,19 @@ WRITE16_MEMBER(bship_state::write_o)
case 3: o12 = RES_2_PARALLEL(RES_K(100), RES_K(150)); break;
}
m_sn->vco_res_w(o12);
-
+
// O2,O6: (TODO) to SN76477 pin 21
//m_sn->slf_cap_w(x);
-
+
// O4: SN76477 pin 22
m_sn->vco_w(data >> 4 & 1);
-
+
// O5: R11 27K to SN76477 pin 23
m_sn->one_shot_cap_w((data & 0x20) ? RES_K(27) : RES_INF);
-
+
// O6: SN76477 pin 25
m_sn->mixer_b_w(data >> 6 & 1);
-
+
// O7: 75494 to light bulb
display_matrix(1, 1, data >> 7 & 1, 1);
}
diff --git a/src/mame/drivers/hk68v10.cpp b/src/mame/drivers/hk68v10.cpp
index e3705319864..5dbdc0b8346 100644
--- a/src/mame/drivers/hk68v10.cpp
+++ b/src/mame/drivers/hk68v10.cpp
@@ -366,13 +366,13 @@ ROM_LOAD16_BYTE ("hk68kv10U12.bin", 0xFC0000, 0x2000, CRC (f2d688e9) SHA1 (e6869
* Setup sequence channel B
* 00
* 04 4C - x16 clock, 2 stop bits, no parity
- * 05 EA -
+ * 05 EA -
* 03 E1 - 8 bit, receiver enable, auto enable on
* 09 00 - no reset
- * 01 00
+ * 01 00
* 0B 56
- * 0C 0B - low baudrate divider
- * 0D 00 - hi baudrate divider
+ * 0C 0B - low baudrate divider
+ * 0D 00 - hi baudrate divider
* 0E 03 - Baud Rate Generator enabled, PCLK is source
*/
ROM_END
diff --git a/src/mame/drivers/hp9845.cpp b/src/mame/drivers/hp9845.cpp
index 2450f760099..748ea998ef3 100644
--- a/src/mame/drivers/hp9845.cpp
+++ b/src/mame/drivers/hp9845.cpp
@@ -104,9 +104,9 @@ public:
driver_device(mconfig, type, tag),
m_lpu(*this , "lpu"),
m_ppu(*this , "ppu"),
- m_screen(*this , "screen"),
+ m_screen(*this , "screen"),
m_palette(*this , "palette"),
- m_gv_timer(*this , "gv_timer"),
+ m_gv_timer(*this , "gv_timer"),
m_io_key0(*this , "KEY0"),
m_io_key1(*this , "KEY1"),
m_io_key2(*this , "KEY2"),
@@ -120,16 +120,16 @@ public:
virtual void machine_reset() override;
TIMER_DEVICE_CALLBACK_MEMBER(scanline_timer);
- TIMER_DEVICE_CALLBACK_MEMBER(gv_timer);
+ TIMER_DEVICE_CALLBACK_MEMBER(gv_timer);
void vblank_w(screen_device &screen, bool state);
- void set_graphic_mode(bool graphic);
+ void set_graphic_mode(bool graphic);
DECLARE_READ16_MEMBER(graphic_r);
DECLARE_WRITE16_MEMBER(graphic_w);
- attotime time_to_gv_mem_availability(void) const;
- void advance_gv_fsm(bool ds , bool trigger);
- void update_graphic_bits(void);
+ attotime time_to_gv_mem_availability(void) const;
+ void advance_gv_fsm(bool ds , bool trigger);
+ void update_graphic_bits(void);
IRQ_CALLBACK_MEMBER(irq_callback);
void update_irq(void);
@@ -148,9 +148,9 @@ public:
private:
required_device<hp_5061_3001_cpu_device> m_lpu;
required_device<hp_5061_3001_cpu_device> m_ppu;
- required_device<screen_device> m_screen;
+ required_device<screen_device> m_screen;
required_device<palette_device> m_palette;
- required_device<timer_device> m_gv_timer;
+ required_device<timer_device> m_gv_timer;
required_ioport m_io_key0;
required_ioport m_io_key1;
required_ioport m_io_key2;
@@ -160,7 +160,7 @@ private:
void set_video_mar(UINT16 mar);
void video_fill_buff(bool buff_idx);
void video_render_buff(unsigned video_scanline , unsigned line_in_row, bool buff_idx);
- void graphic_video_render(unsigned video_scanline);
+ void graphic_video_render(unsigned video_scanline);
// Character generator
const UINT8 *m_chargen;
@@ -176,41 +176,41 @@ private:
offs_t m_video_mar;
UINT16 m_video_word;
bool m_video_load_mar;
- bool m_video_first_mar;
+ bool m_video_first_mar;
bool m_video_byte_idx;
UINT8 m_video_attr;
bool m_video_buff_idx;
bool m_video_blanked;
video_buffer_t m_video_buff[ 2 ];
- // Graphic video
- typedef enum {
- GV_STAT_RESET,
- GV_STAT_WAIT_DS_0 = GV_STAT_RESET,
- GV_STAT_WAIT_TRIG_0,
- GV_STAT_WAIT_MEM_0,
- GV_STAT_WAIT_DS_1,
- GV_STAT_WAIT_DS_2,
- GV_STAT_WAIT_TRIG_1,
- GV_STAT_WAIT_MEM_1,
- GV_STAT_WAIT_MEM_2
- } gv_fsm_state_t;
-
- bool m_graphic_sel;
- gv_fsm_state_t m_gv_fsm_state;
- bool m_gv_int_en;
- bool m_gv_dma_en;
- bool m_gv_ready;
- UINT8 m_gv_cmd; // U65 (GC)
- UINT16 m_gv_data_w; // U29, U45, U28 & U44 (GC)
- UINT16 m_gv_data_r; // U59 & U60 (GC)
- UINT16 m_gv_io_counter; // U1, U2, U14 & U15 (GC)
- UINT16 m_gv_cursor_w; // U38 & U39 (GS)
- UINT16 m_gv_cursor_x; // U31 & U23 (GS)
- UINT16 m_gv_cursor_y; // U15 & U8 (GS)
- bool m_gv_cursor_gc; // U8 (GS)
- bool m_gv_cursor_fs; // U8 (GS)
- std::vector<UINT16> m_graphic_mem;
+ // Graphic video
+ typedef enum {
+ GV_STAT_RESET,
+ GV_STAT_WAIT_DS_0 = GV_STAT_RESET,
+ GV_STAT_WAIT_TRIG_0,
+ GV_STAT_WAIT_MEM_0,
+ GV_STAT_WAIT_DS_1,
+ GV_STAT_WAIT_DS_2,
+ GV_STAT_WAIT_TRIG_1,
+ GV_STAT_WAIT_MEM_1,
+ GV_STAT_WAIT_MEM_2
+ } gv_fsm_state_t;
+
+ bool m_graphic_sel;
+ gv_fsm_state_t m_gv_fsm_state;
+ bool m_gv_int_en;
+ bool m_gv_dma_en;
+ bool m_gv_ready;
+ UINT8 m_gv_cmd; // U65 (GC)
+ UINT16 m_gv_data_w; // U29, U45, U28 & U44 (GC)
+ UINT16 m_gv_data_r; // U59 & U60 (GC)
+ UINT16 m_gv_io_counter; // U1, U2, U14 & U15 (GC)
+ UINT16 m_gv_cursor_w; // U38 & U39 (GS)
+ UINT16 m_gv_cursor_x; // U31 & U23 (GS)
+ UINT16 m_gv_cursor_y; // U15 & U8 (GS)
+ bool m_gv_cursor_gc; // U8 (GS)
+ bool m_gv_cursor_fs; // U8 (GS)
+ std::vector<UINT16> m_graphic_mem;
// Interrupt handling
UINT8 m_irl_pending;
@@ -373,11 +373,11 @@ UINT32 hp9845_state::screen_update(screen_device &screen, bitmap_rgb32 &bitmap,
UINT32 hp9845b_state::screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect)
{
- if (m_graphic_sel) {
- copybitmap(bitmap, m_bitmap, 0, 0, GVIDEO_HBEND, GVIDEO_VBEND, cliprect);
- } else {
- copybitmap(bitmap, m_bitmap, 0, 0, 0, 0, cliprect);
- }
+ if (m_graphic_sel) {
+ copybitmap(bitmap, m_bitmap, 0, 0, GVIDEO_HBEND, GVIDEO_VBEND, cliprect);
+ } else {
+ copybitmap(bitmap, m_bitmap, 0, 0, 0, 0, cliprect);
+ }
return 0;
}
@@ -388,7 +388,7 @@ void hp9845b_state::machine_start()
m_chargen = memregion("chargen")->base();
- m_graphic_mem.resize(GVIDEO_MEM_SIZE);
+ m_graphic_mem.resize(GVIDEO_MEM_SIZE);
}
void hp9845b_state::machine_reset()
@@ -399,16 +399,16 @@ void hp9845b_state::machine_reset()
// Some sensible defaults
m_video_mar = VIDEO_BUFFER_BASE;
m_video_load_mar = false;
- m_video_first_mar = false;
+ m_video_first_mar = false;
m_video_byte_idx = false;
m_video_attr = 0;
m_video_buff_idx = false;
m_video_blanked = false;
- m_graphic_sel = false;
- m_gv_fsm_state = GV_STAT_RESET;
- m_gv_int_en = false;
- m_gv_dma_en = false;
- m_gv_ready = true;
+ m_graphic_sel = false;
+ m_gv_fsm_state = GV_STAT_RESET;
+ m_gv_int_en = false;
+ m_gv_dma_en = false;
+ m_gv_ready = true;
m_irl_pending = 0;
m_irh_pending = 0;
@@ -441,10 +441,10 @@ void hp9845b_state::video_fill_buff(bool buff_idx)
m_video_word = prog_space.read_word(m_video_mar << 1);
if (m_video_load_mar) {
// Load new address into MAR after start of a new frame or NWA instruction
- if (m_video_first_mar) {
- set_graphic_mode(!BIT(m_video_word , 15));
- m_video_first_mar = false;
- }
+ if (m_video_first_mar) {
+ set_graphic_mode(!BIT(m_video_word , 15));
+ m_video_first_mar = false;
+ }
set_video_mar(~m_video_word);
m_video_load_mar = false;
continue;
@@ -492,17 +492,17 @@ void hp9845b_state::video_render_buff(unsigned video_scanline , unsigned line_in
m_video_blanked = true;
}
- const pen_t *pen = m_palette->pens();
+ const pen_t *pen = m_palette->pens();
if (m_video_blanked) {
- // Blank scanline
- for (unsigned i = 0; i < VIDEO_HBSTART; i++) {
- m_bitmap.pix32(video_scanline , i) = pen[ 0 ];
- }
+ // Blank scanline
+ for (unsigned i = 0; i < VIDEO_HBSTART; i++) {
+ m_bitmap.pix32(video_scanline , i) = pen[ 0 ];
+ }
} else {
bool cursor_line = line_in_row == 12;
bool ul_line = line_in_row == 14;
- unsigned video_frame = (unsigned)m_screen->frame_number();
+ unsigned video_frame = (unsigned)m_screen->frame_number();
bool cursor_blink = BIT(video_frame , 3);
bool char_blink = BIT(video_frame , 4);
@@ -539,375 +539,375 @@ void hp9845b_state::video_render_buff(unsigned video_scanline , unsigned line_in
TIMER_DEVICE_CALLBACK_MEMBER(hp9845b_state::scanline_timer)
{
- unsigned video_scanline = param;
-
- if (m_graphic_sel) {
- if (video_scanline >= GVIDEO_VBEND && video_scanline < GVIDEO_VBSTART) {
- graphic_video_render(video_scanline);
- }
- } else if (video_scanline < VIDEO_ACTIVE_SCANLINES) {
- unsigned row = video_scanline / VIDEO_CHAR_HEIGHT;
- unsigned line_in_row = video_scanline - row * VIDEO_CHAR_HEIGHT;
-
- if (line_in_row == 0) {
- // Start of new row, swap buffers
- m_video_buff_idx = !m_video_buff_idx;
- video_fill_buff(!m_video_buff_idx);
- }
-
- video_render_buff(video_scanline , line_in_row , m_video_buff_idx);
- }
+ unsigned video_scanline = param;
+
+ if (m_graphic_sel) {
+ if (video_scanline >= GVIDEO_VBEND && video_scanline < GVIDEO_VBSTART) {
+ graphic_video_render(video_scanline);
+ }
+ } else if (video_scanline < VIDEO_ACTIVE_SCANLINES) {
+ unsigned row = video_scanline / VIDEO_CHAR_HEIGHT;
+ unsigned line_in_row = video_scanline - row * VIDEO_CHAR_HEIGHT;
+
+ if (line_in_row == 0) {
+ // Start of new row, swap buffers
+ m_video_buff_idx = !m_video_buff_idx;
+ video_fill_buff(!m_video_buff_idx);
+ }
+
+ video_render_buff(video_scanline , line_in_row , m_video_buff_idx);
+ }
}
TIMER_DEVICE_CALLBACK_MEMBER(hp9845b_state::gv_timer)
{
- advance_gv_fsm(false , false);
+ advance_gv_fsm(false , false);
}
void hp9845b_state::vblank_w(screen_device &screen, bool state)
{
- // VBlank signal is fed into HALT flag of PPU
- m_ppu->halt_w(state);
-
- if (state) {
- // Start of V blank
- set_video_mar(0);
- m_video_load_mar = true;
- m_video_first_mar = true;
- m_video_byte_idx = false;
- m_video_blanked = false;
- m_video_buff_idx = !m_video_buff_idx;
- video_fill_buff(!m_video_buff_idx);
- }
+ // VBlank signal is fed into HALT flag of PPU
+ m_ppu->halt_w(state);
+
+ if (state) {
+ // Start of V blank
+ set_video_mar(0);
+ m_video_load_mar = true;
+ m_video_first_mar = true;
+ m_video_byte_idx = false;
+ m_video_blanked = false;
+ m_video_buff_idx = !m_video_buff_idx;
+ video_fill_buff(!m_video_buff_idx);
+ }
}
void hp9845b_state::set_graphic_mode(bool graphic)
{
- if (graphic != m_graphic_sel) {
- m_graphic_sel = graphic;
- logerror("GS=%d\n" , graphic);
- if (m_graphic_sel) {
- m_screen->configure(GVIDEO_HTOTAL , GVIDEO_VTOTAL , rectangle(GVIDEO_HBEND , GVIDEO_HBSTART - 1 , GVIDEO_VBEND , GVIDEO_VBSTART - 1) , HZ_TO_ATTOSECONDS(VIDEO_PIXEL_CLOCK) * GVIDEO_HTOTAL * GVIDEO_VTOTAL);
- } else {
- m_screen->configure(VIDEO_HTOTAL , VIDEO_VTOTAL , rectangle(0 , VIDEO_HBSTART - 1 , 0 , VIDEO_ACTIVE_SCANLINES - 1) , HZ_TO_ATTOSECONDS(VIDEO_PIXEL_CLOCK) * VIDEO_HTOTAL * VIDEO_VTOTAL);
- }
- }
+ if (graphic != m_graphic_sel) {
+ m_graphic_sel = graphic;
+ logerror("GS=%d\n" , graphic);
+ if (m_graphic_sel) {
+ m_screen->configure(GVIDEO_HTOTAL , GVIDEO_VTOTAL , rectangle(GVIDEO_HBEND , GVIDEO_HBSTART - 1 , GVIDEO_VBEND , GVIDEO_VBSTART - 1) , HZ_TO_ATTOSECONDS(VIDEO_PIXEL_CLOCK) * GVIDEO_HTOTAL * GVIDEO_VTOTAL);
+ } else {
+ m_screen->configure(VIDEO_HTOTAL , VIDEO_VTOTAL , rectangle(0 , VIDEO_HBSTART - 1 , 0 , VIDEO_ACTIVE_SCANLINES - 1) , HZ_TO_ATTOSECONDS(VIDEO_PIXEL_CLOCK) * VIDEO_HTOTAL * VIDEO_VTOTAL);
+ }
+ }
}
READ16_MEMBER(hp9845b_state::graphic_r)
{
- UINT16 res = 0;
-
- switch (offset) {
- case 0:
- // R4: data register
- res = m_gv_data_r;
- advance_gv_fsm(true , false);
- break;
-
- case 1:
- // R5: status register
- if (m_gv_int_en) {
- BIT_SET(res, 7);
- }
- if (m_gv_dma_en) {
- BIT_SET(res, 6);
- }
- BIT_SET(res, 5);
- break;
-
- case 2:
- // R6: data register with DMA TC
- m_gv_dma_en = false;
- res = m_gv_data_r;
- advance_gv_fsm(true , false);
- break;
-
- case 3:
- // R7: not mapped
- break;
- }
-
- //logerror("rd gv R%u = %04x\n", 4 + offset , res);
-
- return res;
+ UINT16 res = 0;
+
+ switch (offset) {
+ case 0:
+ // R4: data register
+ res = m_gv_data_r;
+ advance_gv_fsm(true , false);
+ break;
+
+ case 1:
+ // R5: status register
+ if (m_gv_int_en) {
+ BIT_SET(res, 7);
+ }
+ if (m_gv_dma_en) {
+ BIT_SET(res, 6);
+ }
+ BIT_SET(res, 5);
+ break;
+
+ case 2:
+ // R6: data register with DMA TC
+ m_gv_dma_en = false;
+ res = m_gv_data_r;
+ advance_gv_fsm(true , false);
+ break;
+
+ case 3:
+ // R7: not mapped
+ break;
+ }
+
+ //logerror("rd gv R%u = %04x\n", 4 + offset , res);
+
+ return res;
}
WRITE16_MEMBER(hp9845b_state::graphic_w)
{
- //logerror("wr gv R%u = %04x\n", 4 + offset , data);
-
- switch (offset) {
- case 0:
- // R4: data register
- m_gv_data_w = data;
- m_gv_cursor_w = data;
- advance_gv_fsm(true , false);
- break;
-
- case 1:
- // R5: command register
- m_gv_cmd = (UINT8)(data & 0xf);
- if (BIT(data , 5)) {
- m_gv_fsm_state = GV_STAT_RESET;
- }
- m_gv_dma_en = BIT(data , 6) != 0;
- m_gv_int_en = BIT(data , 7) != 0;
- advance_gv_fsm(false , false);
- break;
-
- case 2:
- // R6: data register with DMA TC
- m_gv_dma_en = false;
- m_gv_data_w = data;
- m_gv_cursor_w = data;
- advance_gv_fsm(true , false);
- break;
-
- case 3:
- // R7: trigger
- advance_gv_fsm(false , true);
- break;
- }
+ //logerror("wr gv R%u = %04x\n", 4 + offset , data);
+
+ switch (offset) {
+ case 0:
+ // R4: data register
+ m_gv_data_w = data;
+ m_gv_cursor_w = data;
+ advance_gv_fsm(true , false);
+ break;
+
+ case 1:
+ // R5: command register
+ m_gv_cmd = (UINT8)(data & 0xf);
+ if (BIT(data , 5)) {
+ m_gv_fsm_state = GV_STAT_RESET;
+ }
+ m_gv_dma_en = BIT(data , 6) != 0;
+ m_gv_int_en = BIT(data , 7) != 0;
+ advance_gv_fsm(false , false);
+ break;
+
+ case 2:
+ // R6: data register with DMA TC
+ m_gv_dma_en = false;
+ m_gv_data_w = data;
+ m_gv_cursor_w = data;
+ advance_gv_fsm(true , false);
+ break;
+
+ case 3:
+ // R7: trigger
+ advance_gv_fsm(false , true);
+ break;
+ }
}
attotime hp9845b_state::time_to_gv_mem_availability(void) const
{
- if (m_graphic_sel) {
- int hpos = m_screen->hpos();
- if (hpos < (34 - GVIDEO_HCNT_OFF) || hpos >= (628 - GVIDEO_HCNT_OFF)) {
- // Access to graphic memory available now
- return attotime::zero;
- } else {
- // Wait until start of hblank
- return m_screen->time_until_pos(m_screen->vpos() , 628);
- }
- } else {
- // TODO:
- return attotime::zero;
- }
+ if (m_graphic_sel) {
+ int hpos = m_screen->hpos();
+ if (hpos < (34 - GVIDEO_HCNT_OFF) || hpos >= (628 - GVIDEO_HCNT_OFF)) {
+ // Access to graphic memory available now
+ return attotime::zero;
+ } else {
+ // Wait until start of hblank
+ return m_screen->time_until_pos(m_screen->vpos() , 628);
+ }
+ } else {
+ // TODO:
+ return attotime::zero;
+ }
}
void hp9845b_state::advance_gv_fsm(bool ds , bool trigger)
{
- bool get_out = false;
-
- attotime time_mem_av;
-
- do {
- bool act_trig = trigger || m_gv_dma_en || !BIT(m_gv_cmd , 2);
-
- switch (m_gv_fsm_state) {
- case GV_STAT_WAIT_DS_0:
- if ((m_gv_cmd & 0xc) == 0xc) {
- // Read command (11xx)
- m_gv_fsm_state = GV_STAT_WAIT_MEM_0;
- } else if (ds) {
- // Wait for data strobe (r/w on r4 or r6)
- m_gv_fsm_state = GV_STAT_WAIT_TRIG_0;
- } else {
- get_out = true;
- }
- break;
-
- case GV_STAT_WAIT_TRIG_0:
- // Wait for trigger
- if (act_trig) {
- if (BIT(m_gv_cmd , 3)) {
- // Not a cursor command
- // Load memory address
- m_gv_io_counter = ~m_gv_data_w & GVIDEO_ADDR_MASK;
- // Write commands (10xx)
- m_gv_fsm_state = GV_STAT_WAIT_DS_2;
- } else {
- // Cursor command (0xxx)
- if (BIT(m_gv_cmd , 2)) {
- // Write X cursor position (01xx)
- m_gv_cursor_x = (~m_gv_cursor_w >> 6) & 0x3ff;
- //logerror("gv x curs pos = %u\n" , m_gv_cursor_x);
- } else {
- // Write Y cursor position and type (00xx)
- m_gv_cursor_y = (~m_gv_cursor_w >> 6) & 0x1ff;
- m_gv_cursor_gc = BIT(m_gv_cmd , 1) == 0;
- m_gv_cursor_fs = BIT(m_gv_cmd , 0) != 0;
- //logerror("gv y curs pos = %u gc = %d fs = %d\n" , m_gv_cursor_y , m_gv_cursor_gc , m_gv_cursor_fs);
- }
- m_gv_fsm_state = GV_STAT_WAIT_DS_0;
- }
- } else {
- get_out = true;
- }
- break;
-
- case GV_STAT_WAIT_MEM_0:
- time_mem_av = time_to_gv_mem_availability();
- if (time_mem_av.is_zero()) {
- // Read a word from graphic memory
- m_gv_data_r = m_graphic_mem[ m_gv_io_counter ];
- //logerror("rd gv mem @%04x = %04x\n" , m_gv_io_counter , m_gv_data_r);
- m_gv_io_counter = (m_gv_io_counter + 1) & GVIDEO_ADDR_MASK;
- m_gv_fsm_state = GV_STAT_WAIT_DS_1;
- } else {
- m_gv_timer->adjust(time_mem_av);
- get_out = true;
- }
- break;
-
- case GV_STAT_WAIT_DS_1:
- if (ds) {
- m_gv_fsm_state = GV_STAT_WAIT_MEM_0;
- } else {
- get_out = true;
- }
- break;
-
- case GV_STAT_WAIT_DS_2:
- // Wait for data word to be written
- if (ds) {
- m_gv_fsm_state = GV_STAT_WAIT_TRIG_1;
- } else {
- get_out = true;
- }
- break;
-
- case GV_STAT_WAIT_TRIG_1:
- // Wait for trigger
- if (act_trig) {
- if (BIT(m_gv_cmd , 1)) {
- // Clear words (101x)
- m_gv_data_w = 0;
- m_gv_fsm_state = GV_STAT_WAIT_MEM_1;
- } else if (BIT(m_gv_cmd , 0)) {
- // Write a single pixel (1001)
- m_gv_fsm_state = GV_STAT_WAIT_MEM_2;
- } else {
- // Write words (1000)
- m_gv_fsm_state = GV_STAT_WAIT_MEM_1;
- }
- } else {
- get_out = true;
- }
- break;
-
- case GV_STAT_WAIT_MEM_1:
- time_mem_av = time_to_gv_mem_availability();
- if (time_mem_av.is_zero()) {
- // Write a full word to graphic memory
- //logerror("wr gv mem @%04x = %04x\n" , m_gv_io_counter , m_gv_data_w);
- m_graphic_mem[ m_gv_io_counter ] = m_gv_data_w;
- m_gv_io_counter = (m_gv_io_counter + 1) & GVIDEO_ADDR_MASK;
- m_gv_fsm_state = GV_STAT_WAIT_DS_2;
- } else {
- m_gv_timer->adjust(time_mem_av);
- get_out = true;
- }
- break;
-
- case GV_STAT_WAIT_MEM_2:
- time_mem_av = time_to_gv_mem_availability();
- if (time_mem_av.is_zero()) {
- // Write a single pixel to graphic memory
- //logerror("wr gv pixel @%04x:%x = %d\n" , m_gv_io_counter , m_gv_data_w & 0xf , BIT(m_gv_data_w , 15));
- UINT16 mask = 0x8000 >> (m_gv_data_w & 0xf);
- if (BIT(m_gv_data_w , 15)) {
- // Set pixel
- m_graphic_mem[ m_gv_io_counter ] |= mask;
- } else {
- // Clear pixel
- m_graphic_mem[ m_gv_io_counter ] &= ~mask;
- }
- // Not really needed
- m_gv_io_counter = (m_gv_io_counter + 1) & GVIDEO_ADDR_MASK;
- m_gv_fsm_state = GV_STAT_WAIT_DS_0;
- } else {
- m_gv_timer->adjust(time_mem_av);
- get_out = true;
- }
- break;
-
- default:
- logerror("Invalid state reached %d\n" , m_gv_fsm_state);
- m_gv_fsm_state = GV_STAT_RESET;
- }
-
- ds = false;
- trigger = false;
- } while (!get_out);
-
- update_graphic_bits();
+ bool get_out = false;
+
+ attotime time_mem_av;
+
+ do {
+ bool act_trig = trigger || m_gv_dma_en || !BIT(m_gv_cmd , 2);
+
+ switch (m_gv_fsm_state) {
+ case GV_STAT_WAIT_DS_0:
+ if ((m_gv_cmd & 0xc) == 0xc) {
+ // Read command (11xx)
+ m_gv_fsm_state = GV_STAT_WAIT_MEM_0;
+ } else if (ds) {
+ // Wait for data strobe (r/w on r4 or r6)
+ m_gv_fsm_state = GV_STAT_WAIT_TRIG_0;
+ } else {
+ get_out = true;
+ }
+ break;
+
+ case GV_STAT_WAIT_TRIG_0:
+ // Wait for trigger
+ if (act_trig) {
+ if (BIT(m_gv_cmd , 3)) {
+ // Not a cursor command
+ // Load memory address
+ m_gv_io_counter = ~m_gv_data_w & GVIDEO_ADDR_MASK;
+ // Write commands (10xx)
+ m_gv_fsm_state = GV_STAT_WAIT_DS_2;
+ } else {
+ // Cursor command (0xxx)
+ if (BIT(m_gv_cmd , 2)) {
+ // Write X cursor position (01xx)
+ m_gv_cursor_x = (~m_gv_cursor_w >> 6) & 0x3ff;
+ //logerror("gv x curs pos = %u\n" , m_gv_cursor_x);
+ } else {
+ // Write Y cursor position and type (00xx)
+ m_gv_cursor_y = (~m_gv_cursor_w >> 6) & 0x1ff;
+ m_gv_cursor_gc = BIT(m_gv_cmd , 1) == 0;
+ m_gv_cursor_fs = BIT(m_gv_cmd , 0) != 0;
+ //logerror("gv y curs pos = %u gc = %d fs = %d\n" , m_gv_cursor_y , m_gv_cursor_gc , m_gv_cursor_fs);
+ }
+ m_gv_fsm_state = GV_STAT_WAIT_DS_0;
+ }
+ } else {
+ get_out = true;
+ }
+ break;
+
+ case GV_STAT_WAIT_MEM_0:
+ time_mem_av = time_to_gv_mem_availability();
+ if (time_mem_av.is_zero()) {
+ // Read a word from graphic memory
+ m_gv_data_r = m_graphic_mem[ m_gv_io_counter ];
+ //logerror("rd gv mem @%04x = %04x\n" , m_gv_io_counter , m_gv_data_r);
+ m_gv_io_counter = (m_gv_io_counter + 1) & GVIDEO_ADDR_MASK;
+ m_gv_fsm_state = GV_STAT_WAIT_DS_1;
+ } else {
+ m_gv_timer->adjust(time_mem_av);
+ get_out = true;
+ }
+ break;
+
+ case GV_STAT_WAIT_DS_1:
+ if (ds) {
+ m_gv_fsm_state = GV_STAT_WAIT_MEM_0;
+ } else {
+ get_out = true;
+ }
+ break;
+
+ case GV_STAT_WAIT_DS_2:
+ // Wait for data word to be written
+ if (ds) {
+ m_gv_fsm_state = GV_STAT_WAIT_TRIG_1;
+ } else {
+ get_out = true;
+ }
+ break;
+
+ case GV_STAT_WAIT_TRIG_1:
+ // Wait for trigger
+ if (act_trig) {
+ if (BIT(m_gv_cmd , 1)) {
+ // Clear words (101x)
+ m_gv_data_w = 0;
+ m_gv_fsm_state = GV_STAT_WAIT_MEM_1;
+ } else if (BIT(m_gv_cmd , 0)) {
+ // Write a single pixel (1001)
+ m_gv_fsm_state = GV_STAT_WAIT_MEM_2;
+ } else {
+ // Write words (1000)
+ m_gv_fsm_state = GV_STAT_WAIT_MEM_1;
+ }
+ } else {
+ get_out = true;
+ }
+ break;
+
+ case GV_STAT_WAIT_MEM_1:
+ time_mem_av = time_to_gv_mem_availability();
+ if (time_mem_av.is_zero()) {
+ // Write a full word to graphic memory
+ //logerror("wr gv mem @%04x = %04x\n" , m_gv_io_counter , m_gv_data_w);
+ m_graphic_mem[ m_gv_io_counter ] = m_gv_data_w;
+ m_gv_io_counter = (m_gv_io_counter + 1) & GVIDEO_ADDR_MASK;
+ m_gv_fsm_state = GV_STAT_WAIT_DS_2;
+ } else {
+ m_gv_timer->adjust(time_mem_av);
+ get_out = true;
+ }
+ break;
+
+ case GV_STAT_WAIT_MEM_2:
+ time_mem_av = time_to_gv_mem_availability();
+ if (time_mem_av.is_zero()) {
+ // Write a single pixel to graphic memory
+ //logerror("wr gv pixel @%04x:%x = %d\n" , m_gv_io_counter , m_gv_data_w & 0xf , BIT(m_gv_data_w , 15));
+ UINT16 mask = 0x8000 >> (m_gv_data_w & 0xf);
+ if (BIT(m_gv_data_w , 15)) {
+ // Set pixel
+ m_graphic_mem[ m_gv_io_counter ] |= mask;
+ } else {
+ // Clear pixel
+ m_graphic_mem[ m_gv_io_counter ] &= ~mask;
+ }
+ // Not really needed
+ m_gv_io_counter = (m_gv_io_counter + 1) & GVIDEO_ADDR_MASK;
+ m_gv_fsm_state = GV_STAT_WAIT_DS_0;
+ } else {
+ m_gv_timer->adjust(time_mem_av);
+ get_out = true;
+ }
+ break;
+
+ default:
+ logerror("Invalid state reached %d\n" , m_gv_fsm_state);
+ m_gv_fsm_state = GV_STAT_RESET;
+ }
+
+ ds = false;
+ trigger = false;
+ } while (!get_out);
+
+ update_graphic_bits();
}
void hp9845b_state::update_graphic_bits(void)
{
- m_gv_ready = m_gv_fsm_state == GV_STAT_WAIT_DS_0 ||
- m_gv_fsm_state == GV_STAT_WAIT_DS_1 ||
- m_gv_fsm_state == GV_STAT_WAIT_DS_2;
+ m_gv_ready = m_gv_fsm_state == GV_STAT_WAIT_DS_0 ||
+ m_gv_fsm_state == GV_STAT_WAIT_DS_1 ||
+ m_gv_fsm_state == GV_STAT_WAIT_DS_2;
- bool irq = m_gv_int_en && !m_gv_dma_en && m_gv_ready;
+ bool irq = m_gv_int_en && !m_gv_dma_en && m_gv_ready;
- if (irq) {
- BIT_SET(m_irh_pending, GVIDEO_PA - 8);
- } else {
- BIT_CLR(m_irh_pending, GVIDEO_PA - 8);
- }
+ if (irq) {
+ BIT_SET(m_irh_pending, GVIDEO_PA - 8);
+ } else {
+ BIT_CLR(m_irh_pending, GVIDEO_PA - 8);
+ }
- update_irq();
+ update_irq();
- bool dmar = m_gv_ready && m_gv_dma_en;
+ bool dmar = m_gv_ready && m_gv_dma_en;
- m_ppu->dmar_w(dmar);
+ m_ppu->dmar_w(dmar);
- if (m_ppu->pa_r() == GVIDEO_PA) {
- m_ppu->flag_w(m_gv_ready);
- }
+ if (m_ppu->pa_r() == GVIDEO_PA) {
+ m_ppu->flag_w(m_gv_ready);
+ }
}
void hp9845b_state::graphic_video_render(unsigned video_scanline)
{
- const pen_t *pen = m_palette->pens();
- bool yc = (video_scanline + GVIDEO_VCNT_OFF) == (m_gv_cursor_y + 6);
- bool yw;
- bool blink;
-
- if (m_gv_cursor_fs) {
- yw = true;
- // Steady cursor
- blink = true;
- } else {
- yw = (video_scanline + GVIDEO_VCNT_OFF) >= (m_gv_cursor_y + 2) &&
- (video_scanline + GVIDEO_VCNT_OFF) <= (m_gv_cursor_y + 10);
- // Blinking cursor (frame freq. / 16)
- blink = BIT(m_screen->frame_number() , 3) != 0;
- }
-
- unsigned mem_idx = 36 * (video_scanline - GVIDEO_VBEND);
- for (unsigned i = 0; i < GVIDEO_HPIXELS; i += 16) {
- UINT16 word = m_graphic_mem[ mem_idx++ ];
- unsigned x = i;
- for (UINT16 mask = 0x8000; mask != 0; mask >>= 1) {
- unsigned cnt_h = x + GVIDEO_HBEND + GVIDEO_HCNT_OFF;
- bool xc = cnt_h == (m_gv_cursor_x + 6);
- bool xw = m_gv_cursor_fs || (cnt_h >= (m_gv_cursor_x + 2) && cnt_h <= (m_gv_cursor_x + 10));
- unsigned pixel;
- if (blink && ((xw && yc) || (yw && xc && m_gv_cursor_gc))) {
- // Cursor
- pixel = 2;
- } else {
- // Normal pixel
- pixel = (word & mask) != 0;
- }
- m_bitmap.pix32(video_scanline - GVIDEO_VBEND , x++) = pen[ pixel ];
- }
- }
+ const pen_t *pen = m_palette->pens();
+ bool yc = (video_scanline + GVIDEO_VCNT_OFF) == (m_gv_cursor_y + 6);
+ bool yw;
+ bool blink;
+
+ if (m_gv_cursor_fs) {
+ yw = true;
+ // Steady cursor
+ blink = true;
+ } else {
+ yw = (video_scanline + GVIDEO_VCNT_OFF) >= (m_gv_cursor_y + 2) &&
+ (video_scanline + GVIDEO_VCNT_OFF) <= (m_gv_cursor_y + 10);
+ // Blinking cursor (frame freq. / 16)
+ blink = BIT(m_screen->frame_number() , 3) != 0;
+ }
+
+ unsigned mem_idx = 36 * (video_scanline - GVIDEO_VBEND);
+ for (unsigned i = 0; i < GVIDEO_HPIXELS; i += 16) {
+ UINT16 word = m_graphic_mem[ mem_idx++ ];
+ unsigned x = i;
+ for (UINT16 mask = 0x8000; mask != 0; mask >>= 1) {
+ unsigned cnt_h = x + GVIDEO_HBEND + GVIDEO_HCNT_OFF;
+ bool xc = cnt_h == (m_gv_cursor_x + 6);
+ bool xw = m_gv_cursor_fs || (cnt_h >= (m_gv_cursor_x + 2) && cnt_h <= (m_gv_cursor_x + 10));
+ unsigned pixel;
+ if (blink && ((xw && yc) || (yw && xc && m_gv_cursor_gc))) {
+ // Cursor
+ pixel = 2;
+ } else {
+ // Normal pixel
+ pixel = (word & mask) != 0;
+ }
+ m_bitmap.pix32(video_scanline - GVIDEO_VBEND , x++) = pen[ pixel ];
+ }
+ }
}
IRQ_CALLBACK_MEMBER(hp9845b_state::irq_callback)
{
if (irqline == HPHYBRID_IRL) {
- logerror("irq ack L %02x\n" , m_irl_pending);
+ logerror("irq ack L %02x\n" , m_irl_pending);
return m_irl_pending;
} else {
- logerror("irq ack H %02x\n" , m_irh_pending);
+ logerror("irq ack H %02x\n" , m_irh_pending);
return m_irh_pending;
}
}
@@ -1013,10 +1013,10 @@ WRITE8_MEMBER(hp9845b_state::pa_w)
// RHS tape drive (T15)
m_ppu->status_w(m_t15->sts_r());
m_ppu->flag_w(m_t15->flg_r());
- } else if (data == GVIDEO_PA) {
- // Graphic video
- m_ppu->status_w(1);
- m_ppu->flag_w(m_gv_ready);
+ } else if (data == GVIDEO_PA) {
+ // Graphic video
+ m_ppu->status_w(1);
+ m_ppu->flag_w(m_gv_ready);
} else {
m_ppu->status_w(0);
m_ppu->flag_w(0);
@@ -1035,14 +1035,14 @@ WRITE_LINE_MEMBER(hp9845b_state::t15_irq_w)
WRITE_LINE_MEMBER(hp9845b_state::t15_flg_w)
{
- if (m_ppu->pa_r() == T15_PA) {
+ if (m_ppu->pa_r() == T15_PA) {
m_ppu->flag_w(state);
}
}
WRITE_LINE_MEMBER(hp9845b_state::t15_sts_w)
{
- if (m_ppu->pa_r() == T15_PA) {
+ if (m_ppu->pa_r() == T15_PA) {
m_ppu->status_w(state);
}
}
@@ -1082,9 +1082,9 @@ static ADDRESS_MAP_START(global_mem_map , AS_PROGRAM , 16 , hp9845b_state)
ADDRESS_MAP_UNMAP_LOW
AM_RANGE(0x000000 , 0x007fff) AM_RAM AM_SHARE("lpu_ram")
AM_RANGE(0x014000 , 0x017fff) AM_RAM AM_SHARE("ppu_ram")
- AM_RANGE(0x020000 , 0x027fff) AM_RAM AM_SHARE("lpu_02_ram")
+ AM_RANGE(0x020000 , 0x027fff) AM_RAM AM_SHARE("lpu_02_ram")
AM_RANGE(0x030000 , 0x037fff) AM_ROM AM_REGION("lpu" , 0)
- AM_RANGE(0x040000 , 0x047fff) AM_RAM AM_SHARE("lpu_04_ram")
+ AM_RANGE(0x040000 , 0x047fff) AM_RAM AM_SHARE("lpu_04_ram")
AM_RANGE(0x050000 , 0x057fff) AM_ROM AM_REGION("ppu" , 0)
ADDRESS_MAP_END
@@ -1096,9 +1096,9 @@ static ADDRESS_MAP_START(ppu_io_map , AS_IO , 16 , hp9845b_state)
// PA = 0, IC = 3
// Keyboard status input & keyboard interrupt clear
AM_RANGE(HP_MAKE_IOADDR(0 , 3) , HP_MAKE_IOADDR(0 , 3)) AM_READWRITE(kb_status_r , kb_irq_clear_w)
- // PA = 13, IC = 0..3
- // Graphic video
- AM_RANGE(HP_MAKE_IOADDR(GVIDEO_PA , 0) , HP_MAKE_IOADDR(GVIDEO_PA , 3)) AM_READWRITE(graphic_r , graphic_w)
+ // PA = 13, IC = 0..3
+ // Graphic video
+ AM_RANGE(HP_MAKE_IOADDR(GVIDEO_PA , 0) , HP_MAKE_IOADDR(GVIDEO_PA , 3)) AM_READWRITE(graphic_r , graphic_w)
// PA = 15, IC = 0..3
// Right-hand side tape drive (T15)
AM_RANGE(HP_MAKE_IOADDR(T15_PA , 0) , HP_MAKE_IOADDR(T15_PA , 3)) AM_DEVREADWRITE("t15" , hp_taco_device , reg_r , reg_w)
@@ -1118,13 +1118,13 @@ static MACHINE_CONFIG_START( hp9845b, hp9845b_state )
// video hardware
MCFG_SCREEN_ADD_MONOCHROME("screen", RASTER, rgb_t::green)
MCFG_SCREEN_UPDATE_DRIVER(hp9845b_state, screen_update)
- // These parameters are for alpha video
+ // These parameters are for alpha video
MCFG_SCREEN_RAW_PARAMS(VIDEO_PIXEL_CLOCK , VIDEO_HTOTAL , 0 , VIDEO_HBSTART , VIDEO_VTOTAL , 0 , VIDEO_ACTIVE_SCANLINES)
MCFG_SCREEN_VBLANK_DRIVER(hp9845b_state, vblank_w)
MCFG_PALETTE_ADD_MONOCHROME_HIGHLIGHT("palette")
MCFG_TIMER_DRIVER_ADD_SCANLINE("scantimer", hp9845b_state, scanline_timer, "screen", 0, 1)
- MCFG_TIMER_DRIVER_ADD("gv_timer", hp9845b_state, gv_timer)
+ MCFG_TIMER_DRIVER_ADD("gv_timer", hp9845b_state, gv_timer)
// Actual keyboard refresh rate should be KEY_SCAN_OSCILLATOR / 128 (2560 Hz)
MCFG_TIMER_DRIVER_ADD_PERIODIC("kb_timer" , hp9845b_state , kb_scan , attotime::from_hz(100))
diff --git a/src/mame/drivers/icatel.cpp b/src/mame/drivers/icatel.cpp
index 63255983beb..79a4c32509d 100644
--- a/src/mame/drivers/icatel.cpp
+++ b/src/mame/drivers/icatel.cpp
@@ -55,8 +55,8 @@ public:
DECLARE_DRIVER_INIT(icatel);
DECLARE_PALETTE_INIT(icatel);
-
- HD44780_PIXEL_UPDATE(icatel_pixel_update);
+
+ HD44780_PIXEL_UPDATE(icatel_pixel_update);
private:
virtual void machine_start() override;
diff --git a/src/mame/drivers/igspoker.cpp b/src/mame/drivers/igspoker.cpp
index ebe766faadf..79588e1c065 100644
--- a/src/mame/drivers/igspoker.cpp
+++ b/src/mame/drivers/igspoker.cpp
@@ -2332,9 +2332,9 @@ ROM_END
CPUs
1x Z0840006PSC-Z80 CPU (u13) - 8-bit Microprocessor - main.
1x PIC16C65A-20/P (u1) - 8bit CMOS Microcontroller (internal ROM not dumped).
- 1x CP82C55A (u29) - Programmable Peripheral Interface.
+ 1x CP82C55A (u29) - Programmable Peripheral Interface.
1x YM2413 (u3) - FM Operator Type-M (OPM) - sound.
- 1x LM358 (u4) - Dual Operational Amplifier - sound.
+ 1x LM358 (u4) - Dual Operational Amplifier - sound.
1x TDA2003 (u6) - Audio Amplifier - sound.
1x 24.000000 MHz oscillator (x2).
@@ -2420,7 +2420,7 @@ ROM_END
4x 8 DIP switches banks (DSW1-4).
1x 4 DIP switches bank (DSW5).
1x 3.6V battery.
-
+
*/
ROM_START( chleagxb )
ROM_REGION( 0x40000, "maincpu", 0 ) // Each half contains a different set of data+program. The game needs banking.
diff --git a/src/mame/drivers/itt3030.cpp b/src/mame/drivers/itt3030.cpp
index d529d27b031..7bd8017e813 100644
--- a/src/mame/drivers/itt3030.cpp
+++ b/src/mame/drivers/itt3030.cpp
@@ -467,7 +467,7 @@ WRITE8_MEMBER(itt3030_state::kbd_matrix_w)
int rd_masks[8] = { 1, 2, 4, 8, 0x10, 0x20, 0x40, 0x80 };
int tmp_read;
-// printf("matrix_w: %02x (col %d row %d clk %d)\n", data, m_kbdcol, m_kbdrow, (data & 0x80) ? 1 : 0);
+// printf("matrix_w: %02x (col %d row %d clk %d)\n", data, m_kbdcol, m_kbdrow, (data & 0x80) ? 1 : 0);
if ((data & 0x80) && (!m_kbdclk))
{
diff --git a/src/mame/drivers/jack.cpp b/src/mame/drivers/jack.cpp
index 44971916807..8238eacc95a 100644
--- a/src/mame/drivers/jack.cpp
+++ b/src/mame/drivers/jack.cpp
@@ -1432,22 +1432,22 @@ ROM_END
ROM_START( trikitri )
ROM_REGION( 0x10000, "maincpu", 0 ) /* main z80 cpu */
- ROM_LOAD( "1.bin", 0x0000, 0x2000, CRC(248f2f12) SHA1(a1796e3e56a2b499997b0459ab875e7e50b797a2) )
- ROM_LOAD( "2.bin", 0x2000, 0x2000, CRC(04052262) SHA1(056a225c8625e53881753b0b0330f9b277d14a7d) )
- ROM_LOAD( "3.bin", 0x4000, 0x2000, CRC(979c17c1) SHA1(518500d35241ceefa802edd6ffd948385faac9eb) )
- ROM_LOAD( "4.bin", 0x6000, 0x1000, CRC(839d79b7) SHA1(ac1c0fbf23e7d1a53b47dae16170857c55e6ae48) )
+ ROM_LOAD( "1.bin", 0x0000, 0x2000, CRC(248f2f12) SHA1(a1796e3e56a2b499997b0459ab875e7e50b797a2) )
+ ROM_LOAD( "2.bin", 0x2000, 0x2000, CRC(04052262) SHA1(056a225c8625e53881753b0b0330f9b277d14a7d) )
+ ROM_LOAD( "3.bin", 0x4000, 0x2000, CRC(979c17c1) SHA1(518500d35241ceefa802edd6ffd948385faac9eb) )
+ ROM_LOAD( "4.bin", 0x6000, 0x1000, CRC(839d79b7) SHA1(ac1c0fbf23e7d1a53b47dae16170857c55e6ae48) )
ROM_REGION( 0x10000, "audiocpu", 0 ) /* sound z80 cpu */
- ROM_LOAD( "snd.bin", 0x0000, 0x1000, CRC(1589c4a9) SHA1(9422d55952b939c761fc47147f392ef0cc7d141b) )
+ ROM_LOAD( "snd.bin", 0x0000, 0x1000, CRC(1589c4a9) SHA1(9422d55952b939c761fc47147f392ef0cc7d141b) )
ROM_REGION( 0x6000, "gfx1", 0 ) /* gfx - 8x8x3bpp */
- ROM_LOAD( "5.bin", 0x0000, 0x2000, CRC(8cb6ec1c) SHA1(89fb29b9c4931d1e32e705ee4c4e38af219100e4) )
- ROM_LOAD( "6.bin", 0x2000, 0x2000, CRC(a7bed0c1) SHA1(67484858abf08b3ffc320777befbfb922d867af9) )
- ROM_LOAD( "7.bin", 0x4000, 0x2000, CRC(b473ce14) SHA1(491539de23fc4b9d0705434bcfba26043414b3b4) )
+ ROM_LOAD( "5.bin", 0x0000, 0x2000, CRC(8cb6ec1c) SHA1(89fb29b9c4931d1e32e705ee4c4e38af219100e4) )
+ ROM_LOAD( "6.bin", 0x2000, 0x2000, CRC(a7bed0c1) SHA1(67484858abf08b3ffc320777befbfb922d867af9) )
+ ROM_LOAD( "7.bin", 0x4000, 0x2000, CRC(b473ce14) SHA1(491539de23fc4b9d0705434bcfba26043414b3b4) )
ROM_REGION( 0x200, "proms", 0 )
- ROM_LOAD_NIB_LOW( "prom2.bin", 0x000, 0x0100, CRC(ed5cec15) SHA1(22001ecce44d7fd886fc3aa8a184993b6e341c00) )
- ROM_LOAD_NIB_HIGH( "prom1.bin", 0x000, 0x0100, CRC(79632c67) SHA1(21480e44ab4941a1e943c10ea6a58c6177f77933) )
+ ROM_LOAD_NIB_LOW( "prom2.bin", 0x000, 0x0100, CRC(ed5cec15) SHA1(22001ecce44d7fd886fc3aa8a184993b6e341c00) )
+ ROM_LOAD_NIB_HIGH( "prom1.bin", 0x000, 0x0100, CRC(79632c67) SHA1(21480e44ab4941a1e943c10ea6a58c6177f77933) )
ROM_END
diff --git a/src/mame/drivers/lwings.cpp b/src/mame/drivers/lwings.cpp
index 244fe09fde3..518714ab720 100644
--- a/src/mame/drivers/lwings.cpp
+++ b/src/mame/drivers/lwings.cpp
@@ -1036,7 +1036,7 @@ static MACHINE_CONFIG_DERIVED( trojan, lwings )
/* sound hardware */
MCFG_GENERIC_LATCH_8_ADD("soundlatch2")
-
+
MCFG_SOUND_ADD("5205", MSM5205, XTAL_384kHz) /* verified on PCB */
MCFG_MSM5205_PRESCALER_SELECTOR(MSM5205_SEX_4B) /* slave mode */
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50)
diff --git a/src/mame/drivers/macs.cpp b/src/mame/drivers/macs.cpp
index f318b109946..b3a355b90a3 100644
--- a/src/mame/drivers/macs.cpp
+++ b/src/mame/drivers/macs.cpp
@@ -91,7 +91,7 @@ public:
DECLARE_MACHINE_RESET(macs);
DECLARE_MACHINE_START(macs);
ST0016_DMA_OFFS_CB(dma_offset);
-
+
UINT32 screen_update_macs(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
optional_device<st0016_cpu_device> m_maincpu;
diff --git a/src/mame/drivers/mcr68.cpp b/src/mame/drivers/mcr68.cpp
index 6c321f892cb..ede36d0e4f2 100644
--- a/src/mame/drivers/mcr68.cpp
+++ b/src/mame/drivers/mcr68.cpp
@@ -1022,7 +1022,7 @@ static MACHINE_CONFIG_START( zwackery, mcr68_state )
MCFG_CPU_PROGRAM_MAP(zwackery_map)
MCFG_CPU_VBLANK_INT_DRIVER("screen", mcr68_state, mcr68_interrupt)
- MCFG_WATCHDOG_ADD("watchdog")
+ MCFG_WATCHDOG_ADD("watchdog")
// MCFG_WATCHDOG_VBLANK_INIT("screen", 8)
MCFG_MACHINE_START_OVERRIDE(mcr68_state,zwackery)
MCFG_MACHINE_RESET_OVERRIDE(mcr68_state,zwackery)
diff --git a/src/mame/drivers/merit.cpp b/src/mame/drivers/merit.cpp
index 8a57919d4aa..d4498a7874d 100644
--- a/src/mame/drivers/merit.cpp
+++ b/src/mame/drivers/merit.cpp
@@ -726,13 +726,13 @@ INPUT_PORTS_END
static INPUT_PORTS_START( iowapp )
PORT_INCLUDE( meritpoker )
-
+
PORT_MODIFY("IN0") /* Pins #65 through #58 of J3 in decending order */
PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_POKER_HOLD1 )
PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_POKER_HOLD5 )
-// PORT_MODIFY("IN1") /* Pins #57 through #51 of J3 in decending order */
-// PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNKNOWN ) /* If HIGH triggers a "TOKEN LOW" error - Hopper releated */
+// PORT_MODIFY("IN1") /* Pins #57 through #51 of J3 in decending order */
+// PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNKNOWN ) /* If HIGH triggers a "TOKEN LOW" error - Hopper releated */
PORT_MODIFY("DSW")
PORT_DIPNAME( 0x01, 0x00, "Auto Hold" ) PORT_DIPLOCATION("SW1:1")
diff --git a/src/mame/drivers/metlfrzr.cpp b/src/mame/drivers/metlfrzr.cpp
index 3dc524f2e55..aa5ba6bc640 100644
--- a/src/mame/drivers/metlfrzr.cpp
+++ b/src/mame/drivers/metlfrzr.cpp
@@ -2,18 +2,18 @@
// copyright-holders:Angelo Salese
/****************************************
- Metal Freezer (c) 1989 Seibu
-
- preliminary driver by Angelo Salese
-
- HW seems the natural evolution of Dark Mist type.
-
- TODO:
- - Video registers needs better understanding.
- - Nuke legacy video code and re-do it by using tilemap system.
- - sprites are ahead of 1/2 frames;
- - Writes at 0xb800-0xbfff at attract mode gameplay demo transition?
- - DIPs need work - Flip Screen does not function. Still playable
+ Metal Freezer (c) 1989 Seibu
+
+ preliminary driver by Angelo Salese
+
+ HW seems the natural evolution of Dark Mist type.
+
+ TODO:
+ - Video registers needs better understanding.
+ - Nuke legacy video code and re-do it by using tilemap system.
+ - sprites are ahead of 1/2 frames;
+ - Writes at 0xb800-0xbfff at attract mode gameplay demo transition?
+ - DIPs need work - Flip Screen does not function. Still playable
****************************************/
@@ -64,12 +64,12 @@ void metlfrzr_state::video_start()
/*
- video regs format:
- [0x06] ---- --x- used during title screen transition, unknown purpose
- [0x06] ---- ---x
- [0x15] always 0?
- [0x16] always 0?
- [0x17] xxxx xxxx X scrolling base value
- Notice that it's currently unknown how the game is really supposed to NOT enable scrolling during gameplay.
+ [0x06] ---- --x- used during title screen transition, unknown purpose
+ [0x06] ---- ---x
+ [0x15] always 0?
+ [0x16] always 0?
+ [0x17] xxxx xxxx X scrolling base value
+ Notice that it's currently unknown how the game is really supposed to NOT enable scrolling during gameplay.
*/
void metlfrzr_state::legacy_bg_draw(bitmap_ind16 &bitmap,const rectangle &cliprect)
{
@@ -81,7 +81,7 @@ void metlfrzr_state::legacy_bg_draw(bitmap_ind16 &bitmap,const rectangle &clipre
UINT16 x_scroll_value;
x_scroll_value = m_video_regs[0x17] + ((m_video_regs[0x06] & 1) << 8);
x_scroll_base = (x_scroll_value >> 3) * 32;
-
+
for (count=0;count<32*33;count++)
{
int tile_base = count;
@@ -96,10 +96,10 @@ void metlfrzr_state::legacy_bg_draw(bitmap_ind16 &bitmap,const rectangle &clipre
tile_base &= vram_mask;
int x = (count / 32);
-
+
UINT16 tile = m_vram[tile_base*2+0] + ((m_vram[tile_base*2+1] & 0xf0) << 4);
UINT8 color = m_vram[tile_base*2+1] & 0xf;
-
+
gfx->transpen(bitmap,cliprect,tile,color,0,0,x*8-x_scroll_shift,y*8,0xf);
}
@@ -107,16 +107,16 @@ void metlfrzr_state::legacy_bg_draw(bitmap_ind16 &bitmap,const rectangle &clipre
/*
sprite DMA:
- 0xfe00-0xffff contains buffer for data to be copied.
- Sprites are currently lagging (noticeable during scrolling) therefore there must be either an automatic or manual trigger.
- Sprite seems to traverse from top to bottom priority-wise, other than that format is almost 1:1 with darkmist.cpp.
+ 0xfe00-0xffff contains buffer for data to be copied.
+ Sprites are currently lagging (noticeable during scrolling) therefore there must be either an automatic or manual trigger.
+ Sprite seems to traverse from top to bottom priority-wise, other than that format is almost 1:1 with darkmist.cpp.
sprite format:
- [0] tttt tttt tile number
- [1] x--- ---- if 1 sprite is disabled
- [1] -ttt ---- tile bank
- [1] ---- cccc palette number
- [2] yyyy yyyy Y offset
- [3] xxxx xxxx X offset
+ [0] tttt tttt tile number
+ [1] x--- ---- if 1 sprite is disabled
+ [1] -ttt ---- tile bank
+ [1] ---- cccc palette number
+ [2] yyyy yyyy Y offset
+ [3] xxxx xxxx X offset
*/
void metlfrzr_state::legacy_obj_draw(bitmap_ind16 &bitmap,const rectangle &cliprect)
{
@@ -124,19 +124,19 @@ void metlfrzr_state::legacy_obj_draw(bitmap_ind16 &bitmap,const rectangle &clipr
gfx_element *gfx_3 = m_gfxdecode->gfx(3);
int count;
UINT8 *base_spriteram = m_work_ram + 0xe00;
-
+
for(count=0x200-4;count>-1;count-=4)
{
if(base_spriteram[count+1] & 0x80)
continue;
-
+
gfx_element *cur_gfx = base_spriteram[count+1] & 0x40 ? gfx_3 : gfx_2;
UINT8 tile_bank = (base_spriteram[count+1] & 0x30) >> 4;
UINT16 tile = base_spriteram[count] | (tile_bank << 8);
UINT8 color = base_spriteram[count+1] & 0xf;
int y = base_spriteram[count+2];
int x = base_spriteram[count+3];
-
+
cur_gfx->transpen(bitmap,cliprect,tile,color,0,0,x,y,0xf);
}
}
@@ -162,7 +162,7 @@ WRITE8_MEMBER(metlfrzr_state::output_w)
m_fg_tilebank = (data & 0x10) >> 4;
membank("bank1")->set_entry((data & 0xc) >> 2);
-// popmessage("%02x",data & 3);
+// popmessage("%02x",data & 3);
}
static ADDRESS_MAP_START( metlfrzr_map, AS_PROGRAM, 8, metlfrzr_state )
@@ -180,14 +180,14 @@ static ADDRESS_MAP_START( metlfrzr_map, AS_PROGRAM, 8, metlfrzr_state )
AM_RANGE(0xd603, 0xd603) AM_READ_PORT("DSW1")
AM_RANGE(0xd604, 0xd604) AM_READ_PORT("DSW2")
AM_RANGE(0xd600, 0xd61f) AM_RAM AM_SHARE("vregs") // TODO: write-only, debug
-
+
AM_RANGE(0xd700, 0xd700) AM_WRITE(output_w)
AM_RANGE(0xd710, 0xd710) AM_DEVWRITE("t5182", t5182_device, sound_irq_w)
AM_RANGE(0xd711, 0xd711) AM_DEVREAD("t5182", t5182_device, sharedram_semaphore_snd_r)
// following two do swapped access compared to darkmist
AM_RANGE(0xd712, 0xd712) AM_DEVWRITE("t5182", t5182_device, sharedram_semaphore_main_release_w)
AM_RANGE(0xd713, 0xd713) AM_DEVWRITE("t5182", t5182_device, sharedram_semaphore_main_acquire_w)
-
+
AM_RANGE(0xd800, 0xdfff) AM_RAM
AM_RANGE(0xe000, 0xefff) AM_RAM
AM_RANGE(0xf000, 0xffff) AM_RAM AM_SHARE("wram")
@@ -240,7 +240,7 @@ static INPUT_PORTS_START( metlfrzr )
PORT_DIPNAME( 0x80, 0x80, "2-7" )
PORT_DIPSETTING( 0x80, DEF_STR( No ) )
PORT_DIPSETTING( 0x00, DEF_STR( Yes ) )
-
+
PORT_START("DSW1")
PORT_DIPNAME( 0x01, 0x00, "SYSA" )
PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
@@ -264,7 +264,7 @@ static INPUT_PORTS_START( metlfrzr )
PORT_DIPNAME( 0x80, 0x80, DEF_STR( Unknown ) )
PORT_DIPSETTING( 0x80, DEF_STR( Off ) )
PORT_DIPSETTING( 0x00, DEF_STR( On ) )
-
+
PORT_START("DSW2")
PORT_DIPNAME( 0x01, 0x00, "SYSB" )
@@ -313,7 +313,7 @@ static const gfx_layout tile_layout =
RGN_FRAC(1,1),
4,
{ STEP4(0,4) },
- { STEP4_INV(16,1), STEP4_INV(0,1) },
+ { STEP4_INV(16,1), STEP4_INV(0,1) },
{ STEP8(0,32) },
32*8
};
@@ -405,7 +405,7 @@ ROM_START(metlfrzr)
ROM_REGION(0x20000, "gfx3", 0)
ROM_LOAD16_BYTE("14.13a", 0x00001, 0x10000, CRC(a9cd5225) SHA1(f3d5e29ee08fb563fdc1af3c64128f2cd2feb987))
ROM_LOAD16_BYTE("16.11a", 0x00000, 0x10000, CRC(92f2cb49) SHA1(498021d94b0fde216207076491702af2324a2dcc))
-
+
ROM_REGION(0x20000, "gfx4", 0)
ROM_LOAD16_BYTE("15.12a", 0x00001, 0x10000, CRC(ce5c4c8b) SHA1(2351d66ba51e80097ce53bfd448ac24901844cda))
ROM_LOAD16_BYTE("17.10a", 0x00000, 0x10000, CRC(3fec33f7) SHA1(af086ba30fc4521a0114da2824f5baa04d225a89))
diff --git a/src/mame/drivers/mpu4.cpp b/src/mame/drivers/mpu4.cpp
index 1a77ccec16a..a27f886db01 100644
--- a/src/mame/drivers/mpu4.cpp
+++ b/src/mame/drivers/mpu4.cpp
@@ -2765,7 +2765,7 @@ MACHINE_CONFIG_END
#include "mpu4crystal.hxx"
#include "mpu4empire.hxx"
#include "mpu4mdm.hxx"
-#include "mpu4misc.hxx"
+#include "mpu4misc.hxx"
#include "mpu4mod2sw.hxx"
#include "mpu4mod4yam.hxx"
#include "mpu4sw.hxx"
diff --git a/src/mame/drivers/mvme147.cpp b/src/mame/drivers/mvme147.cpp
index 26afc40a74f..84b09c1dd87 100644
--- a/src/mame/drivers/mvme147.cpp
+++ b/src/mame/drivers/mvme147.cpp
@@ -8,7 +8,7 @@
*
* Thanks to Plamen Mihaylov and his site http://www.m88k.com/ I got the information
* required to start the work with this driver. The goal is to boot a tape through
- * the MVME-350 devide connected over a VME bus device.
+ * the MVME-350 devide connected over a VME bus device.
*
*
* ||
@@ -91,7 +91,7 @@
* - A32/D32 VMEbus master/slave interface with system controller function (VMEchip ASIC)
* - Four EIA-232-D serial communications ports (85C30 x 2)
* - Centronics compatible printer port ( PCC ASIC )
- * - Two 16-bit timers and watchdog timer (PCC ASIC )
+ * - Two 16-bit timers and watchdog timer (PCC ASIC )
* - SCSI bus interface with DMA (WD33C93)
* - Ethernet transceiver interface (AM7990)
* - 4-level requester, 7-level interrupter, and 7-level interrupt handler for VMEbus (VMEchip ASIC)
@@ -173,7 +173,7 @@
#endif
/* from documentataion: http://www.m88k.com/Docs/147/147aih.pdf but crystal and divider not known */
-#define BAUDGEN_CLOCK XTAL_5MHz
+#define BAUDGEN_CLOCK XTAL_5MHz
#define SCC_CLOCK (BAUDGEN_CLOCK) /* This gives prompt at the RS232 terminal device (9600) */
class mvme147_state : public driver_device
@@ -212,37 +212,37 @@ private:
required_device<scc85C30_device> m_sccterm2;
// Pointer to System ROMs needed by bootvect_r and masking RAM buffer for post reset accesses
- UINT32 *m_sysrom;
- UINT32 m_sysram[2];
+ UINT32 *m_sysrom;
+ UINT32 m_sysram[2];
// PCC registers
- UINT8 m_genpurp_stat;
+ UINT8 m_genpurp_stat;
// VME chip registers
- UINT8 m_vc_cntl_conf;
+ UINT8 m_vc_cntl_conf;
};
static ADDRESS_MAP_START (mvme147_mem, AS_PROGRAM, 32, mvme147_state)
ADDRESS_MAP_UNMAP_HIGH
- AM_RANGE (0x00000000, 0x00000007) AM_ROM AM_READ (bootvect_r) /* ROM mirror just during reset */
- AM_RANGE (0x00000000, 0x00000007) AM_RAM AM_WRITE (bootvect_w) /* After first write we act as RAM */
+ AM_RANGE (0x00000000, 0x00000007) AM_ROM AM_READ (bootvect_r) /* ROM mirror just during reset */
+ AM_RANGE (0x00000000, 0x00000007) AM_RAM AM_WRITE (bootvect_w) /* After first write we act as RAM */
AM_RANGE (0x00000008, 0x003fffff) AM_RAM /* 4 Mb RAM */
AM_RANGE (0xff800000, 0xff9fffff) AM_ROM AM_REGION("maincpu", 0xff800000) //AM_MIRROR(0x00780000) /* ROM/EEPROM bank 1 - 147bug */
AM_RANGE (0xffa00000, 0xffbfffff) AM_ROM AM_REGION("maincpu", 0xffa00000) //AM_MIRROR(0x00780000) /* ROM/EEPROM bank 2 - unpopulated */
- /* SGS-Thompson M48T18 RAM and clock chip, only 4088 bytes used, and 8 bytes for the RTC, out of 8Kb though */
+ /* SGS-Thompson M48T18 RAM and clock chip, only 4088 bytes used, and 8 bytes for the RTC, out of 8Kb though */
AM_RANGE (0xfffe0000, 0xfffe0fff) AM_DEVREADWRITE8("m48t18", timekeeper_device, read, write, 0xffffffff)
- //AM_RANGE (0xfffe1000, 0xfffe100f) AM_READWRITE32(pcc32_r, pcc32_w, 0xffffffff) /* PCC 32 bits registers - needs U64 cast defined to work */
+ //AM_RANGE (0xfffe1000, 0xfffe100f) AM_READWRITE32(pcc32_r, pcc32_w, 0xffffffff) /* PCC 32 bits registers - needs U64 cast defined to work */
AM_RANGE (0xfffe1010, 0xfffe1017) AM_READWRITE16(pcc16_r, pcc16_w, 0xffffffff) /* PCC 16 bits registers */
- AM_RANGE (0xfffe1018, 0xfffe102f) AM_READWRITE8(pcc8_r, pcc8_w, 0xffffffff) /* PCC 8 bits registers */
+ AM_RANGE (0xfffe1018, 0xfffe102f) AM_READWRITE8(pcc8_r, pcc8_w, 0xffffffff) /* PCC 8 bits registers */
AM_RANGE (0xfffe2000, 0xfffe201b) AM_READWRITE8(vmechip_r, vmechip_w, 0x00ff00ff) /* VMEchip 8 bits registers on odd adresses */
AM_RANGE (0xfffe3000, 0xfffe3003) AM_DEVREADWRITE8("scc", scc85C30_device, ba_cd_inv_r, ba_cd_inv_w, 0xffffffff) /* Port 1&2 - Dual serial port Z80-SCC */
AM_RANGE (0xfffe3800, 0xfffe3803) AM_DEVREADWRITE8("scc2", scc85C30_device, ba_cd_inv_r, ba_cd_inv_w, 0xffffffff) /* Port 3&4 - Dual serial port Z80-SCC */
- //AM_RANGE(0x100000, 0xfeffff) AM_READWRITE(vme_a24_r, vme_a24_w) /* VMEbus Rev B addresses (24 bits) - not verified */
- //AM_RANGE(0xff0000, 0xffffff) AM_READWRITE(vme_a16_r, vme_a16_w) /* VMEbus Rev B addresses (16 bits) - not verified */
+ //AM_RANGE(0x100000, 0xfeffff) AM_READWRITE(vme_a24_r, vme_a24_w) /* VMEbus Rev B addresses (24 bits) - not verified */
+ //AM_RANGE(0xff0000, 0xffffff) AM_READWRITE(vme_a16_r, vme_a16_w) /* VMEbus Rev B addresses (16 bits) - not verified */
ADDRESS_MAP_END
/* Input ports */
@@ -281,7 +281,7 @@ WRITE32_MEMBER (mvme147_state::bootvect_w){
m_sysrom = &m_sysram[0]; // redirect all upcomming accesses to masking RAM until reset.
}
-/****
+/****
* PCC - Periheral Channel Controller driver, might deserve its own driver but will rest here until another board wants it
*/
#if 0 /* Doesn't compile atm */
@@ -312,16 +312,15 @@ WRITE32_MEMBER (mvme147_state::pcc32_w){
#define P16_TIMER2_COUNT (P16BASE + 6)
READ16_MEMBER (mvme147_state::pcc16_r){
-
UINT16 ret = 0;
LOG(("Call to %s[%04x]", FUNCNAME, offset));
switch(offset)
{
- case P16_TIMER1_PRELOAD - P16BASE : LOG((" -> %02x Timer 1 preload - not implemented\n", ret)); break;
- case P16_TIMER1_COUNT - P16BASE : LOG((" -> %02x Timer 1 count - not implemented\n", ret)); break;
- case P16_TIMER2_PRELOAD - P16BASE : LOG((" -> %02x Timer 2 preload - not implemented\n", ret)); break;
- case P16_TIMER2_COUNT - P16BASE : LOG((" -> %02x Timer 2 count - not implemented\n", ret)); break;
+ case P16_TIMER1_PRELOAD - P16BASE : LOG((" -> %02x Timer 1 preload - not implemented\n", ret)); break;
+ case P16_TIMER1_COUNT - P16BASE : LOG((" -> %02x Timer 1 count - not implemented\n", ret)); break;
+ case P16_TIMER2_PRELOAD - P16BASE : LOG((" -> %02x Timer 2 preload - not implemented\n", ret)); break;
+ case P16_TIMER2_COUNT - P16BASE : LOG((" -> %02x Timer 2 count - not implemented\n", ret)); break;
default:
LOG((" -> %02x unsupported register\n", ret));
}
@@ -329,145 +328,144 @@ READ16_MEMBER (mvme147_state::pcc16_r){
}
WRITE16_MEMBER (mvme147_state::pcc16_w){
- LOG(("Call to %s[%04x] <- %04x - ", FUNCNAME, offset, data));
- switch(offset)
- {
- case P16_TIMER1_PRELOAD - P16BASE : LOG(("Timer 1 preload - not implemented\n")); break;
- case P16_TIMER1_COUNT - P16BASE : LOG(("Timer 1 count - not implemented\n")); break;
- case P16_TIMER2_PRELOAD - P16BASE : LOG(("Timer 2 preload - not implemented\n")); break;
- case P16_TIMER2_COUNT - P16BASE : LOG(("Timer 2 count - not implemented\n")); break;
- default:
+ LOG(("Call to %s[%04x] <- %04x - ", FUNCNAME, offset, data));
+ switch(offset)
+ {
+ case P16_TIMER1_PRELOAD - P16BASE : LOG(("Timer 1 preload - not implemented\n")); break;
+ case P16_TIMER1_COUNT - P16BASE : LOG(("Timer 1 count - not implemented\n")); break;
+ case P16_TIMER2_PRELOAD - P16BASE : LOG(("Timer 2 preload - not implemented\n")); break;
+ case P16_TIMER2_COUNT - P16BASE : LOG(("Timer 2 count - not implemented\n")); break;
+ default:
LOG(("unsupported register\n"));
- }
+ }
}
#define P8BASE 0xfffe1018
#define P8_TIMER1_INT_CNTL 0xfffe1018
-#define P8_TIMER1_CNTL 0xfffe1019
+#define P8_TIMER1_CNTL 0xfffe1019
#define P8_TIMER2_INT_CNTL 0xfffe101A
-#define P8_TIMER2_CNTL 0xfffe101B
+#define P8_TIMER2_CNTL 0xfffe101B
#define P8_ACFAIL_INT_CNTL 0xfffe101C
#define P8_WDOG_TIMER_CNTL 0xfffe101D
#define P8_PRINTER_INT_CNTL 0xfffe101E
-#define P8_PRINTER_CNTL 0xfffe101F
-#define P8_DMA_INT_CNTL 0xfffe1020
+#define P8_PRINTER_CNTL 0xfffe101F
+#define P8_DMA_INT_CNTL 0xfffe1020
#define P8_DMA_CNTL_STAT 0xfffe1021
-#define P8_BUSERR_CNTL 0xfffe1022
-#define P8_DMA_STATUS 0xfffe1023
+#define P8_BUSERR_CNTL 0xfffe1022
+#define P8_DMA_STATUS 0xfffe1023
#define P8_ABORT_INT_CNTL 0xfffe1024
#define P8_TABADD_FC_CNTL 0xfffe1025
#define P8_SERIAL_INT_CNTL 0xfffe1026
#define P8_GEN_PURP_CNTL 0xfffe1027
-#define P8_LAN_INT_CNTL 0xfffe1028
+#define P8_LAN_INT_CNTL 0xfffe1028
#define P8_GEN_PURP_STAT 0xfffe1029
#define P8_SCSI_INT_CNTL 0xfffe102A
#define P8_SLAVE_BASE_ADDR 0xfffe102B
-#define P8_SWI_1_CNTL 0xfffe102C
+#define P8_SWI_1_CNTL 0xfffe102C
#define P8_INT_VECT_BASE 0xfffe102D
-#define P8_SWI_2_CNTL 0xfffe102E
+#define P8_SWI_2_CNTL 0xfffe102E
#define P8_REVISION_LEVEL 0xfffe102F
-#define P8_PRINTER_DATA 0xfffe2800
+#define P8_PRINTER_DATA 0xfffe2800
#define P8_PRINTER_STATUS 0xfffe2800
READ8_MEMBER (mvme147_state::pcc8_r){
-
UINT8 ret = 0;
- LOG(("Call to %s[%04x] ", FUNCNAME, offset));
+ LOG(("Call to %s[%04x] ", FUNCNAME, offset));
switch(offset + P8BASE)
{
- case P8_TIMER1_INT_CNTL : LOG((" -> %02x - Timer 1 Interrupt Control - not implemented\n", ret)); break;
- case P8_TIMER1_CNTL : LOG((" -> %02x - Timer 1 Control - not implemented\n", ret)); break;
- case P8_TIMER2_INT_CNTL : LOG((" -> %02x - Timer 2 Interrupt Control - not implemented\n", ret)); break;
- case P8_TIMER2_CNTL : LOG((" -> %02x - Timer 2 Control - not implemented\n", ret)); break;
- case P8_ACFAIL_INT_CNTL : LOG((" -> %02x - AC Fail Interrupt Control Register - not implemented\n", ret)); break;
- case P8_WDOG_TIMER_CNTL : LOG((" -> %02x - Watchdog Timer Control Register - not implemented\n", ret)); break;
+ case P8_TIMER1_INT_CNTL : LOG((" -> %02x - Timer 1 Interrupt Control - not implemented\n", ret)); break;
+ case P8_TIMER1_CNTL : LOG((" -> %02x - Timer 1 Control - not implemented\n", ret)); break;
+ case P8_TIMER2_INT_CNTL : LOG((" -> %02x - Timer 2 Interrupt Control - not implemented\n", ret)); break;
+ case P8_TIMER2_CNTL : LOG((" -> %02x - Timer 2 Control - not implemented\n", ret)); break;
+ case P8_ACFAIL_INT_CNTL : LOG((" -> %02x - AC Fail Interrupt Control Register - not implemented\n", ret)); break;
+ case P8_WDOG_TIMER_CNTL : LOG((" -> %02x - Watchdog Timer Control Register - not implemented\n", ret)); break;
case P8_PRINTER_INT_CNTL : LOG((" -> %02x - Printer Interrupt Control Register - not implemented\n", ret)); break;
- case P8_PRINTER_CNTL : LOG((" -> %02x - Printer Control Register - not implemented\n", ret)); break;
- case P8_DMA_INT_CNTL : LOG((" -> %02x - DMA Interrupt Control Register - not implemented\n", ret)); break;
- case P8_DMA_CNTL_STAT : LOG((" -> %02x - DMA Control and Status Register - not implemented\n", ret)); break;
- case P8_BUSERR_CNTL : LOG((" -> %02x - Bus Error Interrupt Control Register - not implemented\n", ret)); break;
- case P8_DMA_STATUS : LOG((" -> %02x - DMA Status Register - not implemented\n", ret)); break;
- case P8_ABORT_INT_CNTL : LOG((" -> %02x - Abort Interrupt Control Register - not fully implemented\n", ret));
- /* Bit 3 When this bit is high, the interrupt is enabled. The interrupt is disabled when this bit is low. This bit is cleared by reset.
- Bit 6 This bit indicates the current state of the ABORT switch. When this bit is low, the ABORT switch is not pressed. When this bit is
+ case P8_PRINTER_CNTL : LOG((" -> %02x - Printer Control Register - not implemented\n", ret)); break;
+ case P8_DMA_INT_CNTL : LOG((" -> %02x - DMA Interrupt Control Register - not implemented\n", ret)); break;
+ case P8_DMA_CNTL_STAT : LOG((" -> %02x - DMA Control and Status Register - not implemented\n", ret)); break;
+ case P8_BUSERR_CNTL : LOG((" -> %02x - Bus Error Interrupt Control Register - not implemented\n", ret)); break;
+ case P8_DMA_STATUS : LOG((" -> %02x - DMA Status Register - not implemented\n", ret)); break;
+ case P8_ABORT_INT_CNTL : LOG((" -> %02x - Abort Interrupt Control Register - not fully implemented\n", ret));
+ /* Bit 3 When this bit is high, the interrupt is enabled. The interrupt is disabled when this bit is low. This bit is cleared by reset.
+ Bit 6 This bit indicates the current state of the ABORT switch. When this bit is low, the ABORT switch is not pressed. When this bit is
high, the ABORT switch is pressed.
- Bit 7 When this bit is high, an abort interrupt is being generated at Level 7. This bit is edge sensitive and it is set on the leading
+ Bit 7 When this bit is high, an abort interrupt is being generated at Level 7. This bit is edge sensitive and it is set on the leading
edge of interrupt enable and abort. This bit is cleared when a 1 is written to it or when the interrupt is disabled. When cleared,
it remains cleared until the next leading edge of interrupt enable and abort. This bit is cleared by reset. */
ret = 0; /* Always return reset values for now */
break;
- case P8_TABADD_FC_CNTL : LOG((" -> %02x - Table Address Function Code Register - not implemented\n", ret)); break;
- case P8_SERIAL_INT_CNTL : LOG((" -> %02x - Serial Port Interrupt Control Register - not implemented\n", ret)); break;
- case P8_GEN_PURP_CNTL : LOG((" -> %02x - General Purpose Control Register - not implemented\n", ret)); break;
- case P8_LAN_INT_CNTL : LOG((" -> %02x - LAN Interrupt Control Register - not implemented\n", ret)); break;
- case P8_GEN_PURP_STAT : LOG((" -> %02x - General Purpose Status Register\n", ret));
+ case P8_TABADD_FC_CNTL : LOG((" -> %02x - Table Address Function Code Register - not implemented\n", ret)); break;
+ case P8_SERIAL_INT_CNTL : LOG((" -> %02x - Serial Port Interrupt Control Register - not implemented\n", ret)); break;
+ case P8_GEN_PURP_CNTL : LOG((" -> %02x - General Purpose Control Register - not implemented\n", ret)); break;
+ case P8_LAN_INT_CNTL : LOG((" -> %02x - LAN Interrupt Control Register - not implemented\n", ret)); break;
+ case P8_GEN_PURP_STAT : LOG((" -> %02x - General Purpose Status Register\n", ret));
ret = m_genpurp_stat;
break;
- case P8_SCSI_INT_CNTL : LOG((" -> %02x - SCSI Port Interrupt Control Register - not implemented\n", ret)); break;
- case P8_SLAVE_BASE_ADDR : LOG((" -> %02x - Slave Base Address Register - not implemented\n", ret)); break;
- case P8_SWI_1_CNTL : LOG((" -> %02x - Software Interrupt 1 Control Register - not implemented\n", ret)); break;
- case P8_INT_VECT_BASE : LOG((" -> %02x - Interrupt Vector Base - not implemented\n", ret)); break;
- case P8_SWI_2_CNTL : LOG((" -> %02x - Software Interrupt 2 Control Register - not implemented\n", ret)); break;
- case P8_REVISION_LEVEL : LOG((" -> %02x - PCC Revision Level Register - not implemented\n", ret)); break;
- case P8_PRINTER_STATUS : LOG((" -> %02x - Printer Status Register - not implemented\n", ret)); break;
+ case P8_SCSI_INT_CNTL : LOG((" -> %02x - SCSI Port Interrupt Control Register - not implemented\n", ret)); break;
+ case P8_SLAVE_BASE_ADDR : LOG((" -> %02x - Slave Base Address Register - not implemented\n", ret)); break;
+ case P8_SWI_1_CNTL : LOG((" -> %02x - Software Interrupt 1 Control Register - not implemented\n", ret)); break;
+ case P8_INT_VECT_BASE : LOG((" -> %02x - Interrupt Vector Base - not implemented\n", ret)); break;
+ case P8_SWI_2_CNTL : LOG((" -> %02x - Software Interrupt 2 Control Register - not implemented\n", ret)); break;
+ case P8_REVISION_LEVEL : LOG((" -> %02x - PCC Revision Level Register - not implemented\n", ret)); break;
+ case P8_PRINTER_STATUS : LOG((" -> %02x - Printer Status Register - not implemented\n", ret)); break;
default:
- LOG((" -> %02x - unsupported register\n", ret));
+ LOG((" -> %02x - unsupported register\n", ret));
}
return ret;
}
WRITE8_MEMBER (mvme147_state::pcc8_w){
- LOG(("Call to %s[%04x] <- %02x - ", FUNCNAME, offset, data));
+ LOG(("Call to %s[%04x] <- %02x - ", FUNCNAME, offset, data));
switch(offset + P8BASE)
{
- case P8_TIMER1_INT_CNTL : LOG(("Timer 1 Interrupt Control - not implemented\n")); break;
- case P8_TIMER1_CNTL : LOG(("Timer 1 Control - not implemented\n")); break;
- case P8_TIMER2_INT_CNTL : LOG(("Timer 2 Interrupt Control - not implemented\n")); break;
- case P8_TIMER2_CNTL : LOG(("Timer 2 Control - not implemented\n")); break;
- case P8_ACFAIL_INT_CNTL : LOG(("AC Fail Interrupt Control Register - not implemented\n")); break;
- case P8_WDOG_TIMER_CNTL : LOG(("Watchdog Timer Control Register - not implemented\n")); break;
+ case P8_TIMER1_INT_CNTL : LOG(("Timer 1 Interrupt Control - not implemented\n")); break;
+ case P8_TIMER1_CNTL : LOG(("Timer 1 Control - not implemented\n")); break;
+ case P8_TIMER2_INT_CNTL : LOG(("Timer 2 Interrupt Control - not implemented\n")); break;
+ case P8_TIMER2_CNTL : LOG(("Timer 2 Control - not implemented\n")); break;
+ case P8_ACFAIL_INT_CNTL : LOG(("AC Fail Interrupt Control Register - not implemented\n")); break;
+ case P8_WDOG_TIMER_CNTL : LOG(("Watchdog Timer Control Register - not implemented\n")); break;
case P8_PRINTER_INT_CNTL : LOG(("Printer Interrupt Control Register - not implemented\n")); break;
- case P8_PRINTER_CNTL : LOG(("Printer Control Register - not implemented\n")); break;
- case P8_DMA_INT_CNTL : LOG(("DMA Interrupt Control Register - not implemented\n")); break;
- case P8_DMA_CNTL_STAT : LOG(("DMA Control and Status Register - not implemented\n")); break;
- case P8_BUSERR_CNTL : LOG(("Bus Error Interrupt Control Register - not implemented\n")); break;
- case P8_DMA_STATUS : LOG(("DMA Status Register - not implemented\n")); break;
- case P8_ABORT_INT_CNTL : LOG(("Abort Interrupt Control Register - not implemented\n")); break;
- case P8_TABADD_FC_CNTL : LOG(("Table Address Function Code Register - not implemented\n")); break;
- case P8_SERIAL_INT_CNTL : LOG(("Serial Port Interrupt Control Register - not implemented\n")); break;
- case P8_GEN_PURP_CNTL : LOG(("General Purpose Control Register - not implemented\n"));
- /*Bits 0-1 These bits control local RAM parity checking. These bits should not be enabled on the MVME147-010.
- These bits are cleared by reset. x0 = parity disabled, x1 = parity enabled
- Bit 2 This bit is used to test the parity generating and checking logic. When this bit is low, correct parity is written to the DRAM;
- when high, incorrect parity is written to the DRAM. This bit is cleared by reset.
- NOTE: We really don't care about DRAM parity!
- Bit 3 When set, this bit is used to enable the local bus timer that is part of the PCC. Because the VMEchip also contains a local bus
+ case P8_PRINTER_CNTL : LOG(("Printer Control Register - not implemented\n")); break;
+ case P8_DMA_INT_CNTL : LOG(("DMA Interrupt Control Register - not implemented\n")); break;
+ case P8_DMA_CNTL_STAT : LOG(("DMA Control and Status Register - not implemented\n")); break;
+ case P8_BUSERR_CNTL : LOG(("Bus Error Interrupt Control Register - not implemented\n")); break;
+ case P8_DMA_STATUS : LOG(("DMA Status Register - not implemented\n")); break;
+ case P8_ABORT_INT_CNTL : LOG(("Abort Interrupt Control Register - not implemented\n")); break;
+ case P8_TABADD_FC_CNTL : LOG(("Table Address Function Code Register - not implemented\n")); break;
+ case P8_SERIAL_INT_CNTL : LOG(("Serial Port Interrupt Control Register - not implemented\n")); break;
+ case P8_GEN_PURP_CNTL : LOG(("General Purpose Control Register - not implemented\n"));
+ /*Bits 0-1 These bits control local RAM parity checking. These bits should not be enabled on the MVME147-010.
+ These bits are cleared by reset. x0 = parity disabled, x1 = parity enabled
+ Bit 2 This bit is used to test the parity generating and checking logic. When this bit is low, correct parity is written to the DRAM;
+ when high, incorrect parity is written to the DRAM. This bit is cleared by reset.
+ NOTE: We really don't care about DRAM parity!
+ Bit 3 When set, this bit is used to enable the local bus timer that is part of the PCC. Because the VMEchip also contains a local bus
timer, this bit should be cleared, turning off the PCC local bus timer. This bit is cleared by reset.
- Bit 4 This bit is the master interrupt enable. When this bit is low, all interrupts on the MVME147 are disabled; when high, all
+ Bit 4 This bit is the master interrupt enable. When this bit is low, all interrupts on the MVME147 are disabled; when high, all
interrupts are enabled. This bit is cleared by reset
- Bits 5-7 When the pattern %101 is written to these bits, the front panel RESET switch is disabled. The RESET switch is enabled for any
- other pattern. These bits are cleared by reset.
- TODO: Bit 4-7 needs to be implemented
- */
+ Bits 5-7 When the pattern %101 is written to these bits, the front panel RESET switch is disabled. The RESET switch is enabled for any
+ other pattern. These bits are cleared by reset.
+ TODO: Bit 4-7 needs to be implemented
+ */
break;
- case P8_LAN_INT_CNTL : LOG(("LAN Interrupt Control Register - not implemented\n")); break;
- case P8_GEN_PURP_STAT : LOG(("General Purpose Status Register\n"));
- /* Bit 0 This bit is set when a parity error occurs while the local processor is accessing RAM. This bit is cleared by writing a 1 to it.
- This bit is cleared by reset.
- Bit 1 This bit is set when a power-up reset occurs. It is cleared by writing a 1 to it.
+ case P8_LAN_INT_CNTL : LOG(("LAN Interrupt Control Register - not implemented\n")); break;
+ case P8_GEN_PURP_STAT : LOG(("General Purpose Status Register\n"));
+ /* Bit 0 This bit is set when a parity error occurs while the local processor is accessing RAM. This bit is cleared by writing a 1 to it.
+ This bit is cleared by reset.
+ Bit 1 This bit is set when a power-up reset occurs. It is cleared by writing a 1 to it.
When the MVME147BUG is installed, its initialization code clears this bit.
- */
+ */
m_genpurp_stat &= ((data & 1) ? ~1 : 0xff); // Check if parity error bit needs to be cleared
m_genpurp_stat &= ((data & 2) ? ~2 : 0xff); // Check if power up reset bit needs to be cleared
break;
- case P8_SCSI_INT_CNTL : LOG(("SCSI Port Interrupt Control Register - not implemented\n")); break;
- case P8_SLAVE_BASE_ADDR : LOG(("Slave Base Address Register - not implemented\n")); break;
- case P8_SWI_1_CNTL : LOG(("Software Interrupt 1 Control Register - not implemented\n")); break;
- case P8_INT_VECT_BASE : LOG(("Interrupt Vector Base - not implemented\n")); break;
- case P8_SWI_2_CNTL : LOG(("Software Interrupt 2 Control Register - not implemented\n")); break;
- case P8_REVISION_LEVEL : LOG(("PCC Revision Level Register - not implemented\n")); break;
- case P8_PRINTER_DATA : LOG(("Printer Data Register - not implemented\n")); break;
+ case P8_SCSI_INT_CNTL : LOG(("SCSI Port Interrupt Control Register - not implemented\n")); break;
+ case P8_SLAVE_BASE_ADDR : LOG(("Slave Base Address Register - not implemented\n")); break;
+ case P8_SWI_1_CNTL : LOG(("Software Interrupt 1 Control Register - not implemented\n")); break;
+ case P8_INT_VECT_BASE : LOG(("Interrupt Vector Base - not implemented\n")); break;
+ case P8_SWI_2_CNTL : LOG(("Software Interrupt 2 Control Register - not implemented\n")); break;
+ case P8_REVISION_LEVEL : LOG(("PCC Revision Level Register - not implemented\n")); break;
+ case P8_PRINTER_DATA : LOG(("Printer Data Register - not implemented\n")); break;
default:
LOG(("unsupported register\n"));
}
@@ -479,129 +477,128 @@ WRITE8_MEMBER (mvme147_state::pcc8_w){
#define VCBASE 0xfffe2001
#define VC_SYS_CNTL_CONF 0xfffe2001
#define VC_VMEBUS_REQ_CONF 0xfffe2003
-#define VC_MASTER_CONF 0xfffe2005
-#define VC_SLAVE_CONF 0xfffe2007
-#define VC_TIMER_CONF 0xfffe2009
+#define VC_MASTER_CONF 0xfffe2005
+#define VC_SLAVE_CONF 0xfffe2007
+#define VC_TIMER_CONF 0xfffe2009
#define VC_SLAVE_ADR_MOD 0xfffe200B
#define VC_MASTER_ADR_MOD 0xfffe200D
#define VC_INT_HNDL_MASK 0xfffe200F
#define VC_UTIL_INT_MASK 0xfffe2011
#define VC_UTIL_INT_VECT 0xfffe2013
-#define VC_INT_REQUEST 0xfffe2015
+#define VC_INT_REQUEST 0xfffe2015
#define VC_VMEBUS_STAT_ID 0xfffe2017
#define VC_BUS_ERR_STATUS 0xfffe2019
#define VC_GCSR_BASE_ADR 0xfffe201B
READ8_MEMBER (mvme147_state::vmechip_r){
-
UINT8 ret = 0;
- LOG(("Call to %s[%04x] ", FUNCNAME, offset));
+ LOG(("Call to %s[%04x] ", FUNCNAME, offset));
switch(offset * 2 + VCBASE)
{
- case VC_SYS_CNTL_CONF :
- LOG((" -> %02x - System Controller Configuration Register - not implemented\n", ret));
+ case VC_SYS_CNTL_CONF :
+ LOG((" -> %02x - System Controller Configuration Register - not implemented\n", ret));
ret = m_vc_cntl_conf;
break;
- case VC_VMEBUS_REQ_CONF :
- /*
- Bits 0-1 These control bits configure the VMEbus requester level as shown in the table below:
+ case VC_VMEBUS_REQ_CONF :
+ /*
+ Bits 0-1 These control bits configure the VMEbus requester level as shown in the table below:
RQLEV1 RQLEV0 Level
- 0 0 0
- 0 1 1
- 1 0 2
- 1 1 3
- These bits are set to 1, 1 by any reset. Note that writes to REQLEV1,0 do not change the actual
- requester level until the MVME147 goes through the action of having VMEbus mastership and releasing it. This means that
- there are times when the value written into REQLEV1,0 do not match the current requester level (the request level is lagging).
- During such times, reads to REQLEV1,0 reflect the actual requester level, not the value written into REQLEV1,0.
- Bit 3 Setting this bit to 1 prevents the requester from releasing the VMEbus. However, unlike the DWB control bit, setting the
- RNEVER bit does not cause the requester to request the VMEbus. Clearing the RNEVER bit allows the requester to
- relinquish the VMEbus in accordance with the other control bits of the requester configuration register.
- This bit is cleared by any reset.
- Bit 4 The RWD bit allows software to configure the requester release mode. When the bit is set, if RNEVER and DWB are both
- cleared to 0, the requester releases the VMEbus after the MC68030 completes a VMEbus cycle. When the bit is cleared, if
- RNEVER and DWB are both cleared to 0, the requester operates in the Release-On-Request (ROR) mode. After acquiring control
- of the VMEbus, it maintains control until it detects another request pending on the VMEbus. This bit is cleared by any reset.
- Bit 5 The RONR bit controls the manner in which the VMEchip requests the VMEbus. When the bit is set; anytime the
- MVME147 has bus mastership, then gives it up, the VMEchip does not request the VMEbus again until it detects the bus
- request signal BR*, on its level, negated for at least 150 ns. When the VMEchip detects BR* negated, it refrains from
- driving it again for at least 200 ns. This bit is cleared by any reset.
- Bit 6 The DHB status bit is 1 when the MVME147 is VMEbus master and 0 when it is not.
- Bit 7 Setting the DWB control bit to 1 causes the VMEchip to request the VMEbus (if not already bus master). When VMEbus
- mastership has been obtained, it is not relinquished until after the DWB and RNEVER bits are both cleared.
- This bit is cleared by any reset.
- */
- ret = 1 << 6; /* Let BUG147 think we are bus master. TODO: Implement proper VME bus signalling */
- LOG((" -> %02x - VMEbus Requester Configuration Register - not implemented\n", ret));
+ 0 0 0
+ 0 1 1
+ 1 0 2
+ 1 1 3
+ These bits are set to 1, 1 by any reset. Note that writes to REQLEV1,0 do not change the actual
+ requester level until the MVME147 goes through the action of having VMEbus mastership and releasing it. This means that
+ there are times when the value written into REQLEV1,0 do not match the current requester level (the request level is lagging).
+ During such times, reads to REQLEV1,0 reflect the actual requester level, not the value written into REQLEV1,0.
+ Bit 3 Setting this bit to 1 prevents the requester from releasing the VMEbus. However, unlike the DWB control bit, setting the
+ RNEVER bit does not cause the requester to request the VMEbus. Clearing the RNEVER bit allows the requester to
+ relinquish the VMEbus in accordance with the other control bits of the requester configuration register.
+ This bit is cleared by any reset.
+ Bit 4 The RWD bit allows software to configure the requester release mode. When the bit is set, if RNEVER and DWB are both
+ cleared to 0, the requester releases the VMEbus after the MC68030 completes a VMEbus cycle. When the bit is cleared, if
+ RNEVER and DWB are both cleared to 0, the requester operates in the Release-On-Request (ROR) mode. After acquiring control
+ of the VMEbus, it maintains control until it detects another request pending on the VMEbus. This bit is cleared by any reset.
+ Bit 5 The RONR bit controls the manner in which the VMEchip requests the VMEbus. When the bit is set; anytime the
+ MVME147 has bus mastership, then gives it up, the VMEchip does not request the VMEbus again until it detects the bus
+ request signal BR*, on its level, negated for at least 150 ns. When the VMEchip detects BR* negated, it refrains from
+ driving it again for at least 200 ns. This bit is cleared by any reset.
+ Bit 6 The DHB status bit is 1 when the MVME147 is VMEbus master and 0 when it is not.
+ Bit 7 Setting the DWB control bit to 1 causes the VMEchip to request the VMEbus (if not already bus master). When VMEbus
+ mastership has been obtained, it is not relinquished until after the DWB and RNEVER bits are both cleared.
+ This bit is cleared by any reset.
+ */
+ ret = 1 << 6; /* Let BUG147 think we are bus master. TODO: Implement proper VME bus signalling */
+ LOG((" -> %02x - VMEbus Requester Configuration Register - not implemented\n", ret));
break;
- case VC_MASTER_CONF : LOG((" -> %02x - Master Configuration Register - not implemented\n", ret)); break;
- case VC_SLAVE_CONF : LOG((" -> %02x - Slave Configuration Register - not implemented\n", ret)); break;
- case VC_TIMER_CONF : LOG((" -> %02x - Timer Configuration Register - not implemented\n", ret));
- /*Bits 0-1 These two bits configure the local time-out period. They are set to 1 by any reset.
+ case VC_MASTER_CONF : LOG((" -> %02x - Master Configuration Register - not implemented\n", ret)); break;
+ case VC_SLAVE_CONF : LOG((" -> %02x - Slave Configuration Register - not implemented\n", ret)); break;
+ case VC_TIMER_CONF : LOG((" -> %02x - Timer Configuration Register - not implemented\n", ret));
+ /*Bits 0-1 These two bits configure the local time-out period. They are set to 1 by any reset.
LBTO1 LBTO0 Time-Out Period
- 0 0 102 microseconds
- 0 1 205 microseconds
- 1 0 410 microseconds
- 1 1 Timer disabled
+ 0 0 102 microseconds
+ 0 1 205 microseconds
+ 1 0 410 microseconds
+ 1 1 Timer disabled
The local bus timer activates bus error to the MC68030 when it tries to access nonexistent locations in the local memory map
- Bits 2-3 These two bits configure the VMEbus access time-out period. They are set to 1 by any reset.
+ Bits 2-3 These two bits configure the VMEbus access time-out period. They are set to 1 by any reset.
ACTO1 ACTO0 Time-Out Period
- 0 0 102 microseconds
- 0 1 1.6 millisecond
- 1 0 51 milliseconds
- 1 1 Timer disabled
+ 0 0 102 microseconds
+ 0 1 1.6 millisecond
+ 1 0 51 milliseconds
+ 1 1 Timer disabled
The VMEbus access timer activates bus error to the MC68030 (except on write posted time-outs) when the VMEchip is
- unsuccessful in obtaining the VMEbus within the time-out period
- Bits 4-5 These two bits configure the VMEbus global time-out period. VBTO1 is set to 1 and VBTO0 is cleared to 0 by SYSRESET.
+ unsuccessful in obtaining the VMEbus within the time-out period
+ Bits 4-5 These two bits configure the VMEbus global time-out period. VBTO1 is set to 1 and VBTO0 is cleared to 0 by SYSRESET.
VBTO1 VBTO0 Time-Out Period
- 0 0 102 microseconds
- 0 1 205 microseconds
- 1 0 410 microseconds
- 1 1 Timer disabled
- The VMEbus global timer activates BERR* on the VMEbus.
- Bit 6 Setting ARBTO to 1 enables the VMEbus arbitration timer. The VMEbus arbitration timer activates BBSY* if it is not activated
- within 410 µs after the MVME147 arbiter issues a bus grant. The timer deactivates BBSY* as specified in the VMEbus specification.
+ 0 0 102 microseconds
+ 0 1 205 microseconds
+ 1 0 410 microseconds
+ 1 1 Timer disabled
+ The VMEbus global timer activates BERR* on the VMEbus.
+ Bit 6 Setting ARBTO to 1 enables the VMEbus arbitration timer. The VMEbus arbitration timer activates BBSY* if it is not activated
+ within 410 us after the MVME147 arbiter issues a bus grant. The timer deactivates BBSY* as specified in the VMEbus specification.
This causes the arbiter to arbitrate any pending requests for the bus. This bit is set to 1 by SYSRESET.
- */
+ */
break;
- case VC_SLAVE_ADR_MOD : LOG((" -> %02x - Slave Address Modifier Register - not implemented\n", ret)); break;
- case VC_MASTER_ADR_MOD : LOG((" -> %02x - Master Address Modifier Register - not implemented\n", ret)); break;
- case VC_INT_HNDL_MASK : LOG((" -> %02x - Interrupt Handler Mask Register - not implemented\n", ret)); break;
- case VC_UTIL_INT_MASK : LOG((" -> %02x - Utility Interrupt Mask Register - not implemented\n", ret)); break;
- case VC_UTIL_INT_VECT : LOG((" -> %02x - Utility Interrupt Vector Register - not implemented\n", ret)); break;
- case VC_INT_REQUEST : LOG((" -> %02x - Interrupt Request Register - not implemented\n", ret)); break;
- case VC_VMEBUS_STAT_ID : LOG((" -> %02x - VMEbus Status/ID Register - not implemented\n", ret)); break;
- case VC_BUS_ERR_STATUS : LOG((" -> %02x - Bus Error Status Register - not implemented\n", ret)); break;
- case VC_GCSR_BASE_ADR : LOG((" -> %02x - GCSR Base Address Configuration Register - not implemented\n", ret)); break;
+ case VC_SLAVE_ADR_MOD : LOG((" -> %02x - Slave Address Modifier Register - not implemented\n", ret)); break;
+ case VC_MASTER_ADR_MOD : LOG((" -> %02x - Master Address Modifier Register - not implemented\n", ret)); break;
+ case VC_INT_HNDL_MASK : LOG((" -> %02x - Interrupt Handler Mask Register - not implemented\n", ret)); break;
+ case VC_UTIL_INT_MASK : LOG((" -> %02x - Utility Interrupt Mask Register - not implemented\n", ret)); break;
+ case VC_UTIL_INT_VECT : LOG((" -> %02x - Utility Interrupt Vector Register - not implemented\n", ret)); break;
+ case VC_INT_REQUEST : LOG((" -> %02x - Interrupt Request Register - not implemented\n", ret)); break;
+ case VC_VMEBUS_STAT_ID : LOG((" -> %02x - VMEbus Status/ID Register - not implemented\n", ret)); break;
+ case VC_BUS_ERR_STATUS : LOG((" -> %02x - Bus Error Status Register - not implemented\n", ret)); break;
+ case VC_GCSR_BASE_ADR : LOG((" -> %02x - GCSR Base Address Configuration Register - not implemented\n", ret)); break;
default:
LOG(("unsupported register"));
- }
- return ret;
+ }
+ return ret;
}
WRITE8_MEMBER (mvme147_state::vmechip_w){
LOG(("Call to %s[%04x] <- %02x - ", FUNCNAME, offset, data));
switch(offset * 2 + VCBASE)
{
- case VC_SYS_CNTL_CONF :
- LOG(("System Controller Configuration Register - not implemented\n"));
+ case VC_SYS_CNTL_CONF :
+ LOG(("System Controller Configuration Register - not implemented\n"));
m_vc_cntl_conf = data & 0xff;
break;
- case VC_VMEBUS_REQ_CONF : LOG(("VMEbus Requester Configuration Register - not implemented\n")); break;
- case VC_MASTER_CONF : LOG(("Master Configuration Register - not implemented\n")); break;
- case VC_SLAVE_CONF : LOG(("Slave Configuration Register - not implemented\n")); break;
- case VC_TIMER_CONF : LOG(("Timer Configuration Register - not implemented\n")); break;
- case VC_SLAVE_ADR_MOD : LOG(("Slave Address Modifier Register - not implemented\n")); break;
- case VC_MASTER_ADR_MOD : LOG(("Master Address Modifier Register - not implemented\n")); break;
- case VC_INT_HNDL_MASK : LOG(("Interrupt Handler Mask Register - not implemented\n")); break;
- case VC_UTIL_INT_MASK : LOG(("Utility Interrupt Mask Register - not implemented\n")); break;
- case VC_UTIL_INT_VECT : LOG(("Utility Interrupt Vector Register - not implemented\n")); break;
- case VC_INT_REQUEST : LOG(("Interrupt Request Register - not implemented\n")); break;
- case VC_VMEBUS_STAT_ID : LOG(("VMEbus Status/ID Register - not implemented\n")); break;
- case VC_BUS_ERR_STATUS : LOG(("Bus Error Status Register - not implemented\n")); break;
- case VC_GCSR_BASE_ADR : LOG(("GCSR Base Address Configuration Register - not implemented\n")); break;
+ case VC_VMEBUS_REQ_CONF : LOG(("VMEbus Requester Configuration Register - not implemented\n")); break;
+ case VC_MASTER_CONF : LOG(("Master Configuration Register - not implemented\n")); break;
+ case VC_SLAVE_CONF : LOG(("Slave Configuration Register - not implemented\n")); break;
+ case VC_TIMER_CONF : LOG(("Timer Configuration Register - not implemented\n")); break;
+ case VC_SLAVE_ADR_MOD : LOG(("Slave Address Modifier Register - not implemented\n")); break;
+ case VC_MASTER_ADR_MOD : LOG(("Master Address Modifier Register - not implemented\n")); break;
+ case VC_INT_HNDL_MASK : LOG(("Interrupt Handler Mask Register - not implemented\n")); break;
+ case VC_UTIL_INT_MASK : LOG(("Utility Interrupt Mask Register - not implemented\n")); break;
+ case VC_UTIL_INT_VECT : LOG(("Utility Interrupt Vector Register - not implemented\n")); break;
+ case VC_INT_REQUEST : LOG(("Interrupt Request Register - not implemented\n")); break;
+ case VC_VMEBUS_STAT_ID : LOG(("VMEbus Status/ID Register - not implemented\n")); break;
+ case VC_BUS_ERR_STATUS : LOG(("Bus Error Status Register - not implemented\n")); break;
+ case VC_GCSR_BASE_ADR : LOG(("GCSR Base Address Configuration Register - not implemented\n")); break;
default:
LOG(("unsupported register\n"));
}
@@ -669,18 +666,18 @@ ROM_LOAD16_BYTE("147bug-2.44-U30.BIN", 0xff800001, 0x20000, CRC (f883e17d) SHA1
* 09 80 - Channel A reset
* 04 44 - x16 clock, 1 stop bits, no parity
* 03 C1 - 8 bit, receiver enable, auto enable off
- * 01 00 -
+ * 01 00 -
* 02 70 - set interrupt vector 70
* 05 EA
* 0B 56
- * 0C 0E - low baudrate divider
- * 0D 00 - hi baudrate divider
+ * 0C 0E - low baudrate divider
+ * 0D 00 - hi baudrate divider
* 0E 83 - Baud Rate Generator (BRG) enabled, PCLK is BRG source, BRG is DPLL source
* 06 00 - Tx sync character SDLC
* 07 00 - Rx sync character SDLC
* 0F 00 - disable all external interrupt and status
* 10
- * channel B is identical but resets Channel B of course, SCC2 is also identical except using interrupt vector 71
+ * channel B is identical but resets Channel B of course, SCC2 is also identical except using interrupt vector 71
*/
ROM_END
diff --git a/src/mame/drivers/neogeo.cpp b/src/mame/drivers/neogeo.cpp
index 644c4a1873e..6ed800c3006 100644
--- a/src/mame/drivers/neogeo.cpp
+++ b/src/mame/drivers/neogeo.cpp
@@ -432,7 +432,7 @@
backup ram to indiate that the protection check has failed.
****************************************************************************
-
+
Mahjong Panel notes (2009-03 FP):
=================================
@@ -451,8 +451,8 @@
doubt other BIOS were programmed to be compatible with mahjong panels
****************************************************************************
-
- AES driver (home version of MVS)
+
+ AES driver (home version of MVS)
Current emulation status:
- Cartridges run.
- Riding Hero runs in slow-mo due to the unemulated comm link MCU in the cartridge.
@@ -892,13 +892,13 @@ WRITE8_MEMBER(neogeo_state::system_control_w)
WRITE16_MEMBER(neogeo_state::write_banksel)
{
UINT32 len = (!m_slots[m_curr_slot] || m_slots[m_curr_slot]->get_rom_size() == 0) ? m_region_maincpu->bytes() : m_slots[m_curr_slot]->get_rom_size();
-
+
if ((len <= 0x100000) && (data & 0x07))
logerror("PC %06x: warning: bankswitch to %02x but no banks available\n", space.device().safe_pc(), data);
else
{
int bank = data & 0x07;
-
+
if ((bank + 1) * 0x100000 >= len)
{
logerror("PC %06x: warning: bankswitch to empty bank %02x\n", space.device().safe_pc(), data);
@@ -986,7 +986,7 @@ WRITE16_MEMBER(neogeo_state::write_bankprot_pvc)
{
// write to cart ram
m_slots[m_curr_slot]->protection_w(space, offset, data, mem_mask);
-
+
// actual bankswitch
if (offset >= 0xff8)
{
@@ -999,7 +999,7 @@ WRITE16_MEMBER(neogeo_state::write_bankprot_kf2k3bl)
{
// write to cart ram
m_slots[m_curr_slot]->protection_w(space, offset, data, mem_mask);
-
+
// actual bankswitch
if (offset == 0x1ff0/2 || offset == 0x1ff2/2)
{
@@ -1011,7 +1011,7 @@ WRITE16_MEMBER(neogeo_state::write_bankprot_kf2k3bl)
WRITE16_MEMBER(neogeo_state::write_bankprot_ms5p)
{
logerror("ms5plus bankswitch - offset: %06x PC %06x: set banking %04x\n", offset, space.device().safe_pc(), data);
-
+
if ((offset == 0) && (data == 0xa0))
{
m_bank_base = 0xa0;
@@ -1027,7 +1027,7 @@ WRITE16_MEMBER(neogeo_state::write_bankprot_ms5p)
WRITE16_MEMBER(neogeo_state::write_bankprot_kof10th)
{
m_slots[m_curr_slot]->protection_w(space, offset, data, mem_mask);
-
+
if (offset == 0xffff0/2)
{
// Standard bankswitch
@@ -1054,7 +1054,7 @@ void neogeo_state::init_cpu()
{
UINT8 *ROM = (!m_slots[m_curr_slot] || m_slots[m_curr_slot]->get_rom_size() == 0) ? m_region_maincpu->base() : (UINT8 *)m_slots[m_curr_slot]->get_rom_base();
UINT32 len = (!m_slots[m_curr_slot] || m_slots[m_curr_slot]->get_rom_size() == 0) ? m_region_maincpu->bytes() : m_slots[m_curr_slot]->get_rom_size();
-
+
if (len > 0x100000)
m_bank_cartridge->set_base(ROM + 0x100000);
else
@@ -1066,18 +1066,18 @@ void neogeo_state::init_audio()
UINT8 *ROM = (!m_slots[m_curr_slot] || m_slots[m_curr_slot]->get_audio_size() == 0) ? m_region_audiocpu->base() : m_slots[m_curr_slot]->get_audio_base();
UINT32 len = (!m_slots[m_curr_slot] || m_slots[m_curr_slot]->get_audio_size() == 0) ? m_region_audiocpu->bytes() : m_slots[m_curr_slot]->get_audio_size();
UINT32 address_mask;
-
+
/* audio bios/cartridge selection */
m_bank_audio_main->configure_entry(0, (m_region_audiobios != nullptr) ? m_region_audiobios->base() : ROM); /* on hardware with no SM1 ROM, the cart ROM is always enabled */
m_bank_audio_main->configure_entry(1, ROM);
m_bank_audio_main->set_entry(1);
-
+
/* audio banking */
m_bank_audio_cart[0] = membank("audio_f000");
m_bank_audio_cart[1] = membank("audio_e000");
m_bank_audio_cart[2] = membank("audio_c000");
m_bank_audio_cart[3] = membank("audio_8000");
-
+
address_mask = (len - 0x10000 - 1) & 0x3ffff;
for (int region = 0; region < 4; region++)
{
@@ -1087,7 +1087,7 @@ void neogeo_state::init_audio()
m_bank_audio_cart[region]->configure_entry(bank, &ROM[bank_address]);
}
}
-
+
// set initial audio banks - THIS IS A HACK
// Z80 banking is handled by the NEO-ZMC chip in the cartridge
// (in later cartridges, by multifunction banking/protection chips that implement the same bank scheme)
@@ -1105,12 +1105,12 @@ void neogeo_state::init_ym()
{
UINT8 *ROM;
UINT32 len;
-
+
// Resetting a sound device causes the core to update() it and generate samples if it's not up to date.
// Thus we preemptively reset it here while the old pointers are still valid so it's up to date and
// doesn't generate samples below when we reset it for the new pointers.
m_ym->reset();
-
+
// all these region_free / region_alloc machinery is needed because current YM emulation does not allow
// to pass a ROM pointer different from a "ymsnd" / "ymsnd.deltat" region, and therefore we need to copy
// the ROM(s) from the cart to the corresponding region(s) with appropriate names...
@@ -1123,17 +1123,17 @@ void neogeo_state::init_ym()
machine().memory().region_alloc(":ymsnd", len, 1, ENDIANNESS_LITTLE);
memcpy(memregion(":ymsnd")->base(), ROM, len);
}
-
+
if (memregion(":ymsnd.deltat"))
machine().memory().region_free(":ymsnd.deltat");
if (m_slots[m_curr_slot] && m_slots[m_curr_slot]->get_ymdelta_size())
{
ROM = m_slots[m_curr_slot]->get_ymdelta_base();
- len = m_slots[m_curr_slot]->get_ymdelta_size();
+ len = m_slots[m_curr_slot]->get_ymdelta_size();
machine().memory().region_alloc(":ymsnd.deltat", len, 1, ENDIANNESS_LITTLE);
memcpy(memregion(":ymsnd.deltat")->base(), ROM, len);
}
-
+
m_ym->reset(); // reset it again to get the new pointers
}
@@ -1164,10 +1164,10 @@ void neogeo_state::set_slot_idx(int slot)
address_space &space = m_maincpu->space(AS_PROGRAM);
m_curr_slot = slot;
m_bank_base = 0;
-
+
if (!m_slots[m_curr_slot]->user_loadable())
m_slots[m_curr_slot]->late_decrypt_all();
-
+
// unmap any handler that previous carts could have installed
space.unmap_readwrite(0x000080, 0x0fffff);
space.unmap_readwrite(0x200000, 0x2fffff);
@@ -1175,24 +1175,24 @@ void neogeo_state::set_slot_idx(int slot)
space.install_rom(0x000080, 0x0fffff, 0, 0, (UINT16 *)m_region_maincpu->base() + 0x80/2);
else
space.install_rom(0x000080, 0x0fffff, 0, 0, (UINT16 *)m_slots[m_curr_slot]->get_rom_base() + 0x80/2);
-
+
space.install_read_bank(0x200000, 0x2fffff, 0, 0, "cartridge");
space.install_write_handler(0x2ffff0, 0x2fffff, write16_delegate(FUNC(neogeo_state::write_banksel),this));
m_bank_cartridge = membank("cartridge");
-
+
init_cpu();
-
+
init_audio();
m_audiocpu->reset(); // svc have no sound if in higher slots without this?
-
+
init_ym();
-
+
init_sprites();
-
+
if (!m_slots[m_curr_slot]->user_loadable())
m_slots[m_curr_slot]->set_cart_type(m_slots[m_curr_slot]->default_option());
-
+
int type = m_slots[m_curr_slot]->get_type();
switch (type)
{
@@ -1306,16 +1306,16 @@ void neogeo_state::set_slot_idx(int slot)
void neogeo_state::common_machine_start()
{
m_use_cart_vectors = 0;
-
+
create_interrupt_timers();
-
+
/* irq levels for MVS / AES */
m_vblank_level = 1;
m_raster_level = 2;
-
+
/* start with an IRQ3 - but NOT on a reset */
m_irq3_pending = 1;
-
+
/* register state save */
save_item(NAME(m_display_position_interrupt_control));
save_item(NAME(m_display_counter));
@@ -1346,21 +1346,21 @@ void neogeo_state::machine_start()
{
m_type = NEOGEO_MVS;
common_machine_start();
-
+
// enable rtc and serial mode
m_upd4990a->cs_w(1);
m_upd4990a->oe_w(1);
m_upd4990a->c0_w(1);
m_upd4990a->c1_w(1);
m_upd4990a->c2_w(1);
-
+
if (m_slot1) { m_slots[0] = m_slot1; } else { m_slots[0] = nullptr; }
if (m_slot2) { m_slots[1] = m_slot2; } else { m_slots[1] = nullptr; }
if (m_slot3) { m_slots[2] = m_slot3; } else { m_slots[2] = nullptr; }
if (m_slot4) { m_slots[3] = m_slot4; } else { m_slots[3] = nullptr; }
if (m_slot5) { m_slots[4] = m_slot5; } else { m_slots[4] = nullptr; }
if (m_slot6) { m_slots[5] = m_slot6; } else { m_slots[5] = nullptr; }
-
+
m_sprgen->m_fixed_layer_bank_type = 0;
m_sprgen->set_screen(m_screen);
@@ -1372,7 +1372,7 @@ void neogeo_state::machine_start()
void neogeo_state::neogeo_postload()
{
m_bank_audio_main->set_entry(m_use_cart_audio);
-
+
if (m_type == NEOGEO_MVS)
set_outputs();
if (m_type == NEOGEO_MVS || m_type == NEOGEO_AES)
@@ -1392,23 +1392,23 @@ void neogeo_state::machine_reset()
{
offs_t offs;
address_space &space = m_maincpu->space(AS_PROGRAM);
-
+
// reset system control registers
for (offs = 0; offs < 8; offs++)
system_control_w(space, offs, 0);
-
+
// disable audiocpu nmi
m_audio_cpu_nmi_enabled = false;
m_audio_cpu_nmi_pending = false;
audio_cpu_check_nmi();
-
+
m_maincpu->reset();
-
+
start_interrupt_timers();
-
+
// trigger the IRQ3 that was set by MACHINE_START
update_interrupts();
-
+
m_recurse = false;
}
@@ -1700,23 +1700,23 @@ MACHINE_CONFIG_END
// two cartslots (MV-2F)
#define NEOGEO_CONFIG_TWO_CARTSLOTS \
- NEOGEO_CONFIG_CARTSLOT("cslot1") \
+ NEOGEO_CONFIG_CARTSLOT("cslot1") \
NEOGEO_CONFIG_CARTSLOT("cslot2")
// four cartslots (MV-4F)
#define NEOGEO_CONFIG_FOUR_CARTSLOTS \
- NEOGEO_CONFIG_CARTSLOT("cslot1") \
- NEOGEO_CONFIG_CARTSLOT("cslot2") \
- NEOGEO_CONFIG_CARTSLOT("cslot3") \
+ NEOGEO_CONFIG_CARTSLOT("cslot1") \
+ NEOGEO_CONFIG_CARTSLOT("cslot2") \
+ NEOGEO_CONFIG_CARTSLOT("cslot3") \
NEOGEO_CONFIG_CARTSLOT("cslot4")
// six cartslots (MV-6F)
#define NEOGEO_CONFIG_SIX_CARTSLOTS \
- NEOGEO_CONFIG_CARTSLOT("cslot1") \
- NEOGEO_CONFIG_CARTSLOT("cslot2") \
- NEOGEO_CONFIG_CARTSLOT("cslot3") \
- NEOGEO_CONFIG_CARTSLOT("cslot4") \
- NEOGEO_CONFIG_CARTSLOT("cslot5") \
+ NEOGEO_CONFIG_CARTSLOT("cslot1") \
+ NEOGEO_CONFIG_CARTSLOT("cslot2") \
+ NEOGEO_CONFIG_CARTSLOT("cslot3") \
+ NEOGEO_CONFIG_CARTSLOT("cslot4") \
+ NEOGEO_CONFIG_CARTSLOT("cslot5") \
NEOGEO_CONFIG_CARTSLOT("cslot6")
@@ -1746,14 +1746,14 @@ MACHINE_START_MEMBER(aes_state, aes)
{
m_type = NEOGEO_AES;
common_machine_start();
-
+
m_slots[0] = m_slot1;
m_slots[1] = nullptr;
m_slots[2] = nullptr;
m_slots[3] = nullptr;
m_slots[4] = nullptr;
m_slots[5] = nullptr;
-
+
m_sprgen->m_fixed_layer_bank_type = 0;
m_sprgen->set_screen(m_screen);
@@ -2036,4 +2036,3 @@ CONS( 1990, aes, 0, 0, aes, aes, driver_device, 0,
// Include standalone drivers for the single games
#include "neodriv.hxx"
-
diff --git a/src/mame/drivers/neopcb.cpp b/src/mame/drivers/neopcb.cpp
index d23aefca218..e33e82c9113 100644
--- a/src/mame/drivers/neopcb.cpp
+++ b/src/mame/drivers/neopcb.cpp
@@ -11,7 +11,7 @@ void neopcb_state::machine_start()
{
m_type = NEOGEO_MVS;
common_machine_start();
-
+
// enable rtc and serial mode
m_upd4990a->cs_w(1);
m_upd4990a->oe_w(1);
@@ -243,7 +243,7 @@ void neopcb_state::svcpcb_gfx_decrypt()
int rom_size = memregion("sprites")->bytes();
UINT8 *rom = memregion("sprites")->base();
dynamic_buffer buf(rom_size);
-
+
for (int i = 0; i < rom_size; i++)
rom[i] ^= xorval[(i % 4)];
@@ -287,7 +287,7 @@ void neopcb_state::kf2k3pcb_gfx_decrypt()
int rom_size = memregion("sprites")->bytes();
UINT8 *rom = memregion("sprites")->base();
dynamic_buffer buf(rom_size);
-
+
for (int i = 0; i < rom_size; i++)
rom[ i ] ^= xorval[ (i % 4) ];
@@ -320,18 +320,18 @@ void neopcb_state::kf2k3pcb_decrypt_s1data()
int srom_size = memregion("sprites")->bytes();
src = memregion("sprites")->base() + srom_size - 0x1000000 - 0x80000; // Decrypt S
dst = memregion("fixed")->base();
-
+
for (int i = 0; i < tx_size / 2; i++)
dst[i] = src[(i & ~0x1f) + ((i & 7) << 2) + ((~i & 8) >> 2) + ((i & 0x10) >> 4)];
-
+
src = memregion("sprites")->base() + srom_size - 0x80000;
dst = memregion("fixed")->base() + 0x80000;
-
- for (int i = 0; i < tx_size / 2; i++)
+
+ for (int i = 0; i < tx_size / 2; i++)
dst[i] = src[(i & ~0x1f) + ((i & 7) << 2) + ((~i & 8) >> 2) + ((i & 0x10) >> 4)];
-
+
dst = memregion("fixed")->base();
-
+
for (int i = 0; i < tx_size; i++)
dst[i] = BITSWAP8(dst[i] ^ 0xd2, 4, 0, 7, 2, 5, 1, 6, 3);
}
@@ -350,10 +350,10 @@ void neopcb_state::kf2k3pcb_sp1_decrypt()
0x03,0x05,0x0b,0x0d,0x03,0x05,0x0b,0x0d,
0x04,0x00,0x04,0x00,0x0e,0x0a,0x0e,0x0a
};
-
+
UINT16 *rom = (UINT16 *)memregion("mainbios")->base();
std::vector<UINT16> buf(0x80000/2);
-
+
for (int i = 0; i < 0x80000/2; i++)
{
// address xor
@@ -367,13 +367,13 @@ void neopcb_state::kf2k3pcb_sp1_decrypt()
if ( i & 0x02000) addr ^= 0x8000;
addr ^= address[((i >> 1) & 0x38) | (i & 7)];
buf[i] = rom[addr];
-
+
// data xor
if (buf[i] & 0x0004) buf[i] ^= 0x0001;
if (buf[i] & 0x0010) buf[i] ^= 0x0002;
if (buf[i] & 0x0020) buf[i] ^= 0x0008;
}
-
+
memcpy(rom, &buf[0], 0x80000);
}
@@ -406,7 +406,7 @@ WRITE16_MEMBER(neopcb_state::write_bankpvc)
{
// write to cart ram
m_pvc_prot->protection_w(space, offset, data, mem_mask);
-
+
// actual bankswitch
if (offset >= 0xff8)
{
@@ -424,7 +424,7 @@ void neopcb_state::install_common()
// install protection handlers + bankswitch handler
m_maincpu->space(AS_PROGRAM).install_readwrite_handler(0x2fe000, 0x2fffff, read16_delegate(FUNC(pvc_prot_device::protection_r),(pvc_prot_device*)m_pvc_prot), write16_delegate(FUNC(neopcb_state::write_bankpvc),this));
-
+
// perform basic memory initialization that are usually done on-cart
m_curr_slot = 0;
m_bank_base = 0;
@@ -439,7 +439,7 @@ void neopcb_state::install_banked_bios()
m_maincpu->space(AS_PROGRAM).install_read_bank(0xc00000, 0xc1ffff, 0, 0x0e0000, "bios_bank");
membank("bios_bank")->configure_entries(0, 2, memregion("mainbios")->base(), 0x20000);
membank("bios_bank")->set_entry(1);
-
+
}
DRIVER_INIT_MEMBER(neopcb_state, ms5pcb)
@@ -513,4 +513,3 @@ GAME( 2003, ms5pcb, 0, neopcb, dualbios, neopcb_state, ms5pcb, RO
GAME( 2003, svcpcb, 0, neopcb, dualbios, neopcb_state, svcpcb, ROT0, "SNK Playmore", "SNK vs. Capcom - SVC Chaos (JAMMA PCB, set 1)", MACHINE_SUPPORTS_SAVE )
GAME( 2003, svcpcba, svcpcb, neopcb, dualbios, neopcb_state, svcpcb, ROT0, "SNK Playmore", "SNK vs. Capcom - SVC Chaos (JAMMA PCB, set 2)" , MACHINE_SUPPORTS_SAVE ) /* Encrypted Code */
GAME( 2003, kf2k3pcb, 0, neopcb, neogeo, neopcb_state, kf2k3pcb, ROT0, "SNK Playmore", "The King of Fighters 2003 (Japan, JAMMA PCB)", MACHINE_SUPPORTS_SAVE )
-
diff --git a/src/mame/drivers/seattle.cpp b/src/mame/drivers/seattle.cpp
index 3d9034e1c7b..395b7cfd0fd 100644
--- a/src/mame/drivers/seattle.cpp
+++ b/src/mame/drivers/seattle.cpp
@@ -2701,7 +2701,7 @@ MACHINE_CONFIG_END
static MACHINE_CONFIG_DERIVED( blitz99, seattle150 )
MCFG_DEVICE_ADD("dcs", DCS2_AUDIO_2115, 0)
MCFG_DCS2_AUDIO_DRAM_IN_MB(2)
-// MCFG_DCS2_AUDIO_POLLING_OFFSET(0x0afb) -- Not in ram???
+// MCFG_DCS2_AUDIO_POLLING_OFFSET(0x0afb) -- Not in ram???
MCFG_DEVICE_ADD("ioasic", MIDWAY_IOASIC, 0)
MCFG_MIDWAY_IOASIC_SHUFFLE(MIDWAY_IOASIC_BLITZ99)
@@ -2713,7 +2713,7 @@ MACHINE_CONFIG_END
static MACHINE_CONFIG_DERIVED( blitz2k, seattle150 )
MCFG_DEVICE_ADD("dcs", DCS2_AUDIO_2115, 0)
MCFG_DCS2_AUDIO_DRAM_IN_MB(2)
-// MCFG_DCS2_AUDIO_POLLING_OFFSET(0x0b5d) -- Not in ram???
+// MCFG_DCS2_AUDIO_POLLING_OFFSET(0x0b5d) -- Not in ram???
MCFG_DEVICE_ADD("ioasic", MIDWAY_IOASIC, 0)
MCFG_MIDWAY_IOASIC_SHUFFLE(MIDWAY_IOASIC_BLITZ99)
@@ -2725,7 +2725,7 @@ MACHINE_CONFIG_END
static MACHINE_CONFIG_DERIVED( carnevil, seattle150 )
MCFG_DEVICE_ADD("dcs", DCS2_AUDIO_2115, 0)
MCFG_DCS2_AUDIO_DRAM_IN_MB(2)
-// MCFG_DCS2_AUDIO_POLLING_OFFSET(0x0af7) -- Not in ram???
+// MCFG_DCS2_AUDIO_POLLING_OFFSET(0x0af7) -- Not in ram???
MCFG_DEVICE_ADD("ioasic", MIDWAY_IOASIC, 0)
MCFG_MIDWAY_IOASIC_SHUFFLE(MIDWAY_IOASIC_CARNEVIL)
@@ -2737,7 +2737,7 @@ MACHINE_CONFIG_END
static MACHINE_CONFIG_DERIVED( hyprdriv, seattle200_widget )
MCFG_DEVICE_ADD("dcs", DCS2_AUDIO_2115, 0)
MCFG_DCS2_AUDIO_DRAM_IN_MB(2)
-// MCFG_DCS2_AUDIO_POLLING_OFFSET(0x0af7) -- Not in ram???
+// MCFG_DCS2_AUDIO_POLLING_OFFSET(0x0af7) -- Not in ram???
MCFG_DEVICE_ADD("ioasic", MIDWAY_IOASIC, 0)
MCFG_MIDWAY_IOASIC_SHUFFLE(MIDWAY_IOASIC_HYPRDRIV)
diff --git a/src/mame/drivers/skylncr.cpp b/src/mame/drivers/skylncr.cpp
index 2bc5ac2fc1b..1c06057c8f9 100644
--- a/src/mame/drivers/skylncr.cpp
+++ b/src/mame/drivers/skylncr.cpp
@@ -1932,7 +1932,7 @@ DRIVER_INIT_MEMBER(skylncr_state, sonikfig)
00 01 02 03 04 05 06 07
\ /
SWAPPED
-
+
00 01 02 03 04 05 06 07
\ \ / /
\ X /
diff --git a/src/mame/drivers/thomson.cpp b/src/mame/drivers/thomson.cpp
index 5b138d2a082..75027cdfecb 100644
--- a/src/mame/drivers/thomson.cpp
+++ b/src/mame/drivers/thomson.cpp
@@ -742,7 +742,7 @@ static MACHINE_CONFIG_START( to7, thomson_state )
MCFG_RAM_ADD(RAM_TAG)
MCFG_RAM_DEFAULT_SIZE("40K")
MCFG_RAM_EXTRA_OPTIONS("24K,48K")
-
+
/* software lists */
MCFG_SOFTWARE_LIST_ADD("to7_cart_list","to7_cart")
MCFG_SOFTWARE_LIST_ADD("to7_cass_list","to7_cass")
@@ -2235,7 +2235,7 @@ static MACHINE_CONFIG_DERIVED( mo6, to7 )
/* internal ram */
MCFG_RAM_MODIFY(RAM_TAG)
MCFG_RAM_DEFAULT_SIZE("128K")
-
+
MCFG_DEVICE_REMOVE("to7_cart_list")
MCFG_DEVICE_REMOVE("to7_cass_list")
MCFG_DEVICE_REMOVE("to_flop_list")
@@ -2505,7 +2505,7 @@ static MACHINE_CONFIG_DERIVED( mo5nr, to7 )
/* internal ram */
MCFG_RAM_MODIFY(RAM_TAG)
MCFG_RAM_DEFAULT_SIZE("128K")
-
+
MCFG_DEVICE_REMOVE("to7_cart_list")
MCFG_DEVICE_REMOVE("to7_cass_list")
MCFG_DEVICE_REMOVE("to_flop_list")
diff --git a/src/mame/drivers/ticalc1x.cpp b/src/mame/drivers/ticalc1x.cpp
index 04dea3b8e16..e558e53756b 100644
--- a/src/mame/drivers/ticalc1x.cpp
+++ b/src/mame/drivers/ticalc1x.cpp
@@ -913,7 +913,7 @@ MACHINE_CONFIG_END
TI Math Marvel
* TMS1980 MCU label TMC1986A-NL (die label 1980A 86A)
* 9-digit cyan VFD display(2 digits are custom), 1-bit sound
-
+
This is the same hardware as DataMan, with R8 connected to a piezo.
***************************************************************************/
@@ -934,7 +934,7 @@ WRITE16_MEMBER(mathmarv_state::write_r)
{
// R8: speaker out
m_speaker->level_w(data >> 8 & 1);
-
+
// rest is same as dataman
dataman_state::write_r(space, offset, data);
}
diff --git a/src/mame/drivers/tourvis.cpp b/src/mame/drivers/tourvis.cpp
index 4ea88122232..18887ebcf4c 100644
--- a/src/mame/drivers/tourvis.cpp
+++ b/src/mame/drivers/tourvis.cpp
@@ -381,7 +381,7 @@ static INPUT_PORTS_START( tourvision )
PORT_DIPSETTING( 0x10, "120" )
PORT_DIPSETTING( 0x08, "90" )
PORT_DIPSETTING( 0x00, "60" )
- PORT_DIPNAME( 0x80, 0x00, DEF_STR( Demo_Sounds ) )
+ PORT_DIPNAME( 0x80, 0x00, DEF_STR( Demo_Sounds ) )
PORT_START( "DSW2" )
PORT_DIPNAME( 0x03, 0x03, "Coins needed 2" )
diff --git a/src/mame/drivers/unixpc.cpp b/src/mame/drivers/unixpc.cpp
index 63bbe281737..d579128dfc8 100644
--- a/src/mame/drivers/unixpc.cpp
+++ b/src/mame/drivers/unixpc.cpp
@@ -5,13 +5,13 @@
AT&T Unix PC series
Skeleton driver by Dirk Best and R. Belmont
-
- DIVS instruction at 0x801112 (the second time) causes a divide-by-zero
- exception the system isn't ready for due to word at 0x5EA6 being zero.
-
- Code might not get there if the attempted FDC boot succeeds; FDC hookup
- probably needs help. 2797 isn't asserting DRQ?
-
+
+ DIVS instruction at 0x801112 (the second time) causes a divide-by-zero
+ exception the system isn't ready for due to word at 0x5EA6 being zero.
+
+ Code might not get there if the attempted FDC boot succeeds; FDC hookup
+ probably needs help. 2797 isn't asserting DRQ?
+
***************************************************************************/
@@ -66,13 +66,13 @@ public:
DECLARE_READ16_MEMBER( diskdma_size_r );
DECLARE_WRITE16_MEMBER( diskdma_size_w );
DECLARE_WRITE16_MEMBER( diskdma_ptr_w );
-
+
DECLARE_WRITE_LINE_MEMBER( wd2797_intrq_w );
DECLARE_WRITE_LINE_MEMBER( wd2797_drq_w );
required_shared_ptr<UINT16> m_mapram;
required_shared_ptr<UINT16> m_videoram;
-
+
private:
UINT16 *m_ramptr;
UINT32 m_ramsize;
@@ -183,7 +183,7 @@ WRITE16_MEMBER( unixpc_state::misc_control_w )
// bit 14 = 0 for disk DMA write, 1 for disk DMA read
// bit 13 = Centronics strobe
// bit 12 = 0 = modem baud rate from UART clock inputs, 1 = baud from programmable timer
-
+
output().set_value("led_0", !BIT(data, 8));
output().set_value("led_1", !BIT(data, 9));
output().set_value("led_2", !BIT(data, 10));
@@ -218,7 +218,7 @@ WRITE16_MEMBER( unixpc_state::diskdma_ptr_w )
m_diskdmaptr &= 0xffff00;
m_diskdmaptr |= (offset & 0xff);
}
-
+
logerror("diskdma_ptr_w: wrote at %x, ptr now %x\n", offset<<1, m_diskdmaptr);
}
diff --git a/src/mame/drivers/vegas.cpp b/src/mame/drivers/vegas.cpp
index 2754a7afe92..395779d3c44 100644
--- a/src/mame/drivers/vegas.cpp
+++ b/src/mame/drivers/vegas.cpp
@@ -2313,7 +2313,7 @@ MACHINE_CONFIG_END
static MACHINE_CONFIG_DERIVED( gauntleg, vegas )
MCFG_DEVICE_ADD("dcs", DCS2_AUDIO_2104, 0)
MCFG_DCS2_AUDIO_DRAM_IN_MB(4)
-// MCFG_DCS2_AUDIO_POLLING_OFFSET(0x0b5d) -- Not in ram???
+// MCFG_DCS2_AUDIO_POLLING_OFFSET(0x0b5d) -- Not in ram???
MCFG_DEVICE_ADD("ioasic", MIDWAY_IOASIC, 0)
MCFG_MIDWAY_IOASIC_SHUFFLE(MIDWAY_IOASIC_CALSPEED)
@@ -2326,7 +2326,7 @@ MACHINE_CONFIG_END
static MACHINE_CONFIG_DERIVED( gauntdl, vegas )
MCFG_DEVICE_ADD("dcs", DCS2_AUDIO_2104, 0)
MCFG_DCS2_AUDIO_DRAM_IN_MB(4)
-// MCFG_DCS2_AUDIO_POLLING_OFFSET(0x0b5d) -- Not in ram???
+// MCFG_DCS2_AUDIO_POLLING_OFFSET(0x0b5d) -- Not in ram???
MCFG_DEVICE_ADD("ioasic", MIDWAY_IOASIC, 0)
MCFG_MIDWAY_IOASIC_SHUFFLE(MIDWAY_IOASIC_GAUNTDL)
@@ -2339,7 +2339,7 @@ MACHINE_CONFIG_END
static MACHINE_CONFIG_DERIVED( warfa, vegas250 )
MCFG_DEVICE_ADD("dcs", DCS2_AUDIO_2104, 0)
MCFG_DCS2_AUDIO_DRAM_IN_MB(4)
-// MCFG_DCS2_AUDIO_POLLING_OFFSET(0x0b5d) -- Not in ram???
+// MCFG_DCS2_AUDIO_POLLING_OFFSET(0x0b5d) -- Not in ram???
MCFG_DEVICE_ADD("ioasic", MIDWAY_IOASIC, 0)
MCFG_MIDWAY_IOASIC_SHUFFLE(MIDWAY_IOASIC_MACE)
@@ -2352,7 +2352,7 @@ MACHINE_CONFIG_END
static MACHINE_CONFIG_DERIVED( tenthdeg, vegas )
MCFG_DEVICE_ADD("dcs", DCS2_AUDIO_2104, 0)
MCFG_DCS2_AUDIO_DRAM_IN_MB(4)
-// MCFG_DCS2_AUDIO_POLLING_OFFSET(0x0afb) -- Not in ram???
+// MCFG_DCS2_AUDIO_POLLING_OFFSET(0x0afb) -- Not in ram???
MCFG_DEVICE_ADD("ioasic", MIDWAY_IOASIC, 0)
MCFG_MIDWAY_IOASIC_SHUFFLE(MIDWAY_IOASIC_GAUNTDL)
diff --git a/src/mame/includes/alesis.h b/src/mame/includes/alesis.h
index bec0463f49d..c4bb2efa70e 100644
--- a/src/mame/includes/alesis.h
+++ b/src/mame/includes/alesis.h
@@ -95,7 +95,7 @@ public:
DECLARE_WRITE8_MEMBER( mmt8_p3_w );
DECLARE_WRITE8_MEMBER( sr16_lcd_w );
HD44780_PIXEL_UPDATE(sr16_pixel_update);
-
+
private:
UINT8 m_kb_matrix;
UINT8 m_leds;
diff --git a/src/mame/includes/asteroid.h b/src/mame/includes/asteroid.h
index 10da970254c..76f90210483 100644
--- a/src/mame/includes/asteroid.h
+++ b/src/mame/includes/asteroid.h
@@ -63,4 +63,3 @@ public:
DISCRETE_SOUND_EXTERN( asteroid );
DISCRETE_SOUND_EXTERN( astdelux );
-
diff --git a/src/mame/includes/astrocde.h b/src/mame/includes/astrocde.h
index e1141d96c33..4f2b447439a 100644
--- a/src/mame/includes/astrocde.h
+++ b/src/mame/includes/astrocde.h
@@ -203,4 +203,3 @@ public:
protected:
virtual void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr) override;
};
-
diff --git a/src/mame/includes/chihiro.h b/src/mame/includes/chihiro.h
index 90757bb4cbc..895cdf6c01c 100644
--- a/src/mame/includes/chihiro.h
+++ b/src/mame/includes/chihiro.h
@@ -212,7 +212,7 @@ public:
enum class NV2A_VERTEX_ATTR {
POS = 0, // position
WEIGHT = 1, // blend weigth
- NORMAL = 2,
+ NORMAL = 2,
COLOR0 = 3, // diffuse
COLOR1 = 4, // specular
FOG = 5,
diff --git a/src/mame/includes/dassault.h b/src/mame/includes/dassault.h
index 2470c42366f..aa8d5a5f4b8 100644
--- a/src/mame/includes/dassault.h
+++ b/src/mame/includes/dassault.h
@@ -36,7 +36,7 @@ public:
m_ram(*this, "ram"),
m_shared_ram(*this, "shared_ram"),
m_ram2(*this, "ram2")
-
+
{ }
/* devices */
diff --git a/src/mame/includes/ladybug.h b/src/mame/includes/ladybug.h
index e6f5572f607..51d1cd92a6f 100644
--- a/src/mame/includes/ladybug.h
+++ b/src/mame/includes/ladybug.h
@@ -3,7 +3,7 @@
/*************************************************************************
Universal 8106-A2 + 8106-B PCB set
-
+
*************************************************************************/
class ladybug_state : public driver_device
diff --git a/src/mame/includes/madmotor.h b/src/mame/includes/madmotor.h
index db43ea6f9c5..27089ace10b 100644
--- a/src/mame/includes/madmotor.h
+++ b/src/mame/includes/madmotor.h
@@ -38,7 +38,7 @@ public:
required_device<deco_bac06_device> m_tilegen3;
required_device<deco_mxc06_device> m_spritegen;
required_device<generic_latch_8_device> m_soundlatch;
-
+
DECLARE_WRITE16_MEMBER(madmotor_sound_w);
DECLARE_DRIVER_INIT(madmotor);
virtual void machine_start() override;
diff --git a/src/mame/includes/megadrvb.h b/src/mame/includes/megadrvb.h
index 5be00cf1810..8b1f6b1c11a 100644
--- a/src/mame/includes/megadrvb.h
+++ b/src/mame/includes/megadrvb.h
@@ -33,5 +33,3 @@ public:
DECLARE_MACHINE_START(md_bootleg) { MACHINE_START_CALL_MEMBER(megadriv); m_vdp->stop_timers(); }
DECLARE_MACHINE_START(md_6button);
};
-
-
diff --git a/src/mame/includes/midzeus.h b/src/mame/includes/midzeus.h
index 9e8a717c3e0..7530b0b68f2 100644
--- a/src/mame/includes/midzeus.h
+++ b/src/mame/includes/midzeus.h
@@ -84,4 +84,3 @@ private:
void log_waveram(UINT32 length_and_base);
void update_gun_irq();
};
-
diff --git a/src/mame/includes/model1.h b/src/mame/includes/model1.h
index 0e93c6b0705..62cb80d9c6e 100644
--- a/src/mame/includes/model1.h
+++ b/src/mame/includes/model1.h
@@ -137,25 +137,25 @@ public:
class view_t
{
- public:
- view_t() { }
+ public:
+ view_t() { }
- void init_translation_matrix();
+ void init_translation_matrix();
- void set_viewport(float xcenter, float ycenter, float xl, float xr, float yb, float yt);
- void set_lightparam(int index, float diffuse, float ambient, float specular, int power);
- void set_zoom(float x, float y);
- void set_light_direction(float x, float y, float z);
- void set_translation_matrix(float* mat);
- void set_view_translation(float x, float y);
+ void set_viewport(float xcenter, float ycenter, float xl, float xr, float yb, float yt);
+ void set_lightparam(int index, float diffuse, float ambient, float specular, int power);
+ void set_zoom(float x, float y);
+ void set_light_direction(float x, float y, float z);
+ void set_translation_matrix(float* mat);
+ void set_view_translation(float x, float y);
- void project_point(point_t *p) const;
- void project_point_direct(point_t *p) const;
+ void project_point(point_t *p) const;
+ void project_point_direct(point_t *p) const;
- void transform_vector(glm::vec3& p) const;
- void transform_point(point_t *p) const;
+ void transform_vector(glm::vec3& p) const;
+ void transform_point(point_t *p) const;
- void recompute_frustum();
+ void recompute_frustum();
int xc, yc, x1, y1, x2, y2;
float zoomx, zoomy, viewx, viewy;
@@ -176,10 +176,10 @@ private:
bool m_swa;
// Devices
- required_device<v60_device> m_maincpu; // V60
- required_device<segam1audio_device> m_m1audio; // Model 1 standard sound board
- optional_device<m1comm_device> m_m1comm; // Model 1 communication board
- optional_device<dsbz80_device> m_dsbz80; // Digital Sound Board
+ required_device<v60_device> m_maincpu; // V60
+ required_device<segam1audio_device> m_m1audio; // Model 1 standard sound board
+ optional_device<m1comm_device> m_m1comm; // Model 1 communication board
+ optional_device<dsbz80_device> m_dsbz80; // Digital Sound Board
optional_device<mb86233_cpu_device> m_tgp;
required_device<screen_device> m_screen;
@@ -195,32 +195,32 @@ private:
int m_snd_cmd_state;
// TGP FIFO
- UINT32 fifoout_pop();
- void fifoout_push(UINT32 data);
- void fifoout_push_f(float data);
- UINT32 fifoin_pop();
- void fifoin_push(UINT32 data);
- float fifoin_pop_f();
- UINT16 ram_get_i();
- float ram_get_f();
- void copro_fifoin_push(UINT32 data);
- UINT32 copro_fifoout_pop();
- void next_fn();
-
- UINT32 m_copro_r;
- UINT32 m_copro_w;
- int m_copro_fifoout_rpos;
- int m_copro_fifoout_wpos;
- UINT32 m_copro_fifoout_data[FIFO_SIZE];
- int m_copro_fifoout_num;
- int m_copro_fifoin_rpos;
- int m_copro_fifoin_wpos;
- UINT32 m_copro_fifoin_data[FIFO_SIZE];
- int m_copro_fifoin_num;
+ UINT32 fifoout_pop();
+ void fifoout_push(UINT32 data);
+ void fifoout_push_f(float data);
+ UINT32 fifoin_pop();
+ void fifoin_push(UINT32 data);
+ float fifoin_pop_f();
+ UINT16 ram_get_i();
+ float ram_get_f();
+ void copro_fifoin_push(UINT32 data);
+ UINT32 copro_fifoout_pop();
+ void next_fn();
+
+ UINT32 m_copro_r;
+ UINT32 m_copro_w;
+ int m_copro_fifoout_rpos;
+ int m_copro_fifoout_wpos;
+ UINT32 m_copro_fifoout_data[FIFO_SIZE];
+ int m_copro_fifoout_num;
+ int m_copro_fifoin_rpos;
+ int m_copro_fifoin_wpos;
+ UINT32 m_copro_fifoin_data[FIFO_SIZE];
+ int m_copro_fifoin_num;
// TGP
- void vr_tgp_reset();
- void tgp_reset(bool swa);
+ void vr_tgp_reset();
+ void tgp_reset(bool swa);
DECLARE_TGP_FUNCTION( fadd );
DECLARE_TGP_FUNCTION( fsub );
@@ -339,19 +339,19 @@ private:
std::function<void(view_t*, point_t*, point_t*, point_t*)> m_clip;
};
- view_t *m_view;
- point_t *m_pointdb;
- point_t *m_pointpt;
- quad_t *m_quaddb;
- quad_t *m_quadpt;
- quad_t **m_quadind;
- offs_t m_pushpc;
- int m_fifoin_rpos;
- int m_fifoin_wpos;
- UINT32 m_fifoin_data[FIFO_SIZE];
- int m_fifoin_cbcount;
+ view_t *m_view;
+ point_t *m_pointdb;
+ point_t *m_pointpt;
+ quad_t *m_quaddb;
+ quad_t *m_quadpt;
+ quad_t **m_quadind;
+ offs_t m_pushpc;
+ int m_fifoin_rpos;
+ int m_fifoin_wpos;
+ UINT32 m_fifoin_data[FIFO_SIZE];
+ int m_fifoin_cbcount;
typedef void (model1_state::*tgp_func)();
- tgp_func m_fifoin_cb;
+ tgp_func m_fifoin_cb;
struct function
{
@@ -361,95 +361,95 @@ private:
static const struct function ftab_vf[];
static const struct function ftab_swa[];
- INT32 m_fifoout_rpos;
- INT32 m_fifoout_wpos;
- UINT32 m_fifoout_data[FIFO_SIZE];
- UINT32 m_list_length;
- float m_cmat[12];
- float m_mat_stack[MAT_STACK_SIZE][12];
- float m_mat_vector[21][12];
- INT32 m_mat_stack_pos;
- float m_acc;
- float m_tgp_vf_xmin;
- float m_tgp_vf_xmax;
- float m_tgp_vf_zmin;
- float m_tgp_vf_zmax;
- float m_tgp_vf_ygnd;
- float m_tgp_vf_yflr;
- float m_tgp_vf_yjmp;
- float m_tgp_vr_circx;
- float m_tgp_vr_circy;
- float m_tgp_vr_circrad;
- float m_tgp_vr_cbox[12];
- int m_tgp_vr_select;
-
- float m_tgp_int_px;
- float m_tgp_int_py;
- float m_tgp_int_pz;
- UINT32 m_tgp_int_adr;
- UINT16 m_ram_adr;
- UINT16 m_ram_latch[2];
- UINT16 m_ram_scanadr;
+ INT32 m_fifoout_rpos;
+ INT32 m_fifoout_wpos;
+ UINT32 m_fifoout_data[FIFO_SIZE];
+ UINT32 m_list_length;
+ float m_cmat[12];
+ float m_mat_stack[MAT_STACK_SIZE][12];
+ float m_mat_vector[21][12];
+ INT32 m_mat_stack_pos;
+ float m_acc;
+ float m_tgp_vf_xmin;
+ float m_tgp_vf_xmax;
+ float m_tgp_vf_zmin;
+ float m_tgp_vf_zmax;
+ float m_tgp_vf_ygnd;
+ float m_tgp_vf_yflr;
+ float m_tgp_vf_yjmp;
+ float m_tgp_vr_circx;
+ float m_tgp_vr_circy;
+ float m_tgp_vr_circrad;
+ float m_tgp_vr_cbox[12];
+ int m_tgp_vr_select;
+
+ float m_tgp_int_px;
+ float m_tgp_int_py;
+ float m_tgp_int_pz;
+ UINT32 m_tgp_int_adr;
+ UINT16 m_ram_adr;
+ UINT16 m_ram_latch[2];
+ UINT16 m_ram_scanadr;
std::unique_ptr<UINT32[]> m_ram_data;
- float m_tgp_vr_base[4];
- int m_puuu;
- int m_ccount;
- UINT32 m_vr_r;
- UINT32 m_vr_w;
- UINT16 m_listctl[2];
- UINT16 *m_glist;
- bool m_render_done;
+ float m_tgp_vr_base[4];
+ int m_puuu;
+ int m_ccount;
+ UINT32 m_vr_r;
+ UINT32 m_vr_w;
+ UINT16 m_listctl[2];
+ UINT16 *m_glist;
+ bool m_render_done;
std::unique_ptr<UINT16[]> m_tgp_ram;
UINT32 *m_poly_rom;
std::unique_ptr<UINT32[]> m_poly_ram;
// Rendering helper functions
- UINT32 readi(const UINT16 *adr) const;
- INT16 readi16(const UINT16 *adr) const;
- float readf(const UINT16 *adr) const;
- void cross_product(point_t* o, const point_t* p, const point_t* q) const;
- float view_determinant(const point_t *p1, const point_t *p2, const point_t *p3) const;
-
- static bool fclip_isc_bottom(view_t*, point_t*);
- static bool fclip_isc_top(view_t*, point_t*);
- static bool fclip_isc_left(view_t*, point_t*);
- static bool fclip_isc_right(view_t*, point_t*);
- static void fclip_clip_bottom(view_t*, point_t*, point_t*, point_t*);
- static void fclip_clip_top(view_t*, point_t*, point_t*, point_t*);
- static void fclip_clip_left(view_t*, point_t*, point_t*, point_t*);
- static void fclip_clip_right(view_t*, point_t*, point_t*, point_t*);
+ UINT32 readi(const UINT16 *adr) const;
+ INT16 readi16(const UINT16 *adr) const;
+ float readf(const UINT16 *adr) const;
+ void cross_product(point_t* o, const point_t* p, const point_t* q) const;
+ float view_determinant(const point_t *p1, const point_t *p2, const point_t *p3) const;
+
+ static bool fclip_isc_bottom(view_t*, point_t*);
+ static bool fclip_isc_top(view_t*, point_t*);
+ static bool fclip_isc_left(view_t*, point_t*);
+ static bool fclip_isc_right(view_t*, point_t*);
+ static void fclip_clip_bottom(view_t*, point_t*, point_t*, point_t*);
+ static void fclip_clip_top(view_t*, point_t*, point_t*, point_t*);
+ static void fclip_clip_left(view_t*, point_t*, point_t*, point_t*);
+ static void fclip_clip_right(view_t*, point_t*, point_t*, point_t*);
// Rendering
- void tgp_render(bitmap_rgb32 &bitmap, const rectangle &cliprect);
- void tgp_scan();
-
- void sort_quads() const;
- void unsort_quads() const;
- void draw_quads(bitmap_rgb32 &bitmap, const rectangle &cliprect);
- static void recompute_frustum(view_t *view);
- static void draw_hline(bitmap_rgb32 &bitmap, int x1, int x2, int y, int color);
- static void draw_hline_moired(bitmap_rgb32 &bitmap, int x1, int x2, int y, int color);
- static void fill_slope(bitmap_rgb32 &bitmap, view_t *view, int color, INT32 x1, INT32 x2, INT32 sl1, INT32 sl2, INT32 y1, INT32 y2, INT32 *nx1, INT32 *nx2);
- static void fill_line(bitmap_rgb32 &bitmap, view_t *view, int color, INT32 y, INT32 x1, INT32 x2);
- void fill_quad(bitmap_rgb32 &bitmap, view_t *view, const quad_t& q) const;
-
- void fclip_push_quad_next(int level, quad_t& q, point_t *p1, point_t *p2, point_t *p3, point_t *p4);
- void fclip_push_quad(int level, quad_t& q);
-
- static float min4f(float a, float b, float c, float d);
- static float max4f(float a, float b, float c, float d);
- static float compute_specular(glm::vec3& normal, glm::vec3& light, float diffuse,int lmode);
-
- void push_object(UINT32 tex_adr, UINT32 poly_adr, UINT32 size);
- UINT16* push_direct(UINT16 *list);
- UINT16* skip_direct(UINT16 *list) const;
- void draw_objects(bitmap_rgb32 &bitmap, const rectangle &cliprect);
- UINT16* draw_direct(bitmap_rgb32 &bitmap, const rectangle &cliprect, UINT16 *list);
-
- UINT16* get_list();
- int get_list_number();
- void end_frame();
+ void tgp_render(bitmap_rgb32 &bitmap, const rectangle &cliprect);
+ void tgp_scan();
+
+ void sort_quads() const;
+ void unsort_quads() const;
+ void draw_quads(bitmap_rgb32 &bitmap, const rectangle &cliprect);
+ static void recompute_frustum(view_t *view);
+ static void draw_hline(bitmap_rgb32 &bitmap, int x1, int x2, int y, int color);
+ static void draw_hline_moired(bitmap_rgb32 &bitmap, int x1, int x2, int y, int color);
+ static void fill_slope(bitmap_rgb32 &bitmap, view_t *view, int color, INT32 x1, INT32 x2, INT32 sl1, INT32 sl2, INT32 y1, INT32 y2, INT32 *nx1, INT32 *nx2);
+ static void fill_line(bitmap_rgb32 &bitmap, view_t *view, int color, INT32 y, INT32 x1, INT32 x2);
+ void fill_quad(bitmap_rgb32 &bitmap, view_t *view, const quad_t& q) const;
+
+ void fclip_push_quad_next(int level, quad_t& q, point_t *p1, point_t *p2, point_t *p3, point_t *p4);
+ void fclip_push_quad(int level, quad_t& q);
+
+ static float min4f(float a, float b, float c, float d);
+ static float max4f(float a, float b, float c, float d);
+ static float compute_specular(glm::vec3& normal, glm::vec3& light, float diffuse,int lmode);
+
+ void push_object(UINT32 tex_adr, UINT32 poly_adr, UINT32 size);
+ UINT16* push_direct(UINT16 *list);
+ UINT16* skip_direct(UINT16 *list) const;
+ void draw_objects(bitmap_rgb32 &bitmap, const rectangle &cliprect);
+ UINT16* draw_direct(bitmap_rgb32 &bitmap, const rectangle &cliprect, UINT16 *list);
+
+ UINT16* get_list();
+ int get_list_number();
+ void end_frame();
clipper_t m_clipfn[4];
@@ -458,7 +458,7 @@ private:
required_device<segas24_tile> m_tiles;
// I/O related
- UINT16 m_lamp_state;
+ UINT16 m_lamp_state;
optional_ioport_array<8> m_analog_ports;
required_ioport_array<3> m_digital_ports;
};
diff --git a/src/mame/includes/mw8080bw.h b/src/mame/includes/mw8080bw.h
index f5347046568..833b5bf1d32 100644
--- a/src/mame/includes/mw8080bw.h
+++ b/src/mame/includes/mw8080bw.h
@@ -86,7 +86,7 @@ public:
UINT8 m_spcenctr_trench_center;
UINT8 m_spcenctr_trench_slope[16]; /* 16x4 bit RAM */
UINT8 m_spcenctr_bright_control;
- UINT8 m_spcenctr_brightness;
+ UINT8 m_spcenctr_brightness;
/* timer */
emu_timer *m_interrupt_timer;
diff --git a/src/mame/includes/neogeo.h b/src/mame/includes/neogeo.h
index 51a88aeadc2..e5f0ffaa303 100644
--- a/src/mame/includes/neogeo.h
+++ b/src/mame/includes/neogeo.h
@@ -99,12 +99,12 @@ public:
DECLARE_WRITE16_MEMBER(write_bankprot_kf2k3bl);
DECLARE_WRITE16_MEMBER(write_bankprot_kof10th);
DECLARE_READ16_MEMBER(read_lorom_kof10th);
-
+
DECLARE_DRIVER_INIT(neogeo);
protected:
void common_machine_start();
-
+
void set_outputs();
// device overrides
@@ -121,7 +121,7 @@ protected:
optional_device<ym2610_device> m_ym;
required_device<neosprite_optimized_device> m_sprgen;
optional_shared_ptr<UINT16> m_save_ram;
-
+
required_device<screen_device> m_screen;
optional_device<palette_device> m_palette;
optional_device<ng_memcard_device> m_memcard;
@@ -169,14 +169,14 @@ protected:
void init_sprites();
// temporary helper to restore memory banking while bankswitch is handled in the driver...
UINT32 m_bank_base;
-
+
optional_device<neogeo_cart_slot_device> m_slot1;
optional_device<neogeo_cart_slot_device> m_slot2;
optional_device<neogeo_cart_slot_device> m_slot3;
optional_device<neogeo_cart_slot_device> m_slot4;
optional_device<neogeo_cart_slot_device> m_slot5;
optional_device<neogeo_cart_slot_device> m_slot6;
-
+
int m_curr_slot;
neogeo_cart_slot_device* m_slots[6];
@@ -185,28 +185,28 @@ private:
void create_interrupt_timers();
void start_interrupt_timers();
void acknowledge_interrupt(UINT16 data);
-
+
void adjust_display_position_interrupt_timer();
void set_display_position_interrupt_control(UINT16 data);
void set_display_counter_msb(UINT16 data);
void set_display_counter_lsb(UINT16 data);
void set_video_control(UINT16 data);
-
+
void create_rgb_lookups();
void set_pens();
void set_screen_shadow(int data);
void set_palette_bank(int data);
-
+
void audio_cpu_check_nmi();
void set_save_ram_unlock(UINT8 data);
void set_output_latch(UINT8 data);
void set_output_data(UINT8 data);
-
+
// internal state
bool m_recurse;
bool m_audio_cpu_nmi_enabled;
bool m_audio_cpu_nmi_pending;
-
+
// MVS-specific state
UINT8 m_save_ram_unlocked;
UINT8 m_output_data;
@@ -214,7 +214,7 @@ private:
UINT8 m_el_value;
UINT8 m_led1_value;
UINT8 m_led2_value;
-
+
emu_timer *m_display_position_interrupt_timer;
emu_timer *m_display_position_vblank_timer;
emu_timer *m_vblank_interrupt_timer;
@@ -223,9 +223,9 @@ private:
UINT8 m_display_position_interrupt_pending;
UINT8 m_irq3_pending;
UINT8 m_display_position_interrupt_control;
-
+
UINT16 get_video_control();
-
+
// color/palette related
std::vector<UINT16> m_paletteram;
UINT8 m_palette_lookup[32][4];
@@ -241,11 +241,11 @@ class aes_state : public neogeo_state
: neogeo_state(mconfig, type, tag)
, m_io_in2(*this, "IN2")
{}
-
+
DECLARE_READ16_MEMBER(aes_in2_r);
DECLARE_INPUT_CHANGED_MEMBER(aes_jp1);
DECLARE_MACHINE_START(aes);
-
+
protected:
required_ioport m_io_in2;
};
@@ -264,7 +264,7 @@ class neopcb_state : public neogeo_state
, m_pcm2_prot(*this, "pcm2")
, m_pvc_prot(*this, "pvc")
{}
-
+
// device overrides
virtual void machine_start() override;
@@ -286,7 +286,7 @@ class neopcb_state : public neogeo_state
void kf2k3pcb_gfx_decrypt();
void kf2k3pcb_decrypt_s1data();
void kf2k3pcb_sp1_decrypt();
-
+
required_device<cmc_prot_device> m_cmc_prot;
required_device<pcm2_prot_device> m_pcm2_prot;
required_device<pvc_prot_device> m_pvc_prot;
@@ -299,4 +299,3 @@ MACHINE_CONFIG_EXTERN( neogeo_base );
MACHINE_CONFIG_EXTERN( neogeo_arcade );
INPUT_PORTS_EXTERN(neogeo);
INPUT_PORTS_EXTERN(aes);
-
diff --git a/src/mame/includes/redclash.h b/src/mame/includes/redclash.h
index 7ebbc12e5e2..b0875b10260 100644
--- a/src/mame/includes/redclash.h
+++ b/src/mame/includes/redclash.h
@@ -29,7 +29,7 @@ public:
DECLARE_WRITE8_MEMBER(sraider_misc_w);
DECLARE_WRITE8_MEMBER(sraider_io_w);
DECLARE_INPUT_CHANGED_MEMBER(left_coin_inserted);
- DECLARE_INPUT_CHANGED_MEMBER(right_coin_inserted);
+ DECLARE_INPUT_CHANGED_MEMBER(right_coin_inserted);
DECLARE_DRIVER_INIT(redclash);
DECLARE_MACHINE_START(sraider);
DECLARE_MACHINE_RESET(sraider);
diff --git a/src/mame/includes/snes.h b/src/mame/includes/snes.h
index bacdabc0d1f..c25379a4537 100644
--- a/src/mame/includes/snes.h
+++ b/src/mame/includes/snes.h
@@ -322,7 +322,7 @@ public:
UINT32 m_wram_address;
UINT16 m_htime;
UINT16 m_vtime;
- bool m_is_pal;
+ bool m_is_pal;
/* non-SNES HW-specific flags / variables */
UINT8 m_is_nss;
diff --git a/src/mame/layout/fidel_csc.lay b/src/mame/layout/fidel_csc.lay
index f65cc5dcc47..9ae92f59ed1 100644
--- a/src/mame/layout/fidel_csc.lay
+++ b/src/mame/layout/fidel_csc.lay
@@ -25,16 +25,16 @@
end
function layout.reset()
- board =
+ board =
{{ 3, 5, 4, 2, 1, 4, 5, 3},
- { 6, 6, 6, 6, 6, 6, 6, 6},
- { 0, 0, 0, 0, 0, 0, 0, 0},
- { 0, 0, 0, 0, 0, 0, 0, 0},
- { 0, 0, 0, 0, 0, 0, 0, 0},
- { 0, 0, 0, 0, 0, 0, 0, 0},
- {12,12,12,12,12,12,12,12},
- { 9,11,10, 8, 7,10,11, 9}}
-
+ { 6, 6, 6, 6, 6, 6, 6, 6},
+ { 0, 0, 0, 0, 0, 0, 0, 0},
+ { 0, 0, 0, 0, 0, 0, 0, 0},
+ { 0, 0, 0, 0, 0, 0, 0, 0},
+ { 0, 0, 0, 0, 0, 0, 0, 0},
+ {12,12,12,12,12,12,12,12},
+ { 9,11,10, 8, 7,10,11, 9}}
+
for y, row in ipairs(board) do
for x, cell in ipairs(row) do
machine:outputs():set_indexed_value("pos", (y * 10) + x, board[y][x])
@@ -49,7 +49,7 @@
layout.reset()
return
end
-
+
for x, tag in ipairs(port_tags) do
local port = ports[tag]
if port then
@@ -260,7 +260,7 @@
<text string="&#x265d;" state="4"><color red="0.27" green="0.25" blue="0.25" /></text>
<text string="&#x265e;" state="5"><color red="0.27" green="0.25" blue="0.25" /></text>
<text string="&#x265f;" state="6"><color red="0.27" green="0.25" blue="0.25" /></text>
-
+
<text string="&#x265a;" state="7"><color red="0.71" green="0.7" blue="0.69" /></text>
<text string="&#x265b;" state="8"><color red="0.71" green="0.7" blue="0.69" /></text>
<text string="&#x265c;" state="9"><color red="0.71" green="0.7" blue="0.69" /></text>
diff --git a/src/mame/layout/mdndclab.lay b/src/mame/layout/mdndclab.lay
index a102145bd6d..4f806c57060 100644
--- a/src/mame/layout/mdndclab.lay
+++ b/src/mame/layout/mdndclab.lay
@@ -49,7 +49,7 @@
for num, col in pairs(walls) do
if col[1] &lt; x and (col[1] + 2.5) &gt; x then
for num2, wall in pairs(col[2]) do
- if wall &lt; y and (wall + 7.5) &gt; y then
+ if wall &lt; y and (wall + 7.5) &gt; y then
local state = machine:outputs():get_indexed_value("colwall", (num * 10) + num2)
machine:outputs():set_indexed_value("colwall", (num * 10) + num2, (~state) &amp; 1)
return
@@ -60,7 +60,7 @@
for num, row in pairs(walls) do
if row[1] &lt; y and (row[1] + 2.5) &gt; y then
for num2, wall in pairs(row[2]) do
- if wall &lt; x and (wall + 7.5) &gt; x then
+ if wall &lt; x and (wall + 7.5) &gt; x then
local state = machine:outputs():get_indexed_value("rowwall", (num * 10) + num2)
machine:outputs():set_indexed_value("rowwall", (num * 10) + num2, (~state) &amp; 1)
return
@@ -392,7 +392,7 @@
<bezel name="rowwall76" element="wall"><bounds x="50" y="67.5" width="7.5" height="2.5" /></bezel>
<bezel name="rowwall77" element="wall"><bounds x="60" y="67.5" width="7.5" height="2.5" /></bezel>
<bezel name="rowwall78" element="wall"><bounds x="70" y="67.5" width="7.5" height="2.5" /></bezel>
-
+
<!-- left side -->
<bezel element="static_red"><bounds x="-12.5" y="0" width="7.5" height="7.5" /></bezel>
diff --git a/src/mame/machine/awboard.cpp b/src/mame/machine/awboard.cpp
index 703d3ebfc88..b9d5a28ced6 100644
--- a/src/mame/machine/awboard.cpp
+++ b/src/mame/machine/awboard.cpp
@@ -301,7 +301,7 @@ READ16_MEMBER(aw_rom_board::pio_r)
UINT32 roffset = epr_offset & 0x3ffffff;
if (roffset >= (mpr_offset / 2))
roffset += mpr_bank * 0x4000000;
- UINT16 retval = (m_region->bytes() > (roffset * 2)) ? m_region->u16(roffset) : 0; // not endian-safe?
+ UINT16 retval = (m_region->bytes() > (roffset * 2)) ? m_region->u16(roffset) : 0; // not endian-safe?
return retval;
}
diff --git a/src/mame/machine/deco146.cpp b/src/mame/machine/deco146.cpp
index 9e477f3aae9..0f0cd068100 100644
--- a/src/mame/machine/deco146.cpp
+++ b/src/mame/machine/deco146.cpp
@@ -1179,12 +1179,12 @@ void deco_146_base_device::write_data(address_space &space, UINT16 address, UINT
if (i==0) // the first cs is our internal protection area
{
-// logerror("write matches cs table (protection) %01x %04x %04x %04x\n", i, real_address, data, mem_mask);
+// logerror("write matches cs table (protection) %01x %04x %04x %04x\n", i, real_address, data, mem_mask);
write_protport(space, real_address, data, mem_mask);
}
else
{
-// logerror("write matches cs table (external connection) %01x %04x %04x %04x\n", i, real_address, data, mem_mask);
+// logerror("write matches cs table (external connection) %01x %04x %04x %04x\n", i, real_address, data, mem_mask);
}
}
}
@@ -1249,7 +1249,7 @@ void deco_146_base_device::write_protport(address_space &space, UINT16 address,
}
else if ((address&0xff) == m_mask_port)
{
-// logerror("LOAD NAND REGISTER %04x %04x\n", data, mem_mask);
+// logerror("LOAD NAND REGISTER %04x %04x\n", data, mem_mask);
COMBINE_DATA(&m_nand);
}
else if ((address&0xff) == m_soundlatch_port)
diff --git a/src/mame/machine/decocrpt.h b/src/mame/machine/decocrpt.h
index c9c56571711..f818c579154 100644
--- a/src/mame/machine/decocrpt.h
+++ b/src/mame/machine/decocrpt.h
@@ -4,4 +4,3 @@
void deco56_decrypt_gfx(running_machine &machine, const char *tag);
void deco74_decrypt_gfx(running_machine &machine, const char *tag);
void deco56_remap_gfx(running_machine &machine, const char *tag);
-
diff --git a/src/mame/machine/gamecom.cpp b/src/mame/machine/gamecom.cpp
index c05e14dcfc7..60242cb7f85 100644
--- a/src/mame/machine/gamecom.cpp
+++ b/src/mame/machine/gamecom.cpp
@@ -603,7 +603,7 @@ WRITE8_MEMBER( gamecom_state::gamecom_update_timers )
if ( m_p_ram[SM8521_TM0D] >= m_timer[0].check_value )
{
m_p_ram[SM8521_TM0D] = 0;
-// m_maincpu->set_input_line(sm8500_cpu_device::TIM0_INT, ASSERT_LINE ); // this causes crazy flickering
+// m_maincpu->set_input_line(sm8500_cpu_device::TIM0_INT, ASSERT_LINE ); // this causes crazy flickering
}
}
}
diff --git a/src/mame/machine/macadb.h b/src/mame/machine/macadb.h
index 2067f492cf9..6a8d16a718e 100644
--- a/src/mame/machine/macadb.h
+++ b/src/mame/machine/macadb.h
@@ -1,3 +1,2 @@
// license:BSD-3-Clause
// copyright-holders:R. Belmont
-
diff --git a/src/mame/machine/pgmprot_igs025_igs028.h b/src/mame/machine/pgmprot_igs025_igs028.h
index 1d6ef718c22..ec3739399ca 100644
--- a/src/mame/machine/pgmprot_igs025_igs028.h
+++ b/src/mame/machine/pgmprot_igs025_igs028.h
@@ -12,7 +12,7 @@ public:
{
}
-
+
required_shared_ptr<UINT16> m_sharedprotram;
required_device<igs025_device> m_igs025;
required_device<igs028_device> m_igs028;
diff --git a/src/mame/mame.lst b/src/mame/mame.lst
index 760b0b52a8f..59255ffa87b 100644
--- a/src/mame/mame.lst
+++ b/src/mame/mame.lst
@@ -9592,7 +9592,7 @@ commandou // 5/1985 (c) 1985 + Data East license (US)
commandou2 // 5/1985 (c) 1985 + Data East license (US)
sinvasn // Europe original?
sinvasnb // bootleg
-mercenario // bootleg
+mercenario // bootleg
@source:compgolf.cpp
compgolf // (c) 1985 Data East Corporation (Japan)
diff --git a/src/mame/video/chihiro.cpp b/src/mame/video/chihiro.cpp
index bd6bdd835b9..b4011053030 100644
--- a/src/mame/video/chihiro.cpp
+++ b/src/mame/video/chihiro.cpp
@@ -2379,10 +2379,10 @@ void nv2a_renderer::convert_vertices_poly(vertex_nv *source, nv2avertex_t *desti
v[i] += matrix.projection[i][j] * t[j];
};
/*for (int i = 0; i < 3; i++) {
- v[i] *= matrix.scale[i];
+ v[i] *= matrix.scale[i];
}
for (int i = 0; i < 3; i++) {
- v[i] += matrix.translate[i];
+ v[i] += matrix.translate[i];
}*/
destination[m].w = v[3];
destination[m].x = (v[0] / v[3])*supersample_factor_x; // source[m].attribute[0].fv[0];
@@ -2864,7 +2864,7 @@ int nv2a_renderer::geforce_exec_method(address_space & space, UINT32 chanel, UIN
// each dword after 1808 contains a 32 bit index value to select the vartices
while (1) {
int c;
-
+
if ((countlen * mult + indexesleft_count) < 4)
break;
if (mult == 1)
@@ -3373,13 +3373,13 @@ int nv2a_renderer::geforce_exec_method(address_space & space, UINT32 chanel, UIN
}
}
/*if (maddress == 0x1b08) {
- (data >> 0) & 15;
- (data >> 4) & 15;
- (data >> 8) & 15;
- (data >> 12) & 15;
- (data >> 16) & 15;
- (data >> 20) & 15;
- (data >> 24) & 255;
+ (data >> 0) & 15;
+ (data >> 4) & 15;
+ (data >> 8) & 15;
+ (data >> 12) & 15;
+ (data >> 16) & 15;
+ (data >> 20) & 15;
+ (data >> 24) & 255;
}*/
if (maddress == 0x1b0c) {
texture[unit].colorkey = (data >> 0) & 3;
diff --git a/src/mame/video/crgolf.cpp b/src/mame/video/crgolf.cpp
index bc25f42b074..3ba4a5c549e 100644
--- a/src/mame/video/crgolf.cpp
+++ b/src/mame/video/crgolf.cpp
@@ -57,7 +57,6 @@ PALETTE_INIT_MEMBER(crgolf_state, crgolf)
PALETTE_INIT_MEMBER(crgolf_state, mastrglf)
{
-
}
/*************************************
@@ -135,4 +134,3 @@ UINT32 crgolf_state::screen_update_crgolf(screen_device &screen, bitmap_ind16 &b
return 0;
}
-
diff --git a/src/mame/video/holeland.cpp b/src/mame/video/holeland.cpp
index a98fd610506..e0df030eedf 100644
--- a/src/mame/video/holeland.cpp
+++ b/src/mame/video/holeland.cpp
@@ -61,7 +61,7 @@ VIDEO_START_MEMBER(holeland_state,holeland)
m_bg_tilemap->set_transmask(0, 0xff, 0x00); /* split type 0 is totally transparent in front half */
m_bg_tilemap->set_transmask(1, 0x01, 0xfe); /* split type 1 has pen 0? transparent in front half */
-
+
save_item(NAME(m_po));
save_item(NAME(m_palette_offset));
}
diff --git a/src/mame/video/ladybug.cpp b/src/mame/video/ladybug.cpp
index 773344349c5..7d4136b77a4 100644
--- a/src/mame/video/ladybug.cpp
+++ b/src/mame/video/ladybug.cpp
@@ -218,4 +218,3 @@ UINT32 ladybug_state::screen_update_ladybug(screen_device &screen, bitmap_ind16
draw_sprites(bitmap, cliprect);
return 0;
}
-
diff --git a/src/mame/video/model1.cpp b/src/mame/video/model1.cpp
index 2c90eaceb25..2a4a192d039 100644
--- a/src/mame/video/model1.cpp
+++ b/src/mame/video/model1.cpp
@@ -36,7 +36,7 @@ void model1_state::view_t::transform_point(point_t *p) const
{
point_t q = *p;
float xx = translation[0] * q.x + translation[3] * q.y + translation[6] * q.z + translation[ 9] + vxx;
- p->y = translation[1] * q.x + translation[4] * q.y + translation[7] * q.z + translation[10] + vyy;
+ p->y = translation[1] * q.x + translation[4] * q.y + translation[7] * q.z + translation[10] + vyy;
float zz = translation[2] * q.x + translation[5] * q.y + translation[8] * q.z + translation[11] + vzz;
p->x = ayyc * xx - ayys * zz;
p->z = ayys * xx + ayyc * zz;
@@ -592,7 +592,7 @@ void model1_state::fclip_clip_right(view_t *view, point_t *pt, point_t *p1, poin
void model1_state::fclip_push_quad_next(int level, quad_t& q, point_t *p1, point_t *p2, point_t *p3, point_t *p4)
{
- quad_t cquad(q.col, q.z, p1, p2, p3, p4);
+ quad_t cquad(q.col, q.z, p1, p2, p3, p4);
fclip_push_quad(level+1, cquad);
}
@@ -757,445 +757,445 @@ float model1_state::compute_specular(glm::vec3& normal, glm::vec3& light, float
void model1_state::push_object(UINT32 tex_adr, UINT32 poly_adr, UINT32 size) {
#if 0
- int dump;
+ int dump;
#endif
- float *poly_data;
- if (poly_adr & 0x800000)
- poly_data = (float *)m_poly_ram.get();
- else
- poly_data = (float *)m_poly_rom;
+ float *poly_data;
+ if (poly_adr & 0x800000)
+ poly_data = (float *)m_poly_ram.get();
+ else
+ poly_data = (float *)m_poly_rom;
- poly_adr &= 0x7fffff;
+ poly_adr &= 0x7fffff;
#if 0
- dump = poly_adr == 0x944ea;
- dump = 0;
+ dump = poly_adr == 0x944ea;
+ dump = 0;
#endif
#if 0
- if (poly_adr < 0x10000 || poly_adr >= 0x80000)
- return;
+ if (poly_adr < 0x10000 || poly_adr >= 0x80000)
+ return;
- if (poly_adr < 0x40000 || poly_adr >= 0x50000)
- return;
+ if (poly_adr < 0x40000 || poly_adr >= 0x50000)
+ return;
- if (poly_adr == 0x4c7db || poly_adr == 0x4cdaa || poly_adr == 0x4d3e7)
- return;
+ if (poly_adr == 0x4c7db || poly_adr == 0x4cdaa || poly_adr == 0x4d3e7)
+ return;
- if (poly_adr != 0x483e5)
- return;
+ if (poly_adr != 0x483e5)
+ return;
#endif
- if (true) {
- LOG_TGP(("XVIDEO: draw object (%x, %x, %x)\n", tex_adr, poly_adr, size));
- }
-
- if (!size)
- size = 0xffffffff;
-
- point_t *old_p0 = m_pointpt++;
- point_t *old_p1 = m_pointpt++;
-
- old_p0->x = poly_data[poly_adr + 0];
- old_p0->y = poly_data[poly_adr + 1];
- old_p0->z = poly_data[poly_adr + 2];
- old_p1->x = poly_data[poly_adr + 3];
- old_p1->y = poly_data[poly_adr + 4];
- old_p1->z = poly_data[poly_adr + 5];
- m_view->transform_point(old_p0);
- m_view->transform_point(old_p1);
-
- if (old_p0->z > 0)
- {
- m_view->project_point(old_p0);
- }
- else
- {
- old_p0->s.x = old_p0->s.y = 0;
- }
-
- if (old_p1->z > 0)
- {
- m_view->project_point(old_p1);
- }
- else
- {
- old_p1->s.x = old_p1->s.y = 0;
- }
-
- float old_z = 0;
-
- poly_adr += 6;
-
- for (int i = 0; i < size; i++)
- {
+ if (true) {
+ LOG_TGP(("XVIDEO: draw object (%x, %x, %x)\n", tex_adr, poly_adr, size));
+ }
+
+ if (!size)
+ size = 0xffffffff;
+
+ point_t *old_p0 = m_pointpt++;
+ point_t *old_p1 = m_pointpt++;
+
+ old_p0->x = poly_data[poly_adr + 0];
+ old_p0->y = poly_data[poly_adr + 1];
+ old_p0->z = poly_data[poly_adr + 2];
+ old_p1->x = poly_data[poly_adr + 3];
+ old_p1->y = poly_data[poly_adr + 4];
+ old_p1->z = poly_data[poly_adr + 5];
+ m_view->transform_point(old_p0);
+ m_view->transform_point(old_p1);
+
+ if (old_p0->z > 0)
+ {
+ m_view->project_point(old_p0);
+ }
+ else
+ {
+ old_p0->s.x = old_p0->s.y = 0;
+ }
+
+ if (old_p1->z > 0)
+ {
+ m_view->project_point(old_p1);
+ }
+ else
+ {
+ old_p1->s.x = old_p1->s.y = 0;
+ }
+
+ float old_z = 0;
+
+ poly_adr += 6;
+
+ for (int i = 0; i < size; i++)
+ {
#if 0
- LOG_TGP(("VIDEO: %08x (%f, %f, %f) (%f, %f, %f) (%f, %f, %f)\n",
- *(UINT32 *)(poly_data + poly_adr) & ~(0x01800303),
- poly_data[poly_adr + 1], poly_data[poly_adr + 2], poly_data[poly_adr + 3],
- poly_data[poly_adr + 4], poly_data[poly_adr + 5], poly_data[poly_adr + 6],
- poly_data[poly_adr + 7], poly_data[poly_adr + 8], poly_data[poly_adr + 9]));
+ LOG_TGP(("VIDEO: %08x (%f, %f, %f) (%f, %f, %f) (%f, %f, %f)\n",
+ *(UINT32 *)(poly_data + poly_adr) & ~(0x01800303),
+ poly_data[poly_adr + 1], poly_data[poly_adr + 2], poly_data[poly_adr + 3],
+ poly_data[poly_adr + 4], poly_data[poly_adr + 5], poly_data[poly_adr + 6],
+ poly_data[poly_adr + 7], poly_data[poly_adr + 8], poly_data[poly_adr + 9]));
#endif
- UINT32 flags = *reinterpret_cast<UINT32*>(poly_data + poly_adr);
-
- int type = flags & 3;
- if (!type)
- break;
-
- if (flags & 0x00001000)
- tex_adr++;
- int lightmode = (flags >> 17) & 15;
-
- point_t *p0 = m_pointpt++;
- point_t *p1 = m_pointpt++;
-
- glm::vec3 vn(poly_data[poly_adr + 1], poly_data[poly_adr + 2], poly_data[poly_adr + 3]);
- p0->x = poly_data[poly_adr + 4];
- p0->y = poly_data[poly_adr + 5];
- p0->z = poly_data[poly_adr + 6];
- p1->x = poly_data[poly_adr + 7];
- p1->y = poly_data[poly_adr + 8];
- p1->z = poly_data[poly_adr + 9];
-
- int link = (flags >> 8) & 3;
-
- m_view->transform_vector(vn);
-
- m_view->transform_point(p0);
- m_view->transform_point(p1);
- if (p0->z > 0)
- {
- m_view->project_point(p0);
- }
- else
- {
- p0->s.x = p0->s.y = 0;
- }
-
- if (p1->z > 0)
- {
- m_view->project_point(p1);
- }
- else
- {
- p1->s.x = p1->s.y = 0;
- }
+ UINT32 flags = *reinterpret_cast<UINT32*>(poly_data + poly_adr);
+
+ int type = flags & 3;
+ if (!type)
+ break;
+
+ if (flags & 0x00001000)
+ tex_adr++;
+ int lightmode = (flags >> 17) & 15;
+
+ point_t *p0 = m_pointpt++;
+ point_t *p1 = m_pointpt++;
+
+ glm::vec3 vn(poly_data[poly_adr + 1], poly_data[poly_adr + 2], poly_data[poly_adr + 3]);
+ p0->x = poly_data[poly_adr + 4];
+ p0->y = poly_data[poly_adr + 5];
+ p0->z = poly_data[poly_adr + 6];
+ p1->x = poly_data[poly_adr + 7];
+ p1->y = poly_data[poly_adr + 8];
+ p1->z = poly_data[poly_adr + 9];
+
+ int link = (flags >> 8) & 3;
+
+ m_view->transform_vector(vn);
+
+ m_view->transform_point(p0);
+ m_view->transform_point(p1);
+ if (p0->z > 0)
+ {
+ m_view->project_point(p0);
+ }
+ else
+ {
+ p0->s.x = p0->s.y = 0;
+ }
+
+ if (p1->z > 0)
+ {
+ m_view->project_point(p1);
+ }
+ else
+ {
+ p1->s.x = p1->s.y = 0;
+ }
#if 0
- if (dump)
- LOG_TGP(("VIDEO: %08x (%f, %f, %f) (%f, %f, %f)\n",
- *(UINT32 *)(poly_data + poly_adr),
- p0->x, p0->y, p0->z,
- p1->x, p1->y, p1->z));
+ if (dump)
+ LOG_TGP(("VIDEO: %08x (%f, %f, %f) (%f, %f, %f)\n",
+ *(UINT32 *)(poly_data + poly_adr),
+ p0->x, p0->y, p0->z,
+ p1->x, p1->y, p1->z));
#endif
#if 0
- if (true || dump) {
- LOG_TGP(("VIDEO: %08x (%d, %d) (%d, %d) (%d, %d) (%d, %d)\n",
- *(UINT32 *)(poly_data + poly_adr),
- old_p0->s.x, old_p0->s.y,
- old_p1->s.x, old_p1->s.y,
- p0->s.x, p0->s.y,
- p1->s.x, p1->s.y));
- }
+ if (true || dump) {
+ LOG_TGP(("VIDEO: %08x (%d, %d) (%d, %d) (%d, %d) (%d, %d)\n",
+ *(UINT32 *)(poly_data + poly_adr),
+ old_p0->s.x, old_p0->s.y,
+ old_p1->s.x, old_p1->s.y,
+ p0->s.x, p0->s.y,
+ p1->s.x, p1->s.y));
+ }
#endif
- quad_t cquad;
-
- if (!link)
- goto next;
-
- if (!(flags & 0x00004000) && view_determinant(old_p1, old_p0, p0) > 0)
- goto next;
-
- vn = glm::normalize(vn);
-
- cquad.p[0] = old_p1;
- cquad.p[1] = old_p0;
- cquad.p[2] = p0;
- cquad.p[3] = p1;
-
- switch ((flags >> 10) & 3)
- {
- case 0:
- cquad.z = old_z;
- break;
- case 1:
- cquad.z = old_z = min4f(old_p1->z, old_p0->z, p0->z, p1->z);
- break;
- case 2:
- cquad.z = old_z = max4f(old_p1->z, old_p0->z, p0->z, p1->z);
- break;
- case 3:
- default:
- cquad.z = 0.0;
- break;
- }
-
- {
+ quad_t cquad;
+
+ if (!link)
+ goto next;
+
+ if (!(flags & 0x00004000) && view_determinant(old_p1, old_p0, p0) > 0)
+ goto next;
+
+ vn = glm::normalize(vn);
+
+ cquad.p[0] = old_p1;
+ cquad.p[1] = old_p0;
+ cquad.p[2] = p0;
+ cquad.p[3] = p1;
+
+ switch ((flags >> 10) & 3)
+ {
+ case 0:
+ cquad.z = old_z;
+ break;
+ case 1:
+ cquad.z = old_z = min4f(old_p1->z, old_p0->z, p0->z, p1->z);
+ break;
+ case 2:
+ cquad.z = old_z = max4f(old_p1->z, old_p0->z, p0->z, p1->z);
+ break;
+ case 3:
+ default:
+ cquad.z = 0.0;
+ break;
+ }
+
+ {
#if 0
- float dif = mult_vector(&vn, &view->light);
- float ln = view->lightparams[lightmode].a + view->lightparams[lightmode].d*MAX(0.0, dif);
- cquad.col = scale_color(machine().pens[0x1000 | (m_tgp_ram[tex_adr - 0x40000] & 0x3ff)], MIN(1.0, ln));
- cquad.col = scale_color(machine().pens[0x1000 | (m_tgp_ram[tex_adr - 0x40000] & 0x3ff)], MIN(1.0, ln));
+ float dif = mult_vector(&vn, &view->light);
+ float ln = view->lightparams[lightmode].a + view->lightparams[lightmode].d*MAX(0.0, dif);
+ cquad.col = scale_color(machine().pens[0x1000 | (m_tgp_ram[tex_adr - 0x40000] & 0x3ff)], MIN(1.0, ln));
+ cquad.col = scale_color(machine().pens[0x1000 | (m_tgp_ram[tex_adr - 0x40000] & 0x3ff)], MIN(1.0, ln));
#endif
- float dif = glm::dot(vn, m_view->light);
- float spec = compute_specular(vn, m_view->light, dif, lightmode);
- float ln = m_view->lightparams[lightmode].a + m_view->lightparams[lightmode].d * MAX(0.0f, dif) + spec;
- int lumval = 255.0f * MIN(1.0f, ln);
- int color = m_paletteram16[0x1000 | (m_tgp_ram[tex_adr - 0x40000] & 0x3ff)];
- int r = (color >> 0x0) & 0x1f;
- int g = (color >> 0x5) & 0x1f;
- int b = (color >> 0xA) & 0x1f;
-
- lumval >>= 2; //there must be a luma translation table somewhere
- if (lumval > 0x3f)
- lumval = 0x3f;
- else if (lumval < 0)
- lumval = 0;
-
- r = (m_color_xlat[(r << 8) | lumval | 0x0] >> 3) & 0x1f;
- g = (m_color_xlat[(g << 8) | lumval | 0x2000] >> 3) & 0x1f;
- b = (m_color_xlat[(b << 8) | lumval | 0x4000] >> 3) & 0x1f;
- cquad.col = (pal5bit(r) << 16) | (pal5bit(g) << 8) | (pal5bit(b) << 0);
- }
-
- if (flags & 0x00002000)
- cquad.col |= MOIRE;
-
- fclip_push_quad(0, cquad);
-
- next:
- poly_adr += 10;
- switch (link) {
- case 0:
- case 2:
- old_p0 = p0;
- old_p1 = p1;
- break;
- case 1:
- old_p1 = p0;
- break;
- case 3:
- old_p0 = p1;
- break;
- }
- }
+ float dif = glm::dot(vn, m_view->light);
+ float spec = compute_specular(vn, m_view->light, dif, lightmode);
+ float ln = m_view->lightparams[lightmode].a + m_view->lightparams[lightmode].d * MAX(0.0f, dif) + spec;
+ int lumval = 255.0f * MIN(1.0f, ln);
+ int color = m_paletteram16[0x1000 | (m_tgp_ram[tex_adr - 0x40000] & 0x3ff)];
+ int r = (color >> 0x0) & 0x1f;
+ int g = (color >> 0x5) & 0x1f;
+ int b = (color >> 0xA) & 0x1f;
+
+ lumval >>= 2; //there must be a luma translation table somewhere
+ if (lumval > 0x3f)
+ lumval = 0x3f;
+ else if (lumval < 0)
+ lumval = 0;
+
+ r = (m_color_xlat[(r << 8) | lumval | 0x0] >> 3) & 0x1f;
+ g = (m_color_xlat[(g << 8) | lumval | 0x2000] >> 3) & 0x1f;
+ b = (m_color_xlat[(b << 8) | lumval | 0x4000] >> 3) & 0x1f;
+ cquad.col = (pal5bit(r) << 16) | (pal5bit(g) << 8) | (pal5bit(b) << 0);
+ }
+
+ if (flags & 0x00002000)
+ cquad.col |= MOIRE;
+
+ fclip_push_quad(0, cquad);
+
+ next:
+ poly_adr += 10;
+ switch (link) {
+ case 0:
+ case 2:
+ old_p0 = p0;
+ old_p1 = p1;
+ break;
+ case 1:
+ old_p1 = p0;
+ break;
+ case 3:
+ old_p0 = p1;
+ break;
+ }
+ }
}
UINT16 *model1_state::push_direct(UINT16 *list) {
- UINT32 tex_adr = readi(list);
- // v1 = readi(list+2);
- // v2 = readi(list+10);
-
- point_t *old_p0 = m_pointpt++;
- point_t *old_p1 = m_pointpt++;
-
- old_p0->x = readf(list + 4);
- old_p0->y = readf(list + 6);
- old_p0->z = readf(list + 8);
- old_p1->x = readf(list + 12);
- old_p1->y = readf(list + 14);
- old_p1->z = readf(list + 16);
-
- LOG_TGP(("VIDEOD start direct\n"));
- LOG_TGP(("VIDEOD (%f, %f, %f) (%f, %f, %f)\n",
- old_p0->x, old_p0->y, old_p0->z,
- old_p1->x, old_p1->y, old_p1->z));
-
- //m_view-transform_point(old_p0);
- //m_view->transform_point(old_p1);
- if (old_p0->z > 0)
- {
- m_view->project_point_direct(old_p0);
- }
- else
- {
- old_p0->s.x = old_p0->s.y = 0;
- }
-
- if (old_p1->z > 0)
- {
- m_view->project_point_direct(old_p1);
- }
- else
- {
- old_p1->s.x = old_p1->s.y = 0;
- }
-
- list += 18;
-
- for (;;) {
- UINT32 flags = readi(list);
-
- int type = flags & 3;
- if (!type)
- break;
-
- if (flags & 0x00001000)
- tex_adr++;
-
- // list+2 is luminosity
- // list+4 is 0?
- // list+12 is z?
-
- point_t *p0 = m_pointpt++;
- point_t *p1 = m_pointpt++;
-
- UINT32 lum = readi(list + 2);
- // v1 = readi(list+4);
-
- float z = 0;
- if (type == 2)
- {
- p0->x = readf(list + 6);
- p0->y = readf(list + 8);
- p0->z = readf(list + 10);
- z = p0->z;
- LOG_TGP(("VIDEOD %08x %08x (%f, %f, %f)\n",
- flags, lum,
- p0->x, p0->y, p0->z));
- *p1 = *p0;
- list += 12;
- }
- else
- {
- p0->x = readf(list + 6);
- p0->y = readf(list + 8);
- p0->z = readf(list + 10);
- p1->x = readf(list + 14);
- p1->y = readf(list + 16);
- p1->z = readf(list + 18);
- z = readf(list + 12);
- LOG_TGP(("VIDEOD %08x %08x (%f, %f, %f) (%f, %f, %f)\n",
- flags, lum,
- p0->x, p0->y, p0->z,
- p1->x, p1->y, p1->z));
- list += 20;
- }
-
- int link = (flags >> 8) & 3;
-
- //m_view->transform_point(p0);
- //m_view->transform_point(p1);
- if (p0->z > 0)
- {
- m_view->project_point_direct(p0);
- }
- if (p1->z > 0)
- {
- m_view->project_point_direct(p1);
- }
+ UINT32 tex_adr = readi(list);
+ // v1 = readi(list+2);
+ // v2 = readi(list+10);
+
+ point_t *old_p0 = m_pointpt++;
+ point_t *old_p1 = m_pointpt++;
+
+ old_p0->x = readf(list + 4);
+ old_p0->y = readf(list + 6);
+ old_p0->z = readf(list + 8);
+ old_p1->x = readf(list + 12);
+ old_p1->y = readf(list + 14);
+ old_p1->z = readf(list + 16);
+
+ LOG_TGP(("VIDEOD start direct\n"));
+ LOG_TGP(("VIDEOD (%f, %f, %f) (%f, %f, %f)\n",
+ old_p0->x, old_p0->y, old_p0->z,
+ old_p1->x, old_p1->y, old_p1->z));
+
+ //m_view-transform_point(old_p0);
+ //m_view->transform_point(old_p1);
+ if (old_p0->z > 0)
+ {
+ m_view->project_point_direct(old_p0);
+ }
+ else
+ {
+ old_p0->s.x = old_p0->s.y = 0;
+ }
+
+ if (old_p1->z > 0)
+ {
+ m_view->project_point_direct(old_p1);
+ }
+ else
+ {
+ old_p1->s.x = old_p1->s.y = 0;
+ }
+
+ list += 18;
+
+ for (;;) {
+ UINT32 flags = readi(list);
+
+ int type = flags & 3;
+ if (!type)
+ break;
+
+ if (flags & 0x00001000)
+ tex_adr++;
+
+ // list+2 is luminosity
+ // list+4 is 0?
+ // list+12 is z?
+
+ point_t *p0 = m_pointpt++;
+ point_t *p1 = m_pointpt++;
+
+ UINT32 lum = readi(list + 2);
+ // v1 = readi(list+4);
+
+ float z = 0;
+ if (type == 2)
+ {
+ p0->x = readf(list + 6);
+ p0->y = readf(list + 8);
+ p0->z = readf(list + 10);
+ z = p0->z;
+ LOG_TGP(("VIDEOD %08x %08x (%f, %f, %f)\n",
+ flags, lum,
+ p0->x, p0->y, p0->z));
+ *p1 = *p0;
+ list += 12;
+ }
+ else
+ {
+ p0->x = readf(list + 6);
+ p0->y = readf(list + 8);
+ p0->z = readf(list + 10);
+ p1->x = readf(list + 14);
+ p1->y = readf(list + 16);
+ p1->z = readf(list + 18);
+ z = readf(list + 12);
+ LOG_TGP(("VIDEOD %08x %08x (%f, %f, %f) (%f, %f, %f)\n",
+ flags, lum,
+ p0->x, p0->y, p0->z,
+ p1->x, p1->y, p1->z));
+ list += 20;
+ }
+
+ int link = (flags >> 8) & 3;
+
+ //m_view->transform_point(p0);
+ //m_view->transform_point(p1);
+ if (p0->z > 0)
+ {
+ m_view->project_point_direct(p0);
+ }
+ if (p1->z > 0)
+ {
+ m_view->project_point_direct(p1);
+ }
#if 1
- if (old_p0 && old_p1)
- LOG_TGP(("VIDEOD: %08x (%d, %d) (%d, %d) (%d, %d) (%d, %d)\n",
- flags,
- old_p0->s.x, old_p0->s.y,
- old_p1->s.x, old_p1->s.y,
- p0->s.x, p0->s.y,
- p1->s.x, p1->s.y));
- else
- LOG_TGP(("VIDEOD: %08x (%d, %d) (%d, %d)\n",
- flags,
- p0->s.x, p0->s.y,
- p1->s.x, p1->s.y));
+ if (old_p0 && old_p1)
+ LOG_TGP(("VIDEOD: %08x (%d, %d) (%d, %d) (%d, %d) (%d, %d)\n",
+ flags,
+ old_p0->s.x, old_p0->s.y,
+ old_p1->s.x, old_p1->s.y,
+ p0->s.x, p0->s.y,
+ p1->s.x, p1->s.y));
+ else
+ LOG_TGP(("VIDEOD: %08x (%d, %d) (%d, %d)\n",
+ flags,
+ p0->s.x, p0->s.y,
+ p1->s.x, p1->s.y));
#endif
- quad_t cquad;
- if (!link)
- goto next;
-
- cquad.p[0] = old_p1;
- cquad.p[1] = old_p0;
- cquad.p[2] = p0;
- cquad.p[3] = p1;
- cquad.z = z;
- {
- int lumval = ((float)(lum >> 24)) * 2.0f;
- int color = m_paletteram16[0x1000 | (m_tgp_ram[tex_adr - 0x40000] & 0x3ff)];
- int r = (color >> 0x0) & 0x1f;
- int g = (color >> 0x5) & 0x1f;
- int b = (color >> 0xA) & 0x1f;
- lumval >>= 2; //there must be a luma translation table somewhere
- if (lumval>0x3f) lumval = 0x3f;
- else if (lumval<0) lumval = 0;
- r = (m_color_xlat[(r << 8) | lumval | 0x0] >> 3) & 0x1f;
- g = (m_color_xlat[(g << 8) | lumval | 0x2000] >> 3) & 0x1f;
- b = (m_color_xlat[(b << 8) | lumval | 0x4000] >> 3) & 0x1f;
- cquad.col = (pal5bit(r) << 16) | (pal5bit(g) << 8) | (pal5bit(b) << 0);
- }
- //cquad.col = scale_color(machine().pens[0x1000|(m_tgp_ram[tex_adr-0x40000] & 0x3ff)],((float) (lum>>24)) / 128.0);
- if (flags & 0x00002000)
- cquad.col |= MOIRE;
-
- fclip_push_quad(0, cquad);
-
- next:
- switch (link) {
- case 0:
- case 2:
- old_p0 = p0;
- old_p1 = p1;
- break;
- case 1:
- old_p1 = p0;
- break;
- case 3:
- old_p0 = p1;
- break;
- }
- }
- return list + 2;
+ quad_t cquad;
+ if (!link)
+ goto next;
+
+ cquad.p[0] = old_p1;
+ cquad.p[1] = old_p0;
+ cquad.p[2] = p0;
+ cquad.p[3] = p1;
+ cquad.z = z;
+ {
+ int lumval = ((float)(lum >> 24)) * 2.0f;
+ int color = m_paletteram16[0x1000 | (m_tgp_ram[tex_adr - 0x40000] & 0x3ff)];
+ int r = (color >> 0x0) & 0x1f;
+ int g = (color >> 0x5) & 0x1f;
+ int b = (color >> 0xA) & 0x1f;
+ lumval >>= 2; //there must be a luma translation table somewhere
+ if (lumval>0x3f) lumval = 0x3f;
+ else if (lumval<0) lumval = 0;
+ r = (m_color_xlat[(r << 8) | lumval | 0x0] >> 3) & 0x1f;
+ g = (m_color_xlat[(g << 8) | lumval | 0x2000] >> 3) & 0x1f;
+ b = (m_color_xlat[(b << 8) | lumval | 0x4000] >> 3) & 0x1f;
+ cquad.col = (pal5bit(r) << 16) | (pal5bit(g) << 8) | (pal5bit(b) << 0);
+ }
+ //cquad.col = scale_color(machine().pens[0x1000|(m_tgp_ram[tex_adr-0x40000] & 0x3ff)],((float) (lum>>24)) / 128.0);
+ if (flags & 0x00002000)
+ cquad.col |= MOIRE;
+
+ fclip_push_quad(0, cquad);
+
+ next:
+ switch (link) {
+ case 0:
+ case 2:
+ old_p0 = p0;
+ old_p1 = p1;
+ break;
+ case 1:
+ old_p1 = p0;
+ break;
+ case 3:
+ old_p0 = p1;
+ break;
+ }
+ }
+ return list + 2;
}
UINT16* model1_state::skip_direct(UINT16 *list) const
{
- list += 18;
+ list += 18;
- while (true) {
- UINT32 flags = readi(list);
+ while (true) {
+ UINT32 flags = readi(list);
- int type = flags & 3;
- if (!type)
- break;
+ int type = flags & 3;
+ if (!type)
+ break;
- if (type == 2)
- list += 12;
- else
- list += 20;
- }
- return list + 2;
+ if (type == 2)
+ list += 12;
+ else
+ list += 20;
+ }
+ return list + 2;
}
void model1_state::draw_objects(bitmap_rgb32 &bitmap, const rectangle &cliprect)
{
- if (m_quadpt != m_quaddb)
- {
- LOG_TGP(("VIDEO: sort&draw\n"));
- sort_quads();
- draw_quads(bitmap, cliprect);
- }
-
- m_quadpt = m_quaddb;
- m_pointpt = m_pointdb;
+ if (m_quadpt != m_quaddb)
+ {
+ LOG_TGP(("VIDEO: sort&draw\n"));
+ sort_quads();
+ draw_quads(bitmap, cliprect);
+ }
+
+ m_quadpt = m_quaddb;
+ m_pointpt = m_pointdb;
}
UINT16 *model1_state::draw_direct(bitmap_rgb32 &bitmap, const rectangle &cliprect, UINT16 *list)
{
- LOG_TGP(("VIDEO: draw direct %x\n", readi(list)));
+ LOG_TGP(("VIDEO: draw direct %x\n", readi(list)));
- draw_objects(bitmap, cliprect);
- UINT16 *res = push_direct(list);
- unsort_quads();
- draw_quads(bitmap, cliprect);
+ draw_objects(bitmap, cliprect);
+ UINT16 *res = push_direct(list);
+ unsort_quads();
+ draw_quads(bitmap, cliprect);
- m_quadpt = m_quaddb;
- m_pointpt = m_pointdb;
- return res;
+ m_quadpt = m_quaddb;
+ m_pointpt = m_pointdb;
+ return res;
}
UINT16 *model1_state::get_list()
@@ -1234,38 +1234,38 @@ WRITE16_MEMBER(model1_state::model1_listctl_w)
void model1_state::view_t::init_translation_matrix()
{
- memset(translation, 0, sizeof(translation));
- translation[0] = 1.0;
- translation[4] = 1.0;
- translation[8] = 1.0;
+ memset(translation, 0, sizeof(translation));
+ translation[0] = 1.0;
+ translation[4] = 1.0;
+ translation[8] = 1.0;
}
void model1_state::view_t::set_viewport(float xcenter, float ycenter, float xl, float xr, float yb, float yt)
{
- xc = xcenter;
- yc = ycenter;
- x1 = xl;
- x2 = xr;
- y1 = yb;
- y2 = yt;
-
- recompute_frustum();
+ xc = xcenter;
+ yc = ycenter;
+ x1 = xl;
+ x2 = xr;
+ y1 = yb;
+ y2 = yt;
+
+ recompute_frustum();
}
void model1_state::view_t::set_lightparam(int index, float diffuse, float ambient, float specular, int power)
{
- lightparams[index].d = diffuse;
- lightparams[index].a = ambient;
- lightparams[index].s = specular;
- lightparams[index].p = power;
+ lightparams[index].d = diffuse;
+ lightparams[index].a = ambient;
+ lightparams[index].s = specular;
+ lightparams[index].p = power;
}
void model1_state::view_t::set_zoom(float x, float y)
{
- zoomx = x;
- zoomy = y;
+ zoomx = x;
+ zoomy = y;
- recompute_frustum();
+ recompute_frustum();
}
void model1_state::view_t::set_light_direction(float x, float y, float z)
@@ -1275,272 +1275,272 @@ void model1_state::view_t::set_light_direction(float x, float y, float z)
void model1_state::view_t::set_translation_matrix(float* mat)
{
- for (int i = 0; i < 12; i++)
- {
- translation[i] = mat[i];
- }
+ for (int i = 0; i < 12; i++)
+ {
+ translation[i] = mat[i];
+ }
}
void model1_state::view_t::set_view_translation(float x, float y)
{
- viewx = x;
- viewy = y;
+ viewx = x;
+ viewy = y;
- recompute_frustum();
+ recompute_frustum();
}
void model1_state::tgp_render(bitmap_rgb32 &bitmap, const rectangle &cliprect)
{
- m_render_done = 1;
- if ((m_listctl[1] & 0x1f) == 0x1f)
- {
- UINT16 *list = get_list();
- int zz = 0;
- LOG_TGP(("VIDEO: render list %d\n", get_list_number()));
-
- m_view->init_translation_matrix();
-
- for (;;) {
- int type = (list[1] << 16) | list[0];
- m_glist = list;
- switch (type & 15)
- {
- case 0:
- list += 2;
- break;
- case 1:
- // 1 = plane 1
- // 2 = ?? draw object (413d3, 17c4c, e)
- // 3 = plane 2
- // 4 = ?? draw object (408a8, a479, 9)
- // 5 = decor
- // 6 = ?? draw object (57bd4, 387460, 2ad)
-
- if (true || zz >= 666)
- push_object(readi(list + 2), readi(list + 4), readi(list + 6));
- list += 8;
- break;
- case 2:
- list = draw_direct(bitmap, cliprect, list + 2);
- break;
- case 3:
- {
- LOG_TGP(("VIDEO: viewport (%d, %d, %d, %d, %d, %d, %d)\n",
- readi(list + 2),
- readi16(list + 4), readi16(list + 6), readi16(list + 8),
- readi16(list + 10), readi16(list + 12), readi16(list + 14)));
-
- draw_objects(bitmap, cliprect);
-
- float xc = readi16(list + 4);
- float yc = 383 - (readi16(list + 6) - 39);
- float x1 = readi16(list + 8);
- float y2 = 383 - (readi16(list + 10) - 39);
- float x2 = readi16(list + 12);
- float y1 = 383 - (readi16(list + 14) - 39);
-
- m_view->set_viewport(xc, yc, x1, x2, y1, y2);
-
- list += 16;
- break;
- }
- case 4:
- {
- int adr = readi(list + 2);
- int len = readi(list + 4) + 1;
- LOG_TGP(("ZVIDEO: color write, adr=%x, len=%x\n", adr, len));
- for (int i = 0; i < len; i++)
- {
- m_tgp_ram[adr - 0x40000 + i] = list[6 + 2 * i];
- }
- list += 6 + len * 2;
- break;
- }
- case 5:
- {
- int adr = readi(list + 2);
- int len = readi(list + 4);
- for (int i = 0; i < len; i++)
- {
- m_poly_ram[adr - 0x800000 + i] = readi(list + 2 * i + 6);
- }
- list += 6 + len * 2;
- break;
- }
- case 6:
- {
- int adr = readi(list + 2);
- int len = readi(list + 4);
- LOG_TGP(("VIDEO: upload data, adr=%x, len=%x\n", adr, len));
- for (int i = 0; i < len; i++)
- {
- int v = readi(list + 6 + i * 2);
- float diffuse = (float(v & 0xff)) / 255.0f;
- float ambient = (float((v >> 8) & 0xff)) / 255.0f;
- float specular = (float((v >> 16) & 0xff)) / 255.0f;
- int power = (v >> 24) & 0xff;
- m_view->set_lightparam(i + adr, diffuse, ambient, specular, power);
- }
- list += 6 + len * 2;
- break;
- }
- case 7:
- LOG_TGP(("VIDEO: code 7 (%d)\n", readi(list + 2)));
- zz++;
- list += 4;
- break;
- case 8:
- LOG_TGP(("VIDEO: select mode %08x\n", readi(list + 2)));
- list += 4;
- break;
- case 9:
- LOG_TGP(("VIDEO: zoom (%f, %f)\n", readf(list + 2), readf(list + 4)));
- m_view->set_zoom(readf(list + 2) * 4, readf(list + 4) * 4);
- list += 6;
- break;
- case 0xa:
- LOG_TGP(("VIDEO: light vector (%f, %f, %f)\n", readf(list + 2), readf(list + 4), readf(list + 6)));
- m_view->set_light_direction(readf(list + 2), readf(list + 4), readf(list + 6));
- list += 8;
- break;
- case 0xb:
- {
- LOG_TGP(("VIDEO: matrix (%f, %f, %f, %f, %f, %f, %f, %f, %f, %f, %f, %f)\n",
- readf(list + 2), readf(list + 4), readf(list + 6),
- readf(list + 8), readf(list + 10), readf(list + 12),
- readf(list + 14), readf(list + 16), readf(list + 18),
- readf(list + 20), readf(list + 22), readf(list + 24)));
- float mat[12];
- for (int i = 0; i < 12; i++)
- {
- mat[i] = readf(list + 2 + 2 * i);
- }
- m_view->set_translation_matrix(mat);
- list += 26;
- break;
- }
- case 0xc:
- LOG_TGP(("VIDEO: trans (%f, %f)\n", readf(list + 2), readf(list + 4)));
- m_view->set_view_translation(readf(list + 2), readf(list + 4));
- list += 6;
- break;
- case 0xf:
- //case -1:
- goto end;
- default:
- LOG_TGP(("VIDEO: unknown type %d\n", type));
- goto end;
- }
- }
- end:
- draw_objects(bitmap, cliprect);
- }
+ m_render_done = 1;
+ if ((m_listctl[1] & 0x1f) == 0x1f)
+ {
+ UINT16 *list = get_list();
+ int zz = 0;
+ LOG_TGP(("VIDEO: render list %d\n", get_list_number()));
+
+ m_view->init_translation_matrix();
+
+ for (;;) {
+ int type = (list[1] << 16) | list[0];
+ m_glist = list;
+ switch (type & 15)
+ {
+ case 0:
+ list += 2;
+ break;
+ case 1:
+ // 1 = plane 1
+ // 2 = ?? draw object (413d3, 17c4c, e)
+ // 3 = plane 2
+ // 4 = ?? draw object (408a8, a479, 9)
+ // 5 = decor
+ // 6 = ?? draw object (57bd4, 387460, 2ad)
+
+ if (true || zz >= 666)
+ push_object(readi(list + 2), readi(list + 4), readi(list + 6));
+ list += 8;
+ break;
+ case 2:
+ list = draw_direct(bitmap, cliprect, list + 2);
+ break;
+ case 3:
+ {
+ LOG_TGP(("VIDEO: viewport (%d, %d, %d, %d, %d, %d, %d)\n",
+ readi(list + 2),
+ readi16(list + 4), readi16(list + 6), readi16(list + 8),
+ readi16(list + 10), readi16(list + 12), readi16(list + 14)));
+
+ draw_objects(bitmap, cliprect);
+
+ float xc = readi16(list + 4);
+ float yc = 383 - (readi16(list + 6) - 39);
+ float x1 = readi16(list + 8);
+ float y2 = 383 - (readi16(list + 10) - 39);
+ float x2 = readi16(list + 12);
+ float y1 = 383 - (readi16(list + 14) - 39);
+
+ m_view->set_viewport(xc, yc, x1, x2, y1, y2);
+
+ list += 16;
+ break;
+ }
+ case 4:
+ {
+ int adr = readi(list + 2);
+ int len = readi(list + 4) + 1;
+ LOG_TGP(("ZVIDEO: color write, adr=%x, len=%x\n", adr, len));
+ for (int i = 0; i < len; i++)
+ {
+ m_tgp_ram[adr - 0x40000 + i] = list[6 + 2 * i];
+ }
+ list += 6 + len * 2;
+ break;
+ }
+ case 5:
+ {
+ int adr = readi(list + 2);
+ int len = readi(list + 4);
+ for (int i = 0; i < len; i++)
+ {
+ m_poly_ram[adr - 0x800000 + i] = readi(list + 2 * i + 6);
+ }
+ list += 6 + len * 2;
+ break;
+ }
+ case 6:
+ {
+ int adr = readi(list + 2);
+ int len = readi(list + 4);
+ LOG_TGP(("VIDEO: upload data, adr=%x, len=%x\n", adr, len));
+ for (int i = 0; i < len; i++)
+ {
+ int v = readi(list + 6 + i * 2);
+ float diffuse = (float(v & 0xff)) / 255.0f;
+ float ambient = (float((v >> 8) & 0xff)) / 255.0f;
+ float specular = (float((v >> 16) & 0xff)) / 255.0f;
+ int power = (v >> 24) & 0xff;
+ m_view->set_lightparam(i + adr, diffuse, ambient, specular, power);
+ }
+ list += 6 + len * 2;
+ break;
+ }
+ case 7:
+ LOG_TGP(("VIDEO: code 7 (%d)\n", readi(list + 2)));
+ zz++;
+ list += 4;
+ break;
+ case 8:
+ LOG_TGP(("VIDEO: select mode %08x\n", readi(list + 2)));
+ list += 4;
+ break;
+ case 9:
+ LOG_TGP(("VIDEO: zoom (%f, %f)\n", readf(list + 2), readf(list + 4)));
+ m_view->set_zoom(readf(list + 2) * 4, readf(list + 4) * 4);
+ list += 6;
+ break;
+ case 0xa:
+ LOG_TGP(("VIDEO: light vector (%f, %f, %f)\n", readf(list + 2), readf(list + 4), readf(list + 6)));
+ m_view->set_light_direction(readf(list + 2), readf(list + 4), readf(list + 6));
+ list += 8;
+ break;
+ case 0xb:
+ {
+ LOG_TGP(("VIDEO: matrix (%f, %f, %f, %f, %f, %f, %f, %f, %f, %f, %f, %f)\n",
+ readf(list + 2), readf(list + 4), readf(list + 6),
+ readf(list + 8), readf(list + 10), readf(list + 12),
+ readf(list + 14), readf(list + 16), readf(list + 18),
+ readf(list + 20), readf(list + 22), readf(list + 24)));
+ float mat[12];
+ for (int i = 0; i < 12; i++)
+ {
+ mat[i] = readf(list + 2 + 2 * i);
+ }
+ m_view->set_translation_matrix(mat);
+ list += 26;
+ break;
+ }
+ case 0xc:
+ LOG_TGP(("VIDEO: trans (%f, %f)\n", readf(list + 2), readf(list + 4)));
+ m_view->set_view_translation(readf(list + 2), readf(list + 4));
+ list += 6;
+ break;
+ case 0xf:
+ //case -1:
+ goto end;
+ default:
+ LOG_TGP(("VIDEO: unknown type %d\n", type));
+ goto end;
+ }
+ }
+ end:
+ draw_objects(bitmap, cliprect);
+ }
}
void model1_state::tgp_scan()
{
#if 0
- if (machine().input().code_pressed_once(KEYCODE_F)) {
- FILE *fp;
- fp = fopen("tgp-ram.bin", "w+b");
- if (fp) {
- fwrite(m_tgp_ram, (0x100000 - 0x40000) * 2, 1, fp);
- fclose(fp);
- }
- exit(0);
- }
+ if (machine().input().code_pressed_once(KEYCODE_F)) {
+ FILE *fp;
+ fp = fopen("tgp-ram.bin", "w+b");
+ if (fp) {
+ fwrite(m_tgp_ram, (0x100000 - 0x40000) * 2, 1, fp);
+ fclose(fp);
+ }
+ exit(0);
+ }
#endif
- if (!m_render_done && (m_listctl[1] & 0x1f) == 0x1f)
- {
- UINT16 *list = get_list();
- // Skip everything but the data uploads
- LOG_TGP(("VIDEO: scan list %d\n", get_list_number()));
- for (;;)
- {
- int type = (list[1] << 16) | list[0];
- switch (type) {
- case 0:
- list += 2;
- break;
- case 1:
- list += 8;
- break;
- case 2:
- list = skip_direct(list + 2);
- break;
- case 3:
- list += 16;
- break;
- case 4:
- {
- int adr = readi(list + 2);
- int len = readi(list + 4) + 1;
- LOG_TGP(("ZVIDEO: scan color write, adr=%x, len=%x\n", adr, len));
- for (int i = 0; i<len; i++)
- {
- m_tgp_ram[adr - 0x40000 + i] = list[6 + 2 * i];
- }
- list += 6 + len * 2;
- break;
- }
- case 5:
- {
- int adr = readi(list + 2);
- int len = readi(list + 4);
- for (int i = 0; i < len; i++)
- {
- m_poly_ram[adr - 0x800000 + i] = readi(list + 2 * i + 6);
- }
- list += 6 + len * 2;
- break;
- }
- case 6:
- {
- int adr = readi(list + 2);
- int len = readi(list + 4);
- //LOG_TGP(("VIDEO: upload data, adr=%x, len=%x\n", adr, len));
- for (int i = 0; i<len; i++)
- {
- int v = readi(list + 6 + i * 2);
- m_view->lightparams[i + adr].d = (float(v & 0xff)) / 255.0f;
- m_view->lightparams[i + adr].a = (float((v >> 8) & 0xff)) / 255.0f;
- m_view->lightparams[i + adr].s = (float((v >> 16) & 0xff)) / 255.0f;
- m_view->lightparams[i + adr].p = (v >> 24) & 0xff;
- //LOG_TGP((" %02X\n",v));
- }
- list += 6 + len * 2;
- break;
- }
- case 7:
- list += 4;
- break;
- case 8:
- list += 4;
- break;
- case 9:
- list += 6;
- break;
- case 0xa:
- list += 8;
- break;
- case 0xb:
- list += 26;
- break;
- case 0xc:
- list += 6;
- break;
- case 0xf:
- case -1:
- goto end;
- default:
- LOG_TGP(("VIDEO: unknown type %d\n", type));
- goto end;
- }
- }
- end:
- ;
- }
- m_render_done = 0;
+ if (!m_render_done && (m_listctl[1] & 0x1f) == 0x1f)
+ {
+ UINT16 *list = get_list();
+ // Skip everything but the data uploads
+ LOG_TGP(("VIDEO: scan list %d\n", get_list_number()));
+ for (;;)
+ {
+ int type = (list[1] << 16) | list[0];
+ switch (type) {
+ case 0:
+ list += 2;
+ break;
+ case 1:
+ list += 8;
+ break;
+ case 2:
+ list = skip_direct(list + 2);
+ break;
+ case 3:
+ list += 16;
+ break;
+ case 4:
+ {
+ int adr = readi(list + 2);
+ int len = readi(list + 4) + 1;
+ LOG_TGP(("ZVIDEO: scan color write, adr=%x, len=%x\n", adr, len));
+ for (int i = 0; i<len; i++)
+ {
+ m_tgp_ram[adr - 0x40000 + i] = list[6 + 2 * i];
+ }
+ list += 6 + len * 2;
+ break;
+ }
+ case 5:
+ {
+ int adr = readi(list + 2);
+ int len = readi(list + 4);
+ for (int i = 0; i < len; i++)
+ {
+ m_poly_ram[adr - 0x800000 + i] = readi(list + 2 * i + 6);
+ }
+ list += 6 + len * 2;
+ break;
+ }
+ case 6:
+ {
+ int adr = readi(list + 2);
+ int len = readi(list + 4);
+ //LOG_TGP(("VIDEO: upload data, adr=%x, len=%x\n", adr, len));
+ for (int i = 0; i<len; i++)
+ {
+ int v = readi(list + 6 + i * 2);
+ m_view->lightparams[i + adr].d = (float(v & 0xff)) / 255.0f;
+ m_view->lightparams[i + adr].a = (float((v >> 8) & 0xff)) / 255.0f;
+ m_view->lightparams[i + adr].s = (float((v >> 16) & 0xff)) / 255.0f;
+ m_view->lightparams[i + adr].p = (v >> 24) & 0xff;
+ //LOG_TGP((" %02X\n",v));
+ }
+ list += 6 + len * 2;
+ break;
+ }
+ case 7:
+ list += 4;
+ break;
+ case 8:
+ list += 4;
+ break;
+ case 9:
+ list += 6;
+ break;
+ case 0xa:
+ list += 8;
+ break;
+ case 0xb:
+ list += 26;
+ break;
+ case 0xc:
+ list += 6;
+ break;
+ case 0xf:
+ case -1:
+ goto end;
+ default:
+ LOG_TGP(("VIDEO: unknown type %d\n", type));
+ goto end;
+ }
+ }
+ end:
+ ;
+ }
+ m_render_done = 0;
}
VIDEO_START_MEMBER(model1_state, model1)
diff --git a/src/mame/video/model3.cpp b/src/mame/video/model3.cpp
index eb1bfbd5438..2a81f39d7bd 100644
--- a/src/mame/video/model3.cpp
+++ b/src/mame/video/model3.cpp
@@ -825,13 +825,13 @@ cached_texture *model3_state::get_texture(int page, int texx, int texy, int texw
-------- -------- -------- ------x- ?
-------- -------- -------- -------x ?
- 0x01,0x02 only present on Step 2+
+ 0x01,0x02 only present on Step 2+
0x01: xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx Model scale (float)
0x02: -------- -------- x------- -------- Texture replace
- -------- -------- -x------ -------- Switch bank
- -------- -------- --xxxxxx x------- X offset
- -------- -------- -------- -xxxxxxx Y offset
+ -------- -------- -x------ -------- Switch bank
+ -------- -------- --xxxxxx x------- X offset
+ -------- -------- -------- -xxxxxxx Y offset
0x03: --x----- -------- -------- -------- ?
-------- -xxxxxxx xxxx---- -------- LOD?
@@ -850,47 +850,47 @@ cached_texture *model3_state::get_texture(int page, int texx, int texy, int texw
Polygon Data
0x00: xxxxxx-- -------- -------- -------- Specular
- ------x- -------- -------- -------- Clockwise data
+ ------x- -------- -------- -------- Clockwise data
-------x xxxxxxxx xxxxxx-- -------- Polygon ID
- -------- -------- ------xx -------- Discard this polygon
- -------- -------- -------- x------- Specular enable
+ -------- -------- ------xx -------- Discard this polygon
+ -------- -------- -------- x------- Specular enable
-------- -------- -------- -x------ 0 = Triangle, 1 = Quad
- -------- -------- -------- --x----- Polygon is points
- -------- -------- -------- ---x---- Smoothing enable
+ -------- -------- -------- --x----- Polygon is points
+ -------- -------- -------- ---x---- Smoothing enable
-------- -------- -------- ----x--- Vertex 3 shared from previous polygon
-------- -------- -------- -----x-- Vertex 2 shared from previous polygon
-------- -------- -------- ------x- Vertex 1 shared from previous polygon
-------- -------- -------- -------x Vertex 0 shared from previous polygon
-
+
0x01: xxxxxxxx xxxxxxxx xxxxxxxx -------- Polygon normal X coordinate (2.22 fixed point)
- -------- -------- -------- x------- Edge on translucency
+ -------- -------- -------- x------- Edge on translucency
-------- -------- -------- -x------ UV format (0 = 13.3, 1 = 16.0)
- -------- -------- -------- --x----- Enable fixed shading
+ -------- -------- -------- --x----- Enable fixed shading
-------- -------- -------- ---x---- Enable double-sided polygon
- -------- -------- -------- ----x--- Enable smooth shading
+ -------- -------- -------- ----x--- Enable smooth shading
-------- -------- -------- -----x-- If set, this is the last polygon
-------- -------- -------- ------x- Poly color, 1 = RGB, 0 = color table
- -------- -------- -------- -------x No LOS return
+ -------- -------- -------- -------x No LOS return
0x02: xxxxxxxx xxxxxxxx xxxxxxxx -------- Polygon normal Y coordinate (2.22 fixed point)
- -------- -------- -------- xxx----- Microtexture select
- -------- -------- -------- ---x---- Microtexture enable
- -------- -------- -------- ----xx-- Microtexture min LOD
+ -------- -------- -------- xxx----- Microtexture select
+ -------- -------- -------- ---x---- Microtexture enable
+ -------- -------- -------- ----xx-- Microtexture min LOD
-------- -------- -------- ------x- Texture U mirror enable
-------- -------- -------- -------x Texture V mirror enable
0x03: xxxxxxxx xxxxxxxx xxxxxxxx -------- Polygon normal Z coordinate (2.22 fixed point)
- -------- -------- -------- x------- X wrap smoothing
- -------- -------- -------- -x------ Y wrap smoothing
+ -------- -------- -------- x------- X wrap smoothing
+ -------- -------- -------- -x------ Y wrap smoothing
-------- -------- -------- --xxx--- Texture width (in 8-pixel tiles)
-------- -------- -------- -----xxx Texture height (in 8-pixel tiles)
0x04: xxxxxxxx xxxxxxxx xxxxxxxx -------- Color (RGB888)
-------- -------- -------- x------- Translator map select
- -------- -------- -------- -x------ Texture page
- -------- -------- -------- --xxxxxx Upper 6 bits of texture U coordinate
+ -------- -------- -------- -x------ Texture page
+ -------- -------- -------- --xxxxxx Upper 6 bits of texture U coordinate
0x05: xxxxxxxx xxxxxxxx xxxxxxxx -------- Texture NP scale
-------- -------- -------- x------- Low bit of texture U coordinate
@@ -900,17 +900,17 @@ cached_texture *model3_state::get_texture(int page, int texx, int texy, int texw
0x06: x------- -------- -------- -------- Texture contour enable
-xxxxxxx -------- -------- -------- Translator map offset
-------- xxxxxx-- -------- -------- Polygon translucency
- -------- ------x- -------- -------- Translucency pattern select
+ -------- ------x- -------- -------- Translucency pattern select
-------- -------x -------- -------- 1 = disable lighting
-------- -------- xxxxx--- -------- Polygon light modifier (Amount that a luminous polygon will burn through fog.
Valid range is 0.0 to 1.0. 0.0 is completely fogged;
1.0 has no fog.)
-------- -------- -----x-- -------- Texture enable
-------- -------- ------xx x------- Texture format
- -------- -------- -------- -xx----- Shininess
- -------- -------- -------- ---x---- High priority polygon
- -------- -------- -------- ----x--- Layered polygon (stencil)
- -------- -------- -------- -----xxx Translucency mode
+ -------- -------- -------- -xx----- Shininess
+ -------- -------- -------- ---x---- High priority polygon
+ -------- -------- -------- ----x--- Layered polygon (stencil)
+ -------- -------- -------- -----xxx Translucency mode
Vertex entry
diff --git a/src/mame/video/mw8080bw.cpp b/src/mame/video/mw8080bw.cpp
index 425bf758fc9..6b0276d6e6d 100644
--- a/src/mame/video/mw8080bw.cpp
+++ b/src/mame/video/mw8080bw.cpp
@@ -82,8 +82,8 @@ UINT32 mw8080bw_state::screen_update_mw8080bw(screen_device &screen, bitmap_rgb3
* (guess) pin 8 low for trench floor
* thus, trench side: 1.4 or 2.2 V
* trench floor: 1.3 or 2.0 V
- * trech top: 1.8 or 3 V
- * scaled to 3.2 V = 255, 1.2 V = 0 (arbitrary values chosen to match video)
+ * trech top: 1.8 or 3 V
+ * scaled to 3.2 V = 255, 1.2 V = 0 (arbitrary values chosen to match video)
*/
#define SPCENCTR_TOP_TRENCH_DARK_RGB32_PEN rgb_t(0x4d, 0x4d, 0x4d)
@@ -111,7 +111,7 @@ UINT32 mw8080bw_state::screen_update_spcenctr(screen_device &screen, bitmap_rgb3
memset(line_buf, 0, 256);
- if(m_spcenctr_bright_control)
+ if(m_spcenctr_bright_control)
m_spcenctr_brightness = 255;
else if(m_spcenctr_brightness > SPCENCTR_BRIGHTNESS_DECAY)
m_spcenctr_brightness -= SPCENCTR_BRIGHTNESS_DECAY;
diff --git a/src/mame/video/neogeo_spr.cpp b/src/mame/video/neogeo_spr.cpp
index 93a9ca1e68e..b6a772d476c 100644
--- a/src/mame/video/neogeo_spr.cpp
+++ b/src/mame/video/neogeo_spr.cpp
@@ -709,15 +709,15 @@ UINT32 neosprite_optimized_device::optimize_helper(std::vector<UINT8> &spritegfx
// convert the sprite graphics data into a format that allows faster blitting
UINT8 *src;
UINT8 *dest;
-
+
UINT32 mask = get_region_mask(region_sprites, region_sprites_size);
-
+
spritegfx.resize(mask + 1);
UINT32 spritegfx_address_mask = mask;
-
+
src = region_sprites;
dest = &spritegfx[0];
-
+
for (unsigned i = 0; i < region_sprites_size; i += 0x80, src += 0x80)
{
for (unsigned y = 0; y < 0x10; y++)
@@ -729,7 +729,7 @@ UINT32 neosprite_optimized_device::optimize_helper(std::vector<UINT8> &spritegfx
(((src[0x42 | (y << 2)] >> x) & 0x01) << 1) |
(((src[0x40 | (y << 2)] >> x) & 0x01) << 0);
}
-
+
for (unsigned x = 0; x < 8; x++)
{
*(dest++) = (((src[0x03 | (y << 2)] >> x) & 0x01) << 3) |
@@ -739,7 +739,7 @@ UINT32 neosprite_optimized_device::optimize_helper(std::vector<UINT8> &spritegfx
}
}
}
-
+
return spritegfx_address_mask;
}
diff --git a/src/mame/video/neogeo_spr.h b/src/mame/video/neogeo_spr.h
index 6be770b9c3b..a5cb2c99c3c 100644
--- a/src/mame/video/neogeo_spr.h
+++ b/src/mame/video/neogeo_spr.h
@@ -26,7 +26,7 @@ public:
virtual void optimize_sprite_data();
virtual void set_optimized_sprite_data(UINT8* sprdata, UINT32 mask);
-
+
virtual void draw_fixed_layer_2pixels(UINT32*&pixel_addr, int offset, UINT8* gfx_base, const pen_t* char_pens);
void draw_fixed_layer(bitmap_rgb32 &bitmap, int scanline);
void set_videoram_offset(UINT16 data);
@@ -114,7 +114,7 @@ public:
virtual void draw_pixel(int romaddr, UINT32* dst, const pen_t *line_pens) override;
std::vector<UINT8> m_sprite_gfx;
UINT8* m_spritegfx8;
-
+
private:
UINT32 optimize_helper(std::vector<UINT8> &spritegfx, UINT8* region_sprites, UINT32 region_sprites_size);
};