-
-
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
Lv2 core implementation #4899
Lv2 core implementation #4899
Conversation
Add labeled controls for different types with a common base class
Implement a container for multiple equal groups of linked models and suiting views. Such groups are suited for representing mono effects where each Model occurs twice. A group provides Models for one mono processor and is visually represented with a group box. This concept is common for LADSPA and Lv2, and useful for any mono effect.
For an explenation about the new Lv2 classes, see Lv2Manager.h
Sorry for the CI failure. It seems like it only requires replacing two |
CI is working again (the left CI errors don't look code related) and I removed a lot of dead code so the code should get more readable. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
First pass cosmetic review, checked for rule Add a space after if, else if, else, for, do, while and switch.
There are some violations of the rule:
If you interpret it strictly. Another rule in the conventions gives this example: Whereas your code occasionally uses this style: However, I can't bring myself to "correct" the latter in review as it looks far more readable to me and I question the original rule. When using explicitly blocked brackets, there should obviously not be spaces before/after. However, for one liners I feel the opposite is true, there should obviously be spaces between the brackets and the code itself. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Finished my style review. A fair amount of places that don't use explicit blocking, so I added comments for that. Don't necessarily agree with that change either, feels like vertical space will balloon in some places if it's "fixed".
Apply fixes according to coding conventions, thanks to @Spekular Co-Authored-By: JohannesLorenz <[email protected]>
Thanks. This means all mandatory reviews are passed now. After there have been so many changes and merges, I'd like to still ask someone to test it through again before we're going to master. Especially loading/saving. I invited you, @douglasdgi , for now. Some testing hints are in the top post. |
One issue is that there's currently hundreds of lines of debug output coming when you start LMMS, like:
I think I'll disable this unless the user sets an environment variable, like -> EDIT: Solved in bca38f0. |
Thanks to @douglasdgi for reporting: If you have installed lv2, but not lilv, you get
The code line is |
It would be good if the search bar in the effects was unselected upon clicking the top bar of the window (or really just anywhere in the window other than the search bar), so that the user can use their keyboard to play whatever instrument they have open without needing to switch windows. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@JohannesLorenz This will fix the reported issue.
Fix CMakeLists.txt issues, thanks to @PhysSong Co-authored-by: Hyunjin Song <[email protected]>
@douglasdgi I fixed it in 867973c . Can you please check if it's fixed well? Do you plan to test more or are you finished with testing? (If you're done, you can approve by submitting a PR review) |
Co-authored-by: Hyunjin Song <[email protected]>
This reverts commit 3862929.
This reverts commit 756b84e.
All reviews successful. I'll try to merge it tomorrow. |
I did some git tricks to get the branch content with a single commit into master (2a66e83) while leaving this branch as it is, so I'm closing this branch now. |
|
||
private: | ||
Lv2FxControls m_controls; | ||
std::vector<sampleFrame> m_tmpOutputSmps; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is invalid because sampleFrame
is an array type. For some reason, libstdc++
allows it. This fails to build on macOS(reported on Discord), but the CI was not spotting this because you didn't add LV2 packages to macOS CI builds.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we redefine sampleFrame
from sample_t[DEFAULT_CHANNELS]
to std::array<sample_t, DEFAULT_CHANNELS>
? The latter is generally recommended over plain arrays in modern C++ as it is much better behaved.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will be fixed now in a new PR #5536 .
@Reflexe you will need to merge this branch (or rebase to master) - If you do, watch out for merge conflicts in lines marked "@recording".
... in order to make standard containers be able to store it. Required for #5532 (#4899) and the recording PR. This includes: * removing the `LocklessRingBuffer<sampleFrame>` specialization * passing samplerame in `StereoDelay::tick` as a reference Additional cleanups: * removing already unused typedef `sampleFrameA` * add some `const_cast` to make code more readable
... in order to make standard containers be able to store it. Required for LMMS#5532 (LMMS#4899) and the recording PR. This includes: * removing the `LocklessRingBuffer<sampleFrame>` specialization * passing samplerame in `StereoDelay::tick` as a reference Additional cleanups: * removing already unused typedef `sampleFrameA` * add some `const_cast` to make code more readable
This is a first minimal Lv2 plugin, supporting the whole core, except for CV ports.
No features or extensions are supported yet.
What should work:
What does not work yet:
values of a linked one, then clicking "Link Channels" does not really link
the first stereo model (bug imported from Ladspa) -> Will be fixed with next master merge.
Known Bug: Triple Oscillator has an orange stripe on its "Plugin" tabKnown Bug: Many old instruments windows are resized wrongKnown Bug: VST/Vestige cannot be instantiatedCode Reviewers:
Feel free to split the review or just look at everything you're interested in.
Review hints:
to first look there.
Testers:
Testing hints:
On advance, many thanks for reviewing and testing!