macos ump endpoint backend#204
Conversation
Will need to figure out a better solution for this
|
heya! thanks a lot! I'm actually in the midst of a fairly large refactor for this but it's been taking dust in the last months due to other work.
Does that design make sense to you ? |
|
@jcelerier
What exactly is the limitation of the current "inject your own context" approach? Looking at the PipeWire backend, it seems the current context field in |
| case CMIDI2_MESSAGE_TYPE_SYSEX7: | ||
| return 8; | ||
| case CMIDI2_MESSAGE_TYPE_SYSEX8_MDS: | ||
| case CMIDI2_MESSAGE_TYPE_FLEX_DATA: |
There was a problem hiding this comment.
If possible, submit the cmidi2 changes directly upstream to https://github.com/atsushieno/cmidi2 as I then merge them regularly.
Considering that ni-midi2 also supports all the parsing required, it would also be fairly reasonable to have the lib use ni-midi2 when it's being enabled to, what do you think?
There was a problem hiding this comment.
Sure I can create a separate PR.
I work at NI with the author Franz and can confirm that using the ni-midi2 library is a no-brainer, as Franz is one of the few people on the planet that knows midi1, midi2, and the USB midi specs inside out from both a standards and practical implementation perspective.
It's tested extensively, well maintained, has zero dependencies, and is actually used in production. IMO it should be the default choice for every c++ midi project.
There was a problem hiding this comment.
Tbh I don't see a need for cmidi in this library... You'll get a better quality result with significantly less work by using Franz's library
There was a problem hiding this comment.
Sorry looking back at this thread I misread your comment, I thought you just wanted me to cherry pick the commit into a separate pr on this repo.
But I'd be interested if you have any reason to use cmidi2 here. Franz's library is years ahead of the C one afaict as he is on the committee, and it's written in modern C++ as a header only MIT license library.
It's also trivial to expose a cmidi2 compatible API and internally convert to one of his c++ types using the primitive constructors:
What do users gain from supporting cmidi2, and is the extra effort worth it?
I'd like to use this repo for testing UMP IO in one of my projects, so would be great to get this WIP feature completed.