MCPcopy Create free account
hub / github.com/doldecomp/mkdd / channelUpdateCallback

Method channelUpdateCallback

libs/JSystem/JAudio/System/JASTrack.cpp:684–707  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

682}
683
684void JASTrack::channelUpdateCallback(u32 p1, JASChannel *ch, JASDsp::TChannel *dspCh, void *arg) {
685 TChannelMgr *channel_mgr = static_cast<TChannelMgr*>(arg);
686 JASTrack *track = channel_mgr->mTrack;
687 switch (p1) {
688 case 0:
689 case 1:
690 ch->mParams = channel_mgr->mParams;
691 track->updateChannel(ch, dspCh);
692 break;
693 case 3:
694 ch->release(0);
695 ch->free();
696 channel_mgr->mChannels[0] = NULL;
697 break;
698 case 2:
699 for (int i = 0; i < 8; i++) {
700 if (ch == channel_mgr->mChannels[i]) {
701 channel_mgr->mChannels[i] = NULL;
702 break;
703 }
704 }
705 break;
706 }
707}
708
709JASTrack *JASTrack::getRootTrack() {
710 JASTrack *track = this;

Callers

nothing calls this directly

Calls 3

updateChannelMethod · 0.45
releaseMethod · 0.45
freeMethod · 0.45

Tested by

no test coverage detected