free-audio / clap

Audio Plugin API
https://cleveraudio.org/
MIT License
1.77k stars 100 forks source link

Default active state is not explicitely stated #187

Closed falkTX closed 1 year ago

falkTX commented 1 year ago

For destroying a plugin, docs say "It is required to deactivate the plugin prior to this call". Does that mean a call to deactivate is needed?

By how other specs work we can reasonably guess that plugin starts at non-active state, so unless specifically activated we do not need to call deactivate before destroying it. Still does not sound fully correct.

Specs should explicitly state, somewhere, that plugin starts in non-active state.

PS: there is a typo in the header docs, sometimes "active" as tag is used, but there is also "active_state" in use. The 1st seems to be a typo since it is only used once.

robbert-vdh commented 1 year ago

For destroying a plugin, docs say "It is required to deactivate the plugin prior to this call". Does that mean a call to deactivate is needed?

A call to deactivate() is only needed when the plugin has been activated. In other words, when the host has called activate() and the plugin returned `true.