FFSampledSP
Loading...
Searching...
No Matches
FFCodecInputStream.c File Reference
#include "FFUtils.h"
#include "com_tagtraum_ffsampledsp_FFCodecInputStream.h"
#include <math.h>

Go to the source code of this file.

Functions

JNIEXPORT void JNICALL Java_com_tagtraum_ffsampledsp_FFCodecInputStream_initIDs (JNIEnv *env, jclass streamClass)
 Init static method and field ids for Java methods/fields.
JNIEXPORT jlong JNICALL Java_com_tagtraum_ffsampledsp_FFCodecInputStream_open (JNIEnv *env, jobject object, jobject target_format, jlong aio_pointer)
 Re-configures SwrContext and Encoder to match the provided target_format.

Function Documentation

◆ Java_com_tagtraum_ffsampledsp_FFCodecInputStream_initIDs()

JNIEXPORT void JNICALL Java_com_tagtraum_ffsampledsp_FFCodecInputStream_initIDs ( JNIEnv * env,
jclass streamClass )

Init static method and field ids for Java methods/fields.

Called exactly once from the static initializer of FFCodecInputStream. Because the JVM serializes class initialization, the ids are guaranteed to be set before any thread can call into native code with a stream instance.

Parameters
envJNIEnv
streamClassFFCodecInputStream class

Definition at line 46 of file FFCodecInputStream.c.

◆ Java_com_tagtraum_ffsampledsp_FFCodecInputStream_open()

JNIEXPORT jlong JNICALL Java_com_tagtraum_ffsampledsp_FFCodecInputStream_open ( JNIEnv * env,
jobject object,
jobject target_format,
jlong aio_pointer )

Re-configures SwrContext and Encoder to match the provided target_format.

Parameters
envJNIEnv
objectstream instance this call stems from, i.e. a FFCodecInputStream
target_formattarget AudioFormat
aio_pointerPointer to the FFAudioIO struct of the FFNativePeerInputStream that opened the file/stream
Returns
pointer to the FFAudioIO struct that was given as parameter

Definition at line 97 of file FFCodecInputStream.c.