Previous 15994 Revisions Next

r14279 Tuesday 31st January, 2012 at 08:19:38 UTC by Miodrag Milanović
gb regression fix, other instances are fine since they are not accessing regions directly (nw)
[src/mess/video]gb.c

src/mess/video/gb.c
r14278r14279
12361236   if (mode == GB_VIDEO_CGB) vram_size = 0x4000;
12371237
12381238   /* free regions if already allocated */
1239   if (machine.region("gfx1")->base())      machine.region_free("gfx1");
1240   if (machine.region("gfx2")->base())      machine.region_free("gfx2");
1239   if (machine.region("gfx1")->base())      machine.region_free(":gfx1");
1240   if (machine.region("gfx2")->base())      machine.region_free(":gfx2");
12411241
1242   state->m_lcd.gb_vram = machine.region_alloc("gfx1", vram_size, 1, ENDIANNESS_LITTLE );
1243   state->m_lcd.gb_oam = machine.region_alloc("gfx2", 0x100, 1, ENDIANNESS_LITTLE );
1242   state->m_lcd.gb_vram = machine.region_alloc(":gfx1", vram_size, 1, ENDIANNESS_LITTLE );
1243   state->m_lcd.gb_oam = machine.region_alloc(":gfx2", 0x100, 1, ENDIANNESS_LITTLE );
12441244   memset( state->m_lcd.gb_vram->base(), 0, vram_size );
12451245
12461246   state->m_lcd.gb_vram_ptr = state->m_lcd.gb_vram->base();

Previous 15994 Revisions Next


© 1998-2018 The MESS Team