1571 lines
37 KiB
Smali
1571 lines
37 KiB
Smali
.class public final Lco/discord/media_engine/VoiceQuality;
|
|
.super Ljava/lang/Object;
|
|
.source "VoiceQuality.kt"
|
|
|
|
|
|
# instance fields
|
|
.field public _duration:Lco/discord/media_engine/Duration;
|
|
|
|
.field public _inboundStats:Ljava/util/Map;
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"Ljava/util/Map<",
|
|
"Ljava/lang/String;",
|
|
"Lco/discord/media_engine/InboundAudio;",
|
|
">;"
|
|
}
|
|
.end annotation
|
|
.end field
|
|
|
|
.field public _outboundStats:Lco/discord/media_engine/OutboundAudio;
|
|
|
|
|
|
# direct methods
|
|
.method public constructor <init>()V
|
|
.locals 2
|
|
|
|
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
|
|
|
|
new-instance v0, Ljava/util/LinkedHashMap;
|
|
|
|
invoke-direct {v0}, Ljava/util/LinkedHashMap;-><init>()V
|
|
|
|
iput-object v0, p0, Lco/discord/media_engine/VoiceQuality;->_inboundStats:Ljava/util/Map;
|
|
|
|
new-instance v0, Lco/discord/media_engine/OutboundAudio;
|
|
|
|
const/4 v1, 0x0
|
|
|
|
invoke-direct {v0, v1, v1}, Lco/discord/media_engine/OutboundAudio;-><init>(II)V
|
|
|
|
iput-object v0, p0, Lco/discord/media_engine/VoiceQuality;->_outboundStats:Lco/discord/media_engine/OutboundAudio;
|
|
|
|
new-instance v0, Lco/discord/media_engine/Duration;
|
|
|
|
invoke-direct {v0, v1, v1, v1, v1}, Lco/discord/media_engine/Duration;-><init>(IIII)V
|
|
|
|
iput-object v0, p0, Lco/discord/media_engine/VoiceQuality;->_duration:Lco/discord/media_engine/Duration;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
|
|
# virtual methods
|
|
.method public final getBufferStats(Ljava/util/Map;)V
|
|
.locals 6
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"(",
|
|
"Ljava/util/Map<",
|
|
"Ljava/lang/String;",
|
|
"Ljava/lang/Object;",
|
|
">;)V"
|
|
}
|
|
.end annotation
|
|
|
|
const/4 v0, 0x0
|
|
|
|
if-eqz p1, :cond_8
|
|
|
|
iget-object v1, p0, Lco/discord/media_engine/VoiceQuality;->_inboundStats:Ljava/util/Map;
|
|
|
|
invoke-interface {v1}, Ljava/util/Map;->entrySet()Ljava/util/Set;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-interface {v1}, Ljava/util/Set;->iterator()Ljava/util/Iterator;
|
|
|
|
move-result-object v1
|
|
|
|
move-object v2, v0
|
|
|
|
:cond_0
|
|
:goto_0
|
|
invoke-interface {v1}, Ljava/util/Iterator;->hasNext()Z
|
|
|
|
move-result v3
|
|
|
|
if-eqz v3, :cond_2
|
|
|
|
invoke-interface {v1}, Ljava/util/Iterator;->next()Ljava/lang/Object;
|
|
|
|
move-result-object v3
|
|
|
|
check-cast v3, Ljava/util/Map$Entry;
|
|
|
|
invoke-interface {v3}, Ljava/util/Map$Entry;->getValue()Ljava/lang/Object;
|
|
|
|
move-result-object v3
|
|
|
|
check-cast v3, Lco/discord/media_engine/InboundAudio;
|
|
|
|
if-nez v2, :cond_1
|
|
|
|
invoke-virtual {v3}, Lco/discord/media_engine/InboundAudio;->getBufferStats()Lco/discord/media_engine/InboundBufferStats;
|
|
|
|
move-result-object v2
|
|
|
|
goto :goto_0
|
|
|
|
:cond_1
|
|
invoke-virtual {v2}, Lco/discord/media_engine/InboundBufferStats;->getAudioJitterBuffer()Lco/discord/media_engine/PlayoutMetric;
|
|
|
|
move-result-object v4
|
|
|
|
if-eqz v4, :cond_0
|
|
|
|
invoke-virtual {v3}, Lco/discord/media_engine/InboundAudio;->getBufferStats()Lco/discord/media_engine/InboundBufferStats;
|
|
|
|
move-result-object v5
|
|
|
|
invoke-virtual {v5}, Lco/discord/media_engine/InboundBufferStats;->getAudioJitterBuffer()Lco/discord/media_engine/PlayoutMetric;
|
|
|
|
move-result-object v5
|
|
|
|
if-eqz v5, :cond_0
|
|
|
|
invoke-virtual {v5}, Lco/discord/media_engine/PlayoutMetric;->getP75()F
|
|
|
|
move-result v5
|
|
|
|
invoke-virtual {v4}, Lco/discord/media_engine/PlayoutMetric;->getP75()F
|
|
|
|
move-result v4
|
|
|
|
cmpl-float v4, v5, v4
|
|
|
|
if-lez v4, :cond_0
|
|
|
|
invoke-virtual {v3}, Lco/discord/media_engine/InboundAudio;->getBufferStats()Lco/discord/media_engine/InboundBufferStats;
|
|
|
|
move-result-object v2
|
|
|
|
goto :goto_0
|
|
|
|
:cond_2
|
|
if-eqz v2, :cond_3
|
|
|
|
invoke-virtual {v2}, Lco/discord/media_engine/InboundBufferStats;->getAudioJitterBuffer()Lco/discord/media_engine/PlayoutMetric;
|
|
|
|
move-result-object v1
|
|
|
|
goto :goto_1
|
|
|
|
:cond_3
|
|
move-object v1, v0
|
|
|
|
:goto_1
|
|
const-string v3, "audio_jitter_buffer"
|
|
|
|
invoke-static {v3, v1, p1}, Lco/discord/media_engine/VoiceQualityKt;->access$explodePlayoutMetric(Ljava/lang/String;Lco/discord/media_engine/PlayoutMetric;Ljava/util/Map;)V
|
|
|
|
if-eqz v2, :cond_4
|
|
|
|
invoke-virtual {v2}, Lco/discord/media_engine/InboundBufferStats;->getAudioJitterTarget()Lco/discord/media_engine/PlayoutMetric;
|
|
|
|
move-result-object v1
|
|
|
|
goto :goto_2
|
|
|
|
:cond_4
|
|
move-object v1, v0
|
|
|
|
:goto_2
|
|
const-string v3, "audio_jitter_target"
|
|
|
|
invoke-static {v3, v1, p1}, Lco/discord/media_engine/VoiceQualityKt;->access$explodePlayoutMetric(Ljava/lang/String;Lco/discord/media_engine/PlayoutMetric;Ljava/util/Map;)V
|
|
|
|
if-eqz v2, :cond_5
|
|
|
|
invoke-virtual {v2}, Lco/discord/media_engine/InboundBufferStats;->getAudioJitterDelay()Lco/discord/media_engine/PlayoutMetric;
|
|
|
|
move-result-object v1
|
|
|
|
goto :goto_3
|
|
|
|
:cond_5
|
|
move-object v1, v0
|
|
|
|
:goto_3
|
|
const-string v3, "audio_jitter_delay"
|
|
|
|
invoke-static {v3, v1, p1}, Lco/discord/media_engine/VoiceQualityKt;->access$explodePlayoutMetric(Ljava/lang/String;Lco/discord/media_engine/PlayoutMetric;Ljava/util/Map;)V
|
|
|
|
if-eqz v2, :cond_6
|
|
|
|
invoke-virtual {v2}, Lco/discord/media_engine/InboundBufferStats;->getRelativeReceptionDelay()Lco/discord/media_engine/PlayoutMetric;
|
|
|
|
move-result-object v1
|
|
|
|
goto :goto_4
|
|
|
|
:cond_6
|
|
move-object v1, v0
|
|
|
|
:goto_4
|
|
const-string v3, "relative_reception_delay"
|
|
|
|
invoke-static {v3, v1, p1}, Lco/discord/media_engine/VoiceQualityKt;->access$explodePlayoutMetric(Ljava/lang/String;Lco/discord/media_engine/PlayoutMetric;Ljava/util/Map;)V
|
|
|
|
if-eqz v2, :cond_7
|
|
|
|
invoke-virtual {v2}, Lco/discord/media_engine/InboundBufferStats;->getRelativePlayoutDelay()Lco/discord/media_engine/PlayoutMetric;
|
|
|
|
move-result-object v0
|
|
|
|
:cond_7
|
|
const-string v1, "relative_playout_delay"
|
|
|
|
invoke-static {v1, v0, p1}, Lco/discord/media_engine/VoiceQualityKt;->access$explodePlayoutMetric(Ljava/lang/String;Lco/discord/media_engine/PlayoutMetric;Ljava/util/Map;)V
|
|
|
|
return-void
|
|
|
|
:cond_8
|
|
const-string p1, "result"
|
|
|
|
invoke-static {p1}, Li0/n/c/h;->c(Ljava/lang/String;)V
|
|
|
|
throw v0
|
|
.end method
|
|
|
|
.method public final getDurationStats(Ljava/util/Map;)V
|
|
.locals 2
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"(",
|
|
"Ljava/util/Map<",
|
|
"Ljava/lang/String;",
|
|
"Ljava/lang/Object;",
|
|
">;)V"
|
|
}
|
|
.end annotation
|
|
|
|
if-eqz p1, :cond_0
|
|
|
|
iget-object v0, p0, Lco/discord/media_engine/VoiceQuality;->_duration:Lco/discord/media_engine/Duration;
|
|
|
|
invoke-virtual {v0}, Lco/discord/media_engine/Duration;->getListening()I
|
|
|
|
move-result v0
|
|
|
|
invoke-static {v0}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v0
|
|
|
|
const-string v1, "duration_listening"
|
|
|
|
invoke-interface {p1, v1, v0}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
iget-object v0, p0, Lco/discord/media_engine/VoiceQuality;->_duration:Lco/discord/media_engine/Duration;
|
|
|
|
invoke-virtual {v0}, Lco/discord/media_engine/Duration;->getSpeaking()I
|
|
|
|
move-result v0
|
|
|
|
invoke-static {v0}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v0
|
|
|
|
const-string v1, "duration_speaking"
|
|
|
|
invoke-interface {p1, v1, v0}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
iget-object v0, p0, Lco/discord/media_engine/VoiceQuality;->_duration:Lco/discord/media_engine/Duration;
|
|
|
|
invoke-virtual {v0}, Lco/discord/media_engine/Duration;->getParticipation()I
|
|
|
|
move-result v0
|
|
|
|
invoke-static {v0}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v0
|
|
|
|
const-string v1, "duration_participation"
|
|
|
|
invoke-interface {p1, v1, v0}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
iget-object v0, p0, Lco/discord/media_engine/VoiceQuality;->_duration:Lco/discord/media_engine/Duration;
|
|
|
|
invoke-virtual {v0}, Lco/discord/media_engine/Duration;->getConnected()I
|
|
|
|
move-result v0
|
|
|
|
invoke-static {v0}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v0
|
|
|
|
const-string v1, "duration_connected"
|
|
|
|
invoke-interface {p1, v1, v0}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
return-void
|
|
|
|
:cond_0
|
|
const-string p1, "result"
|
|
|
|
invoke-static {p1}, Li0/n/c/h;->c(Ljava/lang/String;)V
|
|
|
|
const/4 p1, 0x0
|
|
|
|
throw p1
|
|
.end method
|
|
|
|
.method public final getFrameOpStats(Ljava/util/Map;)V
|
|
.locals 11
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"(",
|
|
"Ljava/util/Map<",
|
|
"Ljava/lang/String;",
|
|
"Ljava/lang/Object;",
|
|
">;)V"
|
|
}
|
|
.end annotation
|
|
|
|
const/4 v0, 0x0
|
|
|
|
if-eqz p1, :cond_16
|
|
|
|
iget-object v1, p0, Lco/discord/media_engine/VoiceQuality;->_inboundStats:Ljava/util/Map;
|
|
|
|
invoke-interface {v1}, Ljava/util/Map;->entrySet()Ljava/util/Set;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-interface {v1}, Ljava/util/Set;->iterator()Ljava/util/Iterator;
|
|
|
|
move-result-object v1
|
|
|
|
move-object v2, v0
|
|
|
|
move-object v3, v2
|
|
|
|
move-object v4, v3
|
|
|
|
move-object v5, v4
|
|
|
|
move-object v6, v5
|
|
|
|
move-object v7, v6
|
|
|
|
:cond_0
|
|
:goto_0
|
|
invoke-interface {v1}, Ljava/util/Iterator;->hasNext()Z
|
|
|
|
move-result v8
|
|
|
|
if-eqz v8, :cond_e
|
|
|
|
invoke-interface {v1}, Ljava/util/Iterator;->next()Ljava/lang/Object;
|
|
|
|
move-result-object v8
|
|
|
|
check-cast v8, Ljava/util/Map$Entry;
|
|
|
|
invoke-interface {v8}, Ljava/util/Map$Entry;->getValue()Ljava/lang/Object;
|
|
|
|
move-result-object v8
|
|
|
|
check-cast v8, Lco/discord/media_engine/InboundAudio;
|
|
|
|
invoke-virtual {v8}, Lco/discord/media_engine/InboundAudio;->getFrameOpStats()Lco/discord/media_engine/InboundFrameOpStats;
|
|
|
|
move-result-object v9
|
|
|
|
invoke-virtual {v9}, Lco/discord/media_engine/InboundFrameOpStats;->getSilent()Ljava/lang/Integer;
|
|
|
|
move-result-object v9
|
|
|
|
const/4 v10, 0x0
|
|
|
|
if-eqz v9, :cond_2
|
|
|
|
invoke-virtual {v9}, Ljava/lang/Number;->intValue()I
|
|
|
|
move-result v9
|
|
|
|
if-eqz v0, :cond_1
|
|
|
|
invoke-virtual {v0}, Ljava/lang/Integer;->intValue()I
|
|
|
|
move-result v0
|
|
|
|
goto :goto_1
|
|
|
|
:cond_1
|
|
const/4 v0, 0x0
|
|
|
|
:goto_1
|
|
add-int/2addr v0, v9
|
|
|
|
invoke-static {v0}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v0
|
|
|
|
:cond_2
|
|
invoke-virtual {v8}, Lco/discord/media_engine/InboundAudio;->getFrameOpStats()Lco/discord/media_engine/InboundFrameOpStats;
|
|
|
|
move-result-object v9
|
|
|
|
invoke-virtual {v9}, Lco/discord/media_engine/InboundFrameOpStats;->getNormal()Ljava/lang/Integer;
|
|
|
|
move-result-object v9
|
|
|
|
if-eqz v9, :cond_4
|
|
|
|
invoke-virtual {v9}, Ljava/lang/Number;->intValue()I
|
|
|
|
move-result v9
|
|
|
|
if-eqz v2, :cond_3
|
|
|
|
invoke-virtual {v2}, Ljava/lang/Integer;->intValue()I
|
|
|
|
move-result v2
|
|
|
|
goto :goto_2
|
|
|
|
:cond_3
|
|
const/4 v2, 0x0
|
|
|
|
:goto_2
|
|
add-int/2addr v2, v9
|
|
|
|
invoke-static {v2}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v2
|
|
|
|
:cond_4
|
|
invoke-virtual {v8}, Lco/discord/media_engine/InboundAudio;->getFrameOpStats()Lco/discord/media_engine/InboundFrameOpStats;
|
|
|
|
move-result-object v9
|
|
|
|
invoke-virtual {v9}, Lco/discord/media_engine/InboundFrameOpStats;->getMerged()Ljava/lang/Integer;
|
|
|
|
move-result-object v9
|
|
|
|
if-eqz v9, :cond_6
|
|
|
|
invoke-virtual {v9}, Ljava/lang/Number;->intValue()I
|
|
|
|
move-result v9
|
|
|
|
if-eqz v3, :cond_5
|
|
|
|
invoke-virtual {v3}, Ljava/lang/Integer;->intValue()I
|
|
|
|
move-result v3
|
|
|
|
goto :goto_3
|
|
|
|
:cond_5
|
|
const/4 v3, 0x0
|
|
|
|
:goto_3
|
|
add-int/2addr v3, v9
|
|
|
|
invoke-static {v3}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v3
|
|
|
|
:cond_6
|
|
invoke-virtual {v8}, Lco/discord/media_engine/InboundAudio;->getFrameOpStats()Lco/discord/media_engine/InboundFrameOpStats;
|
|
|
|
move-result-object v9
|
|
|
|
invoke-virtual {v9}, Lco/discord/media_engine/InboundFrameOpStats;->getExpanded()Ljava/lang/Integer;
|
|
|
|
move-result-object v9
|
|
|
|
if-eqz v9, :cond_8
|
|
|
|
invoke-virtual {v9}, Ljava/lang/Number;->intValue()I
|
|
|
|
move-result v9
|
|
|
|
if-eqz v4, :cond_7
|
|
|
|
invoke-virtual {v4}, Ljava/lang/Integer;->intValue()I
|
|
|
|
move-result v4
|
|
|
|
goto :goto_4
|
|
|
|
:cond_7
|
|
const/4 v4, 0x0
|
|
|
|
:goto_4
|
|
add-int/2addr v4, v9
|
|
|
|
invoke-static {v4}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v4
|
|
|
|
:cond_8
|
|
invoke-virtual {v8}, Lco/discord/media_engine/InboundAudio;->getFrameOpStats()Lco/discord/media_engine/InboundFrameOpStats;
|
|
|
|
move-result-object v9
|
|
|
|
invoke-virtual {v9}, Lco/discord/media_engine/InboundFrameOpStats;->getAccelerated()Ljava/lang/Integer;
|
|
|
|
move-result-object v9
|
|
|
|
if-eqz v9, :cond_a
|
|
|
|
invoke-virtual {v9}, Ljava/lang/Number;->intValue()I
|
|
|
|
move-result v9
|
|
|
|
if-eqz v5, :cond_9
|
|
|
|
invoke-virtual {v5}, Ljava/lang/Integer;->intValue()I
|
|
|
|
move-result v5
|
|
|
|
goto :goto_5
|
|
|
|
:cond_9
|
|
const/4 v5, 0x0
|
|
|
|
:goto_5
|
|
add-int/2addr v5, v9
|
|
|
|
invoke-static {v5}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v5
|
|
|
|
:cond_a
|
|
invoke-virtual {v8}, Lco/discord/media_engine/InboundAudio;->getFrameOpStats()Lco/discord/media_engine/InboundFrameOpStats;
|
|
|
|
move-result-object v9
|
|
|
|
invoke-virtual {v9}, Lco/discord/media_engine/InboundFrameOpStats;->getPreemptiveExpanded()Ljava/lang/Integer;
|
|
|
|
move-result-object v9
|
|
|
|
if-eqz v9, :cond_c
|
|
|
|
invoke-virtual {v9}, Ljava/lang/Number;->intValue()I
|
|
|
|
move-result v9
|
|
|
|
if-eqz v6, :cond_b
|
|
|
|
invoke-virtual {v6}, Ljava/lang/Integer;->intValue()I
|
|
|
|
move-result v6
|
|
|
|
goto :goto_6
|
|
|
|
:cond_b
|
|
const/4 v6, 0x0
|
|
|
|
:goto_6
|
|
add-int/2addr v6, v9
|
|
|
|
invoke-static {v6}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v6
|
|
|
|
:cond_c
|
|
invoke-virtual {v8}, Lco/discord/media_engine/InboundAudio;->getFrameOpStats()Lco/discord/media_engine/InboundFrameOpStats;
|
|
|
|
move-result-object v8
|
|
|
|
invoke-virtual {v8}, Lco/discord/media_engine/InboundFrameOpStats;->getCng()Ljava/lang/Integer;
|
|
|
|
move-result-object v8
|
|
|
|
if-eqz v8, :cond_0
|
|
|
|
invoke-virtual {v8}, Ljava/lang/Number;->intValue()I
|
|
|
|
move-result v8
|
|
|
|
if-eqz v7, :cond_d
|
|
|
|
invoke-virtual {v7}, Ljava/lang/Integer;->intValue()I
|
|
|
|
move-result v10
|
|
|
|
:cond_d
|
|
add-int/2addr v10, v8
|
|
|
|
invoke-static {v10}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v7
|
|
|
|
goto/16 :goto_0
|
|
|
|
:cond_e
|
|
if-eqz v0, :cond_f
|
|
|
|
invoke-virtual {v0}, Ljava/lang/Number;->intValue()I
|
|
|
|
move-result v0
|
|
|
|
invoke-static {v0}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v0
|
|
|
|
const-string v1, "frame_op_silent"
|
|
|
|
invoke-interface {p1, v1, v0}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
:cond_f
|
|
if-eqz v2, :cond_10
|
|
|
|
invoke-virtual {v2}, Ljava/lang/Number;->intValue()I
|
|
|
|
move-result v0
|
|
|
|
invoke-static {v0}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v0
|
|
|
|
const-string v1, "frame_op_normal"
|
|
|
|
invoke-interface {p1, v1, v0}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
:cond_10
|
|
if-eqz v3, :cond_11
|
|
|
|
invoke-virtual {v3}, Ljava/lang/Number;->intValue()I
|
|
|
|
move-result v0
|
|
|
|
invoke-static {v0}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v0
|
|
|
|
const-string v1, "frame_op_merged"
|
|
|
|
invoke-interface {p1, v1, v0}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
:cond_11
|
|
if-eqz v4, :cond_12
|
|
|
|
invoke-virtual {v4}, Ljava/lang/Number;->intValue()I
|
|
|
|
move-result v0
|
|
|
|
invoke-static {v0}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v0
|
|
|
|
const-string v1, "frame_op_expanded"
|
|
|
|
invoke-interface {p1, v1, v0}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
:cond_12
|
|
if-eqz v5, :cond_13
|
|
|
|
invoke-virtual {v5}, Ljava/lang/Number;->intValue()I
|
|
|
|
move-result v0
|
|
|
|
invoke-static {v0}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v0
|
|
|
|
const-string v1, "frame_op_accelerated"
|
|
|
|
invoke-interface {p1, v1, v0}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
:cond_13
|
|
if-eqz v6, :cond_14
|
|
|
|
invoke-virtual {v6}, Ljava/lang/Number;->intValue()I
|
|
|
|
move-result v0
|
|
|
|
invoke-static {v0}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v0
|
|
|
|
const-string v1, "frame_op_preemptive_expanded"
|
|
|
|
invoke-interface {p1, v1, v0}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
:cond_14
|
|
if-eqz v7, :cond_15
|
|
|
|
invoke-virtual {v7}, Ljava/lang/Number;->intValue()I
|
|
|
|
move-result v0
|
|
|
|
invoke-static {v0}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v0
|
|
|
|
const-string v1, "frame_op_cng"
|
|
|
|
invoke-interface {p1, v1, v0}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
:cond_15
|
|
return-void
|
|
|
|
:cond_16
|
|
const-string p1, "result"
|
|
|
|
invoke-static {p1}, Li0/n/c/h;->c(Ljava/lang/String;)V
|
|
|
|
throw v0
|
|
.end method
|
|
|
|
.method public final getMosStats(Ljava/util/Map;)V
|
|
.locals 14
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"(",
|
|
"Ljava/util/Map<",
|
|
"Ljava/lang/String;",
|
|
"Ljava/lang/Object;",
|
|
">;)V"
|
|
}
|
|
.end annotation
|
|
|
|
if-eqz p1, :cond_3
|
|
|
|
const-wide/16 v0, 0x0
|
|
|
|
const/4 v2, 0x5
|
|
|
|
new-array v2, v2, [Ljava/lang/Integer;
|
|
|
|
const/4 v3, 0x0
|
|
|
|
invoke-static {v3}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v4
|
|
|
|
aput-object v4, v2, v3
|
|
|
|
invoke-static {v3}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v4
|
|
|
|
const/4 v5, 0x1
|
|
|
|
aput-object v4, v2, v5
|
|
|
|
invoke-static {v3}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v4
|
|
|
|
const/4 v6, 0x2
|
|
|
|
aput-object v4, v2, v6
|
|
|
|
invoke-static {v3}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v4
|
|
|
|
const/4 v7, 0x3
|
|
|
|
aput-object v4, v2, v7
|
|
|
|
invoke-static {v3}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v4
|
|
|
|
const/4 v8, 0x4
|
|
|
|
aput-object v4, v2, v8
|
|
|
|
iget-object v4, p0, Lco/discord/media_engine/VoiceQuality;->_inboundStats:Ljava/util/Map;
|
|
|
|
invoke-interface {v4}, Ljava/util/Map;->entrySet()Ljava/util/Set;
|
|
|
|
move-result-object v4
|
|
|
|
invoke-interface {v4}, Ljava/util/Set;->iterator()Ljava/util/Iterator;
|
|
|
|
move-result-object v4
|
|
|
|
const/4 v9, 0x0
|
|
|
|
:cond_0
|
|
invoke-interface {v4}, Ljava/util/Iterator;->hasNext()Z
|
|
|
|
move-result v10
|
|
|
|
if-eqz v10, :cond_1
|
|
|
|
invoke-interface {v4}, Ljava/util/Iterator;->next()Ljava/lang/Object;
|
|
|
|
move-result-object v10
|
|
|
|
check-cast v10, Ljava/util/Map$Entry;
|
|
|
|
invoke-interface {v10}, Ljava/util/Map$Entry;->getValue()Ljava/lang/Object;
|
|
|
|
move-result-object v10
|
|
|
|
check-cast v10, Lco/discord/media_engine/InboundAudio;
|
|
|
|
invoke-virtual {v10}, Lco/discord/media_engine/InboundAudio;->getMosSum()D
|
|
|
|
move-result-wide v11
|
|
|
|
add-double/2addr v0, v11
|
|
|
|
invoke-virtual {v10}, Lco/discord/media_engine/InboundAudio;->getMosCount()I
|
|
|
|
move-result v11
|
|
|
|
add-int/2addr v9, v11
|
|
|
|
const/4 v11, 0x0
|
|
|
|
:goto_0
|
|
if-gt v11, v8, :cond_0
|
|
|
|
aget-object v12, v2, v11
|
|
|
|
invoke-virtual {v12}, Ljava/lang/Integer;->intValue()I
|
|
|
|
move-result v12
|
|
|
|
invoke-virtual {v10}, Lco/discord/media_engine/InboundAudio;->getMosBuckets()[Ljava/lang/Integer;
|
|
|
|
move-result-object v13
|
|
|
|
aget-object v13, v13, v11
|
|
|
|
invoke-virtual {v13}, Ljava/lang/Integer;->intValue()I
|
|
|
|
move-result v13
|
|
|
|
add-int/2addr v13, v12
|
|
|
|
invoke-static {v13}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v12
|
|
|
|
aput-object v12, v2, v11
|
|
|
|
add-int/lit8 v11, v11, 0x1
|
|
|
|
goto :goto_0
|
|
|
|
:cond_1
|
|
if-lez v9, :cond_2
|
|
|
|
int-to-double v3, v9
|
|
|
|
div-double/2addr v0, v3
|
|
|
|
invoke-static {v0, v1}, Ljava/lang/Double;->valueOf(D)Ljava/lang/Double;
|
|
|
|
move-result-object v0
|
|
|
|
goto :goto_1
|
|
|
|
:cond_2
|
|
invoke-static {v3}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v0
|
|
|
|
:goto_1
|
|
const-string v1, "mos_mean"
|
|
|
|
invoke-interface {p1, v1, v0}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
aget-object v0, v2, v5
|
|
|
|
const-string v1, "mos_1"
|
|
|
|
invoke-interface {p1, v1, v0}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
aget-object v0, v2, v6
|
|
|
|
const-string v1, "mos_2"
|
|
|
|
invoke-interface {p1, v1, v0}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
aget-object v0, v2, v7
|
|
|
|
const-string v1, "mos_3"
|
|
|
|
invoke-interface {p1, v1, v0}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
aget-object v0, v2, v8
|
|
|
|
const-string v1, "mos_4"
|
|
|
|
invoke-interface {p1, v1, v0}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
return-void
|
|
|
|
:cond_3
|
|
const-string p1, "result"
|
|
|
|
invoke-static {p1}, Li0/n/c/h;->c(Ljava/lang/String;)V
|
|
|
|
const/4 p1, 0x0
|
|
|
|
throw p1
|
|
.end method
|
|
|
|
.method public final getPacketStats(Ljava/util/Map;)V
|
|
.locals 5
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"(",
|
|
"Ljava/util/Map<",
|
|
"Ljava/lang/String;",
|
|
"Ljava/lang/Object;",
|
|
">;)V"
|
|
}
|
|
.end annotation
|
|
|
|
if-eqz p1, :cond_1
|
|
|
|
iget-object v0, p0, Lco/discord/media_engine/VoiceQuality;->_inboundStats:Ljava/util/Map;
|
|
|
|
invoke-interface {v0}, Ljava/util/Map;->entrySet()Ljava/util/Set;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-interface {v0}, Ljava/util/Set;->iterator()Ljava/util/Iterator;
|
|
|
|
move-result-object v0
|
|
|
|
const/4 v1, 0x0
|
|
|
|
const/4 v2, 0x0
|
|
|
|
:goto_0
|
|
invoke-interface {v0}, Ljava/util/Iterator;->hasNext()Z
|
|
|
|
move-result v3
|
|
|
|
if-eqz v3, :cond_0
|
|
|
|
invoke-interface {v0}, Ljava/util/Iterator;->next()Ljava/lang/Object;
|
|
|
|
move-result-object v3
|
|
|
|
check-cast v3, Ljava/util/Map$Entry;
|
|
|
|
invoke-interface {v3}, Ljava/util/Map$Entry;->getValue()Ljava/lang/Object;
|
|
|
|
move-result-object v3
|
|
|
|
check-cast v3, Lco/discord/media_engine/InboundAudio;
|
|
|
|
invoke-virtual {v3}, Lco/discord/media_engine/InboundAudio;->getPacketsReceived()I
|
|
|
|
move-result v4
|
|
|
|
add-int/2addr v1, v4
|
|
|
|
invoke-virtual {v3}, Lco/discord/media_engine/InboundAudio;->getPacketsLost()I
|
|
|
|
move-result v3
|
|
|
|
add-int/2addr v2, v3
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
iget-object v0, p0, Lco/discord/media_engine/VoiceQuality;->_outboundStats:Lco/discord/media_engine/OutboundAudio;
|
|
|
|
invoke-virtual {v0}, Lco/discord/media_engine/OutboundAudio;->getPacketsSent()I
|
|
|
|
move-result v0
|
|
|
|
invoke-static {v0}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v0
|
|
|
|
const-string v3, "packets_sent"
|
|
|
|
invoke-interface {p1, v3, v0}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
iget-object v0, p0, Lco/discord/media_engine/VoiceQuality;->_outboundStats:Lco/discord/media_engine/OutboundAudio;
|
|
|
|
invoke-virtual {v0}, Lco/discord/media_engine/OutboundAudio;->getPacketsLost()I
|
|
|
|
move-result v0
|
|
|
|
invoke-static {v0}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v0
|
|
|
|
const-string v3, "packets_sent_lost"
|
|
|
|
invoke-interface {p1, v3, v0}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
invoke-static {v1}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v0
|
|
|
|
const-string v1, "packets_received"
|
|
|
|
invoke-interface {p1, v1, v0}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
invoke-static {v2}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v0
|
|
|
|
const-string v1, "packets_received_lost"
|
|
|
|
invoke-interface {p1, v1, v0}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
return-void
|
|
|
|
:cond_1
|
|
const-string p1, "result"
|
|
|
|
invoke-static {p1}, Li0/n/c/h;->c(Ljava/lang/String;)V
|
|
|
|
const/4 p1, 0x0
|
|
|
|
throw p1
|
|
.end method
|
|
|
|
.method public final update(Lco/discord/media_engine/Stats;)V
|
|
.locals 34
|
|
|
|
move-object/from16 v0, p0
|
|
|
|
if-eqz p1, :cond_c
|
|
|
|
iget-object v1, v0, Lco/discord/media_engine/VoiceQuality;->_duration:Lco/discord/media_engine/Duration;
|
|
|
|
invoke-virtual {v1}, Lco/discord/media_engine/Duration;->getConnected()I
|
|
|
|
move-result v2
|
|
|
|
const/4 v3, 0x1
|
|
|
|
add-int/2addr v2, v3
|
|
|
|
invoke-virtual {v1, v2}, Lco/discord/media_engine/Duration;->setConnected(I)V
|
|
|
|
iget-object v1, v0, Lco/discord/media_engine/VoiceQuality;->_outboundStats:Lco/discord/media_engine/OutboundAudio;
|
|
|
|
invoke-virtual {v1}, Lco/discord/media_engine/OutboundAudio;->getPacketsSent()I
|
|
|
|
move-result v1
|
|
|
|
iget-object v2, v0, Lco/discord/media_engine/VoiceQuality;->_inboundStats:Ljava/util/Map;
|
|
|
|
invoke-interface {v2}, Ljava/util/Map;->entrySet()Ljava/util/Set;
|
|
|
|
move-result-object v2
|
|
|
|
invoke-interface {v2}, Ljava/util/Set;->iterator()Ljava/util/Iterator;
|
|
|
|
move-result-object v2
|
|
|
|
const/4 v4, 0x0
|
|
|
|
const/4 v5, 0x0
|
|
|
|
:goto_0
|
|
invoke-interface {v2}, Ljava/util/Iterator;->hasNext()Z
|
|
|
|
move-result v6
|
|
|
|
if-eqz v6, :cond_0
|
|
|
|
invoke-interface {v2}, Ljava/util/Iterator;->next()Ljava/lang/Object;
|
|
|
|
move-result-object v6
|
|
|
|
check-cast v6, Ljava/util/Map$Entry;
|
|
|
|
invoke-interface {v6}, Ljava/util/Map$Entry;->getValue()Ljava/lang/Object;
|
|
|
|
move-result-object v6
|
|
|
|
check-cast v6, Lco/discord/media_engine/InboundAudio;
|
|
|
|
invoke-virtual {v6}, Lco/discord/media_engine/InboundAudio;->getPacketsReceived()I
|
|
|
|
move-result v6
|
|
|
|
add-int/2addr v5, v6
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
invoke-virtual/range {p1 .. p1}, Lco/discord/media_engine/Stats;->getOutboundRtpAudio()Lco/discord/media_engine/OutboundRtpAudio;
|
|
|
|
move-result-object v2
|
|
|
|
if-eqz v2, :cond_1
|
|
|
|
new-instance v6, Lco/discord/media_engine/OutboundAudio;
|
|
|
|
invoke-virtual {v2}, Lco/discord/media_engine/OutboundRtpAudio;->getPacketsSent()I
|
|
|
|
move-result v7
|
|
|
|
invoke-virtual {v2}, Lco/discord/media_engine/OutboundRtpAudio;->getPacketsLost()I
|
|
|
|
move-result v2
|
|
|
|
invoke-direct {v6, v7, v2}, Lco/discord/media_engine/OutboundAudio;-><init>(II)V
|
|
|
|
goto :goto_1
|
|
|
|
:cond_1
|
|
new-instance v6, Lco/discord/media_engine/OutboundAudio;
|
|
|
|
invoke-direct {v6, v4, v4}, Lco/discord/media_engine/OutboundAudio;-><init>(II)V
|
|
|
|
:goto_1
|
|
iput-object v6, v0, Lco/discord/media_engine/VoiceQuality;->_outboundStats:Lco/discord/media_engine/OutboundAudio;
|
|
|
|
invoke-virtual/range {p1 .. p1}, Lco/discord/media_engine/Stats;->getInboundRtpAudio()Ljava/util/Map;
|
|
|
|
move-result-object v2
|
|
|
|
invoke-interface {v2}, Ljava/util/Map;->entrySet()Ljava/util/Set;
|
|
|
|
move-result-object v2
|
|
|
|
invoke-interface {v2}, Ljava/util/Set;->iterator()Ljava/util/Iterator;
|
|
|
|
move-result-object v2
|
|
|
|
:goto_2
|
|
invoke-interface {v2}, Ljava/util/Iterator;->hasNext()Z
|
|
|
|
move-result v6
|
|
|
|
if-eqz v6, :cond_6
|
|
|
|
invoke-interface {v2}, Ljava/util/Iterator;->next()Ljava/lang/Object;
|
|
|
|
move-result-object v6
|
|
|
|
check-cast v6, Ljava/util/Map$Entry;
|
|
|
|
invoke-interface {v6}, Ljava/util/Map$Entry;->getKey()Ljava/lang/Object;
|
|
|
|
move-result-object v7
|
|
|
|
check-cast v7, Ljava/lang/String;
|
|
|
|
invoke-interface {v6}, Ljava/util/Map$Entry;->getValue()Ljava/lang/Object;
|
|
|
|
move-result-object v6
|
|
|
|
check-cast v6, Lco/discord/media_engine/InboundRtpAudio;
|
|
|
|
invoke-virtual/range {p1 .. p1}, Lco/discord/media_engine/Stats;->getTransport()Lco/discord/media_engine/Transport;
|
|
|
|
move-result-object v8
|
|
|
|
if-eqz v8, :cond_2
|
|
|
|
invoke-virtual {v8}, Lco/discord/media_engine/Transport;->getPing()I
|
|
|
|
move-result v8
|
|
|
|
goto :goto_3
|
|
|
|
:cond_2
|
|
const/4 v8, 0x0
|
|
|
|
:goto_3
|
|
invoke-virtual {v6}, Lco/discord/media_engine/InboundRtpAudio;->getPacketsReceived()I
|
|
|
|
move-result v10
|
|
|
|
invoke-virtual {v6}, Lco/discord/media_engine/InboundRtpAudio;->getPacketsLost()I
|
|
|
|
move-result v11
|
|
|
|
invoke-virtual {v6}, Lco/discord/media_engine/InboundRtpAudio;->getJitterBuffer()I
|
|
|
|
move-result v9
|
|
|
|
new-instance v18, Lco/discord/media_engine/InboundBufferStats;
|
|
|
|
invoke-virtual {v6}, Lco/discord/media_engine/InboundRtpAudio;->getAudioJitterBuffer()Lco/discord/media_engine/PlayoutMetric;
|
|
|
|
move-result-object v13
|
|
|
|
invoke-virtual {v6}, Lco/discord/media_engine/InboundRtpAudio;->getAudioJitterTarget()Lco/discord/media_engine/PlayoutMetric;
|
|
|
|
move-result-object v14
|
|
|
|
invoke-virtual {v6}, Lco/discord/media_engine/InboundRtpAudio;->getAudioJitterDelay()Lco/discord/media_engine/PlayoutMetric;
|
|
|
|
move-result-object v15
|
|
|
|
invoke-virtual {v6}, Lco/discord/media_engine/InboundRtpAudio;->getRelativeReceptionDelay()Lco/discord/media_engine/PlayoutMetric;
|
|
|
|
move-result-object v16
|
|
|
|
invoke-virtual {v6}, Lco/discord/media_engine/InboundRtpAudio;->getRelativePlayoutDelay()Lco/discord/media_engine/PlayoutMetric;
|
|
|
|
move-result-object v17
|
|
|
|
move-object/from16 v12, v18
|
|
|
|
invoke-direct/range {v12 .. v17}, Lco/discord/media_engine/InboundBufferStats;-><init>(Lco/discord/media_engine/PlayoutMetric;Lco/discord/media_engine/PlayoutMetric;Lco/discord/media_engine/PlayoutMetric;Lco/discord/media_engine/PlayoutMetric;Lco/discord/media_engine/PlayoutMetric;)V
|
|
|
|
new-instance v27, Lco/discord/media_engine/InboundFrameOpStats;
|
|
|
|
invoke-virtual {v6}, Lco/discord/media_engine/InboundRtpAudio;->getOpSilence()Ljava/lang/Integer;
|
|
|
|
move-result-object v20
|
|
|
|
invoke-virtual {v6}, Lco/discord/media_engine/InboundRtpAudio;->getOpNormal()Ljava/lang/Integer;
|
|
|
|
move-result-object v21
|
|
|
|
invoke-virtual {v6}, Lco/discord/media_engine/InboundRtpAudio;->getOpMerge()Ljava/lang/Integer;
|
|
|
|
move-result-object v22
|
|
|
|
invoke-virtual {v6}, Lco/discord/media_engine/InboundRtpAudio;->getOpExpand()Ljava/lang/Integer;
|
|
|
|
move-result-object v23
|
|
|
|
invoke-virtual {v6}, Lco/discord/media_engine/InboundRtpAudio;->getOpAccelerate()Ljava/lang/Integer;
|
|
|
|
move-result-object v24
|
|
|
|
invoke-virtual {v6}, Lco/discord/media_engine/InboundRtpAudio;->getOpPreemptiveExpand()Ljava/lang/Integer;
|
|
|
|
move-result-object v25
|
|
|
|
invoke-virtual {v6}, Lco/discord/media_engine/InboundRtpAudio;->getOpCNG()Ljava/lang/Integer;
|
|
|
|
move-result-object v26
|
|
|
|
move-object/from16 v19, v27
|
|
|
|
invoke-direct/range {v19 .. v26}, Lco/discord/media_engine/InboundFrameOpStats;-><init>(Ljava/lang/Integer;Ljava/lang/Integer;Ljava/lang/Integer;Ljava/lang/Integer;Ljava/lang/Integer;Ljava/lang/Integer;Ljava/lang/Integer;)V
|
|
|
|
iget-object v6, v0, Lco/discord/media_engine/VoiceQuality;->_inboundStats:Ljava/util/Map;
|
|
|
|
invoke-interface {v6, v7}, Ljava/util/Map;->get(Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
move-result-object v12
|
|
|
|
check-cast v12, Lco/discord/media_engine/InboundAudio;
|
|
|
|
if-eqz v12, :cond_5
|
|
|
|
invoke-virtual {v12}, Lco/discord/media_engine/InboundAudio;->getPacketsReceived()I
|
|
|
|
move-result v13
|
|
|
|
sub-int v13, v10, v13
|
|
|
|
invoke-virtual {v12}, Lco/discord/media_engine/InboundAudio;->getPacketsLost()I
|
|
|
|
move-result v14
|
|
|
|
sub-int v14, v11, v14
|
|
|
|
const-wide/16 v15, 0x0
|
|
|
|
invoke-virtual {v12}, Lco/discord/media_engine/InboundAudio;->getMosBuckets()[Ljava/lang/Integer;
|
|
|
|
move-result-object v17
|
|
|
|
if-lez v13, :cond_3
|
|
|
|
if-ltz v14, :cond_3
|
|
|
|
add-int/2addr v8, v9
|
|
|
|
int-to-double v8, v8
|
|
|
|
move/from16 v21, v5
|
|
|
|
int-to-double v4, v14
|
|
|
|
add-int/2addr v13, v14
|
|
|
|
int-to-double v13, v13
|
|
|
|
div-double v28, v4, v13
|
|
|
|
const-wide/16 v30, 0x0
|
|
|
|
const-wide/high16 v32, 0x3ff0000000000000L # 1.0
|
|
|
|
invoke-static/range {v28 .. v33}, Lco/discord/media_engine/VoiceQualityKt;->access$clamp(DDD)D
|
|
|
|
move-result-wide v4
|
|
|
|
invoke-static {v8, v9, v4, v5}, Lco/discord/media_engine/VoiceQualityKt;->access$_calculateMos(DD)D
|
|
|
|
move-result-wide v4
|
|
|
|
invoke-static {v4, v5}, Ljava/lang/Math;->floor(D)D
|
|
|
|
move-result-wide v8
|
|
|
|
double-to-int v8, v8
|
|
|
|
aget-object v9, v17, v8
|
|
|
|
invoke-virtual {v9}, Ljava/lang/Integer;->intValue()I
|
|
|
|
move-result v9
|
|
|
|
add-int/2addr v9, v3
|
|
|
|
invoke-static {v9}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v9
|
|
|
|
aput-object v9, v17, v8
|
|
|
|
move-wide v15, v4
|
|
|
|
goto :goto_4
|
|
|
|
:cond_3
|
|
move/from16 v21, v5
|
|
|
|
:goto_4
|
|
new-instance v4, Lco/discord/media_engine/InboundAudio;
|
|
|
|
invoke-virtual {v12}, Lco/discord/media_engine/InboundAudio;->getMosSum()D
|
|
|
|
move-result-wide v8
|
|
|
|
add-double v22, v8, v15
|
|
|
|
invoke-virtual {v12}, Lco/discord/media_engine/InboundAudio;->getMosCount()I
|
|
|
|
move-result v5
|
|
|
|
const/4 v8, 0x0
|
|
|
|
int-to-double v12, v8
|
|
|
|
cmpl-double v8, v15, v12
|
|
|
|
if-lez v8, :cond_4
|
|
|
|
const/4 v8, 0x1
|
|
|
|
goto :goto_5
|
|
|
|
:cond_4
|
|
const/4 v8, 0x0
|
|
|
|
:goto_5
|
|
add-int/2addr v5, v8
|
|
|
|
move-object v9, v4
|
|
|
|
move-wide v12, v15
|
|
|
|
move-wide/from16 v14, v22
|
|
|
|
move/from16 v16, v5
|
|
|
|
move-object/from16 v19, v27
|
|
|
|
invoke-direct/range {v9 .. v19}, Lco/discord/media_engine/InboundAudio;-><init>(IIDDI[Ljava/lang/Integer;Lco/discord/media_engine/InboundBufferStats;Lco/discord/media_engine/InboundFrameOpStats;)V
|
|
|
|
const/4 v8, 0x0
|
|
|
|
goto :goto_6
|
|
|
|
:cond_5
|
|
move/from16 v21, v5
|
|
|
|
new-instance v4, Lco/discord/media_engine/InboundAudio;
|
|
|
|
const-wide/16 v12, 0x0
|
|
|
|
const-wide/16 v14, 0x0
|
|
|
|
const/16 v16, 0x0
|
|
|
|
const/4 v5, 0x5
|
|
|
|
new-array v5, v5, [Ljava/lang/Integer;
|
|
|
|
const/4 v8, 0x0
|
|
|
|
invoke-static {v8}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v9
|
|
|
|
aput-object v9, v5, v8
|
|
|
|
invoke-static {v8}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v9
|
|
|
|
aput-object v9, v5, v3
|
|
|
|
const/4 v9, 0x2
|
|
|
|
invoke-static {v8}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v17
|
|
|
|
aput-object v17, v5, v9
|
|
|
|
const/4 v9, 0x3
|
|
|
|
invoke-static {v8}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v17
|
|
|
|
aput-object v17, v5, v9
|
|
|
|
const/4 v9, 0x4
|
|
|
|
invoke-static {v8}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v17
|
|
|
|
aput-object v17, v5, v9
|
|
|
|
move-object v9, v4
|
|
|
|
move-object/from16 v17, v5
|
|
|
|
move-object/from16 v19, v27
|
|
|
|
invoke-direct/range {v9 .. v19}, Lco/discord/media_engine/InboundAudio;-><init>(IIDDI[Ljava/lang/Integer;Lco/discord/media_engine/InboundBufferStats;Lco/discord/media_engine/InboundFrameOpStats;)V
|
|
|
|
:goto_6
|
|
invoke-interface {v6, v7, v4}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
move/from16 v5, v21
|
|
|
|
const/4 v4, 0x0
|
|
|
|
goto/16 :goto_2
|
|
|
|
:cond_6
|
|
move/from16 v21, v5
|
|
|
|
const/4 v8, 0x0
|
|
|
|
iget-object v2, v0, Lco/discord/media_engine/VoiceQuality;->_outboundStats:Lco/discord/media_engine/OutboundAudio;
|
|
|
|
invoke-virtual {v2}, Lco/discord/media_engine/OutboundAudio;->getPacketsSent()I
|
|
|
|
move-result v2
|
|
|
|
if-le v2, v1, :cond_7
|
|
|
|
iget-object v1, v0, Lco/discord/media_engine/VoiceQuality;->_duration:Lco/discord/media_engine/Duration;
|
|
|
|
invoke-virtual {v1}, Lco/discord/media_engine/Duration;->getSpeaking()I
|
|
|
|
move-result v2
|
|
|
|
add-int/2addr v2, v3
|
|
|
|
invoke-virtual {v1, v2}, Lco/discord/media_engine/Duration;->setSpeaking(I)V
|
|
|
|
const/4 v1, 0x1
|
|
|
|
goto :goto_7
|
|
|
|
:cond_7
|
|
const/4 v1, 0x0
|
|
|
|
:goto_7
|
|
iget-object v2, v0, Lco/discord/media_engine/VoiceQuality;->_inboundStats:Ljava/util/Map;
|
|
|
|
invoke-interface {v2}, Ljava/util/Map;->entrySet()Ljava/util/Set;
|
|
|
|
move-result-object v2
|
|
|
|
invoke-interface {v2}, Ljava/util/Set;->iterator()Ljava/util/Iterator;
|
|
|
|
move-result-object v2
|
|
|
|
const/4 v4, 0x0
|
|
|
|
:goto_8
|
|
invoke-interface {v2}, Ljava/util/Iterator;->hasNext()Z
|
|
|
|
move-result v5
|
|
|
|
if-eqz v5, :cond_8
|
|
|
|
invoke-interface {v2}, Ljava/util/Iterator;->next()Ljava/lang/Object;
|
|
|
|
move-result-object v5
|
|
|
|
check-cast v5, Ljava/util/Map$Entry;
|
|
|
|
invoke-interface {v5}, Ljava/util/Map$Entry;->getValue()Ljava/lang/Object;
|
|
|
|
move-result-object v5
|
|
|
|
check-cast v5, Lco/discord/media_engine/InboundAudio;
|
|
|
|
invoke-virtual {v5}, Lco/discord/media_engine/InboundAudio;->getPacketsReceived()I
|
|
|
|
move-result v5
|
|
|
|
add-int/2addr v4, v5
|
|
|
|
goto :goto_8
|
|
|
|
:cond_8
|
|
move/from16 v5, v21
|
|
|
|
if-le v4, v5, :cond_9
|
|
|
|
iget-object v2, v0, Lco/discord/media_engine/VoiceQuality;->_duration:Lco/discord/media_engine/Duration;
|
|
|
|
invoke-virtual {v2}, Lco/discord/media_engine/Duration;->getListening()I
|
|
|
|
move-result v4
|
|
|
|
add-int/2addr v4, v3
|
|
|
|
invoke-virtual {v2, v4}, Lco/discord/media_engine/Duration;->setListening(I)V
|
|
|
|
const/4 v4, 0x1
|
|
|
|
goto :goto_9
|
|
|
|
:cond_9
|
|
const/4 v4, 0x0
|
|
|
|
:goto_9
|
|
if-nez v1, :cond_a
|
|
|
|
if-eqz v4, :cond_b
|
|
|
|
:cond_a
|
|
iget-object v1, v0, Lco/discord/media_engine/VoiceQuality;->_duration:Lco/discord/media_engine/Duration;
|
|
|
|
invoke-virtual {v1}, Lco/discord/media_engine/Duration;->getParticipation()I
|
|
|
|
move-result v2
|
|
|
|
add-int/2addr v2, v3
|
|
|
|
invoke-virtual {v1, v2}, Lco/discord/media_engine/Duration;->setParticipation(I)V
|
|
|
|
:cond_b
|
|
return-void
|
|
|
|
:cond_c
|
|
const-string v1, "stats"
|
|
|
|
invoke-static {v1}, Li0/n/c/h;->c(Ljava/lang/String;)V
|
|
|
|
const/4 v1, 0x0
|
|
|
|
throw v1
|
|
.end method
|