-
Notifications
You must be signed in to change notification settings - Fork 46
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add feedback for MIDI event mute/unmute #1188
base: master
Are you sure you want to change the base?
Conversation
Build succeeded! Build osara pr1188-1648,572859e7 completed (commit 572859e75e by @MatejGolian) |
Thanks for your work. Just FYI, I'm about to go away on holiday for a couple of weeks, so I likely won't be able to look at this until the end of January at the very earliest. |
I understand. Have a nice holiday then. |
BTW I have a vague understanding of why it isn't working, but of course not on a level that would help me come up with a solution. |
@MatejGolian the problem seems to be in Remember that toggle commands with multiple selection in Reaper can get kind of crazy; you could end up with w notes muted, x notes unmuted, y CCs muted and z ccs unmuted. See postToggleItemMute. |
@RDMurray, thanks. |
The third parameter is MidiControlChange::ReqParams, which is a struct of 7 bools used to indicate which params of the event should be requested from Reaper. In this case we probably want everything, something like below (untested): ccs.push_back(MidiControlChange::get(take, ccIndex, {
true, // position
true, // message1
true, // channel
true, // message2
true, // message3,
true, // selected
true // muted
})); Btw what does it mean for a CC to be muted? I'm surprised it's even a thing. |
Thanks, I'll have a go at it. |
Build succeeded! Build osara pr1188-1649,3aec252b completed (commit 3aec252b0e by @MatejGolian) |
I've got it. Turns out that the fix was much simpler than it looked like. But thanks @RDMurray, I couldn't have done it without you. |
This is a toggle. It should report when events are unmuted as well. |
Build succeeded! Build osara pr1188-1651,da179299 completed (commit da17929978 by @MatejGolian) |
I've added reporting whenever single events become unmuted. I haven't altered the behavior in case toggling mute for multiple events though. The message being reported in the latter case is analogous to the one Osara reports when navigating to chords containing muted notes which seems reasonable IMO and I think that we don't have to be any more verbose than that. |
I wanted to add feedback when muting/unmuting MIDI events. The reported message should depend on the selection (notes vs CCs vs both). The basic logic seems to work, but I can't figure out how to count muted CCs, because a method completely analogous to how it's done with notes is clearly not possible - at least that's my impression.
@jcsteh could you take a look and perhaps even fix the problem? I think it would take far less time for you to fix it than explain to me what the problem is, but of course I'm not opposed to fixing it myself - I just don't know how.
Many thanks...