# 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

# 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 *;
#}
#-repackageclasses com.meihu //统一归到一个包下
# 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
#表示混淆时不使用大小写混合类名
-dontusemixedcaseclassnames
#表示不跳过library中的非public的类
-dontskipnonpubliclibraryclasses
-dontskipnonpubliclibraryclassmembers
#打印混淆的详细信息
-verbose
-printmapping proguardMapping.txt

-optimizations !code/simplification/cast,!field/*,!class/merging/*

-keepattributes *Annotation*,InnerClasses
# Optimization is turned off by default. Dex does not like code run
# through the ProGuard optimize and preverify steps (and performs some
# of these optimizations on its own).
-dontoptimize
##表示不进行校验,这个校验作用 在java平台上的
#-dontpreverify
# Note that if you want to enable optimization, you cannot just
# include optimization flags in your own project configuration file;
# instead you will need to point to the
# "proguard-android-optimize.txt" file instead of this one from your
# project.properties file.

-keepattributes *Annotation*

# For native methods, see http://proguard.sourceforge.net/manual/examples.html#native
-keepclasseswithmembernames class * {
    native <methods>;
}

# keep setters in Views so that animations can still work.
# see http://proguard.sourceforge.net/manual/examples.html#beans
#-keepclassmembers public class * extends android.view.View {
#   void set*(***);
#   *** get*();
#}


-keep public class * extends android.app.Activity
-keep public class * extends android.app.Application
-keep public class * extends android.app.Service
-keep public class * extends android.content.BroadcastReceiver
-keep public class * extends android.content.ContentProvider
-keep public class * extends android.app.backup.BackupAgentHelper
-keep public class * extends android.preference.Preference
-keep public class * extends android.view.View
-keep class androidx.** {*;}
-keep class android.util.** {*;}

-keep public class * extends android.view.View {
   public <init>(android.content.Context);
   public <init>(android.content.Context, android.util.AttributeSet);
   public <init>(android.content.Context, android.util.AttributeSet, int);
   public void set*(***);
   *** get*();
}

# We want to keep methods in Activity that could be used in the XML attribute onClick
-keepclassmembers class * extends android.app.Activity {
   public void *(android.view.View);
}

# For enumeration classes, see http://proguard.sourceforge.net/manual/examples.html#enumerations
-keepclassmembers enum * {
    public static **[] values();
    public static ** valueOf(java.lang.String);
}

-keepclassmembers class * implements android.os.Parcelable {
  public static final android.os.Parcelable$Creator CREATOR;
}

-keepclassmembers class **.R$* {
    public static <fields>;
}

# The support library contains references to newer platform versions.
# Don't warn about those in case this app is linking against an older
# platform version.  We know about them, and they are safe.
-dontwarn androidx.**

# Understand the @Keep support annotation.
-keep class androidx.annotation.Keep

-keep @androidx.annotation.Keep class * {*;}

-keepclasseswithmembers class * {
    @androidx.annotation.Keep <methods>;
}

-keepclasseswithmembers class * {
    @androidx.annotation.Keep <fields>;
}

-keepclasseswithmembers class * {
    @androidx.annotation.Keep <init>(...);
}

#忽略警告
-ignorewarnings
#保证是独立的jar,没有任何项目引用,如果不写就会认为我们所有的代码是无用的,从而把所有的代码压缩掉,导出一个空的jar
-dontshrink
#保护泛型
-keepattributes Signature

#
-assumenosideeffects class android.util.Log{
    public static *** v(...);
    public static *** i(...);
    public static *** d(...);
    public static *** w(...);
    public static *** e(...);
}

#-keep class com.meihu.beautylibrary.render.MHRender {
#    public <init>();
#}
-keep public class com.meihu.beautylibrary.manager.SharedPreferencesManager{
    public <methods>;
}
-keep class com.meihu.beautylibrary.ve_gl.EglBase {*;}
-keep public class com.meihu.beautylibrary.ve_gl.*{
    public <methods>;
}
-keep interface com.meihu.beautylibrary.utils.DownloadUtil$Callback{
    public <methods>;
}
#-keepclasseswithmembers class com.meihu.beautylibrary.manager.MHBeautyManager {
#    public void *(**);kall
#}
-keep class com.meihu.beautylibrary.manager.MHBeautyManager {
    public <methods>;
}

-keep class com.meihu.beautylibrary.bean.* {*;}
-keep class com.meihu.beautylibrary.program.* {*;}
-keep class com.meihu.beautylibrary.filter.glfilter.resource.bean.* {*;}
#-keep class com.meihu.beautylibrary.filter.glfilter.resource.bean.ResourceData {*;}
#-keep class com.meihu.beautylibrary.filter.glfilter.resource.ResourceHelper{*;}
#-keep class com.meihu.beautylibrary.filter.glfilter.color.bean.DynamicColor{*;}
#-keep enum com.meihu.beautylibrary.filter.glfilter.resource.bean.ResourceType {*;}
#-keep class com.meihu.beautylibrary.filter.glfilter.resource.ResourceCodec.FileDescription {*;}
#-keep class com.meihu.beautylibrary.filter.glfilter.color.bean.DynamicColorData {*;}
-keep class com.meihu.beautylibrary.utils.ThemisUtil {*;}
-keep class com.meihu.beautylibrary.utils.StringUtils {*;}
-keep class com.meihu.beautylibrary.utils.UrlUtils {*;}
-keep class com.meihu.beautylibrary.filter.glfilter.utils.OpenGLUtils {*;}

-keep class  com.meihu.beautylibrary.makeup.* {*;}
-keep class  com.meihu.beautylibrary.constant.UrlConstants {*;}
-keep class  com.meihu.beautylibrary.interfaces.* {*;}

-keep class com.meihu.beautylibrary.render.filter.ksyFilter.GLImageVertFlipFilter {*;}
-keep class com.facegl.FaceTracking {*;}
-keep class com.meihu.beautylibrary.network.DownLoadCallBack{
    public <methods>;
}

-keep class com.meihu.beautylibrary.utils.DownloadUtil{
    public <methods>;
}

-keep class com.meihu.beautylibrary.manager.StickerDownLoader{
    public <methods>;
}
-keep class com.meihu.beautylibrary.manager.LogManager{
    public <methods>;
}
-keep class com.meihu.beautylibrary.MHSDK{
    public <methods>;
}

-keep class com.meihu.beautylibrary.render.filter.water.GLImageWatermarkFilter$CGRect{ *; }


#txmlvb
-dontwarn com.tencent.**
-keep class com.tencent.** { *; }

#Kalle
-dontwarn com.meihu.kalle.**
-keep class com.meihu.kalle** { *; }

#okhttp
## JSR 305 annotations are for embedding nullability information.
#-dontwarn javax.annotation.**
## A resource is loaded with a relative path so the package of this class must be preserved.
#-keepnames class okhttp3.internal.publicsuffix.PublicSuffixDatabase
## Animal Sniffer compileOnly dependency to ensure APIs are compatible with older versions of Java.
#-dontwarn org.codehaus.mojo.animal_sniffer.*
## OkHttp platform used only on JVM and when Conscrypt dependency is available.
#-dontwarn okhttp3.internal.platform.ConscryptPlatform

#rxbus
#-dontwarn com.hwangjr.rxbus.**
#-keep class com.hwangjr.rxbus.**{*;}

#okdownloader
#-dontwarn com.liulishuo.okdownload.**
#-keep class com.liulishuo.okdownload.**{*;}
#-dontwarn edu.umd.cs.**
#-keep class edu.umd.cs.**{*;}

#gpuimage
#-dontwarn jp.co.cyberagent.android.**
#-keep class jp.co.cyberagent.android.**{*;}

#glide\
-keep public class com.meihu.glide.** {*;}
-keep public enum com.meihu.glide.load.ImageHeaderParser$** {
  **[] $VALUES;
  public *;
}
#If you're targeting any API level less than Android API 27, also include:
-dontwarn com.meihu.glide.load.resource.bitmap.VideoDecoder
# for DexGuard only
#-keepresourcexmlelements manifest/application/meta-data@value=GlideModule
-keepattributes Signature

# For using GSON @Expose annotation
-keepattributes *Annotation*

# Gson specific classes
-dontwarn sun.misc.**
#-keep class com.google.gson.stream.** { *; }

# Application classes that will be serialized/deserialized over Gson
#-keep class com.meihu.beautylibrary.ui.bean.StickerServiceBean {*;}

# Prevent proguard from stripping interface information from TypeAdapterFactory,
# JsonSerializer, JsonDeserializer instances (so they can be used in @JsonAdapter)

# Prevent R8 from leaving Data object members always null
