From 6322c369068758140783fc2ecd079a9514407187 Mon Sep 17 00:00:00 2001 From: ningwenqiang Date: Fri, 13 Sep 2024 15:32:27 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E5=BC=80=E6=92=AD=E5=9B=BE?= =?UTF-8?q?=E7=89=87=E5=90=8E=E6=91=84=E5=83=8F=E5=A4=B4=E5=8D=A1=E4=BD=8F?= =?UTF-8?q?=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/tmp/full-r8-config.txt | 583 +++++++++--------- config.gradle | 2 +- .../beautyapi/faceunity/agora/SWManager.java | 22 +- .../live/views/LivePushSwViewHolder.java | 7 +- 4 files changed, 322 insertions(+), 292 deletions(-) diff --git a/app/tmp/full-r8-config.txt b/app/tmp/full-r8-config.txt index f80ae5cc7..1804dd9f1 100644 --- a/app/tmp/full-r8-config.txt +++ b/app/tmp/full-r8-config.txt @@ -1,4 +1,4 @@ -# The proguard configuration file for the following section is D:\AndroidProject\pandorapanL\app\build\intermediates\default_proguard_files\global\proguard-android.txt-8.3.1 +# The proguard configuration file for the following section is D:\AndroidProject\pandorapan\app\build\intermediates\default_proguard_files\global\proguard-android.txt-8.3.1 # This is a configuration file for ProGuard. # http://proguard.sourceforge.net/index.html#manual/usage.html # @@ -95,8 +95,8 @@ # These classes are duplicated between android.jar and core-lambda-stubs.jar. -dontnote java.lang.invoke.** -# End of content from D:\AndroidProject\pandorapanL\app\build\intermediates\default_proguard_files\global\proguard-android.txt-8.3.1 -# The proguard configuration file for the following section is D:\AndroidProject\pandorapanL\app\proguard-rules.pro +# End of content from D:\AndroidProject\pandorapan\app\build\intermediates\default_proguard_files\global\proguard-android.txt-8.3.1 +# The proguard configuration file for the following section is D:\AndroidProject\pandorapan\app\proguard-rules.pro # Add project specific ProGuard rules here. # By default, the flags in this file are appended to flags specified # in /Users/macpro/Library/Android/sdk/tools/proguard/proguard-android.txt @@ -419,8 +419,8 @@ rx.internal.util.atomic.LinkedQueueNode* consumerNode; -keep class com.qiniu.**{public ();} -ignorewarnings -# End of content from D:\AndroidProject\pandorapanL\app\proguard-rules.pro -# The proguard configuration file for the following section is D:\AndroidProject\pandorapanL\app\build\intermediates\aapt_proguard_file\google_testRelease\processGoogle_testReleaseResources\aapt_rules.txt +# End of content from D:\AndroidProject\pandorapan\app\proguard-rules.pro +# The proguard configuration file for the following section is D:\AndroidProject\pandorapan\app\build\intermediates\aapt_proguard_file\link_onlineRelease\processLink_onlineReleaseResources\aapt_rules.txt -keep class androidx.core.app.CoreComponentFactory { (); } -keep class androidx.core.content.FileProvider { (); } -keep class androidx.core.content.FileProvider4Utils { (); } @@ -1093,10 +1093,10 @@ rx.internal.util.atomic.LinkedQueueNode* consumerNode; -keepclassmembers class * { *** videoEditClick(android.view.View); } -# End of content from D:\AndroidProject\pandorapanL\app\build\intermediates\aapt_proguard_file\google_testRelease\processGoogle_testReleaseResources\aapt_rules.txt -# The proguard configuration file for the following section is D:\AndroidProject\pandorapanL\lib_faceunity\build\intermediates\consumer_proguard_dir\google_testRelease\exportGoogle_testReleaseConsumerProguardFiles\lib0\proguard.txt +# End of content from D:\AndroidProject\pandorapan\app\build\intermediates\aapt_proguard_file\link_onlineRelease\processLink_onlineReleaseResources\aapt_rules.txt +# The proguard configuration file for the following section is D:\AndroidProject\pandorapan\lib_faceunity\build\intermediates\consumer_proguard_dir\link_onlineRelease\exportLink_onlineReleaseConsumerProguardFiles\lib0\proguard.txt -# End of content from D:\AndroidProject\pandorapanL\lib_faceunity\build\intermediates\consumer_proguard_dir\google_testRelease\exportGoogle_testReleaseConsumerProguardFiles\lib0\proguard.txt +# End of content from D:\AndroidProject\pandorapan\lib_faceunity\build\intermediates\consumer_proguard_dir\link_onlineRelease\exportLink_onlineReleaseConsumerProguardFiles\lib0\proguard.txt # The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\8d3e3177c15403546de73d87508067d6\transformed\jetified-XPopup-2.10.0\proguard.txt # Generated keep rule for Lifecycle observer adapter. -if class com.lxj.xpopup.core.BasePopupView { @@ -1156,9 +1156,9 @@ rx.internal.util.atomic.LinkedQueueNode* consumerNode; # End of content from C:\Users\CVB88\.gradle\caches\transforms-3\a1df9a6aa192455030f7c9970b70e0e9\transformed\material-1.4.0\proguard.txt -# The proguard configuration file for the following section is D:\AndroidProject\pandorapanL\lib_google\build\intermediates\consumer_proguard_dir\google_testRelease\exportGoogle_testReleaseConsumerProguardFiles\lib0\proguard.txt +# The proguard configuration file for the following section is D:\AndroidProject\pandorapan\lib_google\build\intermediates\consumer_proguard_dir\link_onlineRelease\exportLink_onlineReleaseConsumerProguardFiles\lib0\proguard.txt -# End of content from D:\AndroidProject\pandorapanL\lib_google\build\intermediates\consumer_proguard_dir\google_testRelease\exportGoogle_testReleaseConsumerProguardFiles\lib0\proguard.txt +# End of content from D:\AndroidProject\pandorapan\lib_google\build\intermediates\consumer_proguard_dir\link_onlineRelease\exportLink_onlineReleaseConsumerProguardFiles\lib0\proguard.txt # The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\2929985d9627ba3bb45a0ebd18eaf9d3\transformed\jetified-linesdk-5.0.1\proguard.txt -keepattributes *Annotation* @@ -1377,7 +1377,7 @@ rx.internal.util.atomic.LinkedQueueNode* consumerNode; -keep class com.davemorrissey.labs.subscaleview.** { *; } # End of content from C:\Users\CVB88\.gradle\caches\transforms-3\7bbb003dbf2685697cd42cfb46e77b3f\transformed\jetified-subsampling-scale-image-view-androidx-3.10.0\proguard.txt -# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\0fdcb88552259c6c22dbd3bb46b31518\transformed\appcompat-1.3.1\proguard.txt +# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\ee31731bfec871ceb9cdfd12b05817bc\transformed\appcompat-1.6.1\proguard.txt # Copyright (C) 2018 The Android Open Source Project # # Licensed under the Apache License, Version 2.0 (the "License"); @@ -1401,7 +1401,7 @@ rx.internal.util.atomic.LinkedQueueNode* consumerNode; ; } -# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\0fdcb88552259c6c22dbd3bb46b31518\transformed\appcompat-1.3.1\proguard.txt +# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\ee31731bfec871ceb9cdfd12b05817bc\transformed\appcompat-1.6.1\proguard.txt # The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\b8e86bdadf487d72a43cd430b3f9db16\transformed\jetified-tweet-ui-3.1.1\proguard.txt #Picasso Proguard Config https://github.com/square/picasso -dontwarn com.squareup.okhttp.** @@ -1509,9 +1509,9 @@ rx.internal.util.atomic.LinkedQueueNode* consumerNode; public boolean isLayoutSuppressed(); } # End of content from C:\Users\CVB88\.gradle\caches\transforms-3\e9de7db2640f13ae2ab2a585dfd19337\transformed\recyclerview-1.2.1\proguard.txt -# The proguard configuration file for the following section is D:\AndroidProject\pandorapanL\TabLayout\build\intermediates\consumer_proguard_dir\release\exportReleaseConsumerProguardFiles\lib0\proguard.txt +# The proguard configuration file for the following section is D:\AndroidProject\pandorapan\TabLayout\build\intermediates\consumer_proguard_dir\release\exportReleaseConsumerProguardFiles\lib0\proguard.txt -# End of content from D:\AndroidProject\pandorapanL\TabLayout\build\intermediates\consumer_proguard_dir\release\exportReleaseConsumerProguardFiles\lib0\proguard.txt +# End of content from D:\AndroidProject\pandorapan\TabLayout\build\intermediates\consumer_proguard_dir\release\exportReleaseConsumerProguardFiles\lib0\proguard.txt # The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\bb5ec4ef561b90312eb1ca52da1f144d\transformed\jetified-facebook-applinks-15.2.0\proguard.txt # Copyright (c) Meta Platforms, Inc. and affiliates. # All rights reserved. @@ -1638,6 +1638,10 @@ rx.internal.util.atomic.LinkedQueueNode* consumerNode; } # End of content from C:\Users\CVB88\.gradle\caches\transforms-3\3591196def6c89c6af74e7d30dfb6618\transformed\jetified-runtime-1.0.0\proguard.txt +# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\b826addf48d922103bc9588ad90ee0e6\transformed\jetified-Common-4.1.11\proguard.txt +# 本库模块专用的混淆规则 + +# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\b826addf48d922103bc9588ad90ee0e6\transformed\jetified-Common-4.1.11\proguard.txt # The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\7931210372c8927a076053831aae79b7\transformed\jetified-glide-transformations-3.1.1\proguard.txt -dontwarn jp.co.cyberagent.android.gpuimage.** @@ -1881,10 +1885,135 @@ rx.internal.util.atomic.LinkedQueueNode* consumerNode; } # End of content from C:\Users\CVB88\.gradle\caches\transforms-3\8daf89c63ab14ea80f11dcfb9154f87e\transformed\fragment-1.5.0\proguard.txt -# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\b826addf48d922103bc9588ad90ee0e6\transformed\jetified-Common-4.1.11\proguard.txt -# 本库模块专用的混淆规则 +# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\d5594233d50b1d727f4630790ca89a13\transformed\jetified-core-8.7.0\proguard.txt +# Add project specific ProGuard rules here. +# You can control the set of applied configuration files using the +# proguardFiles setting in build.gradle. +# +# For more details, see +# http://developer.android.com/guide/developing/tools/proguard.html -# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\b826addf48d922103bc9588ad90ee0e6\transformed\jetified-Common-4.1.11\proguard.txt +# If your project uses WebView with JS, uncomment the following +# and specify the fully qualified class name to the JavaScript interface +# class: +#-keepclassmembers class fqcn.of.javascript.interface.for.webview { +# public *; +#} + +# Uncomment this to preserve the line number information for +# debugging stack traces. +#-keepattributes SourceFile,LineNumberTable + +# If you keep the line number information, uncomment this to +# hide the original source file name. +#-renamesourcefileattribute SourceFile + +#################### FaceUnity ####################### +-keep class com.faceunity.wrapper.faceunity {*;} +-keep class com.faceunity.wrapper.faceunity$RotatedImage {*;} + +# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\d5594233d50b1d727f4630790ca89a13\transformed\jetified-core-8.7.0\proguard.txt +# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\526e7910eaa433763f36b642f34c1fee\transformed\jetified-exoplayer-core-2.18.2\proguard.txt +# Proguard rules specific to the core module. + +# Constructors accessed via reflection in DefaultRenderersFactory +-dontnote com.google.android.exoplayer2.ext.vp9.LibvpxVideoRenderer +-keepclassmembers class com.google.android.exoplayer2.ext.vp9.LibvpxVideoRenderer { + (long, android.os.Handler, com.google.android.exoplayer2.video.VideoRendererEventListener, int); +} +-dontnote com.google.android.exoplayer2.ext.av1.Libgav1VideoRenderer +-keepclassmembers class com.google.android.exoplayer2.ext.av1.Libgav1VideoRenderer { + (long, android.os.Handler, com.google.android.exoplayer2.video.VideoRendererEventListener, int); +} +-dontnote com.google.android.exoplayer2.ext.opus.LibopusAudioRenderer +-keepclassmembers class com.google.android.exoplayer2.ext.opus.LibopusAudioRenderer { + (android.os.Handler, com.google.android.exoplayer2.audio.AudioRendererEventListener, com.google.android.exoplayer2.audio.AudioSink); +} +-dontnote com.google.android.exoplayer2.ext.flac.LibflacAudioRenderer +-keepclassmembers class com.google.android.exoplayer2.ext.flac.LibflacAudioRenderer { + (android.os.Handler, com.google.android.exoplayer2.audio.AudioRendererEventListener, com.google.android.exoplayer2.audio.AudioSink); +} +-dontnote com.google.android.exoplayer2.ext.ffmpeg.FfmpegAudioRenderer +-keepclassmembers class com.google.android.exoplayer2.ext.ffmpeg.FfmpegAudioRenderer { + (android.os.Handler, com.google.android.exoplayer2.audio.AudioRendererEventListener, com.google.android.exoplayer2.audio.AudioSink); +} + +# Constructors accessed via reflection in DefaultDownloaderFactory +-dontnote com.google.android.exoplayer2.source.dash.offline.DashDownloader +-keepclassmembers class com.google.android.exoplayer2.source.dash.offline.DashDownloader { + (com.google.android.exoplayer2.MediaItem, com.google.android.exoplayer2.upstream.cache.CacheDataSource$Factory, java.util.concurrent.Executor); +} +-dontnote com.google.android.exoplayer2.source.hls.offline.HlsDownloader +-keepclassmembers class com.google.android.exoplayer2.source.hls.offline.HlsDownloader { + (com.google.android.exoplayer2.MediaItem, com.google.android.exoplayer2.upstream.cache.CacheDataSource$Factory, java.util.concurrent.Executor); +} +-dontnote com.google.android.exoplayer2.source.smoothstreaming.offline.SsDownloader +-keepclassmembers class com.google.android.exoplayer2.source.smoothstreaming.offline.SsDownloader { + (com.google.android.exoplayer2.MediaItem, com.google.android.exoplayer2.upstream.cache.CacheDataSource$Factory, java.util.concurrent.Executor); +} + +# Constructors accessed via reflection in DefaultMediaSourceFactory +-dontnote com.google.android.exoplayer2.source.dash.DashMediaSource$Factory +-keepclasseswithmembers class com.google.android.exoplayer2.source.dash.DashMediaSource$Factory { + (com.google.android.exoplayer2.upstream.DataSource$Factory); +} +-dontnote com.google.android.exoplayer2.source.hls.HlsMediaSource$Factory +-keepclasseswithmembers class com.google.android.exoplayer2.source.hls.HlsMediaSource$Factory { + (com.google.android.exoplayer2.upstream.DataSource$Factory); +} +-dontnote com.google.android.exoplayer2.source.smoothstreaming.SsMediaSource$Factory +-keepclasseswithmembers class com.google.android.exoplayer2.source.smoothstreaming.SsMediaSource$Factory { + (com.google.android.exoplayer2.upstream.DataSource$Factory); +} +-dontnote com.google.android.exoplayer2.source.rtsp.RtspMediaSource$Factory +-keepclasseswithmembers class com.google.android.exoplayer2.source.rtsp.RtspMediaSource$Factory { + (); +} + +# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\526e7910eaa433763f36b642f34c1fee\transformed\jetified-exoplayer-core-2.18.2\proguard.txt +# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\093cf4894c646f12adcf0608a8578513\transformed\vectordrawable-animated-1.1.0\proguard.txt +# Copyright (C) 2016 The Android Open Source Project +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# keep setters in VectorDrawables so that animations can still work. +-keepclassmembers class androidx.vectordrawable.graphics.drawable.VectorDrawableCompat$* { + void set*(***); + *** get*(); +} + +# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\093cf4894c646f12adcf0608a8578513\transformed\vectordrawable-animated-1.1.0\proguard.txt +# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\2d0bd167b8e4c9403f38fc379546639f\transformed\transition-1.4.1\proguard.txt +# Copyright (C) 2017 The Android Open Source Project +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Keep a field in transition that is used to keep a reference to weakly-referenced object +-keepclassmembers class androidx.transition.ChangeBounds$* extends android.animation.AnimatorListenerAdapter { + androidx.transition.ChangeBounds$ViewBounds mViewBounds; +} + +# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\2d0bd167b8e4c9403f38fc379546639f\transformed\transition-1.4.1\proguard.txt # The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\cee8df21fdda9dd7e6106d8566e7a8de\transformed\jetified-facebook-core-15.2.0\proguard.txt # Copyright (c) Meta Platforms, Inc. and affiliates. # All rights reserved. @@ -1944,7 +2073,92 @@ rx.internal.util.atomic.LinkedQueueNode* consumerNode; } # End of content from C:\Users\CVB88\.gradle\caches\transforms-3\cee8df21fdda9dd7e6106d8566e7a8de\transformed\jetified-facebook-core-15.2.0\proguard.txt -# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\570c85082e748d036cbe1ff0c9d5e429\transformed\lifecycle-viewmodel-2.5.0\proguard.txt +# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\3db9f5e64eaa2a61a80545d78dbfe4ed\transformed\jetified-facebook-bolts-15.2.0\proguard.txt +# Copyright (c) Meta Platforms, Inc. and affiliates. +# All rights reserved. +# +# This source code is licensed under the license found in the +# LICENSE file in the root directory of this source tree. + +# To enable ProGuard in your project, edit project.properties +# to define the proguard.config property as described in that file. +# +# Add project specific ProGuard rules here. +# By default, the flags in this file are appended to flags specified +# in ${sdk.dir}/tools/proguard/proguard-android.txt +# You can edit the include path and order by changing the ProGuard +# include property in project.properties. +# +# For more details, see +# http://developer.android.com/guide/developing/tools/proguard.html + +# Add any project specific keep options here: + +# If your project uses WebView with JS, uncomment the following +# and specify the fully qualified class name to the JavaScript interface +# class: +#-keepclassmembers class fqcn.of.javascript.interface.for.webview { +# public *; +#} + +-keepclassmembers class * implements java.io.Serializable { + private static final java.io.ObjectStreamField[] serialPersistentFields; + private void writeObject(java.io.ObjectOutputStream); + private void readObject(java.io.ObjectInputStream); + java.lang.Object writeReplace(); + java.lang.Object readResolve(); +} + +# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\3db9f5e64eaa2a61a80545d78dbfe4ed\transformed\jetified-facebook-bolts-15.2.0\proguard.txt +# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\13795feba8dd8fc2e0266a202e40730e\transformed\media-1.6.0\proguard.txt +# Copyright (C) 2017 The Android Open Source Project +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Prevent Parcelable objects from being removed or renamed. +-keep class android.support.v4.media.** implements android.os.Parcelable { + public static final android.os.Parcelable$Creator *; +} + +# Prevent Parcelable objects from being removed or renamed. +-keep class androidx.media.** implements android.os.Parcelable { + public static final android.os.Parcelable$Creator *; +} +# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\13795feba8dd8fc2e0266a202e40730e\transformed\media-1.6.0\proguard.txt +# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\d8c3626714f2e560684e4c222f456210\transformed\core-1.13.0\proguard.txt +# Never inline methods, but allow shrinking and obfuscation. +-keepclassmembernames,allowobfuscation,allowshrinking class androidx.core.view.ViewCompat$Api* { + ; +} +-keepclassmembernames,allowobfuscation,allowshrinking class androidx.core.view.WindowInsetsCompat$*Impl* { + ; +} +-keepclassmembernames,allowobfuscation,allowshrinking class androidx.core.app.NotificationCompat$*$Api*Impl { + ; +} +-keepclassmembernames,allowobfuscation,allowshrinking class androidx.core.os.UserHandleCompat$Api*Impl { + ; +} +-keepclassmembernames,allowobfuscation,allowshrinking class androidx.core.widget.EdgeEffectCompat$Api*Impl { + ; +} + +# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\d8c3626714f2e560684e4c222f456210\transformed\core-1.13.0\proguard.txt +# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\6ece486db0154bb73a7bdce438b43da9\transformed\jetified-lifecycle-process-2.6.2\proguard.txt +# this rule is need to work properly when app is compiled with api 28, see b/142778206 +-keepclassmembers class * extends androidx.lifecycle.EmptyActivityLifecycleCallbacks { *; } +# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\6ece486db0154bb73a7bdce438b43da9\transformed\jetified-lifecycle-process-2.6.2\proguard.txt +# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\8e869a6a6c2530a8e446d599f2764da5\transformed\lifecycle-viewmodel-2.6.2\proguard.txt -keepclassmembers,allowobfuscation class * extends androidx.lifecycle.ViewModel { (); } @@ -1953,8 +2167,33 @@ rx.internal.util.atomic.LinkedQueueNode* consumerNode; (android.app.Application); } -# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\570c85082e748d036cbe1ff0c9d5e429\transformed\lifecycle-viewmodel-2.5.0\proguard.txt -# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\badee3548ba9b653d6517fdeb8829767\transformed\jetified-lifecycle-viewmodel-savedstate-2.5.0\proguard.txt +# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\8e869a6a6c2530a8e446d599f2764da5\transformed\lifecycle-viewmodel-2.6.2\proguard.txt +# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\ce0e6750868f3f66322f188d971f1ef3\transformed\lifecycle-runtime-2.6.2\proguard.txt +-keepattributes AnnotationDefault, + RuntimeVisibleAnnotations, + RuntimeVisibleParameterAnnotations, + RuntimeVisibleTypeAnnotations + +-keepclassmembers enum androidx.lifecycle.Lifecycle$Event { + ; +} + +-keep !interface * implements androidx.lifecycle.LifecycleObserver { +} + +-keep class * implements androidx.lifecycle.GeneratedAdapter { + (...); +} + +-keepclassmembers class ** { + @androidx.lifecycle.OnLifecycleEvent *; +} + +# this rule is need to work properly when app is compiled with api 28, see b/142778206 +# Also this rule prevents registerIn from being inlined. +-keepclassmembers class androidx.lifecycle.ReportFragment$LifecycleCallbacks { *; } +# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\ce0e6750868f3f66322f188d971f1ef3\transformed\lifecycle-runtime-2.6.2\proguard.txt +# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\bd00b9047184418faa7306a460ee0581\transformed\jetified-lifecycle-viewmodel-savedstate-2.6.2\proguard.txt -keepclassmembers,allowobfuscation class * extends androidx.lifecycle.ViewModel { (androidx.lifecycle.SavedStateHandle); } @@ -1963,8 +2202,28 @@ rx.internal.util.atomic.LinkedQueueNode* consumerNode; (android.app.Application,androidx.lifecycle.SavedStateHandle); } -# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\badee3548ba9b653d6517fdeb8829767\transformed\jetified-lifecycle-viewmodel-savedstate-2.5.0\proguard.txt -# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\0e43e19966d3ba7fcce157667e087c7e\transformed\rules\lib\META-INF\com.android.tools\r8\coroutines.pro +# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\bd00b9047184418faa7306a460ee0581\transformed\jetified-lifecycle-viewmodel-savedstate-2.6.2\proguard.txt +# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\3ada8249efd76aa45d398a9ccd7df9fd\transformed\jetified-savedstate-1.2.1\proguard.txt +# Copyright (C) 2019 The Android Open Source Project +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +-keepclassmembers,allowobfuscation class * implements androidx.savedstate.SavedStateRegistry$AutoRecreated { + (); +} + +# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\3ada8249efd76aa45d398a9ccd7df9fd\transformed\jetified-savedstate-1.2.1\proguard.txt +# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\31bdcbe39d5085657b9e9934bb01ff50\transformed\rules\lib\META-INF\com.android.tools\r8\coroutines.pro # When editing this file, update the following files as well: # - META-INF/proguard/coroutines.pro # - META-INF/com.android.tools/proguard/coroutines.pro @@ -1992,8 +2251,8 @@ rx.internal.util.atomic.LinkedQueueNode* consumerNode; # An annotation used for build tooling, won't be directly accessed. -dontwarn org.codehaus.mojo.animal_sniffer.IgnoreJRERequirement -# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\0e43e19966d3ba7fcce157667e087c7e\transformed\rules\lib\META-INF\com.android.tools\r8\coroutines.pro -# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\039aa78b17fc1889d62d4e8e7d7c1859\transformed\rules\lib\META-INF\com.android.tools\r8-from-1.6.0\coroutines.pro +# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\31bdcbe39d5085657b9e9934bb01ff50\transformed\rules\lib\META-INF\com.android.tools\r8\coroutines.pro +# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\8a5acccede271ffbd4cb8a39c6aa6b22\transformed\rules\lib\META-INF\com.android.tools\r8-from-1.6.0\coroutines.pro # Allow R8 to optimize away the FastServiceLoader. # Together with ServiceLoader optimization in R8 # this results in direct instantiation when loading Dispatchers.Main @@ -2005,8 +2264,6 @@ rx.internal.util.atomic.LinkedQueueNode* consumerNode; boolean ANDROID_DETECTED return true; } --keep class kotlinx.coroutines.android.AndroidDispatcherFactory {*;} - # Disable support for "Missing Main Dispatcher", since we always have Android main dispatcher -assumenosideeffects class kotlinx.coroutines.internal.MainDispatchersKt { boolean SUPPORT_MISSING return false; @@ -2018,7 +2275,8 @@ rx.internal.util.atomic.LinkedQueueNode* consumerNode; boolean getDEBUG() return false; boolean getRECOVER_STACK_TRACES() return false; } -# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\039aa78b17fc1889d62d4e8e7d7c1859\transformed\rules\lib\META-INF\com.android.tools\r8-from-1.6.0\coroutines.pro + +# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\8a5acccede271ffbd4cb8a39c6aa6b22\transformed\rules\lib\META-INF\com.android.tools\r8-from-1.6.0\coroutines.pro # The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\33f970d366250728877e2f4671336331\transformed\jetified-twitter-core-3.1.1\proguard.txt #GSON # Retain Annotations for model objects @@ -2868,261 +3126,21 @@ native ; } # End of content from C:\Users\CVB88\.gradle\caches\transforms-3\9fef6e1dea59ce01cbe6739f12545786\transformed\jetified-SudASR-1.4.3.1201\proguard.txt -# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\d5594233d50b1d727f4630790ca89a13\transformed\jetified-core-8.7.0\proguard.txt -# Add project specific ProGuard rules here. -# You can control the set of applied configuration files using the -# proguardFiles setting in build.gradle. -# -# For more details, see -# http://developer.android.com/guide/developing/tools/proguard.html +# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\04cfd08a3f97a34725fadda3af782615\transformed\jetified-startup-runtime-1.1.1\proguard.txt +# It's important that we preserve initializer names, given they are used in the AndroidManifest.xml. +-keepnames class * extends androidx.startup.Initializer -# If your project uses WebView with JS, uncomment the following -# and specify the fully qualified class name to the JavaScript interface -# class: -#-keepclassmembers class fqcn.of.javascript.interface.for.webview { -# public *; -#} - -# Uncomment this to preserve the line number information for -# debugging stack traces. -#-keepattributes SourceFile,LineNumberTable - -# If you keep the line number information, uncomment this to -# hide the original source file name. -#-renamesourcefileattribute SourceFile - -#################### FaceUnity ####################### --keep class com.faceunity.wrapper.faceunity {*;} --keep class com.faceunity.wrapper.faceunity$RotatedImage {*;} - -# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\d5594233d50b1d727f4630790ca89a13\transformed\jetified-core-8.7.0\proguard.txt -# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\526e7910eaa433763f36b642f34c1fee\transformed\jetified-exoplayer-core-2.18.2\proguard.txt -# Proguard rules specific to the core module. - -# Constructors accessed via reflection in DefaultRenderersFactory --dontnote com.google.android.exoplayer2.ext.vp9.LibvpxVideoRenderer --keepclassmembers class com.google.android.exoplayer2.ext.vp9.LibvpxVideoRenderer { - (long, android.os.Handler, com.google.android.exoplayer2.video.VideoRendererEventListener, int); -} --dontnote com.google.android.exoplayer2.ext.av1.Libgav1VideoRenderer --keepclassmembers class com.google.android.exoplayer2.ext.av1.Libgav1VideoRenderer { - (long, android.os.Handler, com.google.android.exoplayer2.video.VideoRendererEventListener, int); -} --dontnote com.google.android.exoplayer2.ext.opus.LibopusAudioRenderer --keepclassmembers class com.google.android.exoplayer2.ext.opus.LibopusAudioRenderer { - (android.os.Handler, com.google.android.exoplayer2.audio.AudioRendererEventListener, com.google.android.exoplayer2.audio.AudioSink); -} --dontnote com.google.android.exoplayer2.ext.flac.LibflacAudioRenderer --keepclassmembers class com.google.android.exoplayer2.ext.flac.LibflacAudioRenderer { - (android.os.Handler, com.google.android.exoplayer2.audio.AudioRendererEventListener, com.google.android.exoplayer2.audio.AudioSink); -} --dontnote com.google.android.exoplayer2.ext.ffmpeg.FfmpegAudioRenderer --keepclassmembers class com.google.android.exoplayer2.ext.ffmpeg.FfmpegAudioRenderer { - (android.os.Handler, com.google.android.exoplayer2.audio.AudioRendererEventListener, com.google.android.exoplayer2.audio.AudioSink); -} - -# Constructors accessed via reflection in DefaultDownloaderFactory --dontnote com.google.android.exoplayer2.source.dash.offline.DashDownloader --keepclassmembers class com.google.android.exoplayer2.source.dash.offline.DashDownloader { - (com.google.android.exoplayer2.MediaItem, com.google.android.exoplayer2.upstream.cache.CacheDataSource$Factory, java.util.concurrent.Executor); -} --dontnote com.google.android.exoplayer2.source.hls.offline.HlsDownloader --keepclassmembers class com.google.android.exoplayer2.source.hls.offline.HlsDownloader { - (com.google.android.exoplayer2.MediaItem, com.google.android.exoplayer2.upstream.cache.CacheDataSource$Factory, java.util.concurrent.Executor); -} --dontnote com.google.android.exoplayer2.source.smoothstreaming.offline.SsDownloader --keepclassmembers class com.google.android.exoplayer2.source.smoothstreaming.offline.SsDownloader { - (com.google.android.exoplayer2.MediaItem, com.google.android.exoplayer2.upstream.cache.CacheDataSource$Factory, java.util.concurrent.Executor); -} - -# Constructors accessed via reflection in DefaultMediaSourceFactory --dontnote com.google.android.exoplayer2.source.dash.DashMediaSource$Factory --keepclasseswithmembers class com.google.android.exoplayer2.source.dash.DashMediaSource$Factory { - (com.google.android.exoplayer2.upstream.DataSource$Factory); -} --dontnote com.google.android.exoplayer2.source.hls.HlsMediaSource$Factory --keepclasseswithmembers class com.google.android.exoplayer2.source.hls.HlsMediaSource$Factory { - (com.google.android.exoplayer2.upstream.DataSource$Factory); -} --dontnote com.google.android.exoplayer2.source.smoothstreaming.SsMediaSource$Factory --keepclasseswithmembers class com.google.android.exoplayer2.source.smoothstreaming.SsMediaSource$Factory { - (com.google.android.exoplayer2.upstream.DataSource$Factory); -} --dontnote com.google.android.exoplayer2.source.rtsp.RtspMediaSource$Factory --keepclasseswithmembers class com.google.android.exoplayer2.source.rtsp.RtspMediaSource$Factory { - (); -} - -# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\526e7910eaa433763f36b642f34c1fee\transformed\jetified-exoplayer-core-2.18.2\proguard.txt -# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\2d16d937f787a1471d1fcefef8917ded\transformed\jetified-savedstate-1.2.0\proguard.txt -# Copyright (C) 2019 The Android Open Source Project -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - --keepclassmembers,allowobfuscation class * implements androidx.savedstate.SavedStateRegistry$AutoRecreated { +# These Proguard rules ensures that ComponentInitializers are are neither shrunk nor obfuscated, +# and are a part of the primary dex file. This is because they are discovered and instantiated +# during application startup. +-keep class * extends androidx.startup.Initializer { + # Keep the public no-argument constructor while allowing other methods to be optimized. (); } -# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\2d16d937f787a1471d1fcefef8917ded\transformed\jetified-savedstate-1.2.0\proguard.txt -# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\f55e0290d55f2ec9dfa66384635c714c\transformed\transition-1.2.0\proguard.txt -# Copyright (C) 2017 The Android Open Source Project -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +-assumenosideeffects class androidx.startup.StartupLogger { public static ; } -# Keep a field in transition that is used to keep a reference to weakly-referenced object --keepclassmembers class androidx.transition.ChangeBounds$* extends android.animation.AnimatorListenerAdapter { - androidx.transition.ChangeBounds$ViewBounds mViewBounds; -} - -# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\f55e0290d55f2ec9dfa66384635c714c\transformed\transition-1.2.0\proguard.txt -# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\093cf4894c646f12adcf0608a8578513\transformed\vectordrawable-animated-1.1.0\proguard.txt -# Copyright (C) 2016 The Android Open Source Project -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# keep setters in VectorDrawables so that animations can still work. --keepclassmembers class androidx.vectordrawable.graphics.drawable.VectorDrawableCompat$* { - void set*(***); - *** get*(); -} - -# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\093cf4894c646f12adcf0608a8578513\transformed\vectordrawable-animated-1.1.0\proguard.txt -# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\3db9f5e64eaa2a61a80545d78dbfe4ed\transformed\jetified-facebook-bolts-15.2.0\proguard.txt -# Copyright (c) Meta Platforms, Inc. and affiliates. -# All rights reserved. -# -# This source code is licensed under the license found in the -# LICENSE file in the root directory of this source tree. - -# To enable ProGuard in your project, edit project.properties -# to define the proguard.config property as described in that file. -# -# Add project specific ProGuard rules here. -# By default, the flags in this file are appended to flags specified -# in ${sdk.dir}/tools/proguard/proguard-android.txt -# You can edit the include path and order by changing the ProGuard -# include property in project.properties. -# -# For more details, see -# http://developer.android.com/guide/developing/tools/proguard.html - -# Add any project specific keep options here: - -# If your project uses WebView with JS, uncomment the following -# and specify the fully qualified class name to the JavaScript interface -# class: -#-keepclassmembers class fqcn.of.javascript.interface.for.webview { -# public *; -#} - --keepclassmembers class * implements java.io.Serializable { - private static final java.io.ObjectStreamField[] serialPersistentFields; - private void writeObject(java.io.ObjectOutputStream); - private void readObject(java.io.ObjectInputStream); - java.lang.Object writeReplace(); - java.lang.Object readResolve(); -} - -# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\3db9f5e64eaa2a61a80545d78dbfe4ed\transformed\jetified-facebook-bolts-15.2.0\proguard.txt -# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\13795feba8dd8fc2e0266a202e40730e\transformed\media-1.6.0\proguard.txt -# Copyright (C) 2017 The Android Open Source Project -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Prevent Parcelable objects from being removed or renamed. --keep class android.support.v4.media.** implements android.os.Parcelable { - public static final android.os.Parcelable$Creator *; -} - -# Prevent Parcelable objects from being removed or renamed. --keep class androidx.media.** implements android.os.Parcelable { - public static final android.os.Parcelable$Creator *; -} -# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\13795feba8dd8fc2e0266a202e40730e\transformed\media-1.6.0\proguard.txt -# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\c6ec9c31a3362678dbcc66f2e9ea7260\transformed\core-1.10.1\proguard.txt -# Never inline methods, but allow shrinking and obfuscation. --keepclassmembernames,allowobfuscation,allowshrinking class androidx.core.view.ViewCompat$Api* { - ; -} --keepclassmembernames,allowobfuscation,allowshrinking class androidx.core.view.WindowInsetsCompat$*Impl* { - ; -} --keepclassmembernames,allowobfuscation,allowshrinking class androidx.core.app.NotificationCompat$*$Api*Impl { - ; -} --keepclassmembernames,allowobfuscation,allowshrinking class androidx.core.os.UserHandleCompat$Api*Impl { - ; -} --keepclassmembernames,allowobfuscation,allowshrinking class androidx.core.widget.EdgeEffectCompat$Api*Impl { - ; -} - -# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\c6ec9c31a3362678dbcc66f2e9ea7260\transformed\core-1.10.1\proguard.txt -# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\2c964f4aa7e08caf6a082be78fa332c4\transformed\lifecycle-runtime-2.5.0\proguard.txt --keepattributes AnnotationDefault, - RuntimeVisibleAnnotations, - RuntimeVisibleParameterAnnotations, - RuntimeVisibleTypeAnnotations - --keepclassmembers enum androidx.lifecycle.Lifecycle$Event { - ; -} - --keep !interface * implements androidx.lifecycle.LifecycleObserver { -} - --keep class * implements androidx.lifecycle.GeneratedAdapter { - (...); -} - --keepclassmembers class ** { - @androidx.lifecycle.OnLifecycleEvent *; -} - -# this rule is need to work properly when app is compiled with api 28, see b/142778206 -# Also this rule prevents registerIn from being inlined. --keepclassmembers class androidx.lifecycle.ReportFragment$LifecycleCallbacks { *; } -# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\2c964f4aa7e08caf6a082be78fa332c4\transformed\lifecycle-runtime-2.5.0\proguard.txt +# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\04cfd08a3f97a34725fadda3af782615\transformed\jetified-startup-runtime-1.1.1\proguard.txt # The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\4a3cce138aa30f2fd0df44bf999a62d2\transformed\jetified-exoplayer-datasource-2.18.2\proguard.txt # Proguard rules specific to the DataSource module. @@ -3204,17 +3222,6 @@ native ; -dontwarn com.google.auto.value.AutoValue$Builder # End of content from C:\Users\CVB88\.gradle\caches\transforms-3\ad1f4a6564b34286db155b9a62614b62\transformed\jetified-transport-api-3.0.0\proguard.txt -# The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\48f6f745536202396d49c6664e656f00\transformed\jetified-startup-runtime-1.0.0\proguard.txt -# This Proguard rule ensures that ComponentInitializers are are neither shrunk nor obfuscated. -# This is because they are discovered and instantiated during application initialization. --keep class * extends androidx.startup.Initializer { - # Keep the public no-argument constructor while allowing other methods to be optimized. - (); -} - --assumenosideeffects class androidx.startup.StartupLogger - -# End of content from C:\Users\CVB88\.gradle\caches\transforms-3\48f6f745536202396d49c6664e656f00\transformed\jetified-startup-runtime-1.0.0\proguard.txt # The proguard configuration file for the following section is C:\Users\CVB88\.gradle\caches\transforms-3\e1bbd140b52a8e61bea52bf380947059\transformed\jetified-firebase-components-17.0.1\proguard.txt -dontwarn com.google.firebase.components.Component$Instantiation -dontwarn com.google.firebase.components.Component$ComponentType diff --git a/config.gradle b/config.gradle index 7d9737ebc..df71ccf07 100644 --- a/config.gradle +++ b/config.gradle @@ -4,7 +4,7 @@ ext { buildToolsVersion: "29.0.2", minSdkVersion : 23, targetSdkVersion : 34, - versionCode : 603, + versionCode : 604, versionName : "6.8.1", namespace : "com.pandoralive.shayu" ] diff --git a/lib_faceunity/src/main/java/io/agora/beautyapi/faceunity/agora/SWManager.java b/lib_faceunity/src/main/java/io/agora/beautyapi/faceunity/agora/SWManager.java index 1defc06b1..c59e00f02 100644 --- a/lib_faceunity/src/main/java/io/agora/beautyapi/faceunity/agora/SWManager.java +++ b/lib_faceunity/src/main/java/io/agora/beautyapi/faceunity/agora/SWManager.java @@ -5,13 +5,16 @@ import android.content.ContentResolver; import android.content.Context; import android.graphics.Bitmap; import android.graphics.drawable.BitmapDrawable; +import android.hardware.camera2.CameraManager; import android.net.Uri; import android.text.TextUtils; import android.view.SurfaceView; import android.widget.FrameLayout; +import androidx.annotation.NonNull; import androidx.core.content.res.ResourcesCompat; +import com.blankj.utilcode.util.LogUtils; import com.yunbao.common.CommonAppConfig; import com.yunbao.common.CommonAppContext; import com.yunbao.common.bean.SwTokenModel; @@ -68,6 +71,7 @@ public class SWManager extends BaseCacheManager { private ImageTrackOptions imageTrackOptions = null; private onDrPkJoinSuccessListener onDrPkJoinSuccessListener; + String openCameraId = "1"; public void setOnDrPkJoinSuccessListener(SWManager.onDrPkJoinSuccessListener onDrPkJoinSuccessListener) { this.onDrPkJoinSuccessListener = onDrPkJoinSuccessListener; @@ -252,7 +256,20 @@ public class SWManager extends BaseCacheManager { */ public void switchCamera() { if (mRtcEngine != null) { - mRtcEngine.switchCamera(); + if (openCameraId.equals("0")) { + mRtcEngine.switchCamera("1"); + openCameraId = "1"; + } else { + mRtcEngine.switchCamera("0"); + openCameraId = "0"; + } + } + } + + public void resetCamera() { + LogUtils.e("重置摄像头", openCameraId); + if (mRtcEngine != null && !TextUtils.isEmpty(openCameraId)) { + mRtcEngine.switchCamera(openCameraId); } } @@ -524,6 +541,9 @@ public class SWManager extends BaseCacheManager { }); } + public void release() { + } + public interface onRtcEngineListener { void onOpenSuccess(String channel, int uid); diff --git a/live/src/main/java/com/yunbao/live/views/LivePushSwViewHolder.java b/live/src/main/java/com/yunbao/live/views/LivePushSwViewHolder.java index d281ec6a8..9f84f9d85 100644 --- a/live/src/main/java/com/yunbao/live/views/LivePushSwViewHolder.java +++ b/live/src/main/java/com/yunbao/live/views/LivePushSwViewHolder.java @@ -504,8 +504,9 @@ public class LivePushSwViewHolder extends AbsRyLivePushViewHolder implements ITX public void onResume() { mPaused = false; Log.i("摄像头", "onResume: " + isNeedOpenCamera); + swManager.resetCamera(); if (isNeedOpenCamera) { - RCRTCEngine.getInstance().getDefaultVideoStream().startCamera(new IRCRTCResultDataCallback() { + /*RCRTCEngine.getInstance().getDefaultVideoStream().startCamera(new IRCRTCResultDataCallback() { @Override public void onSuccess(Boolean data) { //设置摄像头最大缩放比例 @@ -519,7 +520,7 @@ public class LivePushSwViewHolder extends AbsRyLivePushViewHolder implements ITX public void onFailed(RTCErrorCode errorCode) { Log.i("摄像头", "onFailed: 打开摄像头失败 " + errorCode); } - }); + });*/ } } @@ -549,6 +550,8 @@ public class LivePushSwViewHolder extends AbsRyLivePushViewHolder implements ITX public void release() { super.release(); Bus.getOff(this); + onDestroy(); + SWManager.get().release(); LiveHttpUtil.cancel(LiveHttpConsts.LINK_MIC_TX_MIX_STREAM); rtcRoom = null; }