2020-05-17 12:40:10 +00:00
|
|
|
.class public final Lco/discord/media_engine/VideoStreamRenderer$Muxer;
|
|
|
|
.super Ljava/lang/Object;
|
|
|
|
.source "VideoStreamRenderer.kt"
|
|
|
|
|
|
|
|
|
|
|
|
# annotations
|
|
|
|
.annotation system Ldalvik/annotation/EnclosingClass;
|
|
|
|
value = Lco/discord/media_engine/VideoStreamRenderer;
|
|
|
|
.end annotation
|
|
|
|
|
|
|
|
.annotation system Ldalvik/annotation/InnerClass;
|
|
|
|
accessFlags = 0x19
|
|
|
|
name = "Muxer"
|
|
|
|
.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}, Lco/discord/media_engine/VideoStreamRenderer$Muxer;-><init>()V
|
|
|
|
|
|
|
|
return-void
|
|
|
|
.end method
|
|
|
|
|
|
|
|
|
|
|
|
# virtual methods
|
|
|
|
.method public final addSink(Lcom/hammerandchisel/libdiscord/Discord;Lco/discord/media_engine/VideoStreamRenderer;Ljava/lang/String;)V
|
|
|
|
.locals 3
|
|
|
|
|
2020-07-08 16:44:49 +00:00
|
|
|
const-string v0, "discord"
|
|
|
|
|
|
|
|
const/4 v1, 0x0
|
2020-05-17 12:40:10 +00:00
|
|
|
|
|
|
|
if-eqz p1, :cond_3
|
|
|
|
|
2020-07-08 16:44:49 +00:00
|
|
|
const-string v0, "sink"
|
|
|
|
|
2020-05-17 12:40:10 +00:00
|
|
|
if-eqz p2, :cond_2
|
|
|
|
|
2020-07-08 16:44:49 +00:00
|
|
|
const-string v0, "streamId"
|
|
|
|
|
2020-05-17 12:40:10 +00:00
|
|
|
if-eqz p3, :cond_1
|
|
|
|
|
|
|
|
invoke-static {}, Lco/discord/media_engine/VideoStreamRenderer;->access$getStreams$cp()Ljava/util/Map;
|
|
|
|
|
|
|
|
move-result-object v0
|
|
|
|
|
|
|
|
monitor-enter v0
|
|
|
|
|
|
|
|
:try_start_0
|
|
|
|
invoke-static {}, Lco/discord/media_engine/VideoStreamRenderer;->access$Muxer()Lco/discord/media_engine/VideoStreamRenderer$Muxer;
|
|
|
|
|
|
|
|
invoke-static {}, Lco/discord/media_engine/VideoStreamRenderer;->access$getStreams$cp()Ljava/util/Map;
|
|
|
|
|
|
|
|
move-result-object v1
|
|
|
|
|
|
|
|
invoke-interface {v1, p3}, Ljava/util/Map;->get(Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
|
|
|
|
move-result-object v1
|
|
|
|
|
|
|
|
check-cast v1, Ljava/util/Set;
|
|
|
|
|
|
|
|
if-eqz v1, :cond_0
|
|
|
|
|
|
|
|
monitor-enter v1
|
|
|
|
:try_end_0
|
|
|
|
.catchall {:try_start_0 .. :try_end_0} :catchall_1
|
|
|
|
|
|
|
|
:try_start_1
|
|
|
|
invoke-interface {v1, p2}, Ljava/util/Set;->add(Ljava/lang/Object;)Z
|
|
|
|
:try_end_1
|
|
|
|
.catchall {:try_start_1 .. :try_end_1} :catchall_0
|
|
|
|
|
|
|
|
:try_start_2
|
|
|
|
monitor-exit v1
|
|
|
|
|
|
|
|
goto :goto_0
|
|
|
|
|
|
|
|
:catchall_0
|
|
|
|
move-exception p1
|
|
|
|
|
|
|
|
monitor-exit v1
|
|
|
|
|
|
|
|
throw p1
|
|
|
|
|
|
|
|
:cond_0
|
|
|
|
const/4 v1, 0x1
|
|
|
|
|
|
|
|
new-array v1, v1, [Lco/discord/media_engine/VideoStreamRenderer;
|
|
|
|
|
|
|
|
const/4 v2, 0x0
|
|
|
|
|
|
|
|
aput-object p2, v1, v2
|
|
|
|
|
2020-07-25 02:57:47 +00:00
|
|
|
invoke-static {v1}, Lf/n/a/k/a;->mutableSetOf([Ljava/lang/Object;)Ljava/util/Set;
|
2020-05-17 12:40:10 +00:00
|
|
|
|
|
|
|
move-result-object p2
|
|
|
|
|
|
|
|
new-instance v1, Lco/discord/media_engine/VideoStreamRenderer$Muxer$addSink$1$2;
|
|
|
|
|
|
|
|
invoke-direct {v1, p2}, Lco/discord/media_engine/VideoStreamRenderer$Muxer$addSink$1$2;-><init>(Ljava/util/Set;)V
|
|
|
|
|
|
|
|
invoke-virtual {p1, p3, v1}, Lcom/hammerandchisel/libdiscord/Discord;->setVideoOutputSink(Ljava/lang/String;Lcom/hammerandchisel/libdiscord/Discord$VideoFrameCallback;)V
|
|
|
|
|
|
|
|
invoke-static {}, Lco/discord/media_engine/VideoStreamRenderer;->access$Muxer()Lco/discord/media_engine/VideoStreamRenderer$Muxer;
|
|
|
|
|
|
|
|
invoke-static {}, Lco/discord/media_engine/VideoStreamRenderer;->access$getStreams$cp()Ljava/util/Map;
|
|
|
|
|
|
|
|
move-result-object p1
|
|
|
|
|
|
|
|
invoke-interface {p1, p3, p2}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
:try_end_2
|
|
|
|
.catchall {:try_start_2 .. :try_end_2} :catchall_1
|
|
|
|
|
|
|
|
:goto_0
|
|
|
|
monitor-exit v0
|
|
|
|
|
|
|
|
return-void
|
|
|
|
|
|
|
|
:catchall_1
|
|
|
|
move-exception p1
|
|
|
|
|
|
|
|
monitor-exit v0
|
|
|
|
|
|
|
|
throw p1
|
|
|
|
|
|
|
|
:cond_1
|
2020-07-25 00:57:58 +00:00
|
|
|
invoke-static {v0}, Lj0/n/c/h;->c(Ljava/lang/String;)V
|
2020-05-17 12:40:10 +00:00
|
|
|
|
2020-07-08 16:44:49 +00:00
|
|
|
throw v1
|
2020-05-17 12:40:10 +00:00
|
|
|
|
|
|
|
:cond_2
|
2020-07-25 00:57:58 +00:00
|
|
|
invoke-static {v0}, Lj0/n/c/h;->c(Ljava/lang/String;)V
|
2020-05-17 12:40:10 +00:00
|
|
|
|
2020-07-08 16:44:49 +00:00
|
|
|
throw v1
|
2020-05-17 12:40:10 +00:00
|
|
|
|
|
|
|
:cond_3
|
2020-07-25 00:57:58 +00:00
|
|
|
invoke-static {v0}, Lj0/n/c/h;->c(Ljava/lang/String;)V
|
2020-05-17 12:40:10 +00:00
|
|
|
|
2020-07-08 16:44:49 +00:00
|
|
|
throw v1
|
2020-05-17 12:40:10 +00:00
|
|
|
.end method
|
|
|
|
|
|
|
|
.method public final removeSink(Lcom/hammerandchisel/libdiscord/Discord;Lco/discord/media_engine/VideoStreamRenderer;Ljava/lang/String;)V
|
|
|
|
.locals 3
|
|
|
|
|
2020-07-08 16:44:49 +00:00
|
|
|
const-string v0, "discord"
|
|
|
|
|
|
|
|
const/4 v1, 0x0
|
2020-05-17 12:40:10 +00:00
|
|
|
|
|
|
|
if-eqz p1, :cond_4
|
|
|
|
|
2020-07-08 16:44:49 +00:00
|
|
|
const-string v0, "sink"
|
|
|
|
|
2020-05-17 12:40:10 +00:00
|
|
|
if-eqz p2, :cond_3
|
|
|
|
|
2020-07-08 16:44:49 +00:00
|
|
|
const-string v0, "streamId"
|
|
|
|
|
2020-05-17 12:40:10 +00:00
|
|
|
if-eqz p3, :cond_2
|
|
|
|
|
|
|
|
invoke-static {}, Lco/discord/media_engine/VideoStreamRenderer;->access$getStreams$cp()Ljava/util/Map;
|
|
|
|
|
2020-07-08 16:44:49 +00:00
|
|
|
move-result-object v0
|
2020-05-17 12:40:10 +00:00
|
|
|
|
2020-07-08 16:44:49 +00:00
|
|
|
monitor-enter v0
|
2020-05-17 12:40:10 +00:00
|
|
|
|
|
|
|
:try_start_0
|
|
|
|
invoke-static {}, Lco/discord/media_engine/VideoStreamRenderer;->access$Muxer()Lco/discord/media_engine/VideoStreamRenderer$Muxer;
|
|
|
|
|
|
|
|
invoke-static {}, Lco/discord/media_engine/VideoStreamRenderer;->access$getStreams$cp()Ljava/util/Map;
|
|
|
|
|
|
|
|
move-result-object v2
|
|
|
|
|
|
|
|
invoke-interface {v2, p3}, Ljava/util/Map;->get(Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
|
|
|
|
move-result-object v2
|
|
|
|
|
|
|
|
check-cast v2, Ljava/util/Set;
|
|
|
|
|
|
|
|
if-eqz v2, :cond_1
|
|
|
|
|
|
|
|
monitor-enter v2
|
|
|
|
:try_end_0
|
|
|
|
.catchall {:try_start_0 .. :try_end_0} :catchall_1
|
|
|
|
|
|
|
|
:try_start_1
|
|
|
|
invoke-interface {v2, p2}, Ljava/util/Set;->remove(Ljava/lang/Object;)Z
|
|
|
|
|
|
|
|
invoke-interface {v2}, Ljava/util/Set;->isEmpty()Z
|
|
|
|
|
|
|
|
move-result p2
|
|
|
|
|
|
|
|
if-eqz p2, :cond_0
|
|
|
|
|
2020-07-08 16:44:49 +00:00
|
|
|
invoke-virtual {p1, p3, v1}, Lcom/hammerandchisel/libdiscord/Discord;->setVideoOutputSink(Ljava/lang/String;Lcom/hammerandchisel/libdiscord/Discord$VideoFrameCallback;)V
|
2020-05-17 12:40:10 +00:00
|
|
|
|
|
|
|
invoke-static {}, Lco/discord/media_engine/VideoStreamRenderer;->access$Muxer()Lco/discord/media_engine/VideoStreamRenderer$Muxer;
|
|
|
|
|
|
|
|
invoke-static {}, Lco/discord/media_engine/VideoStreamRenderer;->access$getStreams$cp()Ljava/util/Map;
|
|
|
|
|
|
|
|
move-result-object p1
|
|
|
|
|
|
|
|
invoke-interface {p1, p3}, Ljava/util/Map;->remove(Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
:try_end_1
|
|
|
|
.catchall {:try_start_1 .. :try_end_1} :catchall_0
|
|
|
|
|
|
|
|
:cond_0
|
|
|
|
:try_start_2
|
|
|
|
monitor-exit v2
|
|
|
|
|
|
|
|
goto :goto_0
|
|
|
|
|
|
|
|
:catchall_0
|
|
|
|
move-exception p1
|
|
|
|
|
|
|
|
monitor-exit v2
|
|
|
|
|
|
|
|
throw p1
|
|
|
|
:try_end_2
|
|
|
|
.catchall {:try_start_2 .. :try_end_2} :catchall_1
|
|
|
|
|
|
|
|
:cond_1
|
|
|
|
:goto_0
|
2020-07-08 16:44:49 +00:00
|
|
|
monitor-exit v0
|
2020-05-17 12:40:10 +00:00
|
|
|
|
|
|
|
return-void
|
|
|
|
|
|
|
|
:catchall_1
|
|
|
|
move-exception p1
|
|
|
|
|
2020-07-08 16:44:49 +00:00
|
|
|
monitor-exit v0
|
2020-05-17 12:40:10 +00:00
|
|
|
|
|
|
|
throw p1
|
|
|
|
|
|
|
|
:cond_2
|
2020-07-25 00:57:58 +00:00
|
|
|
invoke-static {v0}, Lj0/n/c/h;->c(Ljava/lang/String;)V
|
2020-05-17 12:40:10 +00:00
|
|
|
|
2020-07-08 16:44:49 +00:00
|
|
|
throw v1
|
2020-05-17 12:40:10 +00:00
|
|
|
|
|
|
|
:cond_3
|
2020-07-25 00:57:58 +00:00
|
|
|
invoke-static {v0}, Lj0/n/c/h;->c(Ljava/lang/String;)V
|
2020-05-17 12:40:10 +00:00
|
|
|
|
2020-07-08 16:44:49 +00:00
|
|
|
throw v1
|
2020-05-17 12:40:10 +00:00
|
|
|
|
|
|
|
:cond_4
|
2020-07-25 00:57:58 +00:00
|
|
|
invoke-static {v0}, Lj0/n/c/h;->c(Ljava/lang/String;)V
|
2020-05-17 12:40:10 +00:00
|
|
|
|
2020-07-08 16:44:49 +00:00
|
|
|
throw v1
|
2020-05-17 12:40:10 +00:00
|
|
|
.end method
|