249 lines
6.8 KiB
Smali
249 lines
6.8 KiB
Smali
.class public final Lcom/discord/stores/StoreMediaEngine$Companion;
|
|
.super Ljava/lang/Object;
|
|
.source "StoreMediaEngine.kt"
|
|
|
|
|
|
# annotations
|
|
.annotation system Ldalvik/annotation/EnclosingClass;
|
|
value = Lcom/discord/stores/StoreMediaEngine;
|
|
.end annotation
|
|
|
|
.annotation system Ldalvik/annotation/InnerClass;
|
|
accessFlags = 0x19
|
|
name = "Companion"
|
|
.end annotation
|
|
|
|
|
|
# direct methods
|
|
.method public constructor <init>()V
|
|
.locals 0
|
|
|
|
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public synthetic constructor <init>(Lkotlin/jvm/internal/DefaultConstructorMarker;)V
|
|
.locals 0
|
|
|
|
invoke-direct {p0}, Lcom/discord/stores/StoreMediaEngine$Companion;-><init>()V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public static final synthetic access$setVoiceConfig(Lcom/discord/stores/StoreMediaEngine$Companion;Lcom/discord/rtcconnection/mediaengine/MediaEngine;Lcom/discord/stores/StoreMediaSettings$VoiceConfiguration;Lcom/discord/stores/StoreMediaEngine$ExperimentConfig;)V
|
|
.locals 0
|
|
|
|
invoke-direct {p0, p1, p2, p3}, Lcom/discord/stores/StoreMediaEngine$Companion;->setVoiceConfig(Lcom/discord/rtcconnection/mediaengine/MediaEngine;Lcom/discord/stores/StoreMediaSettings$VoiceConfiguration;Lcom/discord/stores/StoreMediaEngine$ExperimentConfig;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method private final setVoiceConfig(Lcom/discord/rtcconnection/mediaengine/MediaEngine;Lcom/discord/stores/StoreMediaSettings$VoiceConfiguration;Lcom/discord/stores/StoreMediaEngine$ExperimentConfig;)V
|
|
.locals 15
|
|
|
|
move-object/from16 v0, p1
|
|
|
|
invoke-virtual/range {p2 .. p2}, Lcom/discord/stores/StoreMediaSettings$VoiceConfiguration;->getOutputVolume()F
|
|
|
|
move-result v1
|
|
|
|
invoke-interface {v0, v1}, Lcom/discord/rtcconnection/mediaengine/MediaEngine;->h(F)V
|
|
|
|
invoke-virtual/range {p2 .. p2}, Lcom/discord/stores/StoreMediaSettings$VoiceConfiguration;->getEchoCancellation()Z
|
|
|
|
move-result v1
|
|
|
|
invoke-interface {v0, v1}, Lcom/discord/rtcconnection/mediaengine/MediaEngine;->c(Z)V
|
|
|
|
invoke-virtual/range {p2 .. p2}, Lcom/discord/stores/StoreMediaSettings$VoiceConfiguration;->getNoiseProcessing()Lcom/discord/stores/StoreMediaSettings$NoiseProcessing;
|
|
|
|
move-result-object v1
|
|
|
|
sget-object v2, Lcom/discord/stores/StoreMediaSettings$NoiseProcessing;->Suppression:Lcom/discord/stores/StoreMediaSettings$NoiseProcessing;
|
|
|
|
const/4 v3, 0x1
|
|
|
|
const/4 v4, 0x0
|
|
|
|
if-ne v1, v2, :cond_0
|
|
|
|
const/4 v1, 0x1
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
const/4 v1, 0x0
|
|
|
|
:goto_0
|
|
invoke-interface {v0, v1}, Lcom/discord/rtcconnection/mediaengine/MediaEngine;->i(Z)V
|
|
|
|
invoke-virtual/range {p2 .. p2}, Lcom/discord/stores/StoreMediaSettings$VoiceConfiguration;->getNoiseProcessing()Lcom/discord/stores/StoreMediaSettings$NoiseProcessing;
|
|
|
|
move-result-object v1
|
|
|
|
sget-object v2, Lcom/discord/stores/StoreMediaSettings$NoiseProcessing;->Cancellation:Lcom/discord/stores/StoreMediaSettings$NoiseProcessing;
|
|
|
|
if-ne v1, v2, :cond_1
|
|
|
|
const/4 v1, 0x1
|
|
|
|
goto :goto_1
|
|
|
|
:cond_1
|
|
const/4 v1, 0x0
|
|
|
|
:goto_1
|
|
invoke-interface {v0, v1}, Lcom/discord/rtcconnection/mediaengine/MediaEngine;->d(Z)V
|
|
|
|
invoke-virtual/range {p2 .. p2}, Lcom/discord/stores/StoreMediaSettings$VoiceConfiguration;->getAutomaticGainControl()Z
|
|
|
|
move-result v1
|
|
|
|
invoke-interface {v0, v1}, Lcom/discord/rtcconnection/mediaengine/MediaEngine;->m(Z)V
|
|
|
|
invoke-interface/range {p1 .. p1}, Lcom/discord/rtcconnection/mediaengine/MediaEngine;->getConnections()Ljava/util/List;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-interface {v0}, Ljava/lang/Iterable;->iterator()Ljava/util/Iterator;
|
|
|
|
move-result-object v0
|
|
|
|
:goto_2
|
|
invoke-interface {v0}, Ljava/util/Iterator;->hasNext()Z
|
|
|
|
move-result v1
|
|
|
|
if-eqz v1, :cond_7
|
|
|
|
invoke-interface {v0}, Ljava/util/Iterator;->next()Ljava/lang/Object;
|
|
|
|
move-result-object v1
|
|
|
|
check-cast v1, Lcom/discord/rtcconnection/mediaengine/MediaEngineConnection;
|
|
|
|
invoke-virtual/range {p2 .. p2}, Lcom/discord/stores/StoreMediaSettings$VoiceConfiguration;->getInputMode()Lcom/discord/rtcconnection/mediaengine/MediaEngineConnection$InputMode;
|
|
|
|
move-result-object v2
|
|
|
|
const/16 v5, 0x7f
|
|
|
|
const/16 v6, 0x7f
|
|
|
|
and-int/2addr v6, v3
|
|
|
|
and-int/lit8 v6, v5, 0x2
|
|
|
|
if-eqz v6, :cond_2
|
|
|
|
const/16 v6, 0xa
|
|
|
|
const/16 v9, 0xa
|
|
|
|
goto :goto_3
|
|
|
|
:cond_2
|
|
const/4 v9, 0x0
|
|
|
|
:goto_3
|
|
and-int/lit8 v6, v5, 0x4
|
|
|
|
if-eqz v6, :cond_3
|
|
|
|
const/16 v6, 0x28
|
|
|
|
const/16 v10, 0x28
|
|
|
|
goto :goto_4
|
|
|
|
:cond_3
|
|
const/4 v10, 0x0
|
|
|
|
:goto_4
|
|
and-int/lit8 v6, v5, 0x8
|
|
|
|
and-int/lit8 v6, v5, 0x10
|
|
|
|
and-int/lit8 v6, v5, 0x20
|
|
|
|
and-int/lit8 v5, v5, 0x40
|
|
|
|
if-eqz v5, :cond_4
|
|
|
|
const/4 v5, 0x5
|
|
|
|
const/4 v14, 0x5
|
|
|
|
goto :goto_5
|
|
|
|
:cond_4
|
|
const/4 v14, 0x0
|
|
|
|
:goto_5
|
|
invoke-virtual/range {p2 .. p2}, Lcom/discord/stores/StoreMediaSettings$VoiceConfiguration;->getSensitivity()F
|
|
|
|
move-result v5
|
|
|
|
float-to-int v8, v5
|
|
|
|
invoke-virtual/range {p2 .. p2}, Lcom/discord/stores/StoreMediaSettings$VoiceConfiguration;->getAutomaticVad()Z
|
|
|
|
move-result v11
|
|
|
|
invoke-virtual/range {p2 .. p2}, Lcom/discord/stores/StoreMediaSettings$VoiceConfiguration;->getVadUseKrisp()Z
|
|
|
|
move-result v12
|
|
|
|
invoke-virtual/range {p3 .. p3}, Lcom/discord/stores/StoreMediaEngine$ExperimentConfig;->getKrispFullbandExperimentEnabled()Z
|
|
|
|
move-result v13
|
|
|
|
new-instance v5, Lcom/discord/rtcconnection/mediaengine/MediaEngineConnection$a;
|
|
|
|
move-object v7, v5
|
|
|
|
invoke-direct/range {v7 .. v14}, Lcom/discord/rtcconnection/mediaengine/MediaEngineConnection$a;-><init>(IIIZZZI)V
|
|
|
|
invoke-interface {v1, v2, v5}, Lcom/discord/rtcconnection/mediaengine/MediaEngineConnection;->h(Lcom/discord/rtcconnection/mediaengine/MediaEngineConnection$InputMode;Lcom/discord/rtcconnection/mediaengine/MediaEngineConnection$a;)V
|
|
|
|
invoke-virtual/range {p2 .. p2}, Lcom/discord/stores/StoreMediaSettings$VoiceConfiguration;->isDeafened()Z
|
|
|
|
move-result v2
|
|
|
|
invoke-interface {v1, v2}, Lcom/discord/rtcconnection/mediaengine/MediaEngineConnection;->q(Z)V
|
|
|
|
invoke-virtual/range {p2 .. p2}, Lcom/discord/stores/StoreMediaSettings$VoiceConfiguration;->isMuted()Z
|
|
|
|
move-result v2
|
|
|
|
if-nez v2, :cond_6
|
|
|
|
invoke-interface {v1}, Lcom/discord/rtcconnection/mediaengine/MediaEngineConnection;->getType()Lcom/discord/rtcconnection/mediaengine/MediaEngineConnection$Type;
|
|
|
|
move-result-object v2
|
|
|
|
sget-object v5, Lcom/discord/rtcconnection/mediaengine/MediaEngineConnection$Type;->STREAM:Lcom/discord/rtcconnection/mediaengine/MediaEngineConnection$Type;
|
|
|
|
if-ne v2, v5, :cond_5
|
|
|
|
goto :goto_6
|
|
|
|
:cond_5
|
|
const/4 v2, 0x0
|
|
|
|
goto :goto_7
|
|
|
|
:cond_6
|
|
:goto_6
|
|
const/4 v2, 0x1
|
|
|
|
:goto_7
|
|
invoke-interface {v1, v2}, Lcom/discord/rtcconnection/mediaengine/MediaEngineConnection;->c(Z)V
|
|
|
|
goto :goto_2
|
|
|
|
:cond_7
|
|
return-void
|
|
.end method
|