mirror of
https://github.com/holub/mame
synced 2025-07-05 18:08:04 +03:00
(nw) more header cleaning
This commit is contained in:
parent
fe5e61e0dd
commit
81c398f29d
@ -1,5 +1,9 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:Roberto Fresca
|
||||
#ifndef MAME_INCLUDES_AMPOKER2_H
|
||||
#define MAME_INCLUDES_AMPOKER2_H
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "machine/watchdog.h"
|
||||
#include "emupal.h"
|
||||
@ -7,8 +11,8 @@
|
||||
class ampoker2_state : public driver_device
|
||||
{
|
||||
public:
|
||||
ampoker2_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||
: driver_device(mconfig, type, tag),
|
||||
ampoker2_state(const machine_config &mconfig, device_type type, const char *tag) :
|
||||
driver_device(mconfig, type, tag),
|
||||
m_videoram(*this, "videoram"),
|
||||
m_maincpu(*this, "maincpu"),
|
||||
m_watchdog(*this, "watchdog"),
|
||||
@ -19,6 +23,13 @@ public:
|
||||
void sigma2k(machine_config &config);
|
||||
void ampoker2(machine_config &config);
|
||||
|
||||
void init_rabbitpk();
|
||||
|
||||
protected:
|
||||
virtual void video_start() override;
|
||||
virtual void machine_start() override;
|
||||
|
||||
private:
|
||||
DECLARE_WRITE8_MEMBER(port30_w);
|
||||
DECLARE_WRITE8_MEMBER(port31_w);
|
||||
DECLARE_WRITE8_MEMBER(port32_w);
|
||||
@ -28,17 +39,11 @@ public:
|
||||
DECLARE_WRITE8_MEMBER(port36_w);
|
||||
DECLARE_WRITE8_MEMBER(watchdog_reset_w);
|
||||
DECLARE_WRITE8_MEMBER(videoram_w);
|
||||
void init_rabbitpk();
|
||||
TILE_GET_INFO_MEMBER(get_bg_tile_info);
|
||||
TILE_GET_INFO_MEMBER(s2k_get_bg_tile_info);
|
||||
DECLARE_PALETTE_INIT(ampoker2);
|
||||
DECLARE_VIDEO_START(sigma2k);
|
||||
|
||||
protected:
|
||||
virtual void video_start() override;
|
||||
virtual void machine_start() override;
|
||||
|
||||
private:
|
||||
void io_map(address_map &map);
|
||||
void program_map(address_map &map);
|
||||
|
||||
@ -51,3 +56,5 @@ private:
|
||||
required_device<gfxdecode_device> m_gfxdecode;
|
||||
output_finder<10> m_lamps;
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_AMPOKER2_H
|
||||
|
@ -5,6 +5,10 @@
|
||||
American Speedway
|
||||
|
||||
*************************************************************************/
|
||||
#ifndef MAME_INCLUDES_AMSPDWY_H
|
||||
#define MAME_INCLUDES_AMSPDWY_H
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "machine/gen_latch.h"
|
||||
#include "sound/ym2151.h"
|
||||
@ -14,8 +18,8 @@
|
||||
class amspdwy_state : public driver_device
|
||||
{
|
||||
public:
|
||||
amspdwy_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||
: driver_device(mconfig, type, tag),
|
||||
amspdwy_state(const machine_config &mconfig, device_type type, const char *tag) :
|
||||
driver_device(mconfig, type, tag),
|
||||
m_videoram(*this, "videoram"),
|
||||
m_spriteram(*this, "spriteram"),
|
||||
m_colorram(*this, "colorram"),
|
||||
@ -28,6 +32,14 @@ public:
|
||||
m_soundlatch(*this, "soundlatch")
|
||||
{ }
|
||||
|
||||
void amspdwy(machine_config &config);
|
||||
|
||||
protected:
|
||||
virtual void machine_start() override;
|
||||
virtual void machine_reset() override;
|
||||
virtual void video_start() override;
|
||||
|
||||
private:
|
||||
/* memory pointers */
|
||||
required_shared_ptr<uint8_t> m_videoram;
|
||||
required_shared_ptr<uint8_t> m_spriteram;
|
||||
@ -60,14 +72,12 @@ public:
|
||||
TILEMAP_MAPPER_MEMBER(tilemap_scan_cols_back);
|
||||
|
||||
uint32_t screen_update_amspdwy(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
void draw_sprites( bitmap_ind16 &bitmap, const rectangle &cliprect );
|
||||
uint8_t amspdwy_wheel_r( int index );
|
||||
void draw_sprites(bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
uint8_t amspdwy_wheel_r(int index);
|
||||
|
||||
virtual void machine_start() override;
|
||||
virtual void machine_reset() override;
|
||||
virtual void video_start() override;
|
||||
void amspdwy(machine_config &config);
|
||||
void amspdwy_map(address_map &map);
|
||||
void amspdwy_portmap(address_map &map);
|
||||
void amspdwy_sound_map(address_map &map);
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_AMSPDWY_H
|
||||
|
@ -1,5 +1,10 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:Roberto Fresca
|
||||
#ifndef MAME_INCLUDES_CALOMEGA_H
|
||||
#define MAME_INCLUDES_CALOMEGA_H
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "machine/6821pia.h"
|
||||
#include "machine/6850acia.h"
|
||||
#include "machine/clock.h"
|
||||
@ -28,6 +33,21 @@ public:
|
||||
m_lamps(*this, "lamp%u", 1U)
|
||||
{ }
|
||||
|
||||
void init_sys903();
|
||||
void init_comg080();
|
||||
void init_s903mod();
|
||||
void init_sys905();
|
||||
|
||||
void sys905(machine_config &config);
|
||||
void s903mod(machine_config &config);
|
||||
void sys906(machine_config &config);
|
||||
void sys903(machine_config &config);
|
||||
|
||||
protected:
|
||||
virtual void machine_start() override { m_lamps.resolve(); }
|
||||
virtual void video_start() override;
|
||||
|
||||
private:
|
||||
DECLARE_WRITE8_MEMBER(calomega_videoram_w);
|
||||
DECLARE_WRITE8_MEMBER(calomega_colorram_w);
|
||||
DECLARE_READ8_MEMBER(s903_mux_port_r);
|
||||
@ -49,29 +69,17 @@ public:
|
||||
DECLARE_WRITE_LINE_MEMBER(write_acia_tx);
|
||||
DECLARE_WRITE_LINE_MEMBER(write_acia_clock);
|
||||
DECLARE_WRITE_LINE_MEMBER(update_aciabaud_scale);
|
||||
void init_sys903();
|
||||
void init_comg080();
|
||||
void init_s903mod();
|
||||
void init_sys905();
|
||||
TILE_GET_INFO_MEMBER(get_bg_tile_info);
|
||||
uint32_t screen_update_calomega(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
DECLARE_PALETTE_INIT(calomega);
|
||||
|
||||
void sys905(machine_config &config);
|
||||
void s903mod(machine_config &config);
|
||||
void sys906(machine_config &config);
|
||||
void sys903(machine_config &config);
|
||||
void s903mod_map(address_map &map);
|
||||
void sys903_map(address_map &map);
|
||||
void sys905_map(address_map &map);
|
||||
void sys906_map(address_map &map);
|
||||
protected:
|
||||
virtual void machine_start() override { m_lamps.resolve(); }
|
||||
virtual void video_start() override;
|
||||
|
||||
optional_device_array<pia6821_device, 2> m_pia;
|
||||
|
||||
private:
|
||||
required_device<cpu_device> m_maincpu;
|
||||
optional_device<acia6850_device> m_acia6850_0;
|
||||
optional_device<clock_device> m_aciabaud;
|
||||
@ -95,3 +103,5 @@ private:
|
||||
int m_s905_mux_data;
|
||||
tilemap_t *m_bg_tilemap;
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_CALOMEGA_H
|
||||
|
@ -6,6 +6,10 @@
|
||||
HAR MadMax hardware
|
||||
|
||||
**************************************************************************/
|
||||
#ifndef MAME_INCLUDES_DCHEESE_H
|
||||
#define MAME_INCLUDES_DCHEESE_H
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "machine/gen_latch.h"
|
||||
#include "sound/bsmt2000.h"
|
||||
@ -23,20 +27,27 @@ public:
|
||||
m_audiocpu(*this, "audiocpu"),
|
||||
m_screen(*this, "screen"),
|
||||
m_bsmt(*this, "bsmt"),
|
||||
m_soundlatch(*this, "soundlatch") { }
|
||||
m_soundlatch(*this, "soundlatch")
|
||||
{ }
|
||||
|
||||
void fredmem(machine_config &config);
|
||||
void dcheese(machine_config &config);
|
||||
|
||||
DECLARE_CUSTOM_INPUT_MEMBER(sound_latch_state_r);
|
||||
|
||||
private:
|
||||
protected:
|
||||
enum
|
||||
{
|
||||
TIMER_BLITTER_SCANLINE,
|
||||
TIMER_SIGNAL_IRQ
|
||||
};
|
||||
|
||||
virtual void machine_start() override;
|
||||
virtual void video_start() override;
|
||||
|
||||
virtual void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr) override;
|
||||
|
||||
private:
|
||||
required_region_ptr<uint16_t> m_palrom;
|
||||
required_region_ptr<uint8_t> m_gfxrom;
|
||||
|
||||
@ -72,8 +83,6 @@ private:
|
||||
DECLARE_WRITE16_MEMBER(blitter_vidparam_w);
|
||||
DECLARE_WRITE16_MEMBER(blitter_unknown_w);
|
||||
DECLARE_READ16_MEMBER(blitter_vidparam_r);
|
||||
virtual void machine_start() override;
|
||||
virtual void video_start() override;
|
||||
DECLARE_PALETTE_INIT(dcheese);
|
||||
uint32_t screen_update_dcheese(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
INTERRUPT_GEN_MEMBER(dcheese_vblank);
|
||||
@ -81,13 +90,11 @@ private:
|
||||
void update_irq_state();
|
||||
IRQ_CALLBACK_MEMBER(irq_callback);
|
||||
void update_scanline_irq();
|
||||
void do_clear( );
|
||||
void do_blit( );
|
||||
void do_clear();
|
||||
void do_blit();
|
||||
|
||||
void main_cpu_map(address_map &map);
|
||||
void sound_cpu_map(address_map &map);
|
||||
|
||||
virtual void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr) override;
|
||||
};
|
||||
|
||||
/*----------- defined in drivers/dcheese.c -----------*/
|
||||
#endif // MAME_INCLUDES_DCHEESE_H
|
||||
|
@ -5,6 +5,10 @@
|
||||
Model Racing Dribbling hardware
|
||||
|
||||
*************************************************************************/
|
||||
#ifndef MAME_INCLUDES_DRIBLING_H
|
||||
#define MAME_INCLUDES_DRIBLING_H
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "machine/i8255.h"
|
||||
#include "machine/watchdog.h"
|
||||
@ -13,17 +17,22 @@
|
||||
class dribling_state : public driver_device
|
||||
{
|
||||
public:
|
||||
dribling_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||
: driver_device(mconfig, type, tag),
|
||||
dribling_state(const machine_config &mconfig, device_type type, const char *tag) :
|
||||
driver_device(mconfig, type, tag),
|
||||
m_maincpu(*this, "maincpu"),
|
||||
m_watchdog(*this, "watchdog"),
|
||||
m_ppi8255_0(*this, "ppi8255_0"),
|
||||
m_ppi8255_1(*this, "ppi8255_1"),
|
||||
m_videoram(*this, "videoram"),
|
||||
m_colorram(*this, "colorram"){ }
|
||||
m_colorram(*this, "colorram")
|
||||
{ }
|
||||
|
||||
void dribling(machine_config &config);
|
||||
|
||||
protected:
|
||||
virtual void machine_start() override;
|
||||
virtual void machine_reset() override;
|
||||
|
||||
private:
|
||||
/* devices */
|
||||
required_device<cpu_device> m_maincpu;
|
||||
@ -51,11 +60,11 @@ private:
|
||||
DECLARE_WRITE8_MEMBER(sound_w);
|
||||
DECLARE_WRITE8_MEMBER(pb_w);
|
||||
DECLARE_WRITE8_MEMBER(shr_w);
|
||||
virtual void machine_start() override;
|
||||
virtual void machine_reset() override;
|
||||
DECLARE_PALETTE_INIT(dribling);
|
||||
uint32_t screen_update_dribling(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
INTERRUPT_GEN_MEMBER(dribling_irq_gen);
|
||||
void dribling_map(address_map &map);
|
||||
void io_map(address_map &map);
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_DRIBLING_H
|
||||
|
@ -1,9 +1,10 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders: ElSemi, Roberto Fresca.
|
||||
|
||||
#ifndef MAME_INCLUDES_EFDT_H
|
||||
#define MAME_INCLUDES_EFDT_H
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "machine/74259.h"
|
||||
#include "emupal.h"
|
||||
|
||||
@ -11,8 +12,8 @@
|
||||
class efdt_state : public driver_device
|
||||
{
|
||||
public:
|
||||
efdt_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||
: driver_device(mconfig, type, tag),
|
||||
efdt_state(const machine_config &mconfig, device_type type, const char *tag) :
|
||||
driver_device(mconfig, type, tag),
|
||||
m_maincpu(*this, "maincpu"),
|
||||
m_gfxdecode(*this, "gfxdecode"),
|
||||
m_palette(*this, "palette"),
|
||||
@ -23,6 +24,11 @@ public:
|
||||
|
||||
void efdt(machine_config &config);
|
||||
|
||||
protected:
|
||||
virtual void machine_start() override;
|
||||
virtual void machine_reset() override;
|
||||
virtual void video_start() override;
|
||||
|
||||
private:
|
||||
required_device<cpu_device> m_maincpu;
|
||||
required_device<gfxdecode_device> m_gfxdecode;
|
||||
@ -51,7 +57,6 @@ private:
|
||||
virtual void machine_start() override;
|
||||
virtual void machine_reset() override;
|
||||
|
||||
DECLARE_VIDEO_START(efdt);
|
||||
DECLARE_PALETTE_INIT(efdt);
|
||||
|
||||
DECLARE_WRITE_LINE_MEMBER(vblank_nmi_w);
|
||||
|
@ -29,6 +29,10 @@ public:
|
||||
|
||||
void init_dealer();
|
||||
|
||||
protected:
|
||||
virtual void machine_start() override { m_leds.resolve(); }
|
||||
virtual void machine_reset() override;
|
||||
|
||||
private:
|
||||
DECLARE_WRITE8_MEMBER(dealer_decrypt_rom);
|
||||
DECLARE_WRITE8_MEMBER(port_1_w);
|
||||
@ -37,7 +41,6 @@ private:
|
||||
DECLARE_READ8_MEMBER(ay_porta_mpx_r);
|
||||
DECLARE_WRITE8_MEMBER(flip_screen_w);
|
||||
DECLARE_WRITE8_MEMBER(dealer_pal_w);
|
||||
virtual void machine_reset() override;
|
||||
DECLARE_MACHINE_START(epos);
|
||||
DECLARE_MACHINE_START(dealer);
|
||||
DECLARE_PALETTE_INIT(epos);
|
||||
@ -48,8 +51,6 @@ private:
|
||||
void epos_io_map(address_map &map);
|
||||
void epos_map(address_map &map);
|
||||
|
||||
virtual void machine_start() override { m_leds.resolve(); }
|
||||
|
||||
/* memory pointers */
|
||||
required_shared_ptr<uint8_t> m_videoram;
|
||||
optional_ioport_array<2> m_inputs;
|
||||
|
@ -5,6 +5,10 @@
|
||||
ESD 16 Bit Games
|
||||
|
||||
***************************************************************************/
|
||||
#ifndef MAME_INCLUDES_ESD16_H
|
||||
#define MAME_INCLUDES_ESD16_H
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "machine/eepromser.h"
|
||||
#include "machine/gen_latch.h"
|
||||
@ -13,8 +17,8 @@
|
||||
class esd16_state : public driver_device
|
||||
{
|
||||
public:
|
||||
esd16_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||
: driver_device(mconfig, type, tag),
|
||||
esd16_state(const machine_config &mconfig, device_type type, const char *tag) :
|
||||
driver_device(mconfig, type, tag),
|
||||
m_vram_0(*this, "vram_0"),
|
||||
m_vram_1(*this, "vram_1"),
|
||||
m_scroll_0(*this, "scroll_0"),
|
||||
@ -29,7 +33,7 @@ public:
|
||||
m_sprgen(*this, "spritegen"),
|
||||
m_eeprom(*this, "eeprom"),
|
||||
m_soundlatch(*this, "soundlatch")
|
||||
{}
|
||||
{ }
|
||||
|
||||
void jumppop(machine_config &config);
|
||||
void esd16(machine_config &config);
|
||||
@ -38,6 +42,11 @@ public:
|
||||
void hedpanio(machine_config &config);
|
||||
void hedpanic(machine_config &config);
|
||||
|
||||
protected:
|
||||
virtual void machine_start() override;
|
||||
virtual void machine_reset() override;
|
||||
virtual void video_start() override;
|
||||
|
||||
private:
|
||||
/* memory pointers */
|
||||
required_shared_ptr<uint16_t> m_vram_0;
|
||||
@ -79,9 +88,6 @@ private:
|
||||
TILE_GET_INFO_MEMBER(get_tile_info_0_16x16);
|
||||
TILE_GET_INFO_MEMBER(get_tile_info_1);
|
||||
TILE_GET_INFO_MEMBER(get_tile_info_1_16x16);
|
||||
virtual void machine_start() override;
|
||||
virtual void machine_reset() override;
|
||||
virtual void video_start() override;
|
||||
uint32_t screen_update_hedpanic(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
DECOSPR_PRIORITY_CB_MEMBER(hedpanic_pri_callback);
|
||||
void hedpanic_map(address_map &map);
|
||||
@ -99,3 +105,5 @@ private:
|
||||
void esd16_sprite_area(address_map &map, u32 base);
|
||||
void esd16_vram_area(address_map &map, u32 base);
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_ESD16_H
|
||||
|
@ -35,6 +35,11 @@ public:
|
||||
|
||||
void gotcha(machine_config &config);
|
||||
|
||||
protected:
|
||||
virtual void machine_start() override;
|
||||
virtual void machine_reset() override;
|
||||
virtual void video_start() override;
|
||||
|
||||
private:
|
||||
DECLARE_WRITE16_MEMBER(gotcha_lamps_w);
|
||||
DECLARE_WRITE16_MEMBER(gotcha_fgvideoram_w);
|
||||
@ -46,9 +51,6 @@ private:
|
||||
TILEMAP_MAPPER_MEMBER(gotcha_tilemap_scan);
|
||||
TILE_GET_INFO_MEMBER(fg_get_tile_info);
|
||||
TILE_GET_INFO_MEMBER(bg_get_tile_info);
|
||||
virtual void machine_start() override;
|
||||
virtual void machine_reset() override;
|
||||
virtual void video_start() override;
|
||||
uint32_t screen_update_gotcha(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
inline void get_tile_info( tile_data &tileinfo, int tile_index ,uint16_t *vram, int color_offs);
|
||||
void gotcha_map(address_map &map);
|
||||
|
@ -5,21 +5,29 @@
|
||||
Gumbo - Miss Bingo - Miss Puzzle
|
||||
|
||||
*************************************************************************/
|
||||
#ifndef MAME_INCLUDES_GUMBO_H
|
||||
#define MAME_INCLUDES_GUMBO_H
|
||||
|
||||
#pragma once
|
||||
|
||||
class gumbo_state : public driver_device
|
||||
{
|
||||
public:
|
||||
gumbo_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||
: driver_device(mconfig, type, tag),
|
||||
gumbo_state(const machine_config &mconfig, device_type type, const char *tag) :
|
||||
driver_device(mconfig, type, tag),
|
||||
m_bg_videoram(*this, "bg_videoram"),
|
||||
m_fg_videoram(*this, "fg_videoram"),
|
||||
m_maincpu(*this, "maincpu"),
|
||||
m_gfxdecode(*this, "gfxdecode") { }
|
||||
m_gfxdecode(*this, "gfxdecode")
|
||||
{ }
|
||||
|
||||
void mspuzzle(machine_config &config);
|
||||
void dblpoint(machine_config &config);
|
||||
void gumbo(machine_config &config);
|
||||
|
||||
protected:
|
||||
virtual void video_start() override;
|
||||
|
||||
private:
|
||||
/* memory pointers */
|
||||
required_shared_ptr<uint16_t> m_bg_videoram;
|
||||
@ -28,15 +36,19 @@ private:
|
||||
/* video-related */
|
||||
tilemap_t *m_bg_tilemap;
|
||||
tilemap_t *m_fg_tilemap;
|
||||
|
||||
required_device<cpu_device> m_maincpu;
|
||||
required_device<gfxdecode_device> m_gfxdecode;
|
||||
|
||||
DECLARE_WRITE16_MEMBER(gumbo_bg_videoram_w);
|
||||
DECLARE_WRITE16_MEMBER(gumbo_fg_videoram_w);
|
||||
TILE_GET_INFO_MEMBER(get_gumbo_bg_tile_info);
|
||||
TILE_GET_INFO_MEMBER(get_gumbo_fg_tile_info);
|
||||
virtual void video_start() override;
|
||||
uint32_t screen_update_gumbo(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
required_device<cpu_device> m_maincpu;
|
||||
required_device<gfxdecode_device> m_gfxdecode;
|
||||
|
||||
void dblpoint_map(address_map &map);
|
||||
void gumbo_map(address_map &map);
|
||||
void mspuzzle_map(address_map &map);
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_GUMBO_H
|
||||
|
@ -5,6 +5,10 @@
|
||||
Lady Frog
|
||||
|
||||
*************************************************************************/
|
||||
#ifndef MAME_INCLUDES_LADYFROG_H
|
||||
#define MAME_INCLUDES_LADYFROG_H
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "machine/gen_latch.h"
|
||||
#include "sound/msm5232.h"
|
||||
@ -13,8 +17,8 @@
|
||||
class ladyfrog_state : public driver_device
|
||||
{
|
||||
public:
|
||||
ladyfrog_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||
: driver_device(mconfig, type, tag),
|
||||
ladyfrog_state(const machine_config &mconfig, device_type type, const char *tag) :
|
||||
driver_device(mconfig, type, tag),
|
||||
m_videoram(*this, "videoram"),
|
||||
m_scrlram(*this, "scrlram"),
|
||||
m_maincpu(*this, "maincpu"),
|
||||
@ -22,11 +26,17 @@ public:
|
||||
m_msm(*this, "msm"),
|
||||
m_gfxdecode(*this, "gfxdecode"),
|
||||
m_palette(*this, "palette"),
|
||||
m_soundlatch(*this, "soundlatch") { }
|
||||
m_soundlatch(*this, "soundlatch")
|
||||
{ }
|
||||
|
||||
void toucheme(machine_config &config);
|
||||
void ladyfrog(machine_config &config);
|
||||
|
||||
protected:
|
||||
virtual void machine_start() override;
|
||||
virtual void machine_reset() override;
|
||||
virtual void video_start() override;
|
||||
|
||||
private:
|
||||
/* memory pointers */
|
||||
required_shared_ptr<uint8_t> m_videoram;
|
||||
@ -74,9 +84,6 @@ private:
|
||||
DECLARE_WRITE8_MEMBER(ladyfrog_scrlram_w);
|
||||
DECLARE_WRITE8_MEMBER(unk_w);
|
||||
TILE_GET_INFO_MEMBER(get_tile_info);
|
||||
virtual void machine_start() override;
|
||||
virtual void machine_reset() override;
|
||||
virtual void video_start() override;
|
||||
DECLARE_VIDEO_START(toucheme);
|
||||
DECLARE_VIDEO_START(ladyfrog_common);
|
||||
uint32_t screen_update_ladyfrog(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
@ -85,3 +92,5 @@ private:
|
||||
void ladyfrog_map(address_map &map);
|
||||
void ladyfrog_sound_map(address_map &map);
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_LADYFROG_H
|
||||
|
@ -5,6 +5,10 @@
|
||||
Malzak
|
||||
|
||||
*************************************************************************/
|
||||
#ifndef MAME_INCLUDES_MALZAK_H
|
||||
#define MAME_INCLUDES_MALZAK_H
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "machine/s2636.h"
|
||||
#include "video/saa5050.h"
|
||||
@ -15,15 +19,16 @@ class malzak_state : public driver_device
|
||||
{
|
||||
public:
|
||||
malzak_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||
: driver_device(mconfig, type, tag),
|
||||
m_maincpu(*this, "maincpu"),
|
||||
m_s2636(*this, "s2636%u", 0U),
|
||||
m_trom(*this, "saa5050"),
|
||||
m_videoram(*this, "videoram"),
|
||||
m_gfxdecode(*this, "gfxdecode"),
|
||||
m_screen(*this, "screen"),
|
||||
m_palette(*this, "palette"),
|
||||
m_mainbank(*this, "mainbank") { }
|
||||
: driver_device(mconfig, type, tag)
|
||||
, m_maincpu(*this, "maincpu")
|
||||
, m_s2636(*this, "s2636%u", 0U)
|
||||
, m_trom(*this, "saa5050")
|
||||
, m_videoram(*this, "videoram")
|
||||
, m_gfxdecode(*this, "gfxdecode")
|
||||
, m_screen(*this, "screen")
|
||||
, m_palette(*this, "palette")
|
||||
, m_mainbank(*this, "mainbank")
|
||||
{ }
|
||||
|
||||
void malzak(machine_config &config);
|
||||
void malzak2(machine_config &config);
|
||||
@ -68,3 +73,5 @@ private:
|
||||
void malzak_io_map(address_map &map);
|
||||
void malzak_map(address_map &map);
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_MALZAK_H
|
||||
|
@ -1,5 +1,9 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:Paul Priest, David Haywood
|
||||
#ifndef MAME_INCLUDES_MCATADV_H
|
||||
#define MAME_INCLUDES_MCATADV_H
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "machine/watchdog.h"
|
||||
#include "emupal.h"
|
||||
@ -64,3 +68,5 @@ private:
|
||||
void nost_sound_io_map(address_map &map);
|
||||
void nost_sound_map(address_map &map);
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_MCATADV_H
|
||||
|
@ -24,21 +24,6 @@
|
||||
#define DRMATH_MONITOR_DISPLAY 0
|
||||
|
||||
|
||||
struct micro3d_vtx
|
||||
{
|
||||
int32_t x, y, z;
|
||||
};
|
||||
|
||||
enum planes
|
||||
{
|
||||
CLIP_Z_MIN,
|
||||
CLIP_Z_MAX,
|
||||
CLIP_X_MIN,
|
||||
CLIP_X_MAX,
|
||||
CLIP_Y_MIN,
|
||||
CLIP_Y_MAX
|
||||
};
|
||||
|
||||
class micro3d_sound_device;
|
||||
|
||||
class micro3d_state : public driver_device
|
||||
@ -75,12 +60,36 @@ public:
|
||||
|
||||
DECLARE_CUSTOM_INPUT_MEMBER(botss_hwchk_r);
|
||||
|
||||
private:
|
||||
protected:
|
||||
enum
|
||||
{
|
||||
TIMER_MAC_DONE
|
||||
};
|
||||
|
||||
virtual void machine_reset() override;
|
||||
virtual void video_start() override;
|
||||
virtual void video_reset() override;
|
||||
|
||||
virtual void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr) override;
|
||||
|
||||
private:
|
||||
enum planes
|
||||
{
|
||||
CLIP_Z_MIN,
|
||||
CLIP_Z_MAX,
|
||||
CLIP_X_MIN,
|
||||
CLIP_X_MAX,
|
||||
CLIP_Y_MIN,
|
||||
CLIP_Y_MAX
|
||||
};
|
||||
|
||||
struct micro3d_vtx
|
||||
{
|
||||
int32_t x, y, z;
|
||||
|
||||
constexpr int64_t dot_product(micro3d_vtx const &that) const;
|
||||
};
|
||||
|
||||
required_device<cpu_device> m_maincpu;
|
||||
required_device<i8051_device> m_audiocpu;
|
||||
required_device<upd7759_device> m_upd7759;
|
||||
@ -170,9 +179,6 @@ private:
|
||||
DECLARE_WRITE8_MEMBER(micro3d_sound_p3_w);
|
||||
DECLARE_READ8_MEMBER(micro3d_sound_p1_r);
|
||||
DECLARE_READ8_MEMBER(micro3d_sound_p3_r);
|
||||
virtual void machine_reset() override;
|
||||
virtual void video_start() override;
|
||||
virtual void video_reset() override;
|
||||
INTERRUPT_GEN_MEMBER(micro3d_vblank);
|
||||
TIMER_CALLBACK_MEMBER(mac_done_callback);
|
||||
DECLARE_WRITE8_MEMBER(micro3d_upd7759_w);
|
||||
@ -201,8 +207,6 @@ private:
|
||||
void soundmem_prg(address_map &map);
|
||||
void vgbmem(address_map &map);
|
||||
|
||||
virtual void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr) override;
|
||||
|
||||
required_device<mc2661_device> m_vgb_uart;
|
||||
};
|
||||
|
||||
|
@ -5,20 +5,30 @@
|
||||
Mosaic
|
||||
|
||||
*************************************************************************/
|
||||
#ifndef MAME_INCLUDES_MOSAIC_H
|
||||
#define MAME_INCLUDES_MOSAIC_H
|
||||
|
||||
#pragma once
|
||||
|
||||
class mosaic_state : public driver_device
|
||||
{
|
||||
public:
|
||||
mosaic_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||
: driver_device(mconfig, type, tag),
|
||||
mosaic_state(const machine_config &mconfig, device_type type, const char *tag) :
|
||||
driver_device(mconfig, type, tag),
|
||||
m_maincpu(*this, "maincpu"),
|
||||
m_gfxdecode(*this, "gfxdecode"),
|
||||
m_fgvideoram(*this, "fgvideoram"),
|
||||
m_bgvideoram(*this, "bgvideoram") { }
|
||||
m_bgvideoram(*this, "bgvideoram")
|
||||
{ }
|
||||
|
||||
void mosaic(machine_config &config);
|
||||
void gfire2(machine_config &config);
|
||||
|
||||
protected:
|
||||
virtual void machine_start() override;
|
||||
virtual void machine_reset() override;
|
||||
virtual void video_start() override;
|
||||
|
||||
private:
|
||||
/* devices */
|
||||
required_device<cpu_device> m_maincpu;
|
||||
@ -45,13 +55,11 @@ private:
|
||||
TILE_GET_INFO_MEMBER(get_fg_tile_info);
|
||||
TILE_GET_INFO_MEMBER(get_bg_tile_info);
|
||||
|
||||
virtual void machine_start() override;
|
||||
virtual void machine_reset() override;
|
||||
virtual void video_start() override;
|
||||
|
||||
uint32_t screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
void gfire2_io_map(address_map &map);
|
||||
void gfire2_map(address_map &map);
|
||||
void mosaic_io_map(address_map &map);
|
||||
void mosaic_map(address_map &map);
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_MOSAIC_H
|
||||
|
@ -1,18 +1,28 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:David Haywood
|
||||
#ifndef MAME_INCLUDES_NEWS_H
|
||||
#define MAME_INCLUDES_NEWS_H
|
||||
|
||||
#pragma once
|
||||
|
||||
class news_state : public driver_device
|
||||
{
|
||||
public:
|
||||
news_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||
: driver_device(mconfig, type, tag),
|
||||
news_state(const machine_config &mconfig, device_type type, const char *tag) :
|
||||
driver_device(mconfig, type, tag),
|
||||
m_bgram(*this, "bgram"),
|
||||
m_fgram(*this, "fgram"),
|
||||
m_maincpu(*this, "maincpu"),
|
||||
m_gfxdecode(*this, "gfxdecode") { }
|
||||
m_gfxdecode(*this, "gfxdecode")
|
||||
{ }
|
||||
|
||||
void news(machine_config &config);
|
||||
|
||||
protected:
|
||||
virtual void machine_start() override;
|
||||
virtual void machine_reset() override;
|
||||
virtual void video_start() override;
|
||||
|
||||
private:
|
||||
/* memory pointers */
|
||||
required_shared_ptr<uint8_t> m_bgram;
|
||||
@ -22,16 +32,17 @@ private:
|
||||
tilemap_t *m_fg_tilemap;
|
||||
tilemap_t *m_bg_tilemap;
|
||||
int m_bgpic;
|
||||
|
||||
required_device<cpu_device> m_maincpu;
|
||||
required_device<gfxdecode_device> m_gfxdecode;
|
||||
|
||||
DECLARE_WRITE8_MEMBER(news_fgram_w);
|
||||
DECLARE_WRITE8_MEMBER(news_bgram_w);
|
||||
DECLARE_WRITE8_MEMBER(news_bgpic_w);
|
||||
TILE_GET_INFO_MEMBER(get_fg_tile_info);
|
||||
TILE_GET_INFO_MEMBER(get_bg_tile_info);
|
||||
virtual void machine_start() override;
|
||||
virtual void machine_reset() override;
|
||||
virtual void video_start() override;
|
||||
uint32_t screen_update_news(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
required_device<cpu_device> m_maincpu;
|
||||
required_device<gfxdecode_device> m_gfxdecode;
|
||||
void news_map(address_map &map);
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_NEWS_H
|
||||
|
@ -49,6 +49,10 @@ public:
|
||||
void init_enc();
|
||||
void init_deb();
|
||||
|
||||
protected:
|
||||
virtual void machine_start() override { m_lamps.resolve(); }
|
||||
virtual void video_start() override;
|
||||
|
||||
private:
|
||||
DECLARE_WRITE_LINE_MEMBER(ppi2_obf_w);
|
||||
TIMER_CALLBACK_MEMBER(ppi2_ack);
|
||||
@ -74,9 +78,6 @@ private:
|
||||
void nortest1_map(address_map &map);
|
||||
void ssjkrpkr_map(address_map &map);
|
||||
|
||||
virtual void machine_start() override { m_lamps.resolve(); }
|
||||
virtual void video_start() override;
|
||||
|
||||
std::unique_ptr<uint16_t[]> m_np_vram;
|
||||
required_device<cpu_device> m_maincpu;
|
||||
required_device_array<i8255_device, 3> m_ppi8255;
|
||||
|
@ -1,5 +1,9 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:David Haywood, Paul Priest
|
||||
#ifndef MAME_INCLUDES_ONESHOT_H
|
||||
#define MAME_INCLUDES_ONESHOT_H
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "sound/okim6295.h"
|
||||
#include "emupal.h"
|
||||
@ -7,8 +11,8 @@
|
||||
class oneshot_state : public driver_device
|
||||
{
|
||||
public:
|
||||
oneshot_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||
: driver_device(mconfig, type, tag),
|
||||
oneshot_state(const machine_config &mconfig, device_type type, const char *tag) :
|
||||
driver_device(mconfig, type, tag),
|
||||
m_sprites(*this, "sprites"),
|
||||
m_bg_videoram(*this, "bg_videoram"),
|
||||
m_mid_videoram(*this, "mid_videoram"),
|
||||
@ -17,11 +21,17 @@ public:
|
||||
m_maincpu(*this, "maincpu"),
|
||||
m_oki(*this, "oki"),
|
||||
m_gfxdecode(*this, "gfxdecode"),
|
||||
m_palette(*this, "palette") { }
|
||||
m_palette(*this, "palette")
|
||||
{ }
|
||||
|
||||
void maddonna(machine_config &config);
|
||||
void oneshot(machine_config &config);
|
||||
|
||||
protected:
|
||||
virtual void machine_start() override;
|
||||
virtual void machine_reset() override;
|
||||
virtual void video_start() override;
|
||||
|
||||
private:
|
||||
/* memory pointers */
|
||||
required_shared_ptr<uint16_t> m_sprites;
|
||||
@ -46,6 +56,10 @@ private:
|
||||
|
||||
/* devices */
|
||||
required_device<cpu_device> m_maincpu;
|
||||
required_device<okim6295_device> m_oki;
|
||||
required_device<gfxdecode_device> m_gfxdecode;
|
||||
required_device<palette_device> m_palette;
|
||||
|
||||
DECLARE_READ16_MEMBER(oneshot_in0_word_r);
|
||||
DECLARE_READ16_MEMBER(oneshot_gun_x_p1_r);
|
||||
DECLARE_READ16_MEMBER(oneshot_gun_y_p1_r);
|
||||
@ -58,16 +72,12 @@ private:
|
||||
TILE_GET_INFO_MEMBER(get_oneshot_bg_tile_info);
|
||||
TILE_GET_INFO_MEMBER(get_oneshot_mid_tile_info);
|
||||
TILE_GET_INFO_MEMBER(get_oneshot_fg_tile_info);
|
||||
virtual void machine_start() override;
|
||||
virtual void machine_reset() override;
|
||||
virtual void video_start() override;
|
||||
uint32_t screen_update_oneshot(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
uint32_t screen_update_maddonna(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
void draw_crosshairs( bitmap_ind16 &bitmap, const rectangle &cliprect );
|
||||
void draw_sprites( bitmap_ind16 &bitmap, const rectangle &cliprect );
|
||||
required_device<okim6295_device> m_oki;
|
||||
required_device<gfxdecode_device> m_gfxdecode;
|
||||
required_device<palette_device> m_palette;
|
||||
void oneshot_map(address_map &map);
|
||||
void oneshot_sound_map(address_map &map);
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_ONESHOT_H
|
||||
|
@ -19,6 +19,12 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
void pass(machine_config &config);
|
||||
|
||||
protected:
|
||||
virtual void video_start() override;
|
||||
|
||||
private:
|
||||
DECLARE_WRITE16_MEMBER(pass_bg_videoram_w);
|
||||
DECLARE_WRITE16_MEMBER(pass_fg_videoram_w);
|
||||
TILE_GET_INFO_MEMBER(get_pass_bg_tile_info);
|
||||
@ -26,14 +32,10 @@ public:
|
||||
|
||||
uint32_t screen_update_pass(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
|
||||
void pass(machine_config &config);
|
||||
void pass_map(address_map &map);
|
||||
void pass_sound_io_map(address_map &map);
|
||||
void pass_sound_map(address_map &map);
|
||||
protected:
|
||||
virtual void video_start() override;
|
||||
|
||||
private:
|
||||
tilemap_t *m_bg_tilemap;
|
||||
tilemap_t *m_fg_tilemap;
|
||||
|
||||
|
@ -42,6 +42,10 @@ public:
|
||||
|
||||
DECLARE_INPUT_CHANGED_MEMBER(input_changed);
|
||||
|
||||
protected:
|
||||
virtual void machine_start() override { m_lamps.resolve(); }
|
||||
virtual void video_start() override;
|
||||
|
||||
private:
|
||||
INTERRUPT_GEN_MEMBER(nmi_handler);
|
||||
|
||||
@ -55,7 +59,6 @@ private:
|
||||
DECLARE_READ8_MEMBER(pio_portb_r);
|
||||
DECLARE_WRITE8_MEMBER(pio_portb_w);
|
||||
|
||||
|
||||
DECLARE_WRITE8_MEMBER(polyplay_characterram_w);
|
||||
DECLARE_PALETTE_INIT(polyplay);
|
||||
uint32_t screen_update_polyplay(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
@ -64,9 +67,6 @@ private:
|
||||
void polyplay_mem_zre(address_map &map);
|
||||
void polyplay_mem_zrepp(address_map &map);
|
||||
|
||||
virtual void machine_start() override { m_lamps.resolve(); }
|
||||
virtual void video_start() override;
|
||||
|
||||
required_shared_ptr<uint8_t> m_videoram;
|
||||
required_shared_ptr<uint8_t> m_characterram;
|
||||
|
||||
|
@ -1,13 +1,17 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:Nicola Salmoria
|
||||
#ifndef MAME_INCLUDES_TAXIDRIV_H
|
||||
#define MAME_INCLUDES_TAXIDRIV_H
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "emupal.h"
|
||||
|
||||
class taxidriv_state : public driver_device
|
||||
{
|
||||
public:
|
||||
taxidriv_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||
: driver_device(mconfig, type, tag),
|
||||
taxidriv_state(const machine_config &mconfig, device_type type, const char *tag) :
|
||||
driver_device(mconfig, type, tag),
|
||||
m_maincpu(*this, "maincpu"),
|
||||
m_gfxdecode(*this, "gfxdecode"),
|
||||
m_palette(*this, "palette"),
|
||||
@ -19,10 +23,14 @@ public:
|
||||
m_vram5(*this, "vram5"),
|
||||
m_vram6(*this, "vram6"),
|
||||
m_vram7(*this, "vram7"),
|
||||
m_scroll(*this, "scroll") { }
|
||||
m_scroll(*this, "scroll")
|
||||
{ }
|
||||
|
||||
void taxidriv(machine_config &config);
|
||||
|
||||
protected:
|
||||
virtual void machine_start() override;
|
||||
|
||||
private:
|
||||
required_device<cpu_device> m_maincpu;
|
||||
required_device<gfxdecode_device> m_gfxdecode;
|
||||
@ -69,7 +77,6 @@ private:
|
||||
DECLARE_WRITE8_MEMBER(p8910_0b_w);
|
||||
DECLARE_WRITE8_MEMBER(spritectrl_w);
|
||||
|
||||
virtual void machine_start() override;
|
||||
DECLARE_PALETTE_INIT(taxidriv);
|
||||
|
||||
uint32_t screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
@ -78,3 +85,5 @@ private:
|
||||
void cpu3_port_map(address_map &map);
|
||||
void main_map(address_map &map);
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_TAXIDRIV_H
|
||||
|
@ -1,5 +1,9 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:Luca Elia
|
||||
#ifndef MAME_INCLUDES_THEDEEP_H
|
||||
#define MAME_INCLUDES_THEDEEP_H
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "machine/gen_latch.h"
|
||||
#include "machine/timer.h"
|
||||
@ -10,8 +14,8 @@
|
||||
class thedeep_state : public driver_device
|
||||
{
|
||||
public:
|
||||
thedeep_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||
: driver_device(mconfig, type, tag),
|
||||
thedeep_state(const machine_config &mconfig, device_type type, const char *tag) :
|
||||
driver_device(mconfig, type, tag),
|
||||
m_maincpu(*this,"maincpu"),
|
||||
m_audiocpu(*this, "audiocpu"),
|
||||
m_mcu(*this, "mcu"),
|
||||
@ -24,10 +28,15 @@ public:
|
||||
m_vram_1(*this, "vram_1"),
|
||||
m_scroll(*this, "scroll"),
|
||||
m_scroll2(*this, "scroll2")
|
||||
{ }
|
||||
{ }
|
||||
|
||||
void thedeep(machine_config &config);
|
||||
|
||||
protected:
|
||||
virtual void machine_start() override;
|
||||
virtual void machine_reset() override;
|
||||
virtual void video_start() override;
|
||||
|
||||
private:
|
||||
required_device<cpu_device> m_maincpu;
|
||||
required_device<cpu_device> m_audiocpu;
|
||||
@ -69,9 +78,6 @@ private:
|
||||
TILE_GET_INFO_MEMBER(get_tile_info_0);
|
||||
TILE_GET_INFO_MEMBER(get_tile_info_1);
|
||||
|
||||
virtual void machine_start() override;
|
||||
virtual void machine_reset() override;
|
||||
virtual void video_start() override;
|
||||
DECLARE_PALETTE_INIT(thedeep);
|
||||
|
||||
uint32_t screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
@ -82,3 +88,5 @@ private:
|
||||
void audio_map(address_map &map);
|
||||
void main_map(address_map &map);
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_THEDEEP_H
|
||||
|
@ -1,5 +1,9 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:Ernesto Corvi, Roberto Fresca
|
||||
#ifndef MAME_INCLUDES_TRUCO_H
|
||||
#define MAME_INCLUDES_TRUCO_H
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "machine/watchdog.h"
|
||||
#include "sound/dac.h"
|
||||
@ -8,16 +12,21 @@
|
||||
class truco_state : public driver_device
|
||||
{
|
||||
public:
|
||||
truco_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||
: driver_device(mconfig, type, tag),
|
||||
truco_state(const machine_config &mconfig, device_type type, const char *tag) :
|
||||
driver_device(mconfig, type, tag),
|
||||
m_maincpu(*this, "maincpu"),
|
||||
m_watchdog(*this, "watchdog"),
|
||||
m_dac(*this, "dac"),
|
||||
m_videoram(*this, "videoram"),
|
||||
m_battery_ram(*this, "battery_ram") { }
|
||||
m_battery_ram(*this, "battery_ram")
|
||||
{ }
|
||||
|
||||
void truco(machine_config &config);
|
||||
|
||||
protected:
|
||||
virtual void machine_start() override;
|
||||
virtual void machine_reset() override;
|
||||
|
||||
private:
|
||||
required_device<cpu_device> m_maincpu;
|
||||
required_device<watchdog_timer_device> m_watchdog;
|
||||
@ -34,8 +43,6 @@ private:
|
||||
DECLARE_WRITE_LINE_MEMBER(pia_irqa_w);
|
||||
DECLARE_WRITE_LINE_MEMBER(pia_irqb_w);
|
||||
|
||||
virtual void machine_start() override;
|
||||
virtual void machine_reset() override;
|
||||
DECLARE_PALETTE_INIT(truco);
|
||||
|
||||
uint32_t screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
@ -43,3 +50,5 @@ private:
|
||||
INTERRUPT_GEN_MEMBER(interrupt);
|
||||
void main_map(address_map &map);
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_TRUCO_H
|
||||
|
@ -1,5 +1,9 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:Ernesto Corvi
|
||||
#ifndef MAME_INCLUDES_TRUCOCL_H
|
||||
#define MAME_INCLUDES_TRUCOCL_H
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "sound/dac.h"
|
||||
#include "emupal.h"
|
||||
@ -19,12 +23,18 @@ public:
|
||||
|
||||
void init_trucocl();
|
||||
|
||||
private:
|
||||
protected:
|
||||
enum
|
||||
{
|
||||
TIMER_DAC_IRQ
|
||||
};
|
||||
|
||||
virtual void machine_reset() override;
|
||||
virtual void video_start() override;
|
||||
|
||||
virtual void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr) override;
|
||||
|
||||
private:
|
||||
int m_cur_dac_address;
|
||||
int m_cur_dac_address_index;
|
||||
required_shared_ptr<uint8_t> m_videoram;
|
||||
@ -39,7 +49,6 @@ private:
|
||||
DECLARE_WRITE8_MEMBER(trucocl_colorram_w);
|
||||
DECLARE_WRITE8_MEMBER(audio_dac_w);
|
||||
TILE_GET_INFO_MEMBER(get_bg_tile_info);
|
||||
virtual void video_start() override;
|
||||
DECLARE_PALETTE_INIT(trucocl);
|
||||
uint32_t screen_update_trucocl(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
INTERRUPT_GEN_MEMBER(trucocl_interrupt);
|
||||
@ -49,7 +58,6 @@ private:
|
||||
|
||||
void main_map(address_map &map);
|
||||
void main_io(address_map &map);
|
||||
|
||||
virtual void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr) override;
|
||||
virtual void machine_reset() override;
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_TRUCOCL_H
|
||||
|
@ -1,22 +1,31 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:David Haywood, Nicola Salmoria
|
||||
#ifndef MAME_INCLUDES_USGAMES_H
|
||||
#define MAME_INCLUDES_USGAMES_H
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "emupal.h"
|
||||
|
||||
class usgames_state : public driver_device
|
||||
{
|
||||
public:
|
||||
usgames_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||
: driver_device(mconfig, type, tag),
|
||||
usgames_state(const machine_config &mconfig, device_type type, const char *tag) :
|
||||
driver_device(mconfig, type, tag),
|
||||
m_maincpu(*this, "maincpu"),
|
||||
m_gfxdecode(*this, "gfxdecode"),
|
||||
m_videoram(*this, "videoram"),
|
||||
m_charram(*this, "charram"),
|
||||
m_leds(*this, "led%u", 0U) { }
|
||||
m_leds(*this, "led%u", 0U)
|
||||
{ }
|
||||
|
||||
void usg32(machine_config &config);
|
||||
void usg185(machine_config &config);
|
||||
|
||||
protected:
|
||||
virtual void machine_start() override;
|
||||
virtual void video_start() override;
|
||||
|
||||
private:
|
||||
required_device<cpu_device> m_maincpu;
|
||||
required_device<gfxdecode_device> m_gfxdecode;
|
||||
@ -36,11 +45,11 @@ private:
|
||||
|
||||
TILE_GET_INFO_MEMBER(get_tile_info);
|
||||
|
||||
virtual void machine_start() override;
|
||||
virtual void video_start() override;
|
||||
DECLARE_PALETTE_INIT(usgames);
|
||||
|
||||
uint32_t screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
void usg185_map(address_map &map);
|
||||
void usgames_map(address_map &map);
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_USGAMES_H
|
||||
|
@ -1,19 +1,29 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:David Haywood
|
||||
#ifndef MAME_INCLUDES_XYONIX_H
|
||||
#define MAME_INCLUDES_XYONIX_H
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "emupal.h"
|
||||
|
||||
class xyonix_state : public driver_device
|
||||
{
|
||||
public:
|
||||
xyonix_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||
: driver_device(mconfig, type, tag),
|
||||
xyonix_state(const machine_config &mconfig, device_type type, const char *tag) :
|
||||
driver_device(mconfig, type, tag),
|
||||
m_maincpu(*this, "maincpu"),
|
||||
m_gfxdecode(*this, "gfxdecode"),
|
||||
m_vidram(*this, "vidram") { }
|
||||
m_vidram(*this, "vidram")
|
||||
{ }
|
||||
|
||||
void xyonix(machine_config &config);
|
||||
|
||||
protected:
|
||||
virtual void machine_start() override;
|
||||
virtual void machine_reset() override;
|
||||
virtual void video_start() override;
|
||||
|
||||
private:
|
||||
required_device<cpu_device> m_maincpu;
|
||||
required_device<gfxdecode_device> m_gfxdecode;
|
||||
@ -35,9 +45,6 @@ private:
|
||||
DECLARE_WRITE8_MEMBER(io_w);
|
||||
DECLARE_WRITE8_MEMBER(vidram_w);
|
||||
|
||||
virtual void machine_start() override;
|
||||
virtual void machine_reset() override;
|
||||
virtual void video_start() override;
|
||||
TILE_GET_INFO_MEMBER(get_tile_info);
|
||||
DECLARE_PALETTE_INIT(xyonix);
|
||||
uint32_t screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
@ -46,3 +53,5 @@ private:
|
||||
void main_map(address_map &map);
|
||||
void port_map(address_map &map);
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_XYONIX_H
|
||||
|
@ -109,12 +109,12 @@ WRITE8_MEMBER( micro3d_state::vgb_uart_w )
|
||||
*
|
||||
*************************************/
|
||||
|
||||
static inline int64_t dot_product(micro3d_vtx *v1, micro3d_vtx *v2)
|
||||
inline constexpr int64_t micro3d_state::micro3d_vtx::dot_product(micro3d_vtx const &that) const
|
||||
{
|
||||
int64_t result = ((int64_t)v1->x * (int64_t)v2->x) +
|
||||
((int64_t)v1->y * (int64_t)v2->y) +
|
||||
((int64_t)v1->z * (int64_t)v2->z);
|
||||
return result;
|
||||
return
|
||||
(int64_t(x) * int64_t(that.x)) +
|
||||
(int64_t(y) * int64_t(that.y)) +
|
||||
(int64_t(z) * int64_t(that.z));
|
||||
}
|
||||
|
||||
static inline int64_t normalised_multiply(int32_t a, int32_t b)
|
||||
@ -280,23 +280,19 @@ WRITE32_MEMBER(micro3d_state::micro3d_mac2_w)
|
||||
case 0x11: cnt += 0x100;
|
||||
case 0x10:
|
||||
{
|
||||
int i;
|
||||
micro3d_vtx v2;
|
||||
|
||||
v2.x = mac_sram[mrab11 + 0x7fc];
|
||||
v2.y = mac_sram[mrab11 + 0x7fd];
|
||||
v2.z = mac_sram[mrab11 + 0x7fe];
|
||||
|
||||
for (i = 0; i <= cnt; ++i)
|
||||
for (int i = 0; i <= cnt; ++i)
|
||||
{
|
||||
micro3d_vtx v1;
|
||||
int64_t dp;
|
||||
|
||||
v1.x = mac_sram[sram_r_addr++];
|
||||
v1.y = mac_sram[sram_r_addr++];
|
||||
v1.z = mac_sram[sram_r_addr++];
|
||||
|
||||
dp = dot_product(&v1, &v2);
|
||||
int64_t const dp = v1.dot_product(v2);
|
||||
mac_sram[sram_w_addr++] = dp >> 32;
|
||||
mac_sram[sram_w_addr++] = dp & 0xffffffff;
|
||||
mac_sram[sram_w_addr++] = 0;
|
||||
@ -310,23 +306,19 @@ WRITE32_MEMBER(micro3d_state::micro3d_mac2_w)
|
||||
case 0x15: cnt += 0x100;
|
||||
case 0x14:
|
||||
{
|
||||
int i;
|
||||
|
||||
for (i = 0; i <= cnt; ++i)
|
||||
for (int i = 0; i <= cnt; ++i)
|
||||
{
|
||||
micro3d_vtx v1;
|
||||
micro3d_vtx v2;
|
||||
int64_t dp;
|
||||
|
||||
v1.x = mac_sram[sram_r_addr++];
|
||||
v1.y = mac_sram[sram_r_addr++];
|
||||
v1.z = mac_sram[sram_r_addr++];
|
||||
|
||||
micro3d_vtx v2;
|
||||
v2.x = mac_sram[vtx_addr++];
|
||||
v2.y = mac_sram[vtx_addr++];
|
||||
v2.z = mac_sram[vtx_addr++];
|
||||
|
||||
dp = dot_product(&v1, &v2);
|
||||
int64_t const dp = v1.dot_product(v2);
|
||||
mac_sram[sram_w_addr++] = dp >> 32;
|
||||
mac_sram[sram_w_addr++] = dp & 0xffffffff;
|
||||
mac_sram[sram_w_addr++] = 0;
|
||||
|
@ -145,15 +145,14 @@ int micro3d_state::inside(micro3d_vtx *v, enum planes plane)
|
||||
return 0;
|
||||
}
|
||||
|
||||
/* Calculate where two points intersect */
|
||||
micro3d_vtx micro3d_state::intersect(micro3d_vtx *v1, micro3d_vtx *v2, enum planes plane)
|
||||
// Calculate where two points intersect
|
||||
micro3d_state::micro3d_vtx micro3d_state::intersect(micro3d_vtx *v1, micro3d_vtx *v2, enum planes plane)
|
||||
{
|
||||
float m = 0.0;
|
||||
micro3d_vtx vo = { 0, 0, 0 };
|
||||
|
||||
if (v1->x != v2->x)
|
||||
m = (float)(v1->y - v2->y) / (float)(v1->x - v2->x);
|
||||
m = float(v1->y - v2->y) / float(v1->x - v2->x);
|
||||
|
||||
micro3d_vtx vo = { 0, 0, 0 };
|
||||
switch (plane)
|
||||
{
|
||||
case CLIP_Z_MIN:
|
||||
@ -162,8 +161,8 @@ micro3d_vtx micro3d_state::intersect(micro3d_vtx *v1, micro3d_vtx *v2, enum plan
|
||||
|
||||
if (v1->z != v2->z)
|
||||
{
|
||||
mxz = (float)(v1->x - v2->x) / (float)(v1->z - v2->z);
|
||||
myz = (float)(v1->y - v2->y) / (float)(v1->z - v2->z);
|
||||
mxz = float(v1->x - v2->x) / float(v1->z - v2->z);
|
||||
myz = float(v1->y - v2->y) / float(v1->z - v2->z);
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -182,8 +181,8 @@ micro3d_vtx micro3d_state::intersect(micro3d_vtx *v1, micro3d_vtx *v2, enum plan
|
||||
|
||||
if (v1->z != v2->z)
|
||||
{
|
||||
mxz = (float)(v1->x - v2->x) / (float)(v1->z - v2->z);
|
||||
myz = (float)(v1->y - v2->y) / (float)(v1->z - v2->z);
|
||||
mxz = float(v1->x - v2->x) / float(v1->z - v2->z);
|
||||
myz = float(v1->y - v2->y) / float(v1->z - v2->z);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user