igs/igs_m027_023vid.cpp, igs/pgm.cpp: removed unneeded trampoline

This commit is contained in:
Ivan Vangelista 2024-10-18 22:43:53 +02:00
parent 16a5e4eb9e
commit 4c8c9e5780
3 changed files with 12 additions and 27 deletions

View file

@ -27,7 +27,6 @@ Main components for the PCB-0457-03-GS are:
#include "machine/nvram.h"
#include "machine/ticket.h"
#include "machine/timer.h"
#include "sound/ics2115.h"
#include "emupal.h"
@ -110,7 +109,6 @@ private:
TIMER_DEVICE_CALLBACK_MEMBER(interrupt);
u32 screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
u16 sprites_r(offs_t offset);
void screen_vblank(int state);
@ -148,17 +146,12 @@ void igs_m027_023vid_state::machine_reset()
}
u32 igs_m027_023vid_state::screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect)
{
return m_video->screen_update(screen, bitmap, cliprect);
}
void igs_m027_023vid_state::screen_vblank(int state)
{
// rising edge
if (state)
{
/* first 0xa00 of main ram = sprites, seems to be buffered, DMA? */
// first 0xa00 of main ram = sprites, seems to be buffered, DMA?
m_video->get_sprites();
}
}
@ -344,7 +337,7 @@ void igs_m027_023vid_state::gpio_out_w(u8 data)
TIMER_DEVICE_CALLBACK_MEMBER(igs_m027_023vid_state::interrupt)
{
int scanline = param;
int const scanline = param;
switch (scanline)
{
@ -365,7 +358,7 @@ u16 igs_m027_023vid_state::sprites_r(offs_t offset)
// it is also copied to a secondary RAM area, which seems to be our datasource in this case
address_space &mem = m_maincpu->space(AS_PROGRAM);
u16 sprdata = mem.read_word(0x28000000 + offset * 2);
u16 const sprdata = mem.read_word(0x28000000 + offset * 2);
return sprdata;
}
@ -404,7 +397,7 @@ void igs_m027_023vid_state::m027_023vid(machine_config &config)
m_screen->set_vblank_time(ATTOSECONDS_IN_USEC(1000));
m_screen->set_size(512, 256);
m_screen->set_visarea(0, 448-1, 0, 224-1);
m_screen->set_screen_update(FUNC(igs_m027_023vid_state::screen_update));
m_screen->set_screen_update(m_video, FUNC(igs023_video_device::screen_update));
m_screen->set_palette(m_palette);
m_screen->screen_vblank().set(FUNC(igs_m027_023vid_state::screen_vblank));

View file

@ -457,11 +457,6 @@ void pgm_state::video_start()
{
}
u32 pgm_state::screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect)
{
return m_video->screen_update(screen, bitmap, cliprect);
}
void pgm_state::screen_vblank(int state)
{
// rising edge
@ -493,7 +488,7 @@ void pgm_state::pgmbase(machine_config &config)
/* video hardware */
screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
screen.set_raw(50_MHz_XTAL/5, 640, 0, 448, 264, 0, 224); // or 20MHz / 2? framerate verified
screen.set_screen_update(FUNC(pgm_state::screen_update));
screen.set_screen_update(m_video, FUNC(igs023_video_device::screen_update));
screen.screen_vblank().set(FUNC(pgm_state::screen_vblank));
screen.set_palette(m_palette);

View file

@ -20,6 +20,7 @@
#include "machine/timer.h"
#include "machine/v3021.h"
#include "sound/ics2115.h"
#include "emupal.h"
#include "tilemap.h"
@ -54,28 +55,28 @@ protected:
virtual void machine_reset() override ATTR_COLD;
virtual void video_start() override ATTR_COLD;
/* memory pointers */
// memory pointers
required_shared_ptr<u16> m_mainram;
optional_ioport m_region;
optional_ioport m_regionhack;
/* devices */
// devices
required_device<cpu_device> m_maincpu;
/* hack */
// hack
int m_irq4_disabled = 0;
void pgm_base_mem(address_map &map) ATTR_COLD;
void pgm_mem(address_map &map) ATTR_COLD;
private:
/* memory pointers */
// memory pointers
required_shared_ptr<u8> m_z80_mainram;
/* devices */
// devices
required_device<cpu_device> m_soundcpu;
required_device<palette_device> m_palette;
required_device<generic_latch_8_device> m_soundlatch;
@ -83,7 +84,6 @@ private:
required_device<ics2115_device> m_ics;
required_device<igs023_video_device> m_video;
/* used by rendering */
void coin_counter_w(u16 data);
u8 z80_ram_r(offs_t offset);
void z80_ram_w(offs_t offset, u8 data);
@ -92,7 +92,6 @@ private:
void m68k_l1_w(u8 data);
void z80_l3_w(u8 data);
u32 screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
void screen_vblank(int state);
TIMER_DEVICE_CALLBACK_MEMBER(interrupt);
u16 sprites_r(offs_t offset);
@ -104,10 +103,8 @@ private:
/*----------- defined in drivers/pgm.cpp -----------*/
//----------- defined in igs/pgm.cpp -----------
INPUT_PORTS_EXTERN(pgm);
extern gfx_decode_entry const gfx_pgm[];
#endif // MAME_IGS_PGM_H