Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
jami-daemon
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
savoirfairelinux
jami-daemon
Commits
b71c65d4
Commit
b71c65d4
authored
4 years ago
by
Sébastien Blin
Committed by
Adrien Béraud
4 years ago
Browse files
Options
Downloads
Patches
Plain Diff
conference: do not bind audio for muted participants
Change-Id: I9185ae55bd507b2b9869545928ad8792c81e4172 GitLab: #552
parent
0208aaa3
Branches
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/conference.cpp
+21
-4
21 additions, 4 deletions
src/conference.cpp
with
21 additions
and
4 deletions
src/conference.cpp
+
21
−
4
View file @
b71c65d4
...
@@ -443,7 +443,14 @@ Conference::attach()
...
@@ -443,7 +443,14 @@ Conference::attach()
if
(
getState
()
==
State
::
ACTIVE_DETACHED
)
{
if
(
getState
()
==
State
::
ACTIVE_DETACHED
)
{
auto
&
rbPool
=
Manager
::
instance
().
getRingBufferPool
();
auto
&
rbPool
=
Manager
::
instance
().
getRingBufferPool
();
for
(
const
auto
&
participant
:
getParticipantList
())
{
for
(
const
auto
&
participant
:
getParticipantList
())
{
if
(
auto
call
=
Manager
::
instance
().
getCallFromCallID
(
participant
))
{
if
(
isMuted
(
string_remove_suffix
(
call
->
getPeerNumber
(),
'@'
)))
rbPool
.
bindHalfDuplexOut
(
participant
,
RingBufferPool
::
DEFAULT_ID
);
else
rbPool
.
bindCallID
(
participant
,
RingBufferPool
::
DEFAULT_ID
);
rbPool
.
bindCallID
(
participant
,
RingBufferPool
::
DEFAULT_ID
);
rbPool
.
flush
(
participant
);
}
// Reset ringbuffer's readpointers
// Reset ringbuffer's readpointers
rbPool
.
flush
(
participant
);
rbPool
.
flush
(
participant
);
}
}
...
@@ -497,14 +504,24 @@ Conference::bindParticipant(const std::string& participant_id)
...
@@ -497,14 +504,24 @@ Conference::bindParticipant(const std::string& participant_id)
auto
&
rbPool
=
Manager
::
instance
().
getRingBufferPool
();
auto
&
rbPool
=
Manager
::
instance
().
getRingBufferPool
();
for
(
const
auto
&
item
:
participants_
)
{
for
(
const
auto
&
item
:
participants_
)
{
if
(
participant_id
!=
item
)
if
(
participant_id
!=
item
)
{
// Do not attach muted participants
if
(
auto
call
=
Manager
::
instance
().
getCallFromCallID
(
item
))
{
if
(
isMuted
(
string_remove_suffix
(
call
->
getPeerNumber
(),
'@'
)))
rbPool
.
bindHalfDuplexOut
(
item
,
participant_id
);
else
rbPool
.
bindCallID
(
participant_id
,
item
);
rbPool
.
bindCallID
(
participant_id
,
item
);
}
}
rbPool
.
flush
(
item
);
rbPool
.
flush
(
item
);
}
}
// Bind local participant to other participants only if the
// Bind local participant to other participants only if the
// local is attached to the conference.
// local is attached to the conference.
if
(
getState
()
==
State
::
ACTIVE_ATTACHED
)
{
if
(
getState
()
==
State
::
ACTIVE_ATTACHED
)
{
if
(
isMuted
(
"host"
sv
))
rbPool
.
bindHalfDuplexOut
(
RingBufferPool
::
DEFAULT_ID
,
participant_id
);
else
rbPool
.
bindCallID
(
participant_id
,
RingBufferPool
::
DEFAULT_ID
);
rbPool
.
bindCallID
(
participant_id
,
RingBufferPool
::
DEFAULT_ID
);
rbPool
.
flush
(
RingBufferPool
::
DEFAULT_ID
);
rbPool
.
flush
(
RingBufferPool
::
DEFAULT_ID
);
}
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment