gearmulator

Emulation of classic VA synths of the late 90s/2000s that are based on Motorola 56300 family DSPs
Log | Files | Refs | Submodules | README | LICENSE

jportaudio.dox (2186B)


      1 /** 
      2 @page java_binding JPortAudio Java Binding
      3 @ingroup jportaudio
      4 
      5 <i>Note: this page has not been reviewed, and may contain errors.</i>
      6 
      7 @section java_draft DRAFT - IN PROGRESS
      8 
      9 9/4/12 JPortAudio is very new and should be considered an "alpha" release.
     10 The building of JPortAudio will eventually be integrated into the Makefile as an optional build.
     11 
     12 Currently JPortAudio is only supported for Windows and Macintosh. Please contact us if you want to help with porting Linux.
     13 
     14 For reference documentation of the JPortAudio API see: com.portaudio.PortAudio
     15 
     16 For an example see: PlaySine.java
     17 
     18 @section java_comp_windows Building JPortAudio on Windows
     19 
     20 Build the Java code using the Eclipse project in "jportaudio". Export as "jportaudio.jar".
     21 
     22 If you modify the JNI API then you will need to regenerate the JNI .h files using:
     23 
     24 @code
     25 cd bindings/java/scripts
     26 make_header.bat
     27 @endcode
     28 
     29 Build the JNI DLL using the Visual Studio 2010 solution in "java/c/build/vs2010/PortAudioJNI".
     30 
     31 @section java_use_windows Using JPortAudio on Windows
     32 
     33 Put the "jportaudio.jar" in the classpath for your application.
     34 Place the following libraries where they can be found, typically in the same folder as your application.
     35 
     36 - portaudio_x86.dll
     37 - portaudio_x64.dll
     38 - jportaudio_x86.dll
     39 - jportaudio_x64.dll
     40 
     41 @section java_comp_max Building JPortAudio on Mac
     42 
     43 These are notes from building JPortAudio on a Mac with 10.6.8 and XCode 4.
     44 
     45 I created a target of type 'C' library.
     46 
     47 I added the regular PortAudio frameworks plus the JavaVM framework.
     48 
     49 I modified com_portaudio_PortAudio.h and com_portaudio_BlockingStream.h so that jni.h could found.
     50 
     51 @code
     52 #if defined(__APPLE__)
     53 #include <JavaVM/jni.h>
     54 #else
     55 #include <jni.h>
     56 #endif
     57 @endcode
     58 
     59 This is bad because those header files are autogenerated and will be overwritten.
     60 We need a better solution for this.
     61 
     62 I had trouble finding the "libjportaudio.jnilib". So I added a Build Phase that copied the library to "/Users/phil/Library/Java/Extensions".
     63 
     64 On the Mac we can create a universal library for both 32 and 64-bit JVMs. So in the JAR file I will open "jportaudio" on Apple. ON WIndows I will continue to open "jportaudio_x64" and "jportaudio_x86".
     65 */