| 648 |
* Create an optimised media connection between this channel and another. This |
* Create an optimised media connection between this channel and another. This |
| 649 |
* will disconnect the current ipm connection and replace it with a half-duplex |
* will disconnect the current ipm connection and replace it with a half-duplex |
| 650 |
* connection to a device in 'other_channel'. |
* connection to a device in 'other_channel'. |
| 651 |
|
* WARNING: If a m3g device (H324) is bridged to conference, it will not be |
| 652 |
|
* possible to display a caption as this feature requires an ipm device. |
| 653 |
*/ |
*/ |
| 654 |
bool DialogicChannel::bridge( Channel* other_channel ) |
bool DialogicChannel::bridge( Channel* other_channel ) |
| 655 |
{ |
{ |
| 661 |
(other_channel->getProtocol() == PROTOCOL_CONF) || |
(other_channel->getProtocol() == PROTOCOL_CONF) || |
| 662 |
(other_channel->getProtocol() == PROTOCOL_H324) ) |
(other_channel->getProtocol() == PROTOCOL_H324) ) |
| 663 |
{ |
{ |
| 664 |
other_channel_ = other_channel; |
other_channel_ = static_cast<DialogicChannel*>(other_channel); |
| 665 |
onMediaEvent(new Event(EVT_CONNECT_OTHER)); |
onMediaEvent(new Event(EVT_CONNECT_OTHER)); |
| 666 |
return true; |
return true; |
| 667 |
} |
} |
| 947 |
|
|
| 948 |
|
|
| 949 |
/* |
/* |
| 950 |
* Handle an outbound call connected event from a dti or an ipt device, now |
* Handle an 'outbound' call connected event from a dti, ipt, confparty of m3g |
| 951 |
* connected the media. |
* device, now connected the media. |
| 952 |
*/ |
*/ |
| 953 |
void DialogicChannel::onConnect( const std::string& conn_type ) |
void DialogicChannel::onConnect( const std::string& conn_type ) |
| 954 |
{ |
{ |
| 1186 |
if ( ipt ) |
if ( ipt ) |
| 1187 |
{ |
{ |
| 1188 |
onMediaEvent(new Event(EVT_IPTIPM_CONNECTED)); |
onMediaEvent(new Event(EVT_IPTIPM_CONNECTED)); |
| 1189 |
|
|
| 1190 |
|
/* if this connection was made to as part of an optimised bridge to |
| 1191 |
|
* a conference channel, the original caption will no longer been seen |
| 1192 |
|
* (conf's ipm disconnected) so its regenerated here and overlayed on |
| 1193 |
|
* this ipm device. Note, this does not take into account the amount |
| 1194 |
|
* of time that the prognal caption has been shown. |
| 1195 |
|
*/ |
| 1196 |
|
if ( other_channel_ && (other_channel_->getProtocol() == PROTOCOL_CONF) ) |
| 1197 |
|
{ |
| 1198 |
|
ConfPartyDevice* confParty = other_channel_->getConfPartyDevice(); |
| 1199 |
|
ConfDevice* confDevice = other_channel_->getConfDevice(); |
| 1200 |
|
if ( confDevice && confParty ) |
| 1201 |
|
{ |
| 1202 |
|
if ( (confDevice->getCaptionDuration() > 0) && (!confParty->getCaption().empty()) ) |
| 1203 |
|
{ |
| 1204 |
|
confDevice->displayCaption(ipm, confParty->getCaption()); |
| 1205 |
|
} |
| 1206 |
|
} |
| 1207 |
|
} |
| 1208 |
} |
} |
| 1209 |
else |
else |
| 1210 |
{ |
{ |