Skip to content

Added cmake for building the project and CPM for auto package management#5

Open
wtrsltnk wants to merge 2 commits into
iffyloop:mainfrom
wtrsltnk:main
Open

Added cmake for building the project and CPM for auto package management#5
wtrsltnk wants to merge 2 commits into
iffyloop:mainfrom
wtrsltnk:main

Conversation

@wtrsltnk
Copy link
Copy Markdown

@wtrsltnk wtrsltnk commented May 3, 2023

Nice project! I got it working with cmake and CPM on windows and was wondering if you could use this. The CPM is auto downloading all the dependancies VST and concurrentqueue. I had to remove the SDL2/ in the SDL includes. Thats an result of using CPM and I am not sure how to fix that yet..

UserData *userData = static_cast<UserData *>(pUserData);

if (command == 144) {
if ((command & 0xf0) == 144) {
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is the purpose of adding 0xf0 here, and the 0x0f two lines below? I'm not very familiar with MIDI...

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry for the late reply!

The command byte has two functions. The first is the command, the second is the midi channel it is supposed to send the comand to. The '& 0xf0' will remove channel part from the byte and make sure only the command part is checked. I had to add this to be able to support sending commands over multiple midi channels. When you send a midi command over channel 5 for example, the command value will not be 144.

@iffyloop
Copy link
Copy Markdown
Owner

Thanks so much for contributing CMake support! I'm sorry it's taken me so long to reply to this PR. I'll get this merged in soon; if you can reply to the question I put above that'd be helpful. (This is my first time merging in a non-trivial PR, so not sure what the most convenient way is to review code with other contributors).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants