| 2027 | } |
| 2028 | |
| 2029 | void CFamiTrackerView::UpdateNoteQueues() { // // // |
| 2030 | const CConstSongView *pSongView = GetSongView(); |
| 2031 | const int Channels = pSongView->GetChannelOrder().GetChannelCount(); |
| 2032 | |
| 2033 | m_pNoteQueue->ClearMaps(); |
| 2034 | |
| 2035 | if (m_bEditEnable || FTEnv.GetSettings()->Midi.bMidiArpeggio) |
| 2036 | pSongView->GetChannelOrder().ForeachChannel([&] (stChannelID i) { |
| 2037 | m_pNoteQueue->AddMap({i}); |
| 2038 | }); |
| 2039 | else { |
| 2040 | m_pNoteQueue->AddMap({apu_subindex_t::triangle}); |
| 2041 | m_pNoteQueue->AddMap({apu_subindex_t::noise}); |
| 2042 | m_pNoteQueue->AddMap({apu_subindex_t::dpcm}); |
| 2043 | |
| 2044 | CSoundChipSet chips = GetModuleData()->GetSoundChipSet(); |
| 2045 | |
| 2046 | if (chips.ContainsChip(sound_chip_t::VRC6)) { |
| 2047 | m_pNoteQueue->AddMap({vrc6_subindex_t::pulse1, vrc6_subindex_t::pulse2}); |
| 2048 | m_pNoteQueue->AddMap({vrc6_subindex_t::sawtooth}); |
| 2049 | } |
| 2050 | if (chips.ContainsChip(sound_chip_t::VRC7)) |
| 2051 | m_pNoteQueue->AddMap({ |
| 2052 | vrc7_subindex_t::ch1, vrc7_subindex_t::ch2, vrc7_subindex_t::ch3, |
| 2053 | vrc7_subindex_t::ch4, vrc7_subindex_t::ch5, vrc7_subindex_t::ch6, |
| 2054 | }); |
| 2055 | if (chips.ContainsChip(sound_chip_t::FDS)) |
| 2056 | m_pNoteQueue->AddMap({fds_subindex_t::wave}); |
| 2057 | if (chips.ContainsChip(sound_chip_t::MMC5)) |
| 2058 | m_pNoteQueue->AddMap({apu_subindex_t::pulse1, apu_subindex_t::pulse2, mmc5_subindex_t::pulse1, mmc5_subindex_t::pulse2}); |
| 2059 | else |
| 2060 | m_pNoteQueue->AddMap({apu_subindex_t::pulse1, apu_subindex_t::pulse2}); |
| 2061 | if (chips.ContainsChip(sound_chip_t::N163)) { |
| 2062 | std::vector<stChannelID> n; |
| 2063 | std::size_t NamcoChannels = GetModuleData()->GetNamcoChannels(); |
| 2064 | for (std::size_t i = 0; i < NamcoChannels; ++i) |
| 2065 | n.emplace_back(sound_chip_t::N163, static_cast<std::uint8_t>(i)); |
| 2066 | m_pNoteQueue->AddMap(n); |
| 2067 | } |
| 2068 | if (chips.ContainsChip(sound_chip_t::S5B)) |
| 2069 | m_pNoteQueue->AddMap({s5b_subindex_t::square1, s5b_subindex_t::square2, s5b_subindex_t::square3}); |
| 2070 | } |
| 2071 | |
| 2072 | // for (int i = 0; i < Channels; ++i) |
| 2073 | // if (IsChannelMuted(i)) |
| 2074 | // m_pNoteQueue->MuteChannel(pDoc->GetChannelType(i)); |
| 2075 | } |
| 2076 | |
| 2077 | ////////////////////////////////////////////////////////////////////////////////////////////////////////// |
| 2078 | /// Tracker input routines |
no test coverage detected