Changeset 3568 for pjproject/branches/1.x/pjmedia/src/pjmedia/jbuf.c
- Timestamp:
- May 18, 2011 6:59:23 AM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/branches/1.x/pjmedia/src/pjmedia/jbuf.c
r3561 r3568 120 120 continuously updated based on 121 121 current frame burst level. */ 122 pj_bool_t jb_prefetching; /**< flag if jbuf is prefetching. */ 122 123 int jb_status; /**< status is 'init' until the first 123 124 'put' operation */ … … 141 142 #define JB_STATUS_INITIALIZING 0 142 143 #define JB_STATUS_PROCESSING 1 143 #define JB_STATUS_PREFETCHING 2144 144 145 145 … … 551 551 jb->jb_init_cycle_cnt= 0; 552 552 jb->jb_max_hist_level= 0; 553 jb->jb_prefetching = (jb->jb_prefetch != 0); 553 554 554 555 jb_framelist_reset(&jb->jb_framelist); … … 861 862 862 863 if (status == PJ_SUCCESS) { 863 if (jb->jb_ status == JB_STATUS_PREFETCHING) {864 if (jb->jb_prefetching) { 864 865 TRACE__((jb->jb_name.ptr, "PUT prefetch_cnt=%d/%d", 865 866 new_size, jb->jb_prefetch)); 866 867 if (new_size >= jb->jb_prefetch) 867 jb->jb_ status = JB_STATUS_PROCESSING;868 jb->jb_prefetching = PJ_FALSE; 868 869 } 869 870 jb->jb_level += (new_size > cur_size ? new_size-cur_size : 1); … … 892 893 pj_uint32_t *bit_info) 893 894 { 894 if (jb->jb_ status == JB_STATUS_PREFETCHING) {895 if (jb->jb_prefetching) { 895 896 896 897 /* Can't return frame because jitter buffer is filling up … … 939 940 /* Jitter buffer is empty */ 940 941 if (jb->jb_prefetch) 941 jb->jb_ status = JB_STATUS_PREFETCHING;942 jb->jb_prefetching = PJ_TRUE; 942 943 943 944 //pj_bzero(frame, jb->jb_frame_size);
Note: See TracChangeset
for help on using the changeset viewer.