Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(661)

Unified Diff: webrtc/modules/audio_conference_mixer/include/audio_conference_mixer_defines.h

Issue 1986093002: Propagate muted info from VoE Channel to AudioConferenceMixer (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@mixer-mod-3
Patch Set: Fixing win build Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | webrtc/modules/audio_conference_mixer/source/audio_conference_mixer_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/modules/audio_conference_mixer/include/audio_conference_mixer_defines.h
diff --git a/webrtc/modules/audio_conference_mixer/include/audio_conference_mixer_defines.h b/webrtc/modules/audio_conference_mixer/include/audio_conference_mixer_defines.h
index 5d58f42435ef6ee6cfc302b3dcd57b74e744a075..e1c5aedc8870eda6f8869b5aa65e23c1438bd6e2 100644
--- a/webrtc/modules/audio_conference_mixer/include/audio_conference_mixer_defines.h
+++ b/webrtc/modules/audio_conference_mixer/include/audio_conference_mixer_defines.h
@@ -11,6 +11,7 @@
#ifndef WEBRTC_MODULES_AUDIO_CONFERENCE_MIXER_INCLUDE_AUDIO_CONFERENCE_MIXER_DEFINES_H_
#define WEBRTC_MODULES_AUDIO_CONFERENCE_MIXER_INCLUDE_AUDIO_CONFERENCE_MIXER_DEFINES_H_
+#include "webrtc/base/checks.h"
#include "webrtc/modules/include/module_common_types.h"
#include "webrtc/typedefs.h"
@@ -25,8 +26,34 @@ public:
// audio every time it's called.
//
// If it returns -1, the frame will not be added to the mix.
+ //
+ // NOTE: This function should not be called. It will remain for a short
+ // time so that subclasses can override it without getting warnings.
+ // TODO(henrik.lundin) Remove this function.
virtual int32_t GetAudioFrame(int32_t id,
- AudioFrame* audioFrame) = 0;
+ AudioFrame* audioFrame) {
+ RTC_CHECK(false);
+ return -1;
+ }
+
+
+ // The implementation of GetAudioFrameWithMuted should update audio_frame
+ // with new audio every time it's called. The return value will be
+ // interpreted as follows.
+ enum class AudioFrameInfo {
+ kNormal, // The samples in audio_frame are valid and should be used.
+ kMuted, // The samples in audio_frame should not be used, but should be
+ // implicitly interpreted as zero. Other fields in audio_frame
+ // may be read and should contain meaningful values.
+ kError // audio_frame will not be used.
+ };
+
+ virtual AudioFrameInfo GetAudioFrameWithMuted(int32_t id,
+ AudioFrame* audio_frame) {
+ return GetAudioFrame(id, audio_frame) == -1 ?
+ AudioFrameInfo::kError :
+ AudioFrameInfo::kNormal;
+ }
// Returns true if the participant was mixed this mix iteration.
bool IsMixed() const;
« no previous file with comments | « no previous file | webrtc/modules/audio_conference_mixer/source/audio_conference_mixer_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698