- Timestamp:
- Feb 23, 2009 10:21:33 AM (16 years ago)
- Location:
- pjproject/branches/projects/aps-direct/pjmedia/src
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/branches/projects/aps-direct/pjmedia/src/pjmedia-audiodev/wmme_dev.c
r2471 r2474 584 584 585 585 /* Done setting up play device. */ 586 PJ_LOG( 5, (THIS_FILE,586 PJ_LOG(4, (THIS_FILE, 587 587 " WaveAPI Sound player \"%s\" initialized (" 588 588 "format=%s, clock_rate=%d, " … … 664 664 665 665 /* Done setting up play device. */ 666 PJ_LOG( 5,(THIS_FILE,666 PJ_LOG(4,(THIS_FILE, 667 667 " WaveAPI Sound recorder \"%s\" initialized " 668 668 "(format=%s, clock_rate=%d, " … … 789 789 790 790 /* Get frame from application. */ 791 PJ_LOG(5,(THIS_FILE, "xxx %u play_cb", play_cnt++));791 //PJ_LOG(5,(THIS_FILE, "xxx %u play_cb", play_cnt++)); 792 792 status = (*strm->play_cb)(strm->user_data, frame); 793 793 … … 934 934 935 935 /* Call callback */ 936 PJ_LOG(5,(THIS_FILE, "xxx %u rec_cb", rec_cnt++));936 //PJ_LOG(5,(THIS_FILE, "xxx %u rec_cb", rec_cnt++)); 937 937 status = (*strm->rec_cb)(strm->user_data, frame); 938 938 if (status != PJ_SUCCESS) … … 1198 1198 return CONVERT_MM_ERROR(mr); 1199 1199 } 1200 PJ_LOG( 5,(THIS_FILE, "WMME playback stream started"));1200 PJ_LOG(4,(THIS_FILE, "WMME playback stream started")); 1201 1201 } 1202 1202 … … 1207 1207 return CONVERT_MM_ERROR(mr); 1208 1208 } 1209 PJ_LOG( 5,(THIS_FILE, "WMME capture stream started"));1209 PJ_LOG(4,(THIS_FILE, "WMME capture stream started")); 1210 1210 } 1211 1211 … … 1227 1227 return CONVERT_MM_ERROR(mr); 1228 1228 } 1229 PJ_LOG( 5,(THIS_FILE, "Stopped WMME playback stream"));1229 PJ_LOG(4,(THIS_FILE, "Stopped WMME playback stream")); 1230 1230 } 1231 1231 … … 1236 1236 return CONVERT_MM_ERROR(mr); 1237 1237 } 1238 PJ_LOG( 5,(THIS_FILE, "Stopped WMME capture stream"));1238 PJ_LOG(4,(THIS_FILE, "Stopped WMME capture stream")); 1239 1239 } 1240 1240 -
pjproject/branches/projects/aps-direct/pjmedia/src/pjmedia/sound_port.c
r2469 r2474 253 253 254 254 /* Create software EC if parameter specifies EC but device 255 * doesn't support EC 255 * doesn't support EC. Only do this if the format is PCM! 256 256 */ 257 257 if ((snd_port->aud_param.flags & PJMEDIA_AUD_DEV_CAP_EC) && 258 (snd_port->aud_caps & PJMEDIA_AUD_DEV_CAP_EC)==0) 258 (snd_port->aud_caps & PJMEDIA_AUD_DEV_CAP_EC)==0 && 259 param_copy.ext_fmt.id == PJMEDIA_FORMAT_PCM) 259 260 { 260 261 if ((snd_port->aud_param.flags & PJMEDIA_AUD_DEV_CAP_EC_TAIL)==0) { … … 532 533 } else { 533 534 /* We use software EC */ 534 /* Sound port must have 16bits per sample */535 PJ_ASSERT_RETURN(snd_port->bits_per_sample == 16,536 PJ_EINVALIDOP);537 535 538 536 /* Check if there is change in parameters */ … … 543 541 } 544 542 543 status = pjmedia_aud_stream_get_param(snd_port->aud_stream, &prm); 544 if (status != PJ_SUCCESS) 545 return status; 546 547 /* Audio stream must be in PCM format */ 548 PJ_ASSERT_RETURN(prm.ext_fmt.id == PJMEDIA_FORMAT_PCM, 549 PJ_EINVALIDOP); 550 545 551 /* Destroy AEC */ 546 552 if (snd_port->ec_state) { … … 549 555 } 550 556 551 snd_port->ec_options = options;552 snd_port->ec_tail_len = tail_ms;553 554 557 if (tail_ms != 0) { 555 558 unsigned delay_ms; 556 557 status = pjmedia_aud_stream_get_param(snd_port->aud_stream, &prm);558 if (status != PJ_SUCCESS)559 prm.input_latency_ms = prm.output_latency_ms = 0;560 559 561 560 //No need to add input latency in the latency calculation, … … 578 577 status = PJ_SUCCESS; 579 578 } 579 580 snd_port->ec_options = options; 581 snd_port->ec_tail_len = tail_ms; 580 582 } 581 583
Note: See TracChangeset
for help on using the changeset viewer.