Skip to content
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

OBS MIDI ignores midi "value" with Program Change #136

Open
tomvanduuren opened this issue May 28, 2021 · 5 comments
Open

OBS MIDI ignores midi "value" with Program Change #136

tomvanduuren opened this issue May 28, 2021 · 5 comments
Assignees
Labels
bug Something isn't working In Progress
Projects

Comments

@tomvanduuren
Copy link

Incompatibility with the Roland V-1HD midi controller.

The Roland V-1HD midi video controller can switch HDMI inputs.
A HDMI input switch also outputs a MIDI change. The MIDI change is a value change with the same note/control.
So only the value changes:
(Input 1 = Value 0, Input 2 = Value 1, Input 3 = Value 2, Input 4 = Value 3)

Platform

Operating system and version: Windows 10 Home - 20H2
OBS Studio version: OBS - 26.1.1.

Expected Behavior

Trigger on change of midi "value" with "program change" using the same note/control.
Example: MIDI channel 1:
Program Change - Note/control 127 - Value 1
Program Change - Note/control 127 - Value 2
Program Change - Note/control 127 - Value 3

Current Behavior

No trigger change on value change with the same note/control being used.
("use value in trigger**" is enabled)

Steps to Reproduce

  1. Add mapping - Change scene -> Midi settings: Program Change - Note/control 127 - Value 1
  2. Add mapping - Change scene -> Midi settings: Program Change - Note/control 127 - Value 2

Additional information

none

@tomvanduuren tomvanduuren added the bug Something isn't working label May 28, 2021
@cpyarger cpyarger changed the title OBS MIDI ignores midi "value" OBS MIDI ignores midi "value" with Program Change Jul 24, 2021
@cpyarger
Copy link
Owner

This may be an oversight, as I don't have any device that uses program change by default I will be looking into it.

@cpyarger cpyarger self-assigned this Sep 18, 2021
@cpyarger cpyarger added this to Needs triage in Bug Tracker via automation Sep 18, 2021
@cpyarger cpyarger moved this from Needs triage to Low Priority in Bug Tracker Sep 18, 2021
@robrob2142
Copy link

You should just change the "value" with the "note/cc", as programm changes do not have a value, but are only used for switching stuff. Value should therefore be grayed out.

@robrob2142
Copy link

My suspision was true, you implemented Programm Changes wrongly. They are 2 Byte: first byte defining Programm Change Type<< 4 | Channel, and second being the PC number.

Inside MidiMessage I changed behaviour with programm change messages: MidiMessage::get_midi_value() to return 0xFF to avoid crashing and MidiMessage::get_midi_note_or_control() to read from the second byte[1]. It now works flawlessly.

You should update that to be able to use programm changes effectively. I might just commit that, as it's such a minute change.

@cpyarger
Copy link
Owner

submit a pull request then 😸

@Synthetic-Future
Copy link

Ran into a similar issue with my MPK, still looking for a solution.

When I send a program change OBS MIDI will learn it as a "program change " with note/control "127" and "value" -whatever program change I send-. So it records the velocity as the program change number and the program change number as the value. This would be okay except that OBS MIDI doesn't listen for values.

Is there some way to get OBS MIDI to list the actual program change value as note/control and the velocity as value (so switch those 2 values around). I am no coder so I don't really know how to solve this issue myself and OBS MIDI doesn't allow for manual entry sadly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working In Progress
Projects
No open projects
Bug Tracker
Low Priority
Development

No branches or pull requests

4 participants