diff options
author | braveyao@webrtc.org <braveyao@webrtc.org@4adac7df-926f-26a2-2b94-8c16560cd09d> | 2014-05-15 03:18:15 +0000 |
---|---|---|
committer | braveyao@webrtc.org <braveyao@webrtc.org@4adac7df-926f-26a2-2b94-8c16560cd09d> | 2014-05-15 03:18:15 +0000 |
commit | ca2c70f2bae88987267a2727449ac86330fb8dbd (patch) | |
tree | 2a8ed2231421354a4a221c90f20fa40c4517c8c4 /examples | |
parent | dd0f8b2a5f7fde0d8a515ea90bcf32fcad7ad230 (diff) | |
download | webrtc-ca2c70f2bae88987267a2727449ac86330fb8dbd.tar.gz |
WebRTCDemo: couldn't run a second time. The reason is voe could register/unregister for each run, but vie would expect initialization only once per process.
This cl is to teach videocapture android how to deinitialize and allow it to be re-initializable.
BUG=3284
TEST=ManualTest
R=fischman@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/15429004
git-svn-id: http://webrtc.googlecode.com/svn/trunk/webrtc@6167 4adac7df-926f-26a2-2b94-8c16560cd09d
Diffstat (limited to 'examples')
-rw-r--r-- | examples/android/media_demo/jni/on_load.cc | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/examples/android/media_demo/jni/on_load.cc b/examples/android/media_demo/jni/on_load.cc index 27a2394b..9f9a0c7a 100644 --- a/examples/android/media_demo/jni/on_load.cc +++ b/examples/android/media_demo/jni/on_load.cc @@ -47,6 +47,8 @@ JOWW(void, NativeWebRtcContextRegistry_register)( JOWW(void, NativeWebRtcContextRegistry_unRegister)( JNIEnv* jni, jclass) { + CHECK(webrtc::VideoEngine::SetAndroidObjects(NULL) == 0, + "Failed to unregister android objects from video engine"); CHECK(webrtc::VoiceEngine::SetAndroidObjects(NULL, NULL, NULL) == 0, "Failed to unregister android objects from voice engine"); webrtc_examples::ClearVieDeviceObjects(); |