当前位置: 首页>>代码示例>>C++>>正文


C++ TOBYTE函数代码示例

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


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

示例1: artmagic_from_shiftreg

void artmagic_from_shiftreg(address_space *space, offs_t address, UINT16 *data)
{
	artmagic_state *state = space->machine().driver_data<artmagic_state>();
	UINT16 *vram = address_to_vram(state, &address);
	if (vram)
		memcpy(&vram[address], data, TOBYTE(0x2000));
}
开发者ID:j4y4r,项目名称:j4ymame,代码行数:7,代码来源:artmagic.c

示例2: TOBYTE

void tms340x0_device::write_pixel_r_t_32(offs_t offset, UINT32 data)
{
	/* TODO: plane masking */
	UINT32 a = TOBYTE(offset & 0xffffffe0);
	data = (this->*m_raster_op)(data, TMS34010_RDMEM_DWORD(a));

	if (data)
		TMS34010_WRMEM_DWORD(a, data);
}
开发者ID:GiuseppeGorgoglione,项目名称:mame,代码行数:9,代码来源:tms34010.cpp

示例3: wfield_16

void wfield_16(offs_t offset,UINT32 data)
{
	if (offset & 0x0f)
	{
		WFIELDMAC(0xffff,1);
	}
	else
	{
		TMS34010_WRMEM_WORD(TOBYTE(offset),data);
	}
}
开发者ID:BirchJD,项目名称:xmame-0.103-RPi,代码行数:11,代码来源:34010fld.c

示例4: wfield_16

void wfield_16(UINT32 bitaddr, UINT32 data)
{
	if (bitaddr&0x0f)
	{
		WFIELDMAC(0xffff,1);
	}
	else
	{
		TMS34010_WRMEM_WORD(TOBYTE(bitaddr),data);
	}
}
开发者ID:cyberkni,项目名称:276in1JAMMA,代码行数:11,代码来源:34010fld.cpp

示例5: rfield_z_16

INT32 rfield_z_16(UINT32 bitaddr)
{
	if (bitaddr&0x0f)
	{
		RFIELDMAC_Z(0xffff,1);
	}
	else
	{
		return TMS34010_RDMEM_WORD(TOBYTE(bitaddr));
	}
}
开发者ID:cyberkni,项目名称:276in1JAMMA,代码行数:11,代码来源:34010fld.cpp

示例6: rfield_s_08

UINT32 rfield_s_08(offs_t offset)
{
	UINT32 ret;
	if (offset & 0x07)
	{
		RFIELDMAC(0xff,9);
	}

	else
		ret = TMS34010_RDMEM(TOBYTE(offset));
	return (INT32)(INT8)ret;
}
开发者ID:BirchJD,项目名称:xmame-0.103-RPi,代码行数:12,代码来源:34010fld.c

示例7: rfield_z_16

UINT32 rfield_z_16(offs_t offset)
{
	UINT32 ret;
	if (offset & 0x0f)
	{
		RFIELDMAC(0xffff,1);
	}

	else
		ret = TMS34010_RDMEM_WORD(TOBYTE(offset));
	return ret;
}
开发者ID:BirchJD,项目名称:xmame-0.103-RPi,代码行数:12,代码来源:34010fld.c

示例8: rfield_s_16

INT32 rfield_s_16(UINT32 bitaddr)
{
	if (bitaddr&0x0f)
	{
		RFIELDMAC_S(0xffff,1);
		return (INT32)(INT16)ret;
	}
	else
	{
		return (INT32)(INT16)TMS34010_RDMEM_WORD(TOBYTE(bitaddr));
	}
}
开发者ID:cyberkni,项目名称:276in1JAMMA,代码行数:12,代码来源:34010fld.cpp

示例9: rfield_s_08

INT32 rfield_s_08(UINT32 bitaddr)
{
	if (bitaddr&0x07)											
	{															
		RFIELDMAC_S(0xff,9);
		return (INT32)(INT8)ret;
	}															
	else														
	{															
		return (INT32)(INT8)TMS34010_RDMEM(TOBYTE(bitaddr));					
	}
}
开发者ID:cyberkni,项目名称:276in1JAMMA,代码行数:12,代码来源:34010fld.cpp

示例10: rfield_s_16

UINT32 rfield_s_16(offs_t offset)
{
	UINT32 ret;
	if (offset & 0x0f)
	{
		RFIELDMAC(0xffff,1);
	}

	else
	{
		ret = TMS34010_RDMEM_WORD(TOBYTE(offset));
	}

	return (INT32)(INT16)ret;
}
开发者ID:BirchJD,项目名称:xmame-0.103-RPi,代码行数:15,代码来源:34010fld.c

示例11: TOBYTE

inline INT32 tms340x0_device::PARAM_LONG()
{
	UINT32 pc = TOBYTE(m_pc);
	m_pc += 4 << 3;
	return (UINT16)m_direct->read_raw_word(pc) | (m_direct->read_raw_word(pc + 2) << 16);
}
开发者ID:Ander-son,项目名称:libretro-mame,代码行数:6,代码来源:tms34010.c

示例12: TMS34010_WRMEM_DWORD

void tms340x0_device::write_pixel_t_32(offs_t offset, UINT32 data)
{
	/* TODO: plane masking */
	if (data)
		TMS34010_WRMEM_DWORD(TOBYTE(offset & 0xffffffe0), data);
}
开发者ID:GiuseppeGorgoglione,项目名称:mame,代码行数:6,代码来源:tms34010.cpp

示例13: TMS34010_WRMEM_WORD

void tms340x0_device::write_pixel_16(offs_t offset, UINT32 data)
{
	/* TODO: plane masking */
	TMS34010_WRMEM_WORD(TOBYTE(offset & 0xfffffff0), data);
}
开发者ID:GiuseppeGorgoglione,项目名称:mame,代码行数:5,代码来源:tms34010.cpp

示例14: TMS34010_RDMEM_DWORD

UINT32 tms340x0_device::read_pixel_32(offs_t offset)
{
	/* TODO: Plane masking */
	return TMS34010_RDMEM_DWORD(TOBYTE(offset & 0xffffffe0));
}
开发者ID:GiuseppeGorgoglione,项目名称:mame,代码行数:5,代码来源:tms34010.cpp

示例15: TOBYTE

	}
}


static struct tms34010_config master_config =
{
	0,							/* halt on reset */
	NULL,						/* generate interrupt */
	exterm_to_shiftreg_master,	/* write to shiftreg function */
	exterm_from_shiftreg_master	/* read from shiftreg function */
};


static struct MemoryReadAddress master_readmem[] =
{
	{ TOBYTE(0x00000000), TOBYTE(0x000fffff), exterm_master_videoram_r },
	{ TOBYTE(0x00c800e0), TOBYTE(0x00c800ef), exterm_master_speedup_r },
	{ TOBYTE(0x00c00000), TOBYTE(0x00ffffff), MRA_BANK1 },
	{ TOBYTE(0x01000000), TOBYTE(0x0100000f), MRA_NOP }, /* Off by one bug in RAM test, prevent log entry */
	{ TOBYTE(0x01200000), TOBYTE(0x012fffff), exterm_host_data_r },
	{ TOBYTE(0x01400000), TOBYTE(0x0140000f), exterm_input_port_0_1_r },
	{ TOBYTE(0x01440000), TOBYTE(0x0144000f), exterm_input_port_2_3_r },
	{ TOBYTE(0x01480000), TOBYTE(0x0148000f), input_port_4_r },
	{ TOBYTE(0x01800000), TOBYTE(0x01807fff), paletteram_word_r },
	{ TOBYTE(0x01808000), TOBYTE(0x0180800f), MRA_NOP }, /* Off by one bug in RAM test, prevent log entry */
	{ TOBYTE(0x02800000), TOBYTE(0x02807fff), MRA_BANK2 },
	{ TOBYTE(0x03000000), TOBYTE(0x03ffffff), exterm_coderom_r },
	{ TOBYTE(0x3f000000), TOBYTE(0x3fffffff), exterm_coderom_r },
	{ TOBYTE(0xc0000000), TOBYTE(0xc00001ff), tms34010_io_register_r },
	{ TOBYTE(0xff000000), TOBYTE(0xffffffff), MRA_BANK3 },
	{ -1 }  /* end of table */
开发者ID:ArnaudFeld,项目名称:MameAppleTV,代码行数:31,代码来源:exterm.cpp


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