-
-
Notifications
You must be signed in to change notification settings - Fork 1k
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 loading of user-defined scales/chords #5204
base: master
Are you sure you want to change the base?
Conversation
Downloads for this pull requestGenerated by the LMMS pull requests bot. |
I think the real problem is the misleading name. IMO it should be |
Completely missed this PR. Sorry! lmms/include/InstrumentFunctions.h Lines 83 to 86 in c755b56
Old way... Yeah, this was maybe a bit too optimistic... I thought I could just restart the failing Travis build job and an AppImage would magically appear somewhere. That assumption was incorrect. |
First impressions.
|
I might change to JSON with the recent idea for switching over. It would be a lot easier to edit. For instance {
"scales": [
{ "name": "Major", "keys": [0, 2, 4, 5, 7, 9, 11] }
],
"chords": [
{ "name": "Major", "keys": [0, 4, 7] }
]
}
I tossed the idea around, but adding to the end of a long list would be annoying. My ideal solution is the idea of attaching a scales/chords file to project files, so they're auto loaded per project. There's a few ways we can handle this really. This PR is a stepping stone to get it in first! 😁
Yeah, like above there's a few ideas we can move to from this. I'd like some more feedback from people who want to use it though. |
@Veratil are you still working on this one? If not, I am happy to take it on... I agree with the move to JSON. I think its a much more concise way of displaying this information. I would argue 'keys' should be renamed to 'notes' (i.e. notes of a scale) as a scale's 'key' is something different (the tonic root of a scale). In this case, you are defining a generic set of numerical values that make up the scale. |
I put it aside for a while to work on other things, this was from when I was early learning the codebase. If you'd like to fork my branch and make a PR against it I'd be happy to merge them in here, too. |
Anyone want to pick up the mantle on this one ? |
Enhancement for #241.
This will look for a
notes.xml
file in the default working directory. If found, it will load those chords and scales instead of the default ones. I decided to load only one or the other because it gives the option (currently requiring manual moving/deleting/updating/whatever of the file) of changing out XML files in case a user wanted to only see certain chords/scales for a project.Possible future enhancement: Link projects to custom scale/chord files.
The XML file is laid out as so:
As the current chords/scales are set with the equivalent to pitch class integer notation the
key
s follow the same.There is a little leeway with getting the
<semiTone>
nodes as it doesn't actually look for the node name, so technically as long as thekey
attribute is there it could be called anything.Additionally, this PR "fixes" the
Chord stacking & arpeggio
tab to only list actual chords in the Stacking combobox, instead of including scales as well. I doubt anyone wants to hit all the notes of the scale at the same time. I left the Arpeggio combobox to include them though.Another slight change is to the
octave
chord to actually play the next octave up (I don't see the point of having it if it's just the note you select). If this is incorrect then I can revert that line.