void VRC7SoundInstall(void) { LogTableInitialize(); sndp.kmif = OPLSoundAlloc(OPL_TYPE_VRC7); if (sndp.kmif) { NESAudioHandlerInstall(s_opll_audio_handler); NESVolumeHandlerInstall(s_opll_volume_handler); NESTerminateHandlerInstall(s_opll_terminate_handler); NESResetHandlerInstall(s_vrc7_reset_handler); NESWriteHandlerInstall(s_vrc7_write_handler); } }
void FME7SoundInstall(NEZ_PLAY* pNezPlay) { PSGSOUND *psgs; psgs = XMALLOC(sizeof(PSGSOUND)); if (!psgs) return; XMEMSET(psgs, 0, sizeof(PSGSOUND)); ((NSFNSF*)pNezPlay->nsf)->psgs = psgs; psgs->psgp = PSGSoundAlloc(PSG_TYPE_YM2149); //エンベロープ31段階あったんでYM2149系でしょう。 if (!psgs->psgp) return; LogTableInitialize(); NESTerminateHandlerInstall(&pNezPlay->nth, s_psg_terminate_handler); NESVolumeHandlerInstall(pNezPlay, s_psg_volume_handler); NESAudioHandlerInstall(pNezPlay, s_psg_audio_handler); NESWriteHandlerInstall(pNezPlay, s_fme7_write_handler); NESResetHandlerInstall(pNezPlay->nrh, s_fme7_reset_handler); }