Ignore:
Timestamp:
Mar 26, 2015 10:06:45 AM (10 years ago)
Author:
nanang
Message:

Re #1790: Misc fixes on renderer viewing in pjsua CLI app sample, e.g: handle NULL surface, handle video disabled, cleanup unused codes.

Location:
pjproject/trunk/pjsip-apps/src/pjsua/android/jni
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • pjproject/trunk/pjsip-apps/src/pjsua/android/jni/pjsua.i

    r5014 r5030  
    55#include "../../pjsua_app.h" 
    66#include <android/native_window_jni.h> 
    7  
    8 #ifdef __cplusplus 
    9 extern "C" { 
    10 #endif 
    11         int pjsuaStart(); 
    12         void pjsuaDestroy(); 
    13         int pjsuaRestart(); 
    14         void setCallbackObject(PjsuaAppCallback* callback);      
    15 #ifdef __cplusplus 
    16 } 
    17 #endif 
    187%} 
    198 
     
    2312/* Convert Surface object to ANativeWindow for setIncomingVideoRenderer() */ 
    2413%typemap(in) jobject surface { 
    25     $1 = (jobject)ANativeWindow_fromSurface(jenv, $input); 
     14    $1 = $input? (jobject)ANativeWindow_fromSurface(jenv, $input) : NULL; 
    2615} 
    2716 
  • pjproject/trunk/pjsip-apps/src/pjsua/android/jni/pjsua_app_callback.cpp

    r5014 r5030  
    4646static void on_call_media_state(pjsua_call_id call_id) 
    4747{ 
     48#if PJMEDIA_HAS_VIDEO 
    4849    pjsua_call_info call_info; 
    4950    unsigned mi; 
    50     pj_bool_t has_error = PJ_FALSE; 
    5151 
    5252    pjsua_call_get_info(call_id, &call_info); 
     
    6868        } 
    6969    } 
     70#endif 
    7071     
    7172    /* Forward to original callback */ 
Note: See TracChangeset for help on using the changeset viewer.