| 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;
|
|
|