Changeset 3313 for pjproject/trunk
- Timestamp:
- Sep 20, 2010 6:13:02 AM (14 years ago)
- Location:
- pjproject/trunk
- Files:
-
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/trunk/pjmedia/docs/doxygen.cfg
r2037 r3313 854 854 PJ_HAS_EVENT_OBJ=1 \ 855 855 PJ_HAS_TCP=1 \ 856 PJMEDIA_HAS_SRTP=1 856 PJMEDIA_HAS_SRTP=1 \ 857 PJMEDIA_STREAM_ENABLE_KA=1 857 858 858 859 # If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then -
pjproject/trunk/pjmedia/include/pjmedia/stream.h
r3237 r3313 128 128 delay in msec (-1 for default). */ 129 129 int jb_max; /**< Jitter buffer max delay in msec. */ 130 131 #if defined(PJMEDIA_STREAM_ENABLE_KA) && PJMEDIA_STREAM_ENABLE_KA!=0 132 pj_bool_t use_ka; /**< Stream keep-alive and NAT hole punch 133 (see @ref PJMEDIA_STREAM_ENABLE_KA) 134 is enabled? */ 135 #endif 130 136 }; 131 137 -
pjproject/trunk/pjmedia/src/pjmedia/stream.c
r3292 r3313 198 198 199 199 #if defined(PJMEDIA_STREAM_ENABLE_KA) && PJMEDIA_STREAM_ENABLE_KA!=0 200 pj_bool_t use_ka; /**< Stream keep-alive with non- 201 codec-VAD mechanism is 202 enabled? */ 200 203 pj_timestamp last_frm_ts_sent; /**< Timestamp of last sending 201 204 packet */ … … 1124 1127 * PJMEDIA_STREAM_KA_INTERVAL, send keep-alive packet. 1125 1128 */ 1129 if (stream->use_ka) 1126 1130 { 1127 1131 pj_uint32_t dtx_duration; … … 1974 1978 stream->jb_last_frm = PJMEDIA_JB_NORMAL_FRAME; 1975 1979 1980 #if defined(PJMEDIA_STREAM_ENABLE_KA) && PJMEDIA_STREAM_ENABLE_KA!=0 1981 stream->use_ka = info->use_ka; 1982 #endif 1983 1976 1984 /* Build random RTCP CNAME. CNAME has user@host format */ 1977 1985 stream->cname.ptr = p = (char*) pj_pool_alloc(pool, 20); … … 2285 2293 #if defined(PJMEDIA_STREAM_ENABLE_KA) && PJMEDIA_STREAM_ENABLE_KA!=0 2286 2294 /* NAT hole punching by sending KA packet via RTP transport. */ 2287 send_keep_alive_packet(stream); 2295 if (stream->use_ka) 2296 send_keep_alive_packet(stream); 2288 2297 #endif 2289 2298 -
pjproject/trunk/pjsip/docs/doxygen.cfg
r2037 r3313 847 847 PREDEFINED = PJ_DECL(x)=x PJ_DEF(x)=x PJ_IDECL(x)=x \ 848 848 PJ_IDEF(x)=x PJ_INLINE(x)=x PJ_DECL_DATA(x)=x \ 849 PJMEDIA_HAS_SRTP=1 849 PJMEDIA_HAS_SRTP=1 \ 850 PJMEDIA_STREAM_ENABLE_KA=1 850 851 851 852 -
pjproject/trunk/pjsip/include/pjsua-lib/pjsua.h
r3305 r3313 2318 2318 unsigned reg_use_proxy; 2319 2319 2320 #if defined(PJMEDIA_STREAM_ENABLE_KA) && (PJMEDIA_STREAM_ENABLE_KA != 0) 2321 /** 2322 * Specify whether stream keep-alive and NAT hole punching with 2323 * non-codec-VAD mechanism (see @ref PJMEDIA_STREAM_ENABLE_KA) is enabled 2324 * for this account. 2325 * 2326 * Default: PJ_FALSE (disabled) 2327 */ 2328 pj_bool_t use_stream_ka; 2329 #endif 2330 2320 2331 } pjsua_acc_config; 2321 2332 -
pjproject/trunk/pjsip/src/pjsua-lib/pjsua_acc.c
r3305 r3313 753 753 acc->cfg.srtp_secure_signaling = cfg->srtp_secure_signaling; 754 754 acc->cfg.srtp_optional_dup_offer = cfg->srtp_optional_dup_offer; 755 #endif 756 757 #if defined(PJMEDIA_STREAM_ENABLE_KA) && (PJMEDIA_STREAM_ENABLE_KA != 0) 758 acc->cfg.use_stream_ka = cfg->use_stream_ka; 755 759 #endif 756 760 -
pjproject/trunk/pjsip/src/pjsua-lib/pjsua_core.c
r3305 r3313 186 186 cfg->reg_use_proxy = PJSUA_REG_USE_OUTBOUND_PROXY | 187 187 PJSUA_REG_USE_ACC_PROXY; 188 #if defined(PJMEDIA_STREAM_ENABLE_KA) && PJMEDIA_STREAM_ENABLE_KA!=0 189 cfg->use_stream_ka = (PJMEDIA_STREAM_ENABLE_KA != 0); 190 #endif 188 191 } 189 192 -
pjproject/trunk/pjsip/src/pjsua-lib/pjsua_media.c
r3219 r3313 1546 1546 /* Reset session info with only one media stream */ 1547 1547 sess_info.stream_cnt = 1; 1548 if (si != &sess_info.stream_info[0]) 1548 if (si != &sess_info.stream_info[0]) { 1549 1549 pj_memcpy(&sess_info.stream_info[0], si, sizeof(pjmedia_stream_info)); 1550 si = &sess_info.stream_info[0]; 1551 } 1550 1552 1551 1553 /* Check if no media is active */ … … 1638 1640 si->rtp_seq = call->rtp_tx_seq; 1639 1641 si->rtp_seq_ts_set = call->rtp_tx_seq_ts_set; 1642 1643 #if defined(PJMEDIA_STREAM_ENABLE_KA) && PJMEDIA_STREAM_ENABLE_KA!=0 1644 /* Enable/disable stream keep-alive and NAT hole punch. */ 1645 si->use_ka = pjsua_var.acc[call->acc_id].cfg.use_stream_ka; 1646 #endif 1640 1647 1641 1648 /* Create session based on session info. */
Note: See TracChangeset
for help on using the changeset viewer.