summaryrefslogtreecommitdiffstatshomepage
path: root/src/mame/video/cps1.c
diff options
context:
space:
mode:
author Alex W. Jackson <alex.w.jackson@gmail.com>2014-02-05 17:25:58 +0000
committer Alex W. Jackson <alex.w.jackson@gmail.com>2014-02-05 17:25:58 +0000
commit1f7a3bf649c4f27fca0ae70c4965887ed0a83e5c (patch)
treeea24ecd0b0da821708ab554ac4fd5e6ef0e5d102 /src/mame/video/cps1.c
parent0353541f5bbc4afbe95555847fae53414fa1e701 (diff)
Stop the flipping insanity [Alex Jackson]
Tilemap flipping is now calculated relative to the center of the visible area rather than to the total screen size, and the generic flip screen functions no longer reconfigure the actual screen. These changes ensure that in most cases flipping should Just Work for drivers that use MCFG_RAW_PARAMs, games that have a programmable CRTC, and games that have raster effects, and should fix many longstanding flip/cocktail-related regressions. (nw) Unfortunately, it also means that all the thankless work that Osso and hap have been doing over the last few months fixing flipscreen regressions will have to be reverted now. I've also undoubtedly caused new regressions in drivers that handle flipscreen in unusual ways. But now we can share video device implementations between drivers that have been updated to RAW_PARAMs and drivers that haven't without kludges all over the place. And now I can hook up the programmable CRTC in toaplan1.c without abandoning all hope of flipscreen ever working again in that driver. (also nw) I also added savestate registration for the generic soundlatches, which seemed like a good idea. Any particular reason why these weren't being saved?
Diffstat (limited to 'src/mame/video/cps1.c')
-rw-r--r--src/mame/video/cps1.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/mame/video/cps1.c b/src/mame/video/cps1.c
index 2a14a1d1247..a035e7b5f55 100644
--- a/src/mame/video/cps1.c
+++ b/src/mame/video/cps1.c
@@ -2324,7 +2324,7 @@ void cps_state::cps1_render_sprites( screen_device &screen, bitmap_ind16 &bitmap
CODE, \
COLOR, \
!(FLIPX),!(FLIPY), \
- 511-16-(SX),255-16-(SY), screen.priority(),0x02,15); \
+ 512-16-(SX),256-16-(SY), screen.priority(),0x02,15); \
else \
pdrawgfx_transpen(bitmap,\
cliprect,machine().gfx[2], \
@@ -2557,7 +2557,7 @@ void cps_state::cps2_render_sprites( screen_device &screen, bitmap_ind16 &bitmap
CODE, \
COLOR, \
!(FLIPX),!(FLIPY), \
- 511-16-(SX),255-16-(SY), screen.priority(),primasks[priority],15); \
+ 512-16-(SX),256-16-(SY), screen.priority(),primasks[priority],15); \
else \
pdrawgfx_transpen(bitmap,\
cliprect,machine().gfx[2], \
@@ -2720,8 +2720,8 @@ void cps_state::cps1_render_stars( screen_device &screen, bitmap_ind16 &bitmap,
sy = (sy - m_stars2y) & 0xff;
if (flip_screen())
{
- sx = 511 - sx;
- sy = 255 - sy;
+ sx = 512 - sx;
+ sy = 256 - sy;
}
col = ((col & 0xe0) >> 1) + (screen.frame_number() / 16 & 0x0f);
@@ -2745,8 +2745,8 @@ void cps_state::cps1_render_stars( screen_device &screen, bitmap_ind16 &bitmap,
sy = (sy - m_stars1y) & 0xff;
if (flip_screen())
{
- sx = 511 - sx;
- sy = 255 - sy;
+ sx = 512 - sx;
+ sy = 256 - sy;
}
col = ((col & 0xe0) >> 1) + (screen.frame_number() / 16 & 0x0f);