steinbergmedia / vst3sdk

VST 3 Plug-In SDK
Other
1.57k stars 162 forks source link

Max Plugin Parameter ID Clarity #120

Closed VirtualDAW closed 7 months ago

VirtualDAW commented 7 months ago

The documentation states this: https://steinbergmedia.github.io/vst3_dev_portal/pages/Technical+Documentation/Parameters+Automation/Index.html [..]Up to 2^31 parameters can be exported with ID range[0, 2.147.483.648] (the range[2.147.483.649, 4.294.967.296] is reserved for host application).[..]

But getParameterCount() returns "int" (a SIGNED INT), which has a range of -2147483648..+2147483647 max count returned can be 2147483647 = 0x07FFFFFFF, so an id of 2147483647 and 2147483648 is not encodeable. And so it seems its a type in the docs; Max value seems to be 2147483646 or getParameterCount() needs to return "unsigned int"

an id of 2147483648 would be out of 2^31 range, cause it would be 0x80000000 which uses 32bits. And a value of 4294967296 is even out of 3^32 range, cause max. value is 4294967295 = 0x0FFFFFFFF

Seems to be a typo in the docs.

ygrabit commented 7 months ago

Thanks for notifiying this... it will fixed in the doc..