Skip to content
Snippets Groups Projects
Commit 0c3167d1 authored by Tobias Ullerich's avatar Tobias Ullerich
Browse files

Add setRate method for native audio mac

parent 71f78d04
No related branches found
No related tags found
No related merge requests found
......@@ -26,6 +26,8 @@ public class NativeAudio {
public static native double getPosition(int id);
public static native void setRate(int id, double rate);
public static void onPeakMeter(int id, float left, float right) {
if (delegate != null) {
delegate.onPeakMeter(id, left, right);
......
......@@ -7,6 +7,14 @@
#ifdef __cplusplus
extern "C" {
#endif
/*
* Class: de_tobias_playpad_NativeAudio
* Method: initialize
* Signature: ()V
*/
JNIEXPORT void JNICALL Java_de_tobias_playpad_NativeAudio_initialize
(JNIEnv *, jclass);
/*
* Class: de_tobias_playpad_NativeAudio
* Method: play
......@@ -31,6 +39,22 @@ JNIEXPORT void JNICALL Java_de_tobias_playpad_NativeAudio_pause
JNIEXPORT void JNICALL Java_de_tobias_playpad_NativeAudio_stop
(JNIEnv *, jclass, jint);
/*
* Class: de_tobias_playpad_NativeAudio
* Method: seek
* Signature: (ID)V
*/
JNIEXPORT void JNICALL Java_de_tobias_playpad_NativeAudio_seek
(JNIEnv *, jclass, jint, jdouble);
/*
* Class: de_tobias_playpad_NativeAudio
* Method: setLoop
* Signature: (IZ)V
*/
JNIEXPORT void JNICALL Java_de_tobias_playpad_NativeAudio_setLoop
(JNIEnv *, jclass, jint, jboolean);
/*
* Class: de_tobias_playpad_NativeAudio
* Method: getVolume
......@@ -79,6 +103,14 @@ JNIEXPORT jdouble JNICALL Java_de_tobias_playpad_NativeAudio_getDuration
JNIEXPORT jdouble JNICALL Java_de_tobias_playpad_NativeAudio_getPosition
(JNIEnv *, jclass, jint);
/*
* Class: de_tobias_playpad_NativeAudio
* Method: setRate
* Signature: (ID)V
*/
JNIEXPORT void JNICALL Java_de_tobias_playpad_NativeAudio_setRate
(JNIEnv *, jclass, jint, jdouble);
#ifdef __cplusplus
}
#endif
......
No preview for this file type
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment