View Issue Details
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0008942||ardour||bugs||public||2022-07-18 10:03||2022-07-18 13:50|
|Summary||0008942: Ardour LV2 host doesn't provide boundedBlockLength in features array|
Information is from here https://forum.juce.com/t/juce7-technical-preview-branch/50866/87
For the Ardour issue: JUCE plugins need to know their maximum processing block size, so JUCE LV2 plugins declare bufs:boundedBlockSize as an lv2:requiredFeature. If a plugin requires features that cannot be supplied by the host, the host should not attempt to instantiate the plugin. If the host does supply the feature, then it should include the feature in the array of features passed to the plugin during instantiation. For that assertion to fire, one of the following must be true:
*The host cannot supply the boundedBlockLength feature, but attempts to instantiate the plugin anyway. The host should not attempt to instantiate the plugin in this case.
*The host can supply the boundedBlockLength feature, but does not include it in the features data array. In this case, the host should be updated to include boundedBlockLength in its features array.
|Steps To Reproduce||Compile any JUCE plugin with LV2 support.|
Install plugin in LV2 path.
Scan for the new plugins in Ardour.
Add new plugin.
|Tags||No tags attached.|
It's a feature that plugins can require (lv2:requiredFeature), and the host in turn implements and provides
In case of Ardour both are set, minBlockLength is 1 and maxBlockLength 8192. This has been implemented since 2015.
Compare to other plugins that use it (ZynAddSubFX.lv2, KlangFalter.lv2, Pianoteq 6.lv2, moony.lv2 etc)
||thnx, forwarded to juce forum|
||BTW I haven't such issue in the jalv, Muse, Reaper, Carla|
||Odd the same person who wrote jalv (and the LV2 spec) also wrote Ardour's implementation.|
I know :)
Could you take a look at JUCE implementation, please? Or give a point?
||Reading the source, it looks like the feature is indeed not explicitly announced to the plugin, but the min/max options are set.|
When a host supports an `lv2:requiredFeature`, the host MUST pass the feature's URI and any additional data to the plugin in LV2_Descriptor::instantiate(), and the plugin MUST fail to instantiate if a required feature is not supported by the host. (See http://lv2plug.in/ns/lv2core#requiredFeature).
I believe that the JUCE implementation is adhering to the spec by failing to instantiate, given that the host is not reporting boundedBlockLength as supported. Plugins that declare boundedBlockLength as a requiredFeature, but which don't check that the host provides this feature, do not adhere to the spec.
If there's some provision in the spec that means 'data-only' features don't need to be included in the LV2_Feature array, please provide a link to this provision so that I can reference it in a change to JUCE.
If there's no such provision, then I believe the wording in the spec is unambiguous, and Ardour must add boundedBlockLength to its array of supported features in order to declare support.
It is redundant, so it seems plugins just read the options (if present), regardless of the host announcing the feature.
It makes lot more sense the other way around. A host that does not provide the options should refuse plugins that require the feature.
Anyway fixed now in Ardour 7.0-pre0-3175-g79f8606b2d -- Thanks for the heads up.
|2022-07-18 10:03||KottV||New Issue|
|2022-07-18 12:52||x42||Note Added: 0026508|
|2022-07-18 12:52||x42||Assigned To||=> x42|
|2022-07-18 12:52||x42||Status||new => feedback|
|2022-07-18 13:03||KottV||Note Added: 0026509|
|2022-07-18 13:03||KottV||Status||feedback => assigned|
|2022-07-18 13:16||KottV||Note Added: 0026510|
|2022-07-18 13:20||x42||Note Added: 0026511|
|2022-07-18 13:23||KottV||Note Added: 0026512|
|2022-07-18 13:24||x42||Note Added: 0026513|
|2022-07-18 13:32||reuk||Note Added: 0026514|
|2022-07-18 13:46||x42||Note Added: 0026515|
|2022-07-18 13:46||x42||Status||assigned => resolved|
|2022-07-18 13:46||x42||Resolution||open => fixed|
|2022-07-18 13:50||reuk||Note Added: 0026516|