Skip to content

Commit

Permalink
add back opus config function
Browse files Browse the repository at this point in the history
  • Loading branch information
devoxin committed Apr 12, 2024
1 parent 9cc188a commit e0b8088
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions natives/connector/opus.c
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,16 @@ CONNECTOR_EXPORT jlong JNICALL Java_com_sedmelluq_discord_lavaplayer_natives_opu
return (jlong) encoder;
}

CONNECTOR_EXPORT jint JNICALL Java_com_sedmelluq_discord_lavaplayer_natives_opus_OpusEncoderLibrary_configure(JNIEnv *jni, jobject me, jlong instance, jint request, jint value) {
OpusEncoder* encoder = (OpusEncoder*) instance;

if (instance == 0 || encoder == NULL) {
return 0;
}

return opus_encoder_ctl(encoder, request, value);
}

CONNECTOR_EXPORT jint JNICALL Java_com_sedmelluq_discord_lavaplayer_natives_opus_OpusEncoderLibrary_encode(JNIEnv *jni, jobject me, jlong instance, jobject direct_input, jint frame_size,
jobject direct_output, jint output_length) {
if (instance == 0) {
Expand Down

0 comments on commit e0b8088

Please sign in to comment.