• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

C++ GFXDECODE函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C++中GFXDECODE函数的典型用法代码示例。如果您正苦于以下问题:C++ GFXDECODE函数的具体用法?C++ GFXDECODE怎么用?C++ GFXDECODE使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了GFXDECODE函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。

示例1: M68000

void sslam_state::sslam(machine_config &config)
{
	/* basic machine hardware */
	M68000(config, m_maincpu, 12000000);   /* 12 MHz */
	m_maincpu->set_addrmap(AS_PROGRAM, &sslam_state::sslam_program_map);
	m_maincpu->set_vblank_int("screen", FUNC(sslam_state::irq2_line_hold));

	I8051(config, m_audiocpu, 12000000);
	m_audiocpu->set_disable(); /* Internal code is not dumped - 2 boards were protected */

	/* video hardware */
	screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
	screen.set_refresh_hz(58);
	screen.set_vblank_time(ATTOSECONDS_IN_USEC(0));
	screen.set_size(64*8, 32*8);
	screen.set_visarea(1*8, 39*8-1, 1*8, 31*8-1);
	screen.set_screen_update(FUNC(sslam_state::screen_update));
	screen.set_palette(m_palette);

	GFXDECODE(config, m_gfxdecode, m_palette, gfx_sslam);

	PALETTE(config, m_palette, 0x800).set_format(PALETTE_FORMAT_RRRRGGGGBBBBRGBx);

	/* sound hardware */
	SPEAKER(config, "mono").front_center();

	OKIM6295(config, m_oki, 1000000, okim6295_device::PIN7_HIGH);
	m_oki->add_route(ALL_OUTPUTS, "mono", 0.80);
}
开发者ID:Octocontrabass,项目名称:mame,代码行数:29,代码来源:sslam.cpp


示例2: FUNC

GFXDECODE_END

//-------------------------------------------------
//  device_add_mconfig - add device configuration
//-------------------------------------------------

void tk02_device::device_add_mconfig(machine_config &config)
{
	screen_device &screen(SCREEN(config, "mono", SCREEN_TYPE_RASTER));
	screen.set_color(rgb_t::green());
	screen.set_raw(XTAL(8'000'000) * 2, 1024, 0, 640, 312, 0, 250);
	screen.set_screen_update("crtc", FUNC(mc6845_device::screen_update));

	PALETTE(config, m_palette, palette_device::MONOCHROME);

	GFXDECODE(config, "gfxdecode", "palette", gfx_tk02);

	MC6845(config, m_crtc, XTAL(8'000'000) / 4);
	m_crtc->set_screen("mono");
	m_crtc->set_show_border_area(false);
	m_crtc->set_char_width(8);
	m_crtc->set_update_row_callback(FUNC(tk02_device::crtc_update_row), this);
	m_crtc->out_de_callback().set(FUNC(tk02_device::de_w));

	TATUNG_PIPE(config, m_pipe, DERIVED_CLOCK(1, 1), tatung_pipe_cards, nullptr);
}
开发者ID:MoochMcGee,项目名称:mame,代码行数:26,代码来源:tk02.cpp


示例3: Z8001

GFXDECODE_END

void c900_state::c900(machine_config &config)
{
	/* basic machine hardware */
	Z8001(config, m_maincpu, 12_MHz_XTAL / 2);
	m_maincpu->set_addrmap(AS_PROGRAM, &c900_state::mem_map);
	m_maincpu->set_addrmap(AS_DATA, &c900_state::data_map);
	m_maincpu->set_addrmap(AS_IO, &c900_state::io_map);
	m_maincpu->set_addrmap(z8001_device::AS_SIO, &c900_state::special_io_map);

	M6508(config, m_fdcpu, 12_MHz_XTAL / 8); // PH1/PH2 = 1.5 MHz
	m_fdcpu->set_addrmap(AS_PROGRAM, &c900_state::fdc_map);

	GFXDECODE(config, "gfxdecode", "palette", gfx_c900);
	PALETTE(config, "palette", palette_device::MONOCHROME);

	z8036_device &cio(Z8036(config, "cio", 12_MHz_XTAL / 16)); // SNDCLK = 750kHz
	cio.pb_wr_cb().set(FUNC(c900_state::sound_pb_w));

	scc8030_device &scc(SCC8030(config, "scc", 12_MHz_XTAL / 2)); // 5'850'000 is the ideal figure
	/* Port B */
	scc.out_txdb_callback().set("rs232", FUNC(rs232_port_device::write_txd));
	scc.out_dtrb_callback().set("rs232", FUNC(rs232_port_device::write_dtr));
	scc.out_rtsb_callback().set("rs232", FUNC(rs232_port_device::write_rts));
	//scc.out_int_callback().set("rs232", FUNC(c900_state::scc_int));

	rs232_port_device &rs232(RS232_PORT(config, "rs232", default_rs232_devices, "terminal"));
	rs232.rxd_handler().set("scc", FUNC(scc8030_device::rxb_w));
	rs232.cts_handler().set("scc", FUNC(scc8030_device::ctsb_w));

	SPEAKER(config, "mono").front_center();
	SPEAKER_SOUND(config, m_spkrdev).add_route(ALL_OUTPUTS, "mono", 0.05);
}
开发者ID:fesh0r,项目名称:mame-full,代码行数:34,代码来源:c900.cpp


示例4: Z80

INPUT_PORTS_END



void spool99_state::spool99(machine_config &config)
{
	Z80(config, m_maincpu, 24000000/8);
	m_maincpu->set_addrmap(AS_PROGRAM, &spool99_state::spool99_map);
	m_maincpu->set_vblank_int("screen", FUNC(spool99_state::irq0_line_hold));

	GFXDECODE(config, m_gfxdecode, "palette", gfx_spool99);

	screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
	screen.set_refresh_hz(60);
	screen.set_vblank_time(ATTOSECONDS_IN_USEC(0));
	screen.set_size(64*8, 32*8);
	screen.set_visarea(7*8, 55*8-1, 1*8, 31*8-1); //384x240,raw guess
	screen.set_screen_update(FUNC(spool99_state::screen_update));
	screen.set_palette("palette");

	PALETTE(config, "palette").set_format(palette_device::xBGR_444, 0x200);

	EEPROM_93C46_16BIT(config, "eeprom");


	SPEAKER(config, "lspeaker").front_left();
	SPEAKER(config, "rspeaker").front_right();

	OKIM6295(config, m_oki, 1000000, okim6295_device::PIN7_HIGH); // clock frequency & pin 7 not verified
	m_oki->add_route(ALL_OUTPUTS, "lspeaker", 0.47);
	m_oki->add_route(ALL_OUTPUTS, "rspeaker", 0.47);
}
开发者ID:SailorSat,项目名称:cabmame,代码行数:32,代码来源:spool99.cpp


示例5: M68000

void powerbal_state::magicstk(machine_config &config)
{
	/* basic machine hardware */
	M68000(config, m_maincpu, 12000000);   /* 12 MHz */
	m_maincpu->set_addrmap(AS_PROGRAM, &powerbal_state::magicstk_main_map);
	m_maincpu->set_vblank_int("screen", FUNC(powerbal_state::irq2_line_hold));

	EEPROM_93C46_16BIT(config, "eeprom").default_value(0);

	MCFG_MACHINE_START_OVERRIDE(powerbal_state,powerbal)
	MCFG_MACHINE_RESET_OVERRIDE(powerbal_state,powerbal)

	/* video hardware */
	screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
	screen.set_refresh_hz(61);
	screen.set_vblank_time(ATTOSECONDS_IN_USEC(2500) /* not accurate */);
	screen.set_size(128*8, 64*8);
	screen.set_visarea(0*8, 40*8-1, 0*8, 30*8-1);
	screen.set_screen_update(FUNC(powerbal_state::screen_update_powerbal));
	screen.set_palette(m_palette);

	GFXDECODE(config, m_gfxdecode, m_palette, gfx_powerbal);
	PALETTE(config, m_palette).set_format(palette_device::RRRRGGGGBBBBRGBx, 512);

	MCFG_VIDEO_START_OVERRIDE(powerbal_state,powerbal)

	/* sound hardware */
	SPEAKER(config, "mono").front_center();

	OKIM6295(config, m_oki, 1000000, okim6295_device::PIN7_HIGH);
	m_oki->add_route(ALL_OUTPUTS, "mono", 1.0);
	m_oki->set_addrmap(0, &powerbal_state::oki_map);
}
开发者ID:SailorSat,项目名称:cabmame,代码行数:33,代码来源:powerbal.cpp


示例6: M6800

GFXDECODE_END


void sprint8_state::sprint8(machine_config &config)
{
	/* basic machine hardware */
	M6800(config, m_maincpu, 11055000 / 11); /* ? */
	m_maincpu->set_addrmap(AS_PROGRAM, &sprint8_state::sprint8_map);

	TIMER(config, "input_timer").configure_periodic(FUNC(sprint8_state::input_callback), attotime::from_hz(60));

	/* video hardware */
	SCREEN(config, m_screen, SCREEN_TYPE_RASTER);
	m_screen->set_refresh_hz(60);
	m_screen->set_size(512, 261);
	m_screen->set_visarea(0, 495, 0, 231);
	m_screen->set_screen_update(FUNC(sprint8_state::screen_update));
	m_screen->screen_vblank().set(FUNC(sprint8_state::screen_vblank));
	m_screen->set_palette(m_palette);

	GFXDECODE(config, m_gfxdecode, m_palette, gfx_sprint8);
	PALETTE(config, m_palette, FUNC(sprint8_state::sprint8_palette), 36, 18);

	sprint8_audio(config);
}
开发者ID:SailorSat,项目名称:cabmame,代码行数:25,代码来源:sprint8.cpp


示例7: Z80

void ettrivia_state::ettrivia(machine_config &config)
{
	Z80(config, m_maincpu, 12000000/4-48000); //should be ok, it gives the 300 interrupts expected
	m_maincpu->set_addrmap(AS_PROGRAM, &ettrivia_state::cpu_map);
	m_maincpu->set_addrmap(AS_IO, &ettrivia_state::io_map);
	m_maincpu->set_vblank_int("screen", FUNC(ettrivia_state::ettrivia_interrupt));

	NVRAM(config, "nvram", nvram_device::DEFAULT_ALL_0);

	/* video hardware */
	screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
	screen.set_refresh_hz(60);
	screen.set_vblank_time(ATTOSECONDS_IN_USEC(0));
	screen.set_size(256, 256);
	screen.set_visarea(0*8, 32*8-1, 0*8, 28*8-1);
	screen.set_screen_update(FUNC(ettrivia_state::screen_update_ettrivia));
	screen.set_palette("palette");

	GFXDECODE(config, m_gfxdecode, "palette", gfx_ettrivia);
	PALETTE(config, "palette", FUNC(ettrivia_state::ettrivia_palette), 256);

	/* sound hardware */
	SPEAKER(config, "mono").front_center();

	AY8912(config, m_ay[0], 1500000).add_route(ALL_OUTPUTS, "mono", 0.25);

	AY8912(config, m_ay[1], 1500000);
	m_ay[1]->port_a_read_callback().set_ioport("IN1");
	m_ay[1]->add_route(ALL_OUTPUTS, "mono", 0.25);

	AY8912(config, m_ay[2], 1500000);
	m_ay[2]->port_a_read_callback().set_ioport("IN0");
	m_ay[2]->add_route(ALL_OUTPUTS, "mono", 0.25);
}
开发者ID:SailorSat,项目名称:cabmame,代码行数:34,代码来源:ettrivia.cpp


示例8: Z80

void gberet_state::gberetb(machine_config &config)
{
	/* basic machine hardware */
	Z80(config, m_maincpu, XTAL(20'000'000)/4); // divider guessed
	m_maincpu->set_addrmap(AS_PROGRAM, &gberet_state::gberetb_map);
	m_maincpu->set_vblank_int("screen", FUNC(gberet_state::irq0_line_assert));
	m_maincpu->set_periodic_int(FUNC(gberet_state::nmi_line_assert), attotime::from_hz(XTAL(20'000'000)/0x8000)); // divider guessed

	MCFG_MACHINE_START_OVERRIDE(gberet_state,gberet)
	MCFG_MACHINE_RESET_OVERRIDE(gberet_state,gberet)

	/* video hardware */
	screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
	screen.set_refresh_hz(60);
	screen.set_vblank_time(ATTOSECONDS_IN_USEC(0));
	screen.set_size(32*8, 32*8);
	screen.set_visarea(1*8, 31*8-1, 2*8, 30*8-1);
	screen.set_screen_update(FUNC(gberet_state::screen_update_gberetb));
	screen.set_palette(m_palette);

	GFXDECODE(config, m_gfxdecode, m_palette, gfx_gberetb);
	PALETTE(config, m_palette, FUNC(gberet_state::gberet_palette), 2*16*16, 32);
	MCFG_VIDEO_START_OVERRIDE(gberet_state,gberet)

	/* sound hardware */
	SPEAKER(config, "mono").front_center();

	SN76489A(config, m_sn, XTAL(20'000'000)/12).add_route(ALL_OUTPUTS, "mono", 1.0); // divider guessed
}
开发者ID:SailorSat,项目名称:cabmame,代码行数:29,代码来源:gberet.cpp


示例9: Z80

void dday_state::dday(machine_config &config)
{
	/* basic machine hardware */
	Z80(config, m_maincpu, 2000000);     /* 2 MHz ? */
	m_maincpu->set_addrmap(AS_PROGRAM, &dday_state::dday_map);


	/* video hardware */
	SCREEN(config, m_screen, SCREEN_TYPE_RASTER);
	m_screen->set_refresh_hz(60);
	m_screen->set_vblank_time(ATTOSECONDS_IN_USEC(2500) /* not accurate */);
	m_screen->set_size(32*8, 32*8);
	m_screen->set_visarea(0*8, 32*8-1, 0*8, 28*8-1);
	m_screen->set_screen_update(FUNC(dday_state::screen_update_dday));
	m_screen->set_palette(m_palette);

	GFXDECODE(config, m_gfxdecode, m_palette, gfx_dday);
	PALETTE(config, m_palette, FUNC(dday_state::dday_palette), 256).enable_shadows();
	m_palette->set_indirect_entries(256); // HACK!!!

	/* sound hardware */
	SPEAKER(config, "mono").front_center();

	AY8910(config, m_ay1, 1000000).add_route(ALL_OUTPUTS, "mono", 0.25);
	AY8910(config, "ay2", 1000000).add_route(ALL_OUTPUTS, "mono", 0.25);
}
开发者ID:fesh0r,项目名称:mame-full,代码行数:26,代码来源:dday.cpp


示例10: KONAMI1

void megazone_state::megazone(machine_config &config)
{
	/* basic machine hardware */
	KONAMI1(config, m_maincpu, XTAL(18'432'000)/9);        /* 2.048 MHz */
	m_maincpu->set_addrmap(AS_PROGRAM, &megazone_state::megazone_map);

	Z80(config, m_audiocpu, XTAL(18'432'000)/6);     /* Z80 Clock is derived from the H1 signal */
	m_audiocpu->set_addrmap(AS_PROGRAM, &megazone_state::megazone_sound_map);
	m_audiocpu->set_addrmap(AS_IO, &megazone_state::megazone_sound_io_map);

	I8039(config, m_daccpu, XTAL(14'318'181)/2);    /* 7.15909MHz */
	m_daccpu->set_addrmap(AS_PROGRAM, &megazone_state::megazone_i8039_map);
	m_daccpu->set_addrmap(AS_IO, &megazone_state::megazone_i8039_io_map);
	m_daccpu->p1_out_cb().set("dac", FUNC(dac_byte_interface::data_w));
	m_daccpu->p2_out_cb().set(FUNC(megazone_state::i8039_irqen_and_status_w));

	config.m_minimum_quantum = attotime::from_hz(900);

	ls259_device &mainlatch(LS259(config, "mainlatch")); // 13A
	mainlatch.q_out_cb<0>().set(FUNC(megazone_state::coin_counter_2_w));
	mainlatch.q_out_cb<1>().set(FUNC(megazone_state::coin_counter_1_w));
	mainlatch.q_out_cb<5>().set(FUNC(megazone_state::flipscreen_w));
	mainlatch.q_out_cb<7>().set(FUNC(megazone_state::irq_mask_w));

	WATCHDOG_TIMER(config, "watchdog");

	/* video hardware */
	screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
	screen.set_refresh_hz(60);
	screen.set_vblank_time(ATTOSECONDS_IN_USEC(0));
	screen.set_size(36*8, 32*8);
	screen.set_visarea(0*8, 36*8-1, 2*8, 30*8-1);
	screen.set_screen_update(FUNC(megazone_state::screen_update_megazone));
	screen.set_palette(m_palette);
	screen.screen_vblank().set(FUNC(megazone_state::vblank_irq));

	GFXDECODE(config, m_gfxdecode, m_palette, gfx_megazone);
	PALETTE(config, m_palette, FUNC(megazone_state::megazone_palette), 16*16+16*16, 32);

	/* sound hardware */
	SPEAKER(config, "speaker").front_center();

	GENERIC_LATCH_8(config, "soundlatch");

	ay8910_device &aysnd(AY8910(config, "aysnd", XTAL(14'318'181)/8));
	aysnd.port_a_read_callback().set(FUNC(megazone_state::megazone_port_a_r));
	aysnd.port_b_write_callback().set(FUNC(megazone_state::megazone_port_b_w));
	aysnd.add_route(0, "filter.0.0", 0.30);
	aysnd.add_route(1, "filter.0.1", 0.30);
	aysnd.add_route(2, "filter.0.2", 0.30);

	DAC_8BIT_R2R(config, "dac", 0).add_route(ALL_OUTPUTS, "speaker", 0.25); // unknown DAC
	voltage_regulator_device &vref(VOLTAGE_REGULATOR(config, "vref"));
	vref.add_route(0, "dac", 1.0, DAC_VREF_POS_INPUT);
	vref.add_route(0, "dac", -1.0, DAC_VREF_NEG_INPUT);

	FILTER_RC(config, m_filter[0]).add_route(ALL_OUTPUTS, "speaker", 1.0);
	FILTER_RC(config, m_filter[1]).add_route(ALL_OUTPUTS, "speaker", 1.0);
	FILTER_RC(config, m_filter[2]).add_route(ALL_OUTPUTS, "speaker", 1.0);
}
开发者ID:SailorSat,项目名称:cabmame,代码行数:60,代码来源:megazone.cpp


示例11: Z80

void _1942p_state::_1942p(machine_config &config)
{
	/* basic machine hardware */
	Z80(config, m_maincpu, MAIN_CPU_CLOCK_1942P);    /* 4 MHz - verified on PCB */
	m_maincpu->set_addrmap(AS_PROGRAM, &_1942p_state::_1942p_map);
	m_maincpu->set_vblank_int("screen", FUNC(_1942p_state::irq0_line_hold)); // note, powerups won't move down the screen with the original '1942' logic.

	Z80(config, m_audiocpu, SOUND_CPU_CLOCK_1942P);  /* 4 MHz - verified on PCB */
	m_audiocpu->set_addrmap(AS_PROGRAM, &_1942p_state::_1942p_sound_map);
	m_audiocpu->set_addrmap(AS_IO, &_1942p_state::_1942p_sound_io);
	m_audiocpu->set_periodic_int(FUNC(_1942p_state::irq0_line_hold), attotime::from_hz(4*60));


	/* video hardware */
	GFXDECODE(config, m_gfxdecode, m_palette, gfx_1942p);

	PALETTE(config, m_palette, FUNC(_1942p_state::_1942p_palette), 0x500, 0x400);

	screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
	screen.set_refresh_hz(60);
	screen.set_vblank_time(ATTOSECONDS_IN_USEC(0));
	screen.set_size(32*8, 32*8);
	screen.set_visarea(0*8, 32*8-1, 2*8, 30*8-1);
	screen.set_screen_update(FUNC(_1942p_state::screen_update));
	screen.set_palette(m_palette);

	/* sound hardware */
	SPEAKER(config, "mono").front_center();

	GENERIC_LATCH_8(config, m_soundlatch);
	m_soundlatch->data_pending_callback().set_inputline(m_audiocpu, INPUT_LINE_NMI);

	AY8910(config, "ay1", AUDIO_CLOCK_1942P).add_route(ALL_OUTPUTS, "mono", 0.25); // 1.25 MHz - verified on PCB
	AY8910(config, "ay2", AUDIO_CLOCK_1942P).add_route(ALL_OUTPUTS, "mono", 0.25); // 1.25 MHz - verified on PCB
}
开发者ID:fesh0r,项目名称:mame-full,代码行数:35,代码来源:1942.cpp


示例12: Z80

void goindol_state::goindol(machine_config &config)
{
	/* basic machine hardware */
	Z80(config, m_maincpu, XTAL(12'000'000)/2);  /* XTAL confirmed, divisor is not */
	m_maincpu->set_addrmap(AS_PROGRAM, &goindol_state::goindol_map);
	m_maincpu->set_vblank_int("screen", FUNC(goindol_state::irq0_line_hold));

	z80_device &audiocpu(Z80(config, "audiocpu", XTAL(12'000'000)/2)); /* XTAL confirmed, divisor is not */
	audiocpu.set_addrmap(AS_PROGRAM, &goindol_state::sound_map);
	audiocpu.set_periodic_int(FUNC(goindol_state::irq0_line_hold), attotime::from_hz(4*60));

	/* video hardware */
	screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
	screen.set_refresh_hz(60);
	screen.set_vblank_time(ATTOSECONDS_IN_USEC(0));
	screen.set_size(32*8, 32*8);
	screen.set_visarea(0*8, 32*8-1, 2*8, 30*8-1);
	screen.set_screen_update(FUNC(goindol_state::screen_update_goindol));
	screen.set_palette(m_palette);

	GFXDECODE(config, m_gfxdecode, m_palette, gfx_goindol);
	PALETTE(config, m_palette, palette_device::RGB_444_PROMS, "proms", 256);

	/* sound hardware */
	SPEAKER(config, "mono").front_center();

	GENERIC_LATCH_8(config, "soundlatch");

	YM2203(config, "ymsnd", XTAL(12'000'000)/8).add_route(ALL_OUTPUTS, "mono", 0.25);   /* Confirmed pitch from recording */
}
开发者ID:fesh0r,项目名称:mame-full,代码行数:30,代码来源:goindol.cpp


示例13: M68000

void drtomy_state::drtomy(machine_config &config)
{
	/* basic machine hardware */
	M68000(config, m_maincpu, 24000000/2);          /* ? MHz */
	m_maincpu->set_addrmap(AS_PROGRAM, &drtomy_state::drtomy_map);
	m_maincpu->set_vblank_int("screen", FUNC(drtomy_state::irq6_line_hold));


	/* video hardware */
	screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
	screen.set_refresh_hz(60);
	screen.set_vblank_time(ATTOSECONDS_IN_USEC(2500) /* not accurate */);
	screen.set_size(32*16, 32*16);
	screen.set_visarea(0, 320-1, 16, 256-1);
	screen.set_screen_update(FUNC(drtomy_state::screen_update_drtomy));
	screen.set_palette(m_palette);

	GFXDECODE(config, m_gfxdecode, m_palette, gfx_drtomy);
	PALETTE(config, m_palette).set_format(palette_device::xRGB_555, 1024);

	/* sound hardware */
	SPEAKER(config, "mono").front_center();

	OKIM6295(config, m_oki, 26000000/16, okim6295_device::PIN7_LOW).add_route(ALL_OUTPUTS, "mono", 0.8);
}
开发者ID:fesh0r,项目名称:mame-full,代码行数:25,代码来源:drtomy.cpp


示例14: Z80

void egghunt_state::egghunt(machine_config &config)
{
	/* basic machine hardware */
	Z80(config, m_maincpu, 12000000/2);      /* 6 MHz ?*/
	m_maincpu->set_addrmap(AS_PROGRAM, &egghunt_state::egghunt_map);
	m_maincpu->set_addrmap(AS_IO, &egghunt_state::io_map);
	m_maincpu->set_vblank_int("screen", FUNC(egghunt_state::irq0_line_hold)); // or 2 like mitchell.cpp?

	Z80(config, m_audiocpu, 12000000/2);         /* 6 MHz ?*/
	m_audiocpu->set_addrmap(AS_PROGRAM, &egghunt_state::sound_map);


	/* video hardware */
	screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
	screen.set_refresh_hz(60);
	screen.set_vblank_time(ATTOSECONDS_IN_USEC(0));
	screen.set_size(64*8, 32*8);
	screen.set_visarea(8*8, 56*8-1, 1*8, 31*8-1);
	screen.set_screen_update(FUNC(egghunt_state::screen_update_egghunt));
	screen.set_palette(m_palette);

	GFXDECODE(config, m_gfxdecode, m_palette, gfx_egghunt);

	PALETTE(config, m_palette).set_format(palette_device::xRGB_555, 0x400);

	/* sound hardware */
	SPEAKER(config, "mono").front_center();

	GENERIC_LATCH_8(config, m_soundlatch);

	OKIM6295(config, m_oki, 1056000, okim6295_device::PIN7_HIGH).add_route(ALL_OUTPUTS, "mono", 1.0); // clock frequency & pin 7 not verified
}
开发者ID:SailorSat,项目名称:cabmame,代码行数:32,代码来源:egghunt.cpp


示例15: I80C31

GFXDECODE_END

void ti630_state::ti630(machine_config &config)
{
	/* basic machine hardware */
	I80C31(config, m_maincpu, XTAL(10'000'000));
	m_maincpu->set_addrmap(AS_PROGRAM, &ti630_state::i80c31_prg);
	m_maincpu->set_addrmap(AS_IO, &ti630_state::i80c31_io);
	m_maincpu->port_in_cb<1>().set(FUNC(ti630_state::i80c31_p1_r));
	m_maincpu->port_out_cb<1>().set(FUNC(ti630_state::i80c31_p1_w));
	m_maincpu->port_out_cb<3>().set(FUNC(ti630_state::i80c31_p3_w));

	/* video hardware */
	screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_LCD));
	screen.set_refresh_hz(50);
	screen.set_vblank_time(ATTOSECONDS_IN_USEC(2500)); /* not accurate */
	screen.set_screen_update("hd44780", FUNC(hd44780_device::screen_update));
	screen.set_size(6*16, 9*2);
	screen.set_visarea(0, 6*16-1, 0, 9*2-1);
	screen.set_palette("palette");

	PALETTE(config, "palette", 2).set_init(FUNC(ti630_state::palette_init_ti630));

	GFXDECODE(config, "gfxdecode", "palette", gfx_ti630);

	HD44780(config, m_lcdc, 0);
	m_lcdc->set_lcd_size(2, 16);
}
开发者ID:Octocontrabass,项目名称:mame,代码行数:28,代码来源:ti630.cpp


示例16: Z80

void gundealr_state::gundealr(machine_config &config)
{
	/* basic machine hardware */
	Z80(config, m_maincpu, XTAL(12'000'000)/2);   /* 6 MHz verified for Yam! Yam!? */
	m_maincpu->set_addrmap(AS_PROGRAM, &gundealr_state::gundealr_main_map);
	m_maincpu->set_addrmap(AS_IO, &gundealr_state::main_portmap);
	TIMER(config, "scantimer").configure_scanline(FUNC(gundealr_state::scanline), "screen", 0, 1);

	/* video hardware */
	screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
	screen.set_refresh_hz(60);
	screen.set_vblank_time(ATTOSECONDS_IN_USEC(0));
	screen.set_size(32*8, 32*8);
	screen.set_visarea(0*8, 32*8-1, 2*8, 30*8-1);
	screen.set_screen_update(FUNC(gundealr_state::screen_update));
	screen.set_palette(m_palette);

	GFXDECODE(config, m_gfxdecode, m_palette, gfx_gundealr);
	PALETTE(config, m_palette).set_entries(512);

	/* sound hardware */
	SPEAKER(config, "mono").front_center();

	YM2203(config, "ymsnd", XTAL(12'000'000)/8).add_route(ALL_OUTPUTS, "mono", 0.25); /* 1.5Mhz verified for Yam! Yam!? */
}
开发者ID:fesh0r,项目名称:mame-full,代码行数:25,代码来源:gundealr.cpp


示例17: LR35902

void megaduck_state::megaduck(machine_config &config)
{
	/* basic machine hardware */
	LR35902(config, m_maincpu, XTAL(4'194'304)); /* 4.194304 MHz */
	m_maincpu->set_addrmap(AS_PROGRAM, &megaduck_state::megaduck_map);
	m_maincpu->timer_cb().set(FUNC(gb_state::gb_timer_callback));
	m_maincpu->set_halt_bug(true);

	/* video hardware */
	screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_LCD));
	screen.set_refresh_hz(DMG_FRAMES_PER_SECOND);
	screen.set_vblank_time(0);
	screen.set_screen_update("ppu", FUNC(dmg_ppu_device::screen_update));
	screen.set_palette(m_palette);
	screen.set_size(20*8, 18*8);
	screen.set_visarea(0*8, 20*8-1, 0*8, 18*8-1);

	GFXDECODE(config, "gfxdecode", m_palette, gfxdecode_device::empty);
	PALETTE(config, m_palette, FUNC(megaduck_state::megaduck_palette), 4);

	DMG_PPU(config, m_ppu, m_maincpu);

	/* sound hardware */
	SPEAKER(config, "lspeaker").front_left();
	SPEAKER(config, "rspeaker").front_right();
	DMG_APU(config, m_apu, XTAL(4'194'304));
	m_apu->add_route(0, "lspeaker", 0.50);
	m_apu->add_route(1, "rspeaker", 0.50);

	/* cartslot */
	MEGADUCK_CART_SLOT(config, m_cartslot, megaduck_cart, nullptr);
	SOFTWARE_LIST(config, "cart_list").set_original("megaduck");
}
开发者ID:PugsyMAME,项目名称:mame,代码行数:33,代码来源:gb.cpp


示例18: M68000

GFXDECODE_END


/*************************
*    Machine Drivers     *
*************************/

void goldngam_state::base(machine_config &config)
{
	/* basic machine hardware */
	M68000(config, m_maincpu, MASTER_CLOCK);
	m_maincpu->set_addrmap(AS_PROGRAM, &goldngam_state::swisspkr_map);

	PTM6840(config, m_ptm, 2'000'000);
	m_ptm->irq_callback().set_inputline("maincpu", M68K_IRQ_2);

	/* video hardware */
	screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
	screen.set_refresh_hz(60);
	screen.set_vblank_time(ATTOSECONDS_IN_USEC(0));
	screen.set_size(64*8, 64*8);
	screen.set_visarea(4*8, 43*8-1, 1*8, 37*8-1); // 312x288
	screen.set_screen_update(FUNC(goldngam_state::screen_update_goldngam));
	screen.set_palette("palette");

	GFXDECODE(config, "gfxdecode", "palette", gfx_goldngam);

	PALETTE(config, "palette", FUNC(goldngam_state::palette_init), 512);

	/* sound hardware */
	SPEAKER(config, "mono").front_center();
}
开发者ID:PugsyMAME,项目名称:mame,代码行数:32,代码来源:goldngam.cpp


示例19: MB8877

void mtx_sdxcpm_device::device_add_mconfig(machine_config &config)
{
	/* fdc */
	MB8877(config, m_fdc, 8_MHz_XTAL / 8);
	m_fdc->hld_wr_callback().set(FUNC(mtx_sdx_device::motor_w));

	FLOPPY_CONNECTOR(config, "fdc:0", sdx_floppies, "525qd", mtx_sdx_device::floppy_formats).enable_sound(true);
	FLOPPY_CONNECTOR(config, "fdc:1", sdx_floppies, "525qd", mtx_sdx_device::floppy_formats).enable_sound(true);

	/* 80 column video card - required to be installed in MTX internally */
	SCREEN(config, m_screen, SCREEN_TYPE_RASTER);
	m_screen->set_vblank_time(ATTOSECONDS_IN_USEC(2500)); /* not accurate */
	m_screen->set_refresh_hz(50);
	m_screen->set_size(960, 313);
	m_screen->set_visarea(00, 640 - 1, 0, 240 - 1);
	m_screen->set_screen_update("crtc", FUNC(mc6845_device::screen_update));

	GFXDECODE(config, "gfxdecode", "palette", gfx_mtx_sdx);
	PALETTE(config, "palette", palette_device::RGB_3BIT);

	MC6845(config, m_crtc, 15_MHz_XTAL / 8);
	m_crtc->set_screen("screen");
	m_crtc->set_show_border_area(false);
	m_crtc->set_char_width(8);
	m_crtc->set_update_row_callback(FUNC(mtx_sdxcpm_device::crtc_update_row), this);
}
开发者ID:fesh0r,项目名称:mame-full,代码行数:26,代码来源:sdx.cpp


示例20: M68000

void zerozone_state::zerozone(machine_config &config)
{
	/* basic machine hardware */
	M68000(config, m_maincpu, 10000000);   /* 10 MHz */
	m_maincpu->set_addrmap(AS_PROGRAM, &zerozone_state::main_map);

	Z80(config, m_audiocpu, 1000000);  /* 1 MHz ??? */
	m_audiocpu->set_addrmap(AS_PROGRAM, &zerozone_state::sound_map);

	config.m_minimum_quantum = attotime::from_hz(600);

	/* video hardware */
	screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
	screen.set_refresh_hz(60);
	screen.set_vblank_time(ATTOSECONDS_IN_USEC(0));
	screen.set_size(64*8, 32*8);
	screen.set_visarea(1*8, 47*8-1, 2*8, 30*8-1);
	screen.set_palette("palette");
	screen.set_screen_update(FUNC(zerozone_state::screen_update));
	screen.screen_vblank().set(FUNC(zerozone_state::vblank_w));

	GFXDECODE(config, m_gfxdecode, "palette", gfx_zerozone);

	PALETTE(config, "palette").set_format(palette_device::RRRRGGGGBBBBRGBx, 256);

	/* sound hardware */
	SPEAKER(config, "mono").front_center();

	GENERIC_LATCH_8(config, m_soundlatch);

	okim6295_device &oki(OKIM6295(config, "oki", 1056000, okim6295_device::PIN7_HIGH)); // clock frequency & pin 7 not verified
	oki.add_route(ALL_OUTPUTS, "mono", 1.0);
}
开发者ID:fesh0r,项目名称:mame-full,代码行数:33,代码来源:zerozone.cpp



注:本文中的GFXDECODE函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C++ GF_ASSERT函数代码示例发布时间:2022-05-30
下一篇:
C++ GFS2_I函数代码示例发布时间:2022-05-30
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap