Lv2 audio ports with connectionOptional should be used if it avoids stereo
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 10.4k
- Forks
- 1.3k
- Avg merge
- 2d 13h
- Merged PRs (30d)
- 7
Description
Enhancement Summary
Lv2Proc.cpp: ConnectPortVisitor::visit(Lv2Ports::Audio& audio) only connects compulsory ports. Some plugins, like CALF BassEnhancer, make the 2nd stereo port compulsory.
Our implementation to avoid stereo caused some crashes. It's still interesting because it covers issues in plugins that are not
tested for mono input/output.
Justification
Stereo ports should be used when available, it allows using things like balancing, panning, L/R crossing...
Mockup
Since Lv2Proc::check does not allow more than 2 audio inputs or outputs, the number can be at most 2. To find out whether the
second port is a part of the stereo pair, check if both ports have the StereoGroup URI from the port-groups extension. If it does not have this URI, better ignore the optional port - who knows what it is good for.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in Lv2Proc.cpp at ConnectPortVisitor::visit(Lv2Ports::Audio&) and review the two-port limit enforced by Lv2Proc::check. Inspect the LV2 port-groups StereoGroup URI handling, then verify that an optional second audio port is used only when it forms a stereo pair and that non-stereo optional ports remain ignored without crashes.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- audio-video-rtc
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100