mirror of
https://git.jami.net/savoirfairelinux/jami-daemon.git
synced 2025-08-12 22:09:25 +08:00
fix: conditionals for audio-only
Change-Id: Ic2796d22258e37ad531aec4e638196915e35969e Reviewed-by: Guillaume Roguez <guillaume.roguez@savoirfairelinux.com>
This commit is contained in:

committed by
Guillaume Roguez

parent
f8f13c8e64
commit
598caf5170
@ -526,7 +526,8 @@ RingAccount::onConnectedOutgoingCall(SIPCall& call, const std::string& to_id, Ip
|
||||
sdp.setPublishedIP(addrSdp);
|
||||
const bool created = sdp.createOffer(
|
||||
getActiveAccountCodecInfoList(MEDIA_AUDIO),
|
||||
getActiveAccountCodecInfoList(videoEnabled_ and call.isAudioOnly() ? MEDIA_NONE : MEDIA_VIDEO),
|
||||
getActiveAccountCodecInfoList(videoEnabled_ and not call.isAudioOnly() ? MEDIA_VIDEO
|
||||
: MEDIA_NONE),
|
||||
getSrtpKeyExchange()
|
||||
);
|
||||
|
||||
|
@ -232,7 +232,7 @@ SIPAccount::newOutgoingCall(const std::string& toUrl, const std::map<std::string
|
||||
|
||||
const bool created = sdp.createOffer(
|
||||
getActiveAccountCodecInfoList(MEDIA_AUDIO),
|
||||
getActiveAccountCodecInfoList(videoEnabled_ ? MEDIA_VIDEO : MEDIA_NONE),
|
||||
getActiveAccountCodecInfoList(videoEnabled_ and not call->isAudioOnly() ? MEDIA_VIDEO : MEDIA_NONE),
|
||||
getSrtpKeyExchange()
|
||||
);
|
||||
|
||||
|
@ -231,7 +231,8 @@ SIPCall::SIPSessionReinvite()
|
||||
sdp_->clearIce();
|
||||
auto& acc = getSIPAccount();
|
||||
if (not sdp_->createOffer(acc.getActiveAccountCodecInfoList(MEDIA_AUDIO),
|
||||
acc.getActiveAccountCodecInfoList(acc.isVideoEnabled() ? MEDIA_VIDEO : MEDIA_NONE),
|
||||
acc.getActiveAccountCodecInfoList(acc.isVideoEnabled() and not isAudioOnly() ? MEDIA_VIDEO
|
||||
: MEDIA_NONE),
|
||||
acc.getSrtpKeyExchange(),
|
||||
getState() == CallState::HOLD))
|
||||
return !PJ_SUCCESS;
|
||||
|
Reference in New Issue
Block a user