kunstmusik / CsoundJNI

Java binding for Csound using JNI
GNU Lesser General Public License v2.1
5 stars 0 forks source link

Wrong function call for compileCsdText in CsoundJNI.cpp #3

Open antlanc7 opened 2 weeks ago

antlanc7 commented 2 weeks ago

https://github.com/kunstmusik/CsoundJNI/blob/cf2a3b64ab08f12219eb5a01ccb67e8e959245b5/src/main/cpp/CsoundJNI.cpp#L255

At line 255, the function csoundCompileOrcAsync is called, but it should actually call csoundCompileCsdText.

Currently, using compileCsdText in the Java code calls csoundCompileOrcAsync under the hood, which causes it to not function correctly.

kunstmusik commented 2 weeks ago

Thank you for reporting this. I will have to look at compiling the native lib on all of the platforms (I had never gotten around to automating this unfortunately). I'll write back once I can work this out.

FYI: I'm starting to explore using Java 22's FFM API for native access to Csound. Once I can get the library working I expect this to be the path forward for desktop/server Java applications using Csound.