- Timestamp:
- Mar 17, 2011 4:34:43 AM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/branches/projects/2.0-dev/pjsip/include/pjsua-lib/pjsua.h
r3366 r3457 251 251 #define PJSUA_INVALID_ID (-1) 252 252 253 /** Disabled features temporarily for media reorganization */ 254 #define DISABLED_FOR_TICKET_1185 0 255 253 256 /** Call identification */ 254 257 typedef int pjsua_call_id; … … 282 285 # define PJSUA_ACC_MAX_PROXIES 8 283 286 #endif 284 285 #if defined(PJMEDIA_HAS_SRTP) && (PJMEDIA_HAS_SRTP != 0)286 287 287 288 /** … … 304 305 #endif 305 306 306 #endif307 308 307 /** 309 308 * Controls whether PJSUA-LIB should add ICE media feature tag … … 325 324 # define PJSUA_ACQUIRE_CALL_TIMEOUT 2000 326 325 #endif 326 327 328 /** 329 * This enumeration represents pjsua state. 330 */ 331 typedef enum pjsua_state 332 { 333 /** 334 * The library has not been initialized. 335 */ 336 PJSUA_STATE_NULL, 337 338 /** 339 * After pjsua_create() is called but before pjsua_init() is called. 340 */ 341 PJSUA_STATE_CREATED, 342 343 /** 344 * After pjsua_init() is called but before pjsua_start() is called. 345 */ 346 PJSUA_STATE_INIT, 347 348 /** 349 * After pjsua_start() is called but before everything is running. 350 */ 351 PJSUA_STATE_STARTING, 352 353 /** 354 * After pjsua_start() is called and before pjsua_destroy() is called. 355 */ 356 PJSUA_STATE_RUNNING, 357 358 /** 359 * After pjsua_destroy() is called but before the function returns. 360 */ 361 PJSUA_STATE_CLOSING 362 363 } pjsua_state; 327 364 328 365 … … 484 521 * 485 522 * @param call_id Call identification. 486 * @param s ess Media session for the call.523 * @param strm Media stream. 487 524 * @param stream_idx Stream index in the media session. 488 525 * @param p_port On input, it specifies the media port of the … … 492 529 */ 493 530 void (*on_stream_created)(pjsua_call_id call_id, 494 pjmedia_s ession *sess,531 pjmedia_stream *strm, 495 532 unsigned stream_idx, 496 533 pjmedia_port **p_port); … … 501 538 * 502 539 * @param call_id Call identification. 503 * @param s ess Media session for the call.540 * @param strm Media stream. 504 541 * @param stream_idx Stream index in the media session. 505 542 */ 506 543 void (*on_stream_destroyed)(pjsua_call_id call_id, 507 pjmedia_s ession *sess,544 pjmedia_stream *strm, 508 545 unsigned stream_idx); 509 546 … … 1155 1192 pj_str_t user_agent; 1156 1193 1157 #if defined(PJMEDIA_HAS_SRTP) && (PJMEDIA_HAS_SRTP != 0)1158 1194 /** 1159 1195 * Specify default value of secure media transport usage. … … 1185 1221 1186 1222 /** 1187 * Specify whether SRTP in PJMEDIA_SRTP_OPTIONAL mode should compose 1223 * Specify whether SRTP in PJMEDIA_SRTP_OPTIONAL mode should compose 1188 1224 * duplicated media in SDP offer, i.e: unsecured and secured version. 1189 * Otherwise, the SDP media will be composed as unsecured media but 1225 * Otherwise, the SDP media will be composed as unsecured media but 1190 1226 * with SDP "crypto" attribute. 1191 1227 * … … 1193 1229 */ 1194 1230 pj_bool_t srtp_optional_dup_offer; 1195 #endif1196 1231 1197 1232 /** … … 1351 1386 */ 1352 1387 PJ_DECL(pj_status_t) pjsua_destroy(void); 1388 1389 1390 /** 1391 * Retrieve pjsua state. 1392 * 1393 * @return pjsua state. 1394 */ 1395 PJ_DECL(pjsua_state) pjsua_get_state(void); 1353 1396 1354 1397 … … 2094 2137 #endif 2095 2138 2096 2097 2139 /** 2098 2140 * This structure describes account configuration to be specified when … … 2385 2427 pj_str_t ka_data; 2386 2428 2387 #if defined(PJMEDIA_HAS_SRTP) && (PJMEDIA_HAS_SRTP != 0) 2429 /** 2430 * Maximum number of simultaneous active audio streams to be allowed 2431 * for calls on this account. Setting this to zero will disable audio 2432 * in calls on this account. 2433 * 2434 * Default: 1 2435 */ 2436 unsigned max_audio_cnt; 2437 2438 /** 2439 * Maximum number of simultaneous active video streams to be allowed 2440 * for calls on this account. Setting this to zero will disable video 2441 * in calls on this account. 2442 * 2443 * Default: 0 2444 */ 2445 unsigned max_video_cnt; 2446 2447 /** 2448 * Media transport config. 2449 */ 2450 pjsua_transport_config rtp_cfg; 2451 2388 2452 /** 2389 2453 * Specify whether secure media transport should be used for this account. … … 2409 2473 2410 2474 /** 2411 * Specify whether SRTP in PJMEDIA_SRTP_OPTIONAL mode should compose 2475 * Specify whether SRTP in PJMEDIA_SRTP_OPTIONAL mode should compose 2412 2476 * duplicated media in SDP offer, i.e: unsecured and secured version. 2413 * Otherwise, the SDP media will be composed as unsecured media but 2477 * Otherwise, the SDP media will be composed as unsecured media but 2414 2478 * with SDP "crypto" attribute. 2415 2479 * … … 2417 2481 */ 2418 2482 pj_bool_t srtp_optional_dup_offer; 2419 #endif2420 2483 2421 2484 /** … … 2921 2984 typedef enum pjsua_call_media_status 2922 2985 { 2923 /** Call currently has no media */ 2986 /** 2987 * Call currently has no media, or the media is not used. 2988 */ 2924 2989 PJSUA_CALL_MEDIA_NONE, 2925 2990 2926 /** The media is active */ 2991 /** 2992 * The media is active 2993 */ 2927 2994 PJSUA_CALL_MEDIA_ACTIVE, 2928 2995 2929 /** The media is currently put on hold by local endpoint */ 2996 /** 2997 * The media is currently put on hold by local endpoint 2998 */ 2930 2999 PJSUA_CALL_MEDIA_LOCAL_HOLD, 2931 3000 2932 /** The media is currently put on hold by remote endpoint */ 3001 /** 3002 * The media is currently put on hold by remote endpoint 3003 */ 2933 3004 PJSUA_CALL_MEDIA_REMOTE_HOLD, 2934 3005 2935 /** The media has reported error (e.g. ICE negotiation) */ 3006 /** 3007 * The media has reported error (e.g. ICE negotiation) 3008 */ 2936 3009 PJSUA_CALL_MEDIA_ERROR 2937 3010 … … 2983 3056 pjsua_call_media_status media_status; 2984 3057 2985 /** Media direction */ 3058 /** Number of active audio streams in this call */ 3059 unsigned audio_cnt; 3060 3061 /** Media direction of the first audio stream. */ 2986 3062 pjmedia_dir media_dir; 2987 3063 2988 /** The conference port number for the call*/3064 /** The conference port number for the first audio stream. */ 2989 3065 pjsua_conf_port_id conf_slot; 3066 3067 /** Array of audio media stream information */ 3068 struct 3069 { 3070 /** Media index in SDP. */ 3071 unsigned index; 3072 3073 /** Call media status. */ 3074 pjsua_call_media_status media_status; 3075 3076 /** Media direction. */ 3077 pjmedia_dir media_dir; 3078 3079 /** The conference port number for the call. */ 3080 pjsua_conf_port_id conf_slot; 3081 3082 } audio[4]; 2990 3083 2991 3084 /** Up-to-date call connected duration (zero when call is not … … 3083 3176 3084 3177 3178 #if DISABLED_FOR_TICKET_1185 3085 3179 /** 3086 3180 * Retrieve the media session associated with this call. Note that the media … … 3096 3190 PJ_DECL(pjmedia_session*) pjsua_call_get_media_session(pjsua_call_id call_id); 3097 3191 3098 3099 3192 /** 3100 3193 * Retrieve the media transport instance that is used for this call. … … 3107 3200 */ 3108 3201 PJ_DECL(pjmedia_transport*) pjsua_call_get_media_transport(pjsua_call_id cid); 3109 3202 #endif /* DISABLED_FOR_TICKET_1185 */ 3110 3203 3111 3204 /** … … 4883 4976 const pjmedia_codec_param *param); 4884 4977 4885 4886 4887 4978 #if DISABLED_FOR_TICKET_1185 4888 4979 /** 4889 4980 * Create UDP media transports for all the calls. This function creates … … 4917 5008 unsigned count, 4918 5009 pj_bool_t auto_delete); 5010 #endif 4919 5011 4920 5012
Note: See TracChangeset
for help on using the changeset viewer.