summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatarGravatar cam900 <dbtlrchl@naver.com>2019-03-30 06:44:25 +0900
committerGravatarGravatar ajrhacker <ajrhacker@users.noreply.github.com>2019-03-29 17:44:25 -0400
commit8b08ad2ce691219eefa67f8b99baaeecadd35a81 (patch) (github)
tree4a8fea96bbdf44e373d057c56945f0f12cd0fb61
parente4d3e12e25efa7cff945db53990c88628292b512 (diff)
downloadmame-8b08ad2ce691219eefa67f8b99baaeecadd35a81.tar.bz2
mame-8b08ad2ce691219eefa67f8b99baaeecadd35a81.zip
emupal.cpp : Remove MCFGs, Simplify handlers (#4713)
-rw-r--r--src/emu/emupal.cpp36
-rw-r--r--src/emu/emupal.h60
-rw-r--r--src/mame/drivers/blockout.cpp1
-rw-r--r--src/mame/drivers/bottom9.cpp2
-rw-r--r--src/mame/drivers/cbasebal.cpp2
-rw-r--r--src/mame/drivers/cultures.cpp3
-rw-r--r--src/mame/drivers/ddragon3.cpp2
-rw-r--r--src/mame/drivers/dec0.cpp2
-rw-r--r--src/mame/drivers/hotblock.cpp4
-rw-r--r--src/mame/drivers/invqix.cpp2
-rw-r--r--src/mame/drivers/model1.cpp2
-rw-r--r--src/mame/drivers/r2dx_v33.cpp2
-rw-r--r--src/mame/drivers/sigmab98.cpp12
-rw-r--r--src/mame/drivers/spy.cpp2
-rw-r--r--src/mame/drivers/srmp6.cpp2
-rw-r--r--src/mame/drivers/sshangha.cpp4
-rw-r--r--src/mame/drivers/supduck.cpp3
-rw-r--r--src/mame/drivers/tumbleb.cpp2
-rw-r--r--src/mame/drivers/witch.cpp2
-rw-r--r--src/mame/machine/leland.cpp4
-rw-r--r--src/mame/machine/seibucop/seibucop_dma.hxx2
-rw-r--r--src/mame/video/flstory.cpp4
-rw-r--r--src/mame/video/itech32.cpp2
-rw-r--r--src/mame/video/ladyfrog.cpp4
-rw-r--r--src/mame/video/m92.cpp2
-rw-r--r--src/mame/video/midtunit.cpp4
-rw-r--r--src/mame/video/midtview.ipp4
-rw-r--r--src/mame/video/mitchell.cpp2
-rw-r--r--src/mame/video/nova2001.cpp6
-rw-r--r--src/mame/video/nycaptor.cpp4
-rw-r--r--src/mame/video/system1.cpp2
31 files changed, 84 insertions, 101 deletions
diff --git a/src/emu/emupal.cpp b/src/emu/emupal.cpp
index 59b77d66ebf..6a998c4849e 100644
--- a/src/emu/emupal.cpp
+++ b/src/emu/emupal.cpp
@@ -337,6 +337,18 @@ palette_device &palette_device::set_format(rrrrggggbbbbrgbx_t, u32 entries)
return *this;
}
+palette_device &palette_device::set_format(xrgbrrrrggggbbbb_bit0_t, u32 entries)
+{
+ set_format(2, &raw_to_rgb_converter::xRGBRRRRGGGGBBBB_bit0_decoder, entries);
+ return *this;
+}
+
+palette_device &palette_device::set_format(xrgbrrrrggggbbbb_bit4_t, u32 entries)
+{
+ set_format(2, &raw_to_rgb_converter::xRGBRRRRGGGGBBBB_bit4_decoder, entries);
+ return *this;
+}
+
//**************************************************************************
// GENERIC WRITE HANDLERS
@@ -373,35 +385,35 @@ inline void palette_device::update_for_write(offs_t byte_offset, int bytes_modif
// write - write a byte to the base paletteram
//-------------------------------------------------
-WRITE8_MEMBER(palette_device::write8)
+void palette_device::write8(offs_t offset, u8 data)
{
m_paletteram.write8(offset, data);
update_for_write(offset, 1);
}
-WRITE16_MEMBER(palette_device::write16)
+void palette_device::write16(offs_t offset, u16 data, u16 mem_mask)
{
m_paletteram.write16(offset, data, mem_mask);
update_for_write(offset * 2, 2);
}
-WRITE32_MEMBER(palette_device::write32)
+void palette_device::write32(offs_t offset, u32 data, u32 mem_mask)
{
m_paletteram.write32(offset, data, mem_mask);
update_for_write(offset * 4, 4);
}
-READ8_MEMBER(palette_device::read8)
+u8 palette_device::read8(offs_t offset)
{
return m_paletteram.read8(offset);
}
-READ16_MEMBER(palette_device::read16)
+u16 palette_device::read16(offs_t offset)
{
return m_paletteram.read16(offset);
}
-READ32_MEMBER(palette_device::read32)
+u32 palette_device::read32(offs_t offset)
{
return m_paletteram.read32(offset);
}
@@ -412,24 +424,24 @@ READ32_MEMBER(palette_device::read32)
// paletteram
//-------------------------------------------------
-WRITE8_MEMBER(palette_device::write8_ext)
+void palette_device::write8_ext(offs_t offset, u8 data)
{
m_paletteram_ext.write8(offset, data);
update_for_write(offset, 1);
}
-WRITE16_MEMBER(palette_device::write16_ext)
+void palette_device::write16_ext(offs_t offset, u16 data, u16 mem_mask)
{
m_paletteram_ext.write16(offset, data, mem_mask);
update_for_write(offset * 2, 2);
}
-READ8_MEMBER(palette_device::read8_ext)
+u8 palette_device::read8_ext(offs_t offset)
{
return m_paletteram_ext.read8(offset);
}
-READ16_MEMBER(palette_device::read16_ext)
+u16 palette_device::read16_ext(offs_t offset)
{
return m_paletteram_ext.read16(offset);
}
@@ -440,7 +452,7 @@ READ16_MEMBER(palette_device::read16_ext)
// paletteram, updating indirect colors
//-------------------------------------------------
-WRITE8_MEMBER(palette_device::write_indirect)
+void palette_device::write_indirect(offs_t offset, u8 data)
{
m_paletteram.write8(offset, data);
update_for_write(offset, 1, true);
@@ -452,7 +464,7 @@ WRITE8_MEMBER(palette_device::write_indirect)
// paletteram, updating indirect colors
//-------------------------------------------------
-WRITE8_MEMBER(palette_device::write_indirect_ext)
+void palette_device::write_indirect_ext(offs_t offset, u8 data)
{
m_paletteram_ext.write8(offset, data);
update_for_write(offset, 1, true);
diff --git a/src/emu/emupal.h b/src/emu/emupal.h
index 0711bf1a296..b4f52ac2a55 100644
--- a/src/emu/emupal.h
+++ b/src/emu/emupal.h
@@ -97,36 +97,6 @@
//**************************************************************************
-// CONSTANTS
-//**************************************************************************
-
-// exotic 5-5-5 formats
-#define PALETTE_FORMAT_xRGBRRRRGGGGBBBB_bit0 raw_to_rgb_converter(2, &raw_to_rgb_converter::xRGBRRRRGGGGBBBB_bit0_decoder)
-#define PALETTE_FORMAT_xRGBRRRRGGGGBBBB_bit4 raw_to_rgb_converter(2, &raw_to_rgb_converter::xRGBRRRRGGGGBBBB_bit4_decoder)
-
-//**************************************************************************
-// DEVICE CONFIGURATION MACROS
-//**************************************************************************
-
-#define MCFG_PALETTE_ADD(_tag, _entries) \
- MCFG_DEVICE_ADD(_tag, PALETTE, 0) \
- downcast<palette_device &>(*device).set_entries(_entries);
-
-
-#define MCFG_PALETTE_FORMAT(_format) \
- downcast<palette_device &>(*device).set_format(PALETTE_FORMAT_##_format);
-
-
-// not implemented yet
-#if 0
-#define MCFG_PALETTE_ADD_HARDCODED(_tag, _array) \
- MCFG_PALETTE_ADD(_tag, sizeof(_array) / 3) \
- downcast<palette_device &>(*device).set_init(palette_init_delegate(FUNC(palette_device::palette_init_RRRRGGGGBBBB_proms), downcast<palette_device *>(device)));
-#endif
-
-
-
-//**************************************************************************
// TYPE DEFINITIONS
//**************************************************************************
@@ -273,7 +243,9 @@ public:
enum rgb_444_prom_t { RGB_444_PROMS, RRRRGGGGBBBB_PROMS };
// exotic formats
- enum rrrrggggbbbbrgbx_t { RRRRGGGGBBBBRGBx };
+ enum rrrrggggbbbbrgbx_t { RRRRGGGGBBBBRGBx };
+ enum xrgbrrrrggggbbbb_bit0_t { xRGBRRRRGGGGBBBB_bit0 };
+ enum xrgbrrrrggggbbbb_bit4_t { xRGBRRRRGGGGBBBB_bit4 };
// construction/destruction
palette_device(const machine_config &mconfig, const char *tag, device_t *owner, init_delegate &&init, u32 entries = 0U, u32 indirect = 0U);
@@ -358,6 +330,8 @@ public:
palette_device &set_format(grbx_888_t, u32 entries);
palette_device &set_format(bgrx_888_t, u32 entries);
palette_device &set_format(rrrrggggbbbbrgbx_t, u32 entries);
+ palette_device &set_format(xrgbrrrrggggbbbb_bit0_t, u32 entries);
+ palette_device &set_format(xrgbrrrrggggbbbb_bit4_t, u32 entries);
template <typename T> palette_device &set_format(T x, u32 entries, u32 indirect) { set_format(x, entries); set_indirect_entries(indirect); return *this; }
palette_device &set_membits(int membits) { m_membits = membits; m_membits_supplied = true; return *this; }
palette_device &set_endianness(endianness_t endianness) { m_endianness = endianness; m_endianness_supplied = true; return *this; }
@@ -404,18 +378,18 @@ public:
}
// generic read/write handlers
- DECLARE_READ8_MEMBER(read8);
- DECLARE_READ8_MEMBER(read8_ext);
- DECLARE_WRITE8_MEMBER(write8);
- DECLARE_WRITE8_MEMBER(write8_ext);
- DECLARE_WRITE8_MEMBER(write_indirect);
- DECLARE_WRITE8_MEMBER(write_indirect_ext);
- DECLARE_READ16_MEMBER(read16);
- DECLARE_READ16_MEMBER(read16_ext);
- DECLARE_WRITE16_MEMBER(write16);
- DECLARE_WRITE16_MEMBER(write16_ext);
- DECLARE_READ32_MEMBER(read32);
- DECLARE_WRITE32_MEMBER(write32);
+ u8 read8(offs_t offset);
+ u8 read8_ext(offs_t offset);
+ void write8(offs_t offset, u8 data);
+ void write8_ext(offs_t offset, u8 data);
+ void write_indirect(offs_t offset, u8 data);
+ void write_indirect_ext(offs_t offset, u8 data);
+ u16 read16(offs_t offset);
+ u16 read16_ext(offs_t offset);
+ void write16(offs_t offset, u16 data, u16 mem_mask = u16(~0));
+ void write16_ext(offs_t offset, u16 data, u16 mem_mask = u16(~0));
+ u32 read32(offs_t offset);
+ void write32(offs_t offset, u32 data, u32 mem_mask = u32(~0));
// helper to update palette when data changed
void update() { if (!m_init.isnull()) m_init(*this); }
diff --git a/src/mame/drivers/blockout.cpp b/src/mame/drivers/blockout.cpp
index 17bff9d43fd..e3a4b9fc722 100644
--- a/src/mame/drivers/blockout.cpp
+++ b/src/mame/drivers/blockout.cpp
@@ -324,7 +324,6 @@ void blockout_state::blockout(machine_config &config)
PALETTE(config, m_palette).set_entries(513);
-
/* sound hardware */
SPEAKER(config, "lspeaker").front_left();
SPEAKER(config, "rspeaker").front_right();
diff --git a/src/mame/drivers/bottom9.cpp b/src/mame/drivers/bottom9.cpp
index 15e3c7f6167..a03988f867a 100644
--- a/src/mame/drivers/bottom9.cpp
+++ b/src/mame/drivers/bottom9.cpp
@@ -90,7 +90,7 @@ WRITE8_MEMBER(bottom9_state::bottom9_bankedram2_w)
if (m_k052109_selected)
k052109_051960_w(space, offset + 0x2000, data);
else
- m_palette->write8(space, offset, data);
+ m_palette->write8(offset, data);
}
WRITE8_MEMBER(bottom9_state::bankswitch_w)
diff --git a/src/mame/drivers/cbasebal.cpp b/src/mame/drivers/cbasebal.cpp
index 84cb59ac879..304bcd0f7ca 100644
--- a/src/mame/drivers/cbasebal.cpp
+++ b/src/mame/drivers/cbasebal.cpp
@@ -71,7 +71,7 @@ WRITE8_MEMBER(cbasebal_state::bankedram_w)
break;
case 1:
if (offset < 0x800)
- m_palette->write8(space, offset, data);
+ m_palette->write8(offset, data);
break;
default:
cbasebal_scrollram_w(space, offset, data);
diff --git a/src/mame/drivers/cultures.cpp b/src/mame/drivers/cultures.cpp
index 51acf0d401b..1fd6a0c4dc8 100644
--- a/src/mame/drivers/cultures.cpp
+++ b/src/mame/drivers/cultures.cpp
@@ -423,8 +423,7 @@ MACHINE_CONFIG_START(cultures_state::cultures)
screen.set_palette("palette");
GFXDECODE(config, m_gfxdecode, "palette", gfx_cultures);
- MCFG_PALETTE_ADD("palette", 0x3000/2)
- MCFG_PALETTE_FORMAT(xRGBRRRRGGGGBBBB_bit0)
+ PALETTE(config, "palette").set_format(palette_device::xRGBRRRRGGGGBBBB_bit0, 0x3000/2);
/* sound hardware */
SPEAKER(config, "mono").front_center();
diff --git a/src/mame/drivers/ddragon3.cpp b/src/mame/drivers/ddragon3.cpp
index ac3c7c9a629..840baf29b3a 100644
--- a/src/mame/drivers/ddragon3.cpp
+++ b/src/mame/drivers/ddragon3.cpp
@@ -255,7 +255,7 @@ READ16_MEMBER(wwfwfest_state::wwfwfest_paletteram_r)
WRITE16_MEMBER(wwfwfest_state::wwfwfest_paletteram_w)
{
offset = (offset & 0x000f) | (offset & 0x7fc0) >> 2;
- m_palette->write16(space, offset, data, mem_mask);
+ m_palette->write16(offset, data, mem_mask);
}
/*- Priority Control -*/
diff --git a/src/mame/drivers/dec0.cpp b/src/mame/drivers/dec0.cpp
index 105f03a1b83..e6030feec9a 100644
--- a/src/mame/drivers/dec0.cpp
+++ b/src/mame/drivers/dec0.cpp
@@ -795,7 +795,7 @@ READ16_MEMBER( dec0_automat_state::automat_palette_r )
WRITE16_MEMBER( dec0_automat_state::automat_palette_w )
{
offset ^=0xf;
- m_palette->write16(space, offset, data, mem_mask);
+ m_palette->write16(offset, data, mem_mask);
}
diff --git a/src/mame/drivers/hotblock.cpp b/src/mame/drivers/hotblock.cpp
index c053f266313..edc22b3f467 100644
--- a/src/mame/drivers/hotblock.cpp
+++ b/src/mame/drivers/hotblock.cpp
@@ -92,7 +92,7 @@ READ8_MEMBER(hotblock_state::video_read)
if (m_port0 & 0x20) // port 0 = a8 e8 -- palette
{
if (offset < 0x200)
- return m_palette->read8(space, offset);
+ return m_palette->read8(offset);
return 0;
}
@@ -130,7 +130,7 @@ WRITE8_MEMBER(hotblock_state::video_write)
if (m_port0 & 0x20) // port 0 = a8 e8 -- palette
{
if (offset < 0x200)
- m_palette->write8(space, offset, data);
+ m_palette->write8(offset, data);
}
else // port 0 = 88 c8
{
diff --git a/src/mame/drivers/invqix.cpp b/src/mame/drivers/invqix.cpp
index 536e7f6e8fc..bfd2ffeba4d 100644
--- a/src/mame/drivers/invqix.cpp
+++ b/src/mame/drivers/invqix.cpp
@@ -2,7 +2,7 @@
// copyright-holders:R. Belmont
/***************************************************************************
- invqix.c
+ invqix.cpp
Space Invaders / Qix Silver Anniversary Edition
Taito/Namco America inc.
diff --git a/src/mame/drivers/model1.cpp b/src/mame/drivers/model1.cpp
index 8c50750fe83..cda8f528396 100644
--- a/src/mame/drivers/model1.cpp
+++ b/src/mame/drivers/model1.cpp
@@ -890,7 +890,7 @@ WRITE16_MEMBER(model1_state::md0_w)
WRITE16_MEMBER(model1_state::p_w)
{
uint16_t old = m_paletteram16[offset];
- m_palette->write16(space, offset, data, mem_mask);
+ m_palette->write16(offset, data, mem_mask);
if(0 && m_paletteram16[offset] != old)
logerror("XVIDEO: p_w %x, %04x @ %04x (%x)\n", offset, data, mem_mask, m_maincpu->pc());
}
diff --git a/src/mame/drivers/r2dx_v33.cpp b/src/mame/drivers/r2dx_v33.cpp
index 09d63385d51..0fa581fbea7 100644
--- a/src/mame/drivers/r2dx_v33.cpp
+++ b/src/mame/drivers/r2dx_v33.cpp
@@ -376,7 +376,7 @@ WRITE16_MEMBER(r2dx_v33_state::r2dx_paldma_w)
{
uint16_t palval = space.read_word(src);
src += 2;
- m_palette->write16(space, i, palval, 0xffff);
+ m_palette->write16(i, palval);
}
}
diff --git a/src/mame/drivers/sigmab98.cpp b/src/mame/drivers/sigmab98.cpp
index d42c03ae818..5b317cc662f 100644
--- a/src/mame/drivers/sigmab98.cpp
+++ b/src/mame/drivers/sigmab98.cpp
@@ -1674,7 +1674,7 @@ WRITE8_MEMBER(sigmab98_state::gocowboy_4400_w)
}
else if ((offset >= 0x2000) && (offset < 0x2200))
{
- m_palette->write8(space, offset-0x2000, data);
+ m_palette->write8(offset-0x2000, data);
return;
}
else if ((offset >= 0x2800) && (offset < 0x2880))
@@ -1765,7 +1765,7 @@ WRITE8_MEMBER(sigmab98_state::gocowboy_dc00_w)
return;
case 0x64: // (72000) PALETTERAM
- m_palette->write8(space, offset, data);
+ m_palette->write8(offset, data);
return;
}
@@ -1992,7 +1992,7 @@ WRITE8_MEMBER(sigmab98_state::haekaka_b000_w)
case 0x67: // PALETTERAM + VTABLE + VREGS
if (offset < 0x200)
{
- m_palette->write8(space, offset, data);
+ m_palette->write8(offset, data);
return;
}
else if ((offset >= 0x800) && (offset < 0x880))
@@ -2248,7 +2248,7 @@ WRITE8_MEMBER(sigmab98_state::itazuram_nvram_palette_w)
{
if (m_rambank == 0x64)
{
- m_palette->write8(space, offset, data);
+ m_palette->write8(offset, data);
}
else if (m_rambank == 0x52)
{
@@ -2265,7 +2265,7 @@ WRITE8_MEMBER(sigmab98_state::itazuram_palette_w)
if (m_rombank == 0x6c)
{
if (offset < 0x200)
- m_palette->write8(space, offset, data);
+ m_palette->write8(offset, data);
}
else
{
@@ -2497,7 +2497,7 @@ WRITE8_MEMBER(sigmab98_state::tdoboon_c000_w)
case 0x66: // PALETTERAM + VTABLE
if (offset < 0x200)
{
- m_palette->write8(space, offset, data);
+ m_palette->write8(offset, data);
return;
}
else if ((offset >= 0x800) && (offset < 0x880))
diff --git a/src/mame/drivers/spy.cpp b/src/mame/drivers/spy.cpp
index 434b002b8ff..d3120763e23 100644
--- a/src/mame/drivers/spy.cpp
+++ b/src/mame/drivers/spy.cpp
@@ -64,7 +64,7 @@ WRITE8_MEMBER(spy_state::spy_bankedram1_w)
{
if (m_rambank & 1)
{
- m_palette->write8(space,offset,data);
+ m_palette->write8(offset,data);
}
else if (m_rambank & 2)
{
diff --git a/src/mame/drivers/srmp6.cpp b/src/mame/drivers/srmp6.cpp
index 2643a5ee1b6..587883e1d4a 100644
--- a/src/mame/drivers/srmp6.cpp
+++ b/src/mame/drivers/srmp6.cpp
@@ -525,7 +525,7 @@ WRITE16_MEMBER(srmp6_state::paletteram_w)
{
int brg = m_brightness & 0x7f;
- m_palette->write16(space, offset, data, mem_mask);
+ m_palette->write16(offset, data, mem_mask);
if (brg & 0x40)
{
diff --git a/src/mame/drivers/sshangha.cpp b/src/mame/drivers/sshangha.cpp
index 1200d740f49..ce0fde56e78 100644
--- a/src/mame/drivers/sshangha.cpp
+++ b/src/mame/drivers/sshangha.cpp
@@ -184,7 +184,7 @@ WRITE16_MEMBER(sshangha_state::palette_w)
case 0x600: offset = (offset & 0x1ff) | 0x400; break;
}
- m_palette->write16(space, offset, data, mem_mask);
+ m_palette->write16(offset, data, mem_mask);
}
READ16_MEMBER(sshangha_state::palette_r)
@@ -196,7 +196,7 @@ READ16_MEMBER(sshangha_state::palette_r)
case 0x400: offset = (offset & 0x1ff) | 0x000; break;
case 0x600: offset = (offset & 0x1ff) | 0x400; break;
}
- return m_palette->read16(space, offset, mem_mask);
+ return m_palette->read16(offset);
}
void sshangha_state::sshangha_map(address_map &map)
diff --git a/src/mame/drivers/supduck.cpp b/src/mame/drivers/supduck.cpp
index 5a18c908aa1..c365e463fb4 100644
--- a/src/mame/drivers/supduck.cpp
+++ b/src/mame/drivers/supduck.cpp
@@ -467,8 +467,7 @@ MACHINE_CONFIG_START(supduck_state::supduck)
TIGEROAD_SPRITE(config, m_spritegen, 0);
- MCFG_PALETTE_ADD("palette", 0x800/2)
- MCFG_PALETTE_FORMAT(xRGBRRRRGGGGBBBB_bit4)
+ PALETTE(config, m_palette).set_format(palette_device::xRGBRRRRGGGGBBBB_bit4, 0x800/2);
/* sound hardware */
SPEAKER(config, "mono").front_center();
diff --git a/src/mame/drivers/tumbleb.cpp b/src/mame/drivers/tumbleb.cpp
index 8716bc0c83d..fb2ca9a1bc5 100644
--- a/src/mame/drivers/tumbleb.cpp
+++ b/src/mame/drivers/tumbleb.cpp
@@ -3775,7 +3775,7 @@ void tumbleb_state::init_chokchok()
init_htchctch();
/* different palette format, closer to tumblep -- is this controlled by a register? the palette was right with the hatch catch trojan */
- m_maincpu->space(AS_PROGRAM).install_write_handler(0x140000, 0x140fff, write16_delegate(FUNC(palette_device::write16), m_palette.target()));
+ m_maincpu->space(AS_PROGRAM).install_write_handler(0x140000, 0x140fff, write16s_delegate(FUNC(palette_device::write16), m_palette.target()));
/* slightly different banking */
m_maincpu->space(AS_PROGRAM).install_write_handler(0x100002, 0x100003, write16_delegate(FUNC(tumbleb_state::chokchok_tilebank_w),this));
diff --git a/src/mame/drivers/witch.cpp b/src/mame/drivers/witch.cpp
index 79b6dad6827..ba620398e0e 100644
--- a/src/mame/drivers/witch.cpp
+++ b/src/mame/drivers/witch.cpp
@@ -1002,7 +1002,7 @@ void keirinou_state::keirinou(machine_config &config)
PALETTE(config.replace(), m_palette).set_entries(0x200+0x80);
m_gfxdecode->set_info(gfx_keirinou);
-// MCFG_PALETTE_FORMAT(IIBBGGRR)
+// m_palette->set_format(palette_device::IIBBGGRR, 0x200+0x80);
// Keirin Ou does have two individual PPIs (NEC D8255AC-2)
m_ppi[0]->out_pc_callback().set(FUNC(keirinou_state::write_keirinou_a002));
diff --git a/src/mame/machine/leland.cpp b/src/mame/machine/leland.cpp
index 46c871dd30e..6069d59528c 100644
--- a/src/mame/machine/leland.cpp
+++ b/src/mame/machine/leland.cpp
@@ -1236,7 +1236,7 @@ WRITE8_MEMBER(ataxx_state::ataxx_master_output_w)
WRITE8_MEMBER(leland_state::leland_gated_paletteram_w)
{
if (m_wcol_enable)
- m_palette->write8(space, offset, data);
+ m_palette->write8(offset, data);
}
@@ -1251,7 +1251,7 @@ READ8_MEMBER(leland_state::leland_gated_paletteram_r)
WRITE8_MEMBER(ataxx_state::ataxx_paletteram_and_misc_w)
{
if (m_wcol_enable)
- m_palette->write8(space, offset, data);
+ m_palette->write8(offset, data);
else if (offset == 0x7f8 || offset == 0x7f9)
leland_master_video_addr_w(space, offset - 0x7f8, data);
else if (offset == 0x7fc)
diff --git a/src/mame/machine/seibucop/seibucop_dma.hxx b/src/mame/machine/seibucop/seibucop_dma.hxx
index b4bdfb160e7..98b76b26c7f 100644
--- a/src/mame/machine/seibucop/seibucop_dma.hxx
+++ b/src/mame/machine/seibucop/seibucop_dma.hxx
@@ -22,7 +22,7 @@ void raiden2cop_device::dma_palette_buffer()
{
uint16_t palval = m_host_space->read_word(src);
src += 2;
- m_paletteramout_cb(i, palval, 0xffff);
+ m_paletteramout_cb(i, palval);
//m_palette->set_pen_color(i, pal5bit(palval >> 0), pal5bit(palval >> 5), pal5bit(palval >> 10));
}
}
diff --git a/src/mame/video/flstory.cpp b/src/mame/video/flstory.cpp
index be695acd92a..8f0f811f8f5 100644
--- a/src/mame/video/flstory.cpp
+++ b/src/mame/video/flstory.cpp
@@ -110,9 +110,9 @@ WRITE8_MEMBER(flstory_state::flstory_videoram_w)
WRITE8_MEMBER(flstory_state::flstory_palette_w)
{
if (offset & 0x100)
- m_palette->write8_ext(space, (offset & 0xff) + (m_palette_bank << 8), data);
+ m_palette->write8_ext((offset & 0xff) + (m_palette_bank << 8), data);
else
- m_palette->write8(space, (offset & 0xff) + (m_palette_bank << 8), data);
+ m_palette->write8((offset & 0xff) + (m_palette_bank << 8), data);
}
READ8_MEMBER(flstory_state::flstory_palette_r)
diff --git a/src/mame/video/itech32.cpp b/src/mame/video/itech32.cpp
index 8a43b4baf28..a86923847d2 100644
--- a/src/mame/video/itech32.cpp
+++ b/src/mame/video/itech32.cpp
@@ -319,7 +319,7 @@ WRITE16_MEMBER(itech32_state::bloodstm_paletteram_w)
mem_mask >>= 8;
}
- m_palette->write16(space, offset, data, mem_mask);
+ m_palette->write16(offset, data, mem_mask);
}
diff --git a/src/mame/video/ladyfrog.cpp b/src/mame/video/ladyfrog.cpp
index d36c5e72408..f0991b0e39e 100644
--- a/src/mame/video/ladyfrog.cpp
+++ b/src/mame/video/ladyfrog.cpp
@@ -45,9 +45,9 @@ READ8_MEMBER(ladyfrog_state::ladyfrog_videoram_r)
WRITE8_MEMBER(ladyfrog_state::ladyfrog_palette_w)
{
if (offset & 0x100)
- m_palette->write8_ext(space, (offset & 0xff) + (m_palette_bank << 8), data);
+ m_palette->write8_ext((offset & 0xff) + (m_palette_bank << 8), data);
else
- m_palette->write8(space, (offset & 0xff) + (m_palette_bank << 8), data);
+ m_palette->write8((offset & 0xff) + (m_palette_bank << 8), data);
}
READ8_MEMBER(ladyfrog_state::ladyfrog_palette_r)
diff --git a/src/mame/video/m92.cpp b/src/mame/video/m92.cpp
index cd650228b24..3e4c6475ef8 100644
--- a/src/mame/video/m92.cpp
+++ b/src/mame/video/m92.cpp
@@ -140,7 +140,7 @@ READ16_MEMBER(m92_state::paletteram_r)
WRITE16_MEMBER(m92_state::paletteram_w)
{
- m_palette->write16(space, offset | (m_palette_bank << 10), data, mem_mask);
+ m_palette->write16(offset | (m_palette_bank << 10), data, mem_mask);
}
/*****************************************************************************/
diff --git a/src/mame/video/midtunit.cpp b/src/mame/video/midtunit.cpp
index 6fcafa2f232..303e374f5fe 100644
--- a/src/mame/video/midtunit.cpp
+++ b/src/mame/video/midtunit.cpp
@@ -280,13 +280,13 @@ READ16_MEMBER(midwunit_video_device::midwunit_control_r)
WRITE16_MEMBER(midxunit_video_device::midxunit_paletteram_w)
{
if (!(offset & 1))
- m_palette->write16(space, offset / 2, data, mem_mask);
+ m_palette->write16(offset / 2, data, mem_mask);
}
READ16_MEMBER(midxunit_video_device::midxunit_paletteram_r)
{
- return m_palette->read16(space, offset / 2, mem_mask);
+ return m_palette->read16(offset / 2);
}
diff --git a/src/mame/video/midtview.ipp b/src/mame/video/midtview.ipp
index 02da31bf928..046a193e8d3 100644
--- a/src/mame/video/midtview.ipp
+++ b/src/mame/video/midtview.ipp
@@ -45,7 +45,7 @@ void midtunit_video_device::device_add_mconfig(machine_config &config)
debugscreen.set_raw(8000000 * 2, 506, 100, 500, 289, 20, 274);
debugscreen.set_screen_update(FUNC(midtunit_video_device::debug_screen_update));
- PALETTE(config, m_debug_palette, 32768).set_format(PALETTE_FORMAT_xRRRRRGGGGGBBBBB);
+ PALETTE(config, m_debug_palette).set_format(palette_device::xRGB_555, 32768);
}
void midwunit_video_device::device_add_mconfig(machine_config &config)
@@ -54,7 +54,7 @@ void midwunit_video_device::device_add_mconfig(machine_config &config)
debugscreen.set_raw(8000000, 506, 101, 501, 289, 20, 274);
debugscreen.set_screen_update(FUNC(midwunit_video_device::debug_screen_update));
- PALETTE(config, m_debug_palette, 32768).set_format(PALETTE_FORMAT_xRRRRRGGGGGBBBBB);
+ PALETTE(config, m_debug_palette).set_format(palette_device::xRGB_555, 32768);
}
void midtunit_video_device::do_debug_blit()
diff --git a/src/mame/video/mitchell.cpp b/src/mame/video/mitchell.cpp
index b92a66dd096..92c95ecc91f 100644
--- a/src/mame/video/mitchell.cpp
+++ b/src/mame/video/mitchell.cpp
@@ -241,7 +241,7 @@ logerror("PC %04x: pang_gfxctrl_w %02x\n",m_maincpu->pc(),data);
WRITE8_MEMBER(mitchell_state::pang_paletteram_w)
{
- m_palette->write8(space, offset + (m_paletteram_bank ? 0x800 : 0x000), data);
+ m_palette->write8(offset + (m_paletteram_bank ? 0x800 : 0x000), data);
}
READ8_MEMBER(mitchell_state::pang_paletteram_r)
diff --git a/src/mame/video/nova2001.cpp b/src/mame/video/nova2001.cpp
index 748dff44a36..4345133c3e4 100644
--- a/src/mame/video/nova2001.cpp
+++ b/src/mame/video/nova2001.cpp
@@ -47,18 +47,18 @@ rgb_t nova2001_state::BBGGRRII(u32 raw)
WRITE8_MEMBER(nova2001_state::paletteram_w)
{
- m_palette->write8(space, offset, data);
+ m_palette->write8(offset, data);
// expand the sprite palette to full length
if (offset < 16)
{
- m_palette->write8(space, 0x200 + offset * 16 + 1, data);
+ m_palette->write8(0x200 + offset * 16 + 1, data);
if (offset != 1)
{
for (int i = 0; i < 16; i++)
{
- m_palette->write8(space, 0x200 + offset + i * 16, data);
+ m_palette->write8(0x200 + offset + i * 16, data);
}
}
}
diff --git a/src/mame/video/nycaptor.cpp b/src/mame/video/nycaptor.cpp
index 5ac593f439c..ae519916d0f 100644
--- a/src/mame/video/nycaptor.cpp
+++ b/src/mame/video/nycaptor.cpp
@@ -86,9 +86,9 @@ WRITE8_MEMBER(nycaptor_state::nycaptor_videoram_w)
WRITE8_MEMBER(nycaptor_state::nycaptor_palette_w)
{
if (offset & 0x100)
- m_palette->write8_ext(space, (offset & 0xff) + (m_palette_bank << 8), data);
+ m_palette->write8_ext((offset & 0xff) + (m_palette_bank << 8), data);
else
- m_palette->write8(space, (offset & 0xff) + (m_palette_bank << 8), data);
+ m_palette->write8((offset & 0xff) + (m_palette_bank << 8), data);
}
READ8_MEMBER(nycaptor_state::nycaptor_palette_r)
diff --git a/src/mame/video/system1.cpp b/src/mame/video/system1.cpp
index d6c3e0a3bdc..745bd7148da 100644
--- a/src/mame/video/system1.cpp
+++ b/src/mame/video/system1.cpp
@@ -340,7 +340,7 @@ WRITE8_MEMBER(system1_state::system1_paletteram_w)
}
else
{
- m_palette->write8(space, offset, data);
+ m_palette->write8(offset, data);
}
}