Changeset 731 for pjproject/trunk/pjmedia/src/pjmedia/conference.c
- Timestamp:
- Sep 20, 2006 8:02:18 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/trunk/pjmedia/src/pjmedia/conference.c
r655 r731 1267 1267 */ 1268 1268 static pj_status_t write_port(pjmedia_conf *conf, struct conf_port *cport, 1269 pj_uint32_t timestamp) 1269 pj_uint32_t timestamp, 1270 pjmedia_frame_type *frm_type) 1270 1271 { 1271 1272 pj_int16_t *buf; … … 1273 1274 pj_status_t status; 1274 1275 1276 *frm_type = PJMEDIA_FRAME_TYPE_AUDIO; 1277 1275 1278 /* If port is muted or nobody is transmitting to this port, 1276 1279 * transmit NULL frame. … … 1293 1296 1294 1297 cport->tx_level = 0; 1298 *frm_type = PJMEDIA_FRAME_TYPE_NONE; 1295 1299 return PJ_SUCCESS; 1296 1300 1297 1301 } else if (cport->tx_setting != PJMEDIA_PORT_ENABLE) { 1298 1302 cport->tx_level = 0; 1303 *frm_type = PJMEDIA_FRAME_TYPE_NONE; 1299 1304 return PJ_SUCCESS; 1300 1305 } … … 1487 1492 { 1488 1493 pjmedia_conf *conf = this_port->port_data.pdata; 1494 pjmedia_frame_type speaker_frame_type = PJMEDIA_FRAME_TYPE_NONE; 1489 1495 unsigned ci, cj, i, j; 1490 1496 … … 1684 1690 for (i=0, ci=0; i<conf->max_ports && ci<conf->port_cnt; ++i) { 1685 1691 struct conf_port *conf_port = conf->ports[i]; 1692 pjmedia_frame_type frm_type; 1686 1693 pj_status_t status; 1687 1694 … … 1692 1699 ++ci; 1693 1700 1694 status = write_port( conf, conf_port, frame->timestamp.u32.lo); 1701 status = write_port( conf, conf_port, frame->timestamp.u32.lo, 1702 &frm_type); 1695 1703 if (status != PJ_SUCCESS) { 1696 1704 /* bennylp: why do we need this???? … … 1709 1717 continue; 1710 1718 } 1719 1720 /* Set the type of frame to be returned to sound playback 1721 * device. 1722 */ 1723 if (i == 0) 1724 speaker_frame_type = frm_type; 1711 1725 } 1712 1726 … … 1723 1737 1724 1738 /* MUST set frame type */ 1725 frame->type = PJMEDIA_FRAME_TYPE_AUDIO;1739 frame->type = speaker_frame_type; 1726 1740 1727 1741 pj_mutex_unlock(conf->mutex); … … 1745 1759 { 1746 1760 pj_assert(0); 1761 PJ_UNUSED_ARG(this_port); 1762 PJ_UNUSED_ARG(frame); 1747 1763 return -1; 1748 1764 }
Note: See TracChangeset
for help on using the changeset viewer.