summaryrefslogtreecommitdiffstatshomepage
path: root/src/mame/video/polyplay.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/mame/video/polyplay.cpp')
-rw-r--r--src/mame/video/polyplay.cpp35
1 files changed, 17 insertions, 18 deletions
diff --git a/src/mame/video/polyplay.cpp b/src/mame/video/polyplay.cpp
index e34e3acd98c..a8146e3f79d 100644
--- a/src/mame/video/polyplay.cpp
+++ b/src/mame/video/polyplay.cpp
@@ -15,18 +15,18 @@
#include "emu.h"
#include "includes/polyplay.h"
-PALETTE_INIT_MEMBER(polyplay_state, polyplay)
+void polyplay_state::polyplay_palette(palette_device &palette) const
{
- palette.set_pen_color(0,rgb_t(0x00,0x00,0x00));
- palette.set_pen_color(1,rgb_t(0xff,0xff,0xff));
- palette.set_pen_color(2,rgb_t(0x00,0x00,0x00));
- palette.set_pen_color(3,rgb_t(0xff,0x00,0x00));
- palette.set_pen_color(4,rgb_t(0x00,0xff,0x00));
- palette.set_pen_color(5,rgb_t(0xff,0xff,0x00));
- palette.set_pen_color(6,rgb_t(0x00,0x00,0xff));
- palette.set_pen_color(7,rgb_t(0xff,0x00,0xff));
- palette.set_pen_color(8,rgb_t(0x00,0xff,0xff));
- palette.set_pen_color(9,rgb_t(0xff,0xff,0xff));
+ palette.set_pen_color(0, rgb_t(0x00, 0x00, 0x00));
+ palette.set_pen_color(1, rgb_t(0xff, 0xff, 0xff));
+ palette.set_pen_color(2, rgb_t(0x00, 0x00, 0x00));
+ palette.set_pen_color(3, rgb_t(0xff, 0x00, 0x00));
+ palette.set_pen_color(4, rgb_t(0x00, 0xff, 0x00));
+ palette.set_pen_color(5, rgb_t(0xff, 0xff, 0x00));
+ palette.set_pen_color(6, rgb_t(0x00, 0x00, 0xff));
+ palette.set_pen_color(7, rgb_t(0xff, 0x00, 0xff));
+ palette.set_pen_color(8, rgb_t(0x00, 0xff, 0xff));
+ palette.set_pen_color(9, rgb_t(0xff, 0xff, 0xff));
}
WRITE8_MEMBER(polyplay_state::polyplay_characterram_w)
@@ -45,16 +45,15 @@ void polyplay_state::video_start()
uint32_t polyplay_state::screen_update_polyplay(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect)
{
- uint8_t *videoram = m_videoram;
- offs_t offs;
+ uint8_t const *const videoram = m_videoram;
- for (offs = 0; offs < 0x800; offs++)
+ for (offs_t offs = 0; offs < 0x800; offs++)
{
- int sx = (offs & 0x3f) << 3;
- int sy = offs >> 6 << 3;
- uint8_t code = videoram[offs];
+ int const sx = (offs & 0x3f) << 3;
+ int const sy = offs >> 6 << 3;
+ uint8_t const code = videoram[offs];
- m_gfxdecode->gfx((code >> 7) & 0x01)->opaque(bitmap, cliprect, code, 0, 0, 0, sx, sy);
+ m_gfxdecode->gfx(BIT(code, 7))->opaque(bitmap, cliprect, code, 0, 0, 0, sx, sy);
}
return 0;