The JUCE cross-platform C++ framework, with DISTRHO/KXStudio specific changes
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

498 lines
18KB

  1. JUCE breaking changes
  2. =====================
  3. Develop
  4. =======
  5. Change
  6. ------
  7. On Windows, release builds will now link to the dynamic C++ runtime by default
  8. Possible Issues
  9. ---------------
  10. If you are creating a new .jucer project, then your plug-in will now link to the dynamic
  11. C++ runtime by default, which means that you MUST ensure that the C++ runtime libraries
  12. exist on your customer's computers.
  13. Workaround
  14. ----------
  15. If you are only targeting Windows 10, then the C++ runtime is now part of the system core
  16. components and will always exist on the computers of your customers (just like kernel332.dll,
  17. for example). If you are targeting Windows versions between Vista and Windows 10, then you
  18. should build your plug-in with the latest updated version of VS2015 or later, which ensures
  19. that it's linked to the universal runtime. Universal runtime is part of the system's core
  20. libraries on Windows 10 and on Windows versions Vista to 8.1, it will be available on your
  21. customer's computers via Windows Update. Unfortunately, if your customer has just installed
  22. Windows 8.1 to Vista on a fresh computer, then there is a chance that the update mechanism
  23. for the universal runtime hasn't triggered yet and your plug-in may still fail. Your installer
  24. should prompt the user to install all the Windows updates in this case or you can deploy the
  25. universal runtime as a redistributable with your installer. If you are targeting earlier
  26. versions of Windows then you should always include the runtime as a redistributable with your
  27. plug-in's installer. Alternatively, you can change the runtime linking to static (however,
  28. see 'Rationale' section).
  29. Rationale
  30. ---------
  31. In a recent update to Windows 10, Microsoft has limited the number of fiber local storage
  32. (FLS) slots per process. Effectively, this limits how many plug-ins with static runtime
  33. linkage can be loaded into a DAW. In the worst case, this limits the total number of plug-ins
  34. to a maximum of 64 plug-ins. There is no workaround for DAW vendors and the only solution is
  35. to push plug-in vendors to use the dynamic runtime. To help with this, JUCE has decided to make
  36. dynamic runtime linkage the default in JUCE.
  37. Change
  38. ------
  39. AudioProcessorGraph interface has changed in a number of ways - Node objects
  40. are now reference counted, there are different accessor methods to iterate them,
  41. and misc other small improvements to the API
  42. Possible Issues
  43. ---------------
  44. The changes won't cause any silent errors in user code, but will require some
  45. manual refactoring
  46. Workaround
  47. ----------
  48. Just find equivalent new methods to replace existing code.
  49. Rationale
  50. ---------
  51. The graph class was extremely old and creaky, and these changes is the start of
  52. an improvement process that should eventually result in it being broken down
  53. into fundamental graph building block classes for use in other contexts.
  54. Version 5.2.0
  55. =============
  56. Change
  57. ------
  58. Viewport now enables "scroll on drag" mode by default on Android and iOS.
  59. Possible Issues
  60. ---------------
  61. Any code relying on "scroll on drag" mode being turned off by default, should
  62. disable it manually.
  63. Workaround
  64. ----------
  65. None.
  66. Rationale
  67. ---------
  68. It is expected on mobile devices to be able to scroll a list by just a drag,
  69. rather than using a dedicated scrollbar. The scrollbar is still available
  70. though if needed.
  71. Change
  72. ------
  73. The previous setting of Android exporter "Custom manifest xml elements"
  74. creating child nodes of <application> element has been replaced by "Custom
  75. manifest XML content" setting that allows to specify the content of the entire
  76. manifest instead. Any previously values of the old setting will be used in the
  77. new setting by default, and they will need changing as mentioned in Workaround.
  78. The custom content will be merged with the content auto-generated by Projucer.
  79. Any custom elements or custom attributes will override the ones set by
  80. Projucer. Projucer will also automatically add any missing and required
  81. elements and attributes.
  82. Possible Issues
  83. ---------------
  84. If a Projucer project used "Custom manifest xml elements" field, the value will
  85. no longer be compatible with the project generated in the latest Projucer
  86. version. The solution is very simple and quick though, as mentioned in the
  87. Workaround section.
  88. Workaround
  89. ----------
  90. For any elements previously used, simply embed them explicitly in
  91. <manifest><application> elements,for example instead of:
  92. <meta-data android:name="paramId1" android:value="paramValue1"/>
  93. <meta-data android:name="paramId2" android:value="paramValue2"/>
  94. simply write:
  95. <manifest>
  96. <application>
  97. <meta-data android:name="paramId1" android:value="paramValue1"/>
  98. <meta-data android:name="paramId2" android:value="paramValue2"/>
  99. </application>
  100. </manifest>
  101. Rationale
  102. ---------
  103. To maintain the high level of flexibility of generated Android projects and to
  104. avoid creating fields in Projucer for every possible future parameter, it is
  105. simpler to allow to set up the required parameters manually. This way it is not
  106. only possible to add any custom elements but it is also possible to override
  107. the default attributes assigned by Projucer for the required elements. For
  108. instance, if the default value of <supports-screens> element is not
  109. satisfactory because you want a support for x-large screens only, simply set
  110. "Custom manifest XML content" to:
  111. <manifest>
  112. <supports-screens android:xlargeScreens="true"/>
  113. </manifest>
  114. Version 5.1.2
  115. =============
  116. Change
  117. ------
  118. The method used to classify AudioUnit, VST3 and AAX plug-in parameters as
  119. either continuous or discrete has changed, and AudioUnit and AudioUnit v3
  120. parameters are marked as high precision by default.
  121. Possible Issues
  122. ---------------
  123. Plug-ins: DAW projects with automation data written by an AudioUnit, AudioUnit
  124. v3 VST3 or AAX plug-in built with JUCE version 5.1.1 or earlier may load
  125. incorrectly when opened by an AudioUnit, AudioUnit v3, VST3 or AAX plug-in
  126. built with JUCE version 5.1.2 and later.
  127. Hosts: The AudioPluginInstance::getParameterNumSteps method now returns correct
  128. values for AU and VST3 plug-ins.
  129. Workaround
  130. ----------
  131. Plug-ins: Enable JUCE_FORCE_LEGACY_PARAMETER_AUTOMATION_TYPE in the
  132. juce_audio_plugin_client module config page in the Projucer.
  133. Hosts: Use AudioPluginInstance::getDefaultNumParameterSteps as the number of
  134. steps for all parameters.
  135. Rationale
  136. ---------
  137. The old system for presenting plug-in parameters to a host as either continuous
  138. or discrete is inconsistent between plug-in types and lacks sufficient
  139. flexibility. This change harmonises the behaviour and allows individual
  140. parameters to be marked as continuous or discrete. If AudioUnit and AudioUnit
  141. v3 parameters are not marked as high precision then hosts like Logic Pro only
  142. offer a limited number of parameter values, which again produces different
  143. behaviour for different plug-in types.
  144. Change
  145. ------
  146. A new FrameRateType fps23976 has been added to AudioPlayHead,
  147. Possible Issues
  148. ---------------
  149. Previously JUCE would report the FrameRateType fps24 for both 24 and 23.976
  150. fps. If your code uses switch statements (or similar) to handle all possible
  151. frame rate types, then this change may cause it to fall through.
  152. Workaround
  153. ----------
  154. Add fps23976 to your switch statement and handle it appropriately.
  155. Rationale
  156. ---------
  157. JUCE should be able to handle all popular frame rate codes but was missing
  158. support for 23.976.
  159. Change
  160. ------
  161. The String (bool) constructor and operator<< (String&, bool) have been
  162. explicitly deleted.
  163. Possible Issues
  164. ---------------
  165. Previous code which relied on an implicit bool to int type conversion to
  166. produce a String will not compile.
  167. Workaround
  168. ----------
  169. Cast your bool to an integer to generate a string representation of it.
  170. Rationale
  171. ---------
  172. Letting things implicitly convert to bool to produce a String opens the door to
  173. all kinds of nasty type conversion edge cases. Furthermore, before this change,
  174. MacOS would automatically convert bools to ints but this wouldn't occur on
  175. different platform. Now the behaviour is consistent across all operating
  176. systems supported by JUCE.
  177. Change
  178. ------
  179. The writeAsJSON virtual method of the DynamicObject class requires an
  180. additional parameter, maximumDecimalPlaces, to specify the maximum precision of
  181. floating point numbers.
  182. Possible Issues
  183. ---------------
  184. Classes which inherit from DynamicObject and override this method will need to
  185. update their method signature.
  186. Workaround
  187. ----------
  188. Your custom DynamicObject class can choose to ignore the additional parameter
  189. if you don't wish to support this behaviour.
  190. Rationale
  191. ---------
  192. When serialising the results of calculations to JSON the rounding of floating
  193. point numbers can result in numbers with 17 significant figures where only a
  194. few are required. This change to DynamicObject is required to support
  195. truncating those numbers.
  196. Version 5.1.0
  197. =============
  198. Change
  199. ------
  200. The option to set the C++ language standard is now located in the project
  201. settings instead of the build configuration settings.
  202. Possible Issues
  203. ---------------
  204. Projects that had a specific verison of the C++ language standard set for
  205. exporter build configurations will instead use the default (C++11) when
  206. re-saving with the new Projucer.
  207. Workaround
  208. ----------
  209. Change the "C++ Language Standard" setting in the main project settings to the
  210. required version - the Projucer will add this value to the exported project as
  211. a compiler flag when saving exporters.
  212. Rationale
  213. ---------
  214. Having a different C++ language standard option for each build configuration
  215. was unnecessary and was not fully implemented for all exporters. Changing it to
  216. a per-project settings means that the preference will propagate to all
  217. exporters and only needs to be set in one place.
  218. Change
  219. ------
  220. PopupMenus now scale according to the AffineTransform and scaling factor of
  221. their target components.
  222. Possible Issues
  223. ---------------
  224. Developers who have manually scaled their PopupMenus to fit the scaling factor
  225. of the parent UI will now have the scaling applied two times in a row.
  226. Workaround
  227. ----------
  228. 1. Do not apply your own manual scaling to make your popups match the UI
  229. scaling
  230. or
  231. 2. Override the Look&Feel method
  232. PopupMenu::LookAndFeelMethods::shouldPopupMenuScaleWithTargetComponent and
  233. return false. See
  234. https://github.com/WeAreROLI/JUCE/blob/c288c94c2914af20f36c03ca9c5401fcb555e4e9/modules/juce_gui_basics/menus/juce_PopupMenu.h#725
  235. Rationale
  236. ---------
  237. Previously, PopupMenus would not scale if the GUI of the target component (or
  238. any of it’s parents) were scaled. The only way to scale PopupMenus was via the
  239. global scaling factor. This had several drawbacks as the global scaling factor
  240. would scale everything. This was especially problematic in plug-in editors.
  241. Change
  242. ------
  243. Removed the setSecurityFlags() method from the Windows implementation of
  244. WebInputStream as it disabled HTTPS security features.
  245. Possible Issues
  246. ---------------
  247. Any code previously relying on connections to insecure webpages succeeding will
  248. no longer work.
  249. Workaround
  250. ----------
  251. Check network connectivity on Windows and re-write any code that relied on
  252. insecure connections.
  253. Rationale
  254. ---------
  255. The previous behaviour resulted in network connections on Windows having all
  256. the HTTPS security features disabled, exposing users to network attacks. HTTPS
  257. connections on Windows are now secure and will fail when connecting to an
  258. insecure web address.
  259. Change
  260. ------
  261. Pointer arithmetic on a pointer will have the same result regardless if it is
  262. wrapped in JUCE's Atomic class or not.
  263. Possible Issues
  264. ---------------
  265. Any code using pointer arithmetic on Atomic<T*> will now have a different
  266. result leading to undefined behaviour or crashes.
  267. Workaround
  268. ----------
  269. Re-write your code in a way that it does not depend on your pointer being
  270. wrapped in JUCE's Atomic or not. See rationale.
  271. Rationale
  272. ---------
  273. Before this change, pointer arithmetic with JUCE's Atomic type would yield
  274. confusing results. For example, the following code would assert before this
  275. change:
  276. int* a; Atomic<int*> b;
  277. jassert (++a == ++b);
  278. Pointer a in the above code would be advanced by sizeof(int) whereas the JUCE's
  279. Atomic always advances it's underlying pointer by a single byte. The same is
  280. true for operator+=/operator-= and operator--. The difference in behaviour is
  281. confusing and unintuitive. Furthermore, this aligns JUCE's Atomic type with
  282. std::atomic.
  283. Version 4.3.1
  284. =============
  285. Change
  286. ------
  287. JUCE has changed the way native VST3/AudioUnit parameter ids are calculated.
  288. Possible Issues
  289. ---------------
  290. DAW projects with automation data written by an AudioUnit or VST3 plug-in built
  291. with pre JUCE 4.3.1 versions will load incorrectly when opened by an AudioUnit
  292. or VST3 built with JUCE versions 4.3.1 and later. Plug-ins using
  293. JUCE_FORCE_USE_LEGACY_PARAM_IDS are not affected.
  294. Workaround
  295. ----------
  296. Disable JUCE_USE_STUDIO_ONE_COMPATIBLE_PARAMETERS in the
  297. juce_audio_plugin_client module config page in the Projucer. For new plug-ins,
  298. be sure to use the default value for this property.
  299. Rationale
  300. --------
  301. JUCE needs to convert between its own JUCE parameter id format (strings) to the
  302. native parameter id formats of the various plug-in backends. For VST3 and
  303. AudioUnits, JUCE uses a hash function to generate a numeric id. However, some
  304. VST3/AudioUnit hosts (specifically Studio One) have a bug that ignore any
  305. parameters that have a negative parameter id. Therefore, the hash function for
  306. VST3/AudioUnits needed to be changed to only return positive-valued hashes.
  307. Version 4.3.0
  308. =============
  309. Change
  310. ------
  311. A revised multi-bus API was released which supersedes the previously flawed
  312. multi-bus API - JUCE versions 4.0.0 - 4.2.4 (inclusive).
  313. Possible Issues
  314. ---------------
  315. If you have developed a plug-in with JUCE versions 4.0.0 - 4.2.4 (inclusive),
  316. then you will need to update your plug-in to the new multi-bus API. Pre JUCE
  317. 4.0.0 plug-ins are not affected apart from other breaking changes listed in
  318. this document.
  319. Woraround
  320. ---------
  321. None.
  322. Rationale
  323. --------
  324. A flawed multi-bus API was introduced with JUCE versions 4.0.0 up until version
  325. 4.2.4 (inclusive) which was not API compatible with pre JUCE 4 plug-ins. JUCE
  326. 4.3.0 releases a revised multi-bus API which restores pre JUCE 4 API
  327. compatibility. However, the new multi-bus API is not compatible with the flawed
  328. multi-bus API (JUCE version 4.0.0 - 4.2.4).
  329. Change
  330. ------
  331. JUCE now generates the AAX plug-in bus layout configuration id independent from
  332. the position as it appears in the Projucer’s legacy "Channel layout
  333. configuration" field.
  334. Possible Issues
  335. ---------------
  336. ProTools projects generated with a < 4.3.0 JUCE versions of your plug-in, may
  337. load the incorrect bus configuration when upgrading your plug-in to >= 4.3.0
  338. versions of JUCE.
  339. Workaround
  340. ----------
  341. Implement AudioProcessor’s getAAXPluginIDForMainBusConfig callback to manually
  342. override which AAX plug-in id is associated to a specific bus layout of your
  343. plug-in. This workaround is only necessary if you have released your plug-in
  344. built with a version previous to JUCE 4.3.0.
  345. Rationale
  346. --------
  347. The new multi-bus API offers more features, flexibility and accuracy in
  348. specifying bus layouts which cannot be expressed by the Projucer’s legacy
  349. "Channel layout configuration" field. The native plug-in format backends use
  350. the new multi-bus callback APIs to negotiate channel layouts with the host -
  351. including the AAX plug-in ids assigned to specific bus layouts. With the
  352. callback API, there is no notion of an order in which the channel
  353. configurations appear - as was the case with the legacy "Channel layout
  354. configuration" field - and therefore cannot be used to generate the AAX plug-in
  355. id. To remain backward compatible to pre JUCE 4.0.0 plug-ins, JUCE does
  356. transparently convert the legacy "Channel layout configuration" field to the
  357. new callback based multi-bus API, but this does not take the order into account
  358. in which the channel configurations appear in the legacy "Channel layout
  359. configuration" field.
  360. Version 4.2.1
  361. =============
  362. Change
  363. ------
  364. JUCE now uses the paramID property used in AudioProcessorParameterWithID to
  365. uniquely identify parameters to the host.
  366. Possible Issues
  367. ---------------
  368. DAW projects with automation data written by an audio plug-in built with pre
  369. JUCE 4.2.1 will load incorrectly when opened by an audio plug-in built with
  370. JUCE 4.2.1 and later.
  371. Workaround
  372. ----------
  373. Enable JUCE_FORCE_USE_LEGACY_PARAM_IDS in the juce_audio_plugin_client module config
  374. page in the Projucer. For new plug-ins, be sure to disable this property.
  375. Rationale
  376. --------
  377. Each parameter of the AudioProcessor has an id associated so that the plug-in’s
  378. host can uniquely identify parameters. The id has a different data-type for
  379. different plug-in types (for example VST uses integers, AAX uses string
  380. identifiers). Before 4.2.1, JUCE generated the parameter id by using the index
  381. of the parameter, i.e. the first parameter had id zero, the second parameter
  382. had id one, etc. This caused problems for certain plug-in types where JUCE
  383. needs to add internal parameters to the plug-in (for example VST3 requires the
  384. bypass control to be a parameter - so JUCE automatically creates this parameter
  385. for you in the VST3 backend). This causes subtle problems if a parameter is
  386. added to an update of an already published plug-in. The new parameter’s id
  387. would be identical to the id of the bypass parameter in old versions of your
  388. plug-in, causing seemingly random plug-in bypass behaviour when user’s upgrade
  389. their plug-in.
  390. Most plug-in backends differentiate between a parameter’s id an index, so this
  391. distinction was adopted starting with JUCE 4.2.1 by deriving the parameter’s
  392. unique id from the paramID property of AudioProcessorParameterWithID class.