Add thread annotations to AudioLevel
This is a follow-up to https://codereview.webrtc.org/2984473002/. BUG=none TBR=henrika@webrtc.org Review-Url: https://codereview.webrtc.org/2998763002 Cr-Commit-Position: refs/heads/master@{#19306}
This commit is contained in:
parent
578c7c5940
commit
541280a8ca
@ -12,6 +12,7 @@
|
||||
#define WEBRTC_VOICE_ENGINE_AUDIO_LEVEL_H_
|
||||
|
||||
#include "webrtc/rtc_base/criticalsection.h"
|
||||
#include "webrtc/rtc_base/thread_annotations.h"
|
||||
#include "webrtc/typedefs.h"
|
||||
|
||||
namespace webrtc {
|
||||
@ -44,13 +45,13 @@ class AudioLevel {
|
||||
|
||||
rtc::CriticalSection crit_sect_;
|
||||
|
||||
int16_t abs_max_;
|
||||
int16_t count_;
|
||||
int8_t current_level_;
|
||||
int16_t current_level_full_range_;
|
||||
int16_t abs_max_ GUARDED_BY(crit_sect_);
|
||||
int16_t count_ GUARDED_BY(crit_sect_);
|
||||
int8_t current_level_ GUARDED_BY(crit_sect_);
|
||||
int16_t current_level_full_range_ GUARDED_BY(crit_sect_);
|
||||
|
||||
double total_energy_ = 0.0;
|
||||
double total_duration_ = 0.0;
|
||||
double total_energy_ GUARDED_BY(crit_sect_) = 0.0;
|
||||
double total_duration_ GUARDED_BY(crit_sect_) = 0.0;
|
||||
};
|
||||
|
||||
} // namespace voe
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user