[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Linphone-developers] Video call on Android without OpenGL ES 2
From: |
Balder Mørk |
Subject: |
Re: [Linphone-developers] Video call on Android without OpenGL ES 2 |
Date: |
Tue, 19 Aug 2014 11:12:14 +0200 |
User-agent: |
Mozilla/5.0 (Windows NT 6.3; WOW64; rv:24.0) Gecko/20100101 Thunderbird/24.6.0 |
Den 13.08.2014 15:26, skrev Balder Mørk:
Hi,
I am working on an Android app that will use liblinphone for receiving
calls (preferably video) from SIP clients. My app will probably have
to work on quite limited devics, including some that don't have OpenGL
ES 2.0 support. From what I can see, AndroidVideoWindowImpl.java has
code for doing software rendering (controlled by the useGLrendering
member), but I can only get the video rendering to work if I feed
AndroidVideoWindowImpl a GL2JNIView object.
I checked the archives, but I couldn't find any mention of this:
1) Is it possible to make mediastreamer2/liblinphone do software
rendering on devices without OpenGL ES 2 support?
2) How does Linphone handle this problem?
I've come a bit further with this, by editing msvoip.c and changing the
if (1) block that chooses the openGL displayfilter for Android over the
software filters. Now I've stumbled across a few other problems:
1) When building liblinphone I get the following error:
jni/..//submodules/linphone/mediastreamer2/build/android/../../src/android/android-display-bad.cpp:285:
error: undefined reference to 'ms_factory_register_filter(_MSFactory*,
_MSFilterDesc*)'
I notice that the function arguments have '_' prepended to the argument
types, but I know too little about C/C++ to figure out why this line
fails to build.
2) If I comment out the line in msvoip.c that tries to init the "bad"
display filter, I can build and run, but once I try to load video (I'm
using a plain SurfaceView for the video view supplied to
AndroidVideoWindowImpl) I get a crash because requestOrientation is no
longer found in AndroidVideoWindowImpl. Commenting out references to
requestOrientation gets me a step further, but crashes like so:
Video to display has size 352x288
JNI WARNING: 0xb140f9f8 is not a valid JNI reference
in Ldalvik/system/NativeStart;.run:()V (GetIntField)
"Thread-202" prio=5 tid=11 RUNNABLE
| group="main" sCount=0 dsCount=0 obj=0xb13600c8 self=0xb7de8270
| sysTid=3833 nice=0 sched=0/0 cgrp=[fopen-error:2] handle=-1210128528
| state=R schedstat=( 0 0 0 ) utm=0 stm=0 core=0
at dalvik.system.NativeStart.run(Native Method)
[ 08-18 19:31:13.473 3798: 3833 E/dalvikvm ]
VM aborting
Are the Android software filters supposed to work? If they are, did they
break recently or is this a problem with my setup? I'm grateful for any
help here, especially since I've hardly touched C/C++ in years, not to
mention JNI.
I'm currently building from master, but if I should be using some tag
that's more stable, please let me know.
Balder Mørk