In 2021 I completed a Java based sound library for Processing called Pd++ for Processing 3, or Pd4P3. It is based on my Pd++ library (resler / pd — Bitbucket) which is a C++ library based on the signal processing object code from Pure Data.
The library source code lives here:
robertesler/Pd4P3: (github.com)
You can download the library for Processing here: http://www.robertesler.com/software/Pd4P3.zip or find it in the Processing “Manage Tools – Contribution Manager” option.
The basic idea of this library is that the signal processing objects of Pure Data (i.e osc~, cos~, vcf~, vd~, etc.) are represented as classes and can be used in the same way as in Pd but in a structured programming language like C++, C# or Java. Thereby you can use the same code in your own software, sketches, or even make Max or Pd externals, audio plugins, art installations, missile defense systems, etc.
The Processing library comes with an audio scheduler so it will work without any lower level coding. It comes with numerous examples, if you have any questions or issues, contact me via github.
This library also works on Android with native MIDI support via the examples.