本文整理汇总了C++中sid_engine_t类的典型用法代码示例。如果您正苦于以下问题:C++ sid_engine_t类的具体用法?C++ sid_engine_t怎么用?C++ sid_engine_t使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了sid_engine_t类的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。
示例1: sid_sound_machine_close
void sid_sound_machine_close(sound_t *psid)
{
sid_engine.close(psid);
/* free the temp. buffers */
if (buf1) {
lib_free(buf1);
buf1 = NULL;
}
if (buf2) {
lib_free(buf2);
buf2 = NULL;
}
}
开发者ID:markjreed,项目名称:vice-emu,代码行数:13,代码来源:sid.c
示例2:
sound_t *sid_sound_machine_open(int chipno)
{
sidengine = 0;
if (resources_get_int("SidEngine", &sidengine) < 0) {
return NULL;
}
sid_engine = fastsid_hooks;
#ifdef HAVE_RESID
if (sidengine == SID_ENGINE_RESID) {
sid_engine = resid_hooks;
}
#endif
return sid_engine.open(siddata[chipno]);
}
开发者ID:markjreed,项目名称:vice-emu,代码行数:18,代码来源:sid.c
示例3: sid_state_write
void sid_state_write(unsigned int channel, sid_snapshot_state_t *sid_state)
{
sid_engine.state_write(sound_get_psid(channel), sid_state);
}
开发者ID:markjreed,项目名称:vice-emu,代码行数:4,代码来源:sid.c
示例4: sid_sound_machine_prevent_clk_overflow
void sid_sound_machine_prevent_clk_overflow(sound_t *psid, CLOCK sub)
{
sid_engine.prevent_clk_overflow(psid, sub);
}
开发者ID:markjreed,项目名称:vice-emu,代码行数:4,代码来源:sid.c
示例5: sid_sound_machine_calculate_samples
int sid_sound_machine_calculate_samples(sound_t **psid, SWORD *pbuf, int nr, int soc, int scc, int *delta_t)
{
int i;
SWORD *tmp_buf1;
SWORD *tmp_buf2;
int tmp_nr = 0;
int tmp_delta_t = *delta_t;
if (soc == 1 && scc == 1) {
return sid_engine.calculate_samples(psid[0], pbuf, nr, 1, delta_t);
}
if (soc == 1 && scc == 2) {
tmp_buf1 = getbuf1(2 * nr);
tmp_nr = sid_engine.calculate_samples(psid[0], tmp_buf1, nr, 1, &tmp_delta_t);
tmp_nr = sid_engine.calculate_samples(psid[1], pbuf, nr, 1, delta_t);
for (i = 0; i < tmp_nr; i++) {
pbuf[i] = sound_audio_mix(pbuf[i], tmp_buf1[i]);
}
return tmp_nr;
}
if (soc == 1 && scc == 3) {
tmp_buf1 = getbuf1(2 * nr);
tmp_buf2 = getbuf2(2 * nr);
tmp_nr = sid_engine.calculate_samples(psid[0], tmp_buf1, nr, 1, &tmp_delta_t);
tmp_delta_t = *delta_t;
tmp_nr = sid_engine.calculate_samples(psid[2], tmp_buf2, nr, 1, &tmp_delta_t);
tmp_nr = sid_engine.calculate_samples(psid[1], pbuf, nr, 1, delta_t);
for (i = 0; i < tmp_nr; i++) {
pbuf[i] = sound_audio_mix(pbuf[i], tmp_buf1[i]);
pbuf[i] = sound_audio_mix(pbuf[i], tmp_buf2[i]);
}
return tmp_nr;
}
if (soc == 2 && scc == 1) {
tmp_nr = sid_engine.calculate_samples(psid[0], pbuf, nr, 2, delta_t);
for (i = 0; i < tmp_nr; i++) {
pbuf[(i * 2) + 1] = pbuf[i * 2];
}
return tmp_nr;
}
if (soc == 2 && scc == 2) {
tmp_nr = sid_engine.calculate_samples(psid[0], pbuf, nr, 2, &tmp_delta_t);
tmp_nr = sid_engine.calculate_samples(psid[1], pbuf + 1, nr, 2, delta_t);
return tmp_nr;
}
if (soc == 2 && scc == 3) {
tmp_buf1 = getbuf1(2 * nr);
tmp_nr = sid_engine.calculate_samples(psid[2], tmp_buf1, nr, 1, &tmp_delta_t);
tmp_delta_t = *delta_t;
tmp_nr = sid_engine.calculate_samples(psid[0], pbuf, nr, 2, &tmp_delta_t);
tmp_nr = sid_engine.calculate_samples(psid[1], pbuf + 1, nr, 2, delta_t);
for (i = 0; i < tmp_nr; i++) {
pbuf[i * 2] = sound_audio_mix(pbuf[i * 2], tmp_buf1[i]);
pbuf[(i * 2) + 1] = sound_audio_mix(pbuf[(i * 2) + 1], tmp_buf1[i]);
}
}
return tmp_nr;
}
开发者ID:markjreed,项目名称:vice-emu,代码行数:58,代码来源:sid.c
示例6: sid_sound_machine_reset
void sid_sound_machine_reset(sound_t *psid, CLOCK cpu_clk)
{
sid_engine.reset(psid, cpu_clk);
}
开发者ID:markjreed,项目名称:vice-emu,代码行数:4,代码来源:sid.c
示例7: sid_sound_machine_store
void sid_sound_machine_store(sound_t *psid, WORD addr, BYTE byte)
{
sid_engine.store(psid, addr, byte);
}
开发者ID:markjreed,项目名称:vice-emu,代码行数:4,代码来源:sid.c
示例8: sid_sound_machine_read
BYTE sid_sound_machine_read(sound_t *psid, WORD addr)
{
return sid_engine.read(psid, addr);
}
开发者ID:markjreed,项目名称:vice-emu,代码行数:4,代码来源:sid.c
示例9: sid_sound_machine_init
int sid_sound_machine_init(sound_t *psid, int speed, int cycles_per_sec)
{
return sid_engine.init(psid, speed, cycles_per_sec, 1000);
}
开发者ID:markjreed,项目名称:vice-emu,代码行数:4,代码来源:sid.c
示例10: sid_sound_machine_init_vbr
int sid_sound_machine_init_vbr(sound_t *psid, int speed, int cycles_per_sec, int factor)
{
return sid_engine.init(psid, speed * factor / 1000, cycles_per_sec, factor);
}
开发者ID:markjreed,项目名称:vice-emu,代码行数:4,代码来源:sid.c
示例11: sid_sound_machine_close
void sid_sound_machine_close(sound_t *psid)
{
sid_engine.close(psid);
}
开发者ID:Chegwin,项目名称:GBA4iOS-2.0-Beta-4,代码行数:4,代码来源:sid.c
注:本文中的sid_engine_t类示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论