Moving smoothing into the audio level module. (#636)
This commit is contained in:
@@ -628,12 +628,12 @@ func (b *Buffer) GetDeltaStats() *StreamStatsWithLayers {
|
||||
}
|
||||
}
|
||||
|
||||
func (b *Buffer) GetAudioLevel() (uint8, bool) {
|
||||
func (b *Buffer) GetAudioLevel() (float64, bool) {
|
||||
b.RLock()
|
||||
defer b.RUnlock()
|
||||
|
||||
if b.audioLevel == nil {
|
||||
return audio.SilentAudioLevel, false
|
||||
return 0, false
|
||||
}
|
||||
|
||||
return b.audioLevel.GetLevel()
|
||||
|
||||
Reference in New Issue
Block a user