mirror of
https://github.com/holub/mame
synced 2025-05-25 07:15:25 +03:00
[SNES]: Fixed 8bpp layer colors.
This commit is contained in:
parent
fcf3613988
commit
0e6ddcf9a2
@ -338,18 +338,6 @@ READ8_HANDLER( snes_r_io )
|
|||||||
/* offset is from 0x000000 */
|
/* offset is from 0x000000 */
|
||||||
switch( offset )
|
switch( offset )
|
||||||
{
|
{
|
||||||
/* hacks for SimCity 2000 (J) to boot - I presume openbus emulation will fix */
|
|
||||||
case 0x221a:
|
|
||||||
case 0x231c:
|
|
||||||
case 0x241e:
|
|
||||||
return 1;
|
|
||||||
case 0x2017:
|
|
||||||
case 0x221b:
|
|
||||||
case 0x231d:
|
|
||||||
case 0x241f:
|
|
||||||
return 0;
|
|
||||||
case 0x2016:
|
|
||||||
return 2;
|
|
||||||
case OAMDATA: /* 21xy for x=0,1,2 and y=4,5,6,8,9,a returns PPU1 open bus*/
|
case OAMDATA: /* 21xy for x=0,1,2 and y=4,5,6,8,9,a returns PPU1 open bus*/
|
||||||
case BGMODE:
|
case BGMODE:
|
||||||
case MOSAIC:
|
case MOSAIC:
|
||||||
|
@ -473,7 +473,7 @@ INLINE void snes_update_line( UINT8 screen, UINT8 color_depth, UINT8 hires, UINT
|
|||||||
tile_divider = 2;
|
tile_divider = 2;
|
||||||
break;
|
break;
|
||||||
case SNES_COLOR_DEPTH_8BPP:
|
case SNES_COLOR_DEPTH_8BPP:
|
||||||
color_shift = 6; // 2009-08 FP: this should be 6 or 8, if I'm following correctly the drawing code
|
color_shift = 0; //n/a, pal offset is always zero
|
||||||
color_planes = 8;
|
color_planes = 8;
|
||||||
tile_divider = 4;
|
tile_divider = 4;
|
||||||
break;
|
break;
|
||||||
@ -496,7 +496,7 @@ INLINE void snes_update_line( UINT8 screen, UINT8 color_depth, UINT8 hires, UINT
|
|||||||
vflip = snes_vram[tmap + ii + 1] & 0x80;
|
vflip = snes_vram[tmap + ii + 1] & 0x80;
|
||||||
hflip = snes_vram[tmap + ii + 1] & 0x40;
|
hflip = snes_vram[tmap + ii + 1] & 0x40;
|
||||||
priority = ((snes_vram[tmap + ii + 1] & 0x20) >> 5) ? priority_b : priority_a;
|
priority = ((snes_vram[tmap + ii + 1] & 0x20) >> 5) ? priority_b : priority_a;
|
||||||
pal = (snes_vram[tmap + ii + 1] & 0x1c) << color_shift; /* 8 palettes of (4 * color_shift) colours */
|
pal = (color_depth == SNES_COLOR_DEPTH_8BPP) ? 0 : (snes_vram[tmap + ii + 1] & 0x1c) << color_shift; /* 8 palettes of (4 * color_shift) colours */
|
||||||
tile = (snes_vram[tmap + ii + 1] & 0x3) << 8;
|
tile = (snes_vram[tmap + ii + 1] & 0x3) << 8;
|
||||||
tile |= snes_vram[tmap + ii] & 0xff;
|
tile |= snes_vram[tmap + ii] & 0xff;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user