Commit 5f6b3fa7 authored by Simon Morlat's avatar Simon Morlat
Browse files

add setPreferredFramerate/getPreferredFramerate accessors

parent 217be118
......@@ -3399,6 +3399,10 @@ extern "C" void Java_org_linphone_core_LinphoneCoreImpl_setPreferredFramerate(JN
linphone_core_set_preferred_framerate((LinphoneCore *)lc, framerate);
extern "C" float Java_org_linphone_core_LinphoneCoreImpl_getPreferredFramerate(JNIEnv *env, jobject thiz, jlong lc){
return linphone_core_get_preferred_framerate((LinphoneCore *)lc);
JNIEXPORT void JNICALL Java_org_linphone_core_LinphoneCoreImpl_setPreferredVideoSizeByName(JNIEnv *env, jobject thiz, jlong lc, jstring jName) {
const char* cName = env->GetStringUTFChars(jName, NULL);
linphone_core_set_preferred_video_size_by_name((LinphoneCore *)lc, cName);
......@@ -1075,6 +1075,20 @@ public interface LinphoneCore {
VideoSize getPreferredVideoSize();
* Set the preferred frame rate for video.
* Based on the available bandwidth constraints and network conditions, the video encoder
* remains free to lower the framerate. There is no warranty that the preferred frame rate be the actual framerate.
* used during a call. Default value is 0, which means "use encoder's default fps value".
* @param fps the target frame rate in number of frames per seconds.
void setPreferredFramerate(float fps);
* Returns the preferred video framerate, previously set by setPreferredFramerate().
* @return frame rate in number of frames per seconds.
float getPreferredFramerate();
* Returns the currently supported audio codecs, as PayloadType elements
* @return
......@@ -1330,4 +1330,15 @@ public class LinphoneCoreImpl implements LinphoneCore {
* @param path The path where the log files will be written.
public native static void setLogCollectionPath(String path);
private native void setPreferredFramerate(long nativePtr, float fps);
public void setPreferredFramerate(float fps) {
private native float getPreferredFramerate(long nativePtr);
public float getPreferredFramerate() {
return getPreferredFramerate(nativePtr);
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment