milkytracker / MilkyTracker

An FT2 compatible music tracker
http://milkytracker.github.io/
Other
1.68k stars 159 forks source link

Fix muting when exporting for over 32 channels (issue #242) #252

Closed caseyjoy closed 2 years ago

caseyjoy commented 2 years ago

Added the function PlayerBase::setNumChannelMixerChannelsToModuleCount to call ChannelMixer::setNumChannels from PlayerGeneric::exportToWAV.

This makes sure the channels get resized before the muting code so it mutes channels as expected while exporting when there are over 32 channels, as otherwise the resize happens after and discards the channel muting.

Added a comment with the full breakdown of my investigation into this here: https://github.com/milkytracker/MilkyTracker/issues/242#issuecomment-918642675