Commit c60cf038 by mReturn

V2.5.7

parent 111203fe
Showing with 3188 additions and 0 deletions
apply plugin: 'com.android.library'
android {
compileSdkVersion compile_sdk_version
buildToolsVersion build_tools_version
defaultConfig {
minSdkVersion min_sdk_version
targetSdkVersion target_sdk_version
versionCode version_code
versionName verson_name
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
implementation fileTree(include: ['*.jar'], dir: 'libs')
implementation "com.android.support:appcompat-v7:27.1.1"
implementation "com.android.support:recyclerview-v7:27.1.1"
}
# 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 *;
#}
# 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
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.tencent.liteav.demo.beauty">
</manifest>
\ No newline at end of file
package com.tencent.liteav.demo.beauty;
public class BeautyData {
public int icon;
public String text;
public BeautyData(int icon, String text) {
this.icon = icon;
this.text = text;
}
}
package com.tencent.liteav.demo.beauty;
import android.app.Activity;
import android.content.Context;
import android.content.SharedPreferences;
import android.content.res.Resources;
import android.graphics.Bitmap;
import android.graphics.BitmapFactory;
import android.graphics.Color;
import android.preference.PreferenceManager;
import android.text.TextUtils;
import android.util.AttributeSet;
import android.util.Log;
import android.util.TypedValue;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.ArrayAdapter;
import android.widget.FrameLayout;
import android.widget.SeekBar;
import android.widget.TextView;
import android.widget.Toast;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
/**
* Module: BeautyPanel
* <p>
* Function: 美颜的控制 View 控件
*/
public class BeautyPanel extends FrameLayout implements SeekBar.OnSeekBarChangeListener, View.OnClickListener {
private final String TAG = "BeautyPanel";
// 美容
public static final int ITEM_TYPE_BEAUTY = 0;
// 滤镜
public static final int ITEM_TYPE_FILTTER = 1;
// 动效贴纸
public static final int ITEM_TYPE_MOTION = 2;
// 美妆
public static final int ITEM_TYPE_BEAUTY_FACE = 3;
// 手势
public static final int ITEM_TYPE_GESUTRE = 4;
// 抠背
public static final int ITEM_TYPE_KOUBEI = 5;
// 绿幕
public static final int ITEM_TYPE_GREEN = 6;
// 美体
public static final int ITEM_TYPE_BEAUTY_BODY = 7;
private int mSencodGradleType = ITEM_TYPE_BEAUTY;
private int mThirdGradleIndex = 0;
private int[][] mSzSeekBarValue = null;
private int[] mSzSecondGradleIndex = new int[16];
private TextView mSeekBarValue;
private SeekBar mSeekbar;
private CustomProgressDialog mCustomProgressDialog;
private final int mFilterBasicLevel = 5;
private final int mBeautyBasicLevel = 4;
private final int mWhiteBasicLevel = 1;
private final int mRuddyBasicLevel = 0;
private Context mContext;
public static final int BEAUTYPARAM_BEAUTY_STYLE_SMOOTH = 0; // 光滑
public static final int BEAUTYPARAM_BEAUTY_STYLE_NATURAL = 1; // 自然
public static final int BEAUTYPARAM_BEAUTY_STYLE_HAZY = 2; // 天天P图(朦胧)
private ArrayAdapter<String> mFirstGradleAdapter;
private ArrayList<BeautyData> mFilterBeautyDataList;
private ArrayList<BeautyData> mBeautyDataList;
private ArrayList<BeautyData> mGreenScreenDataList;
private ArrayList<BeautyData> mKoubeiDataList;
private ArrayList<BeautyData> mFaceBeautyDataList;
private ArrayList<BeautyData> mGestureDataLit;
private IconTextAdapter mItemAdapter;
private String[] mBeautyStyleString;
private String[] mFilterTypeString;
private ArrayList<String> mFirstGradleArrayString = new ArrayList<String>();
private List<MotionData> motionDataList = new ArrayList<>();
private List<MotionData> motionDataKoubeiList = new ArrayList<>();
private List<MotionData> motionBeautyFaceList = new ArrayList<>();
private List<MotionData> motionGestureList = new ArrayList<>();
private TCHorizontalScrollView mFirstGradlePicker;
private TCHorizontalScrollView mSecondGradlePicker;
private SharedPreferences mPrefs;
private ArrayList<BeautyData> mMotionDataList;
private MotionData motionData;
private ArrayList<BeautyData> beautyDataList;
private int mTextColorPrimary;
private IBeautyKit mProxy;
private BeautyParams mBeautyParams;
public BeautyPanel(Context context, AttributeSet attrs) {
super(context, attrs);
mContext = context;
mBeautyParams = new BeautyParams();
mBeautyStyleString = context.getResources().getStringArray(R.array.beauty_category);
mFilterTypeString = context.getResources().getStringArray(R.array.filter_type);
mPrefs = PreferenceManager.getDefaultSharedPreferences(mContext);
LayoutInflater.from(context).inflate(R.layout.beauty_panel, this);
initView();
}
public void setProxy(IBeautyKit proxy) {
mProxy = proxy;
}
private void initView() {
mTextColorPrimary = UIAttributeUtil.getColorRes(mContext, R.attr.beautyPanelColorPrimary, R.color.colorRed);
mSeekbar = (SeekBar) findViewById(R.id.seekbarThird);
mSeekbar.setOnSeekBarChangeListener(this);
mFirstGradlePicker = (TCHorizontalScrollView) findViewById(R.id.horizontalPickerViewFirst);
mSecondGradlePicker = (TCHorizontalScrollView) findViewById(R.id.horizontalPickerViewSecond);
mSeekBarValue = (TextView) findViewById(R.id.tvSeekbarValue);
mSeekBarValue.setTextColor(mTextColorPrimary);
mItemAdapter = new IconTextAdapter(mContext);
mItemAdapter.setTextColor(mTextColorPrimary);
initBeautyData();
initFilterData();
initMotionData();
initMotionLink();
initGreenScreenData();
initKoubeiData();
initFaceBeautyData();
initGestureData();
setFirstPickerType();
}
private void initMotionLink() {
motionDataList.add(new MotionData("none", "无动效", "", ""));
motionDataKoubeiList.add(new MotionData("none", "无", "", ""));
// 美妆
motionBeautyFaceList.add(new MotionData("none", "无", "", ""));
// 手势
motionGestureList.add(new MotionData("none", "无", "", ""));
}
private void initMotionData() {
mMotionDataList = new ArrayList<BeautyData>();
mMotionDataList.add(new BeautyData(R.drawable.ic_effect_non, getResources().getString(R.string.beauty_setting_pannel_dynamic_effect_none)));
mMotionDataList.add(new BeautyData(R.drawable.video_boom, getResources().getString(R.string.beauty_setting_pannel_dynamic_effect_boom)));
mMotionDataList.add(new BeautyData(R.drawable.video_nihongshu, getResources().getString(R.string.beauty_setting_pannel_dynamic_effect_neon_mouse)));
mMotionDataList.add(new BeautyData(R.drawable.video_fengkuangdacall, getResources().getString(R.string.beauty_setting_pannel_dynamic_effect_crazy_cheer_up)));
mMotionDataList.add(new BeautyData(R.drawable.video_qxingzuo, getResources().getString(R.string.beauty_setting_pannel_dynamic_effect_Q_cancelonstellation)));
mMotionDataList.add(new BeautyData(R.drawable.video_caidai, getResources().getString(R.string.beauty_setting_pannel_dynamic_effect_colored_ribbon)));
mMotionDataList.add(new BeautyData(R.drawable.video_liuhaifadai, getResources().getString(R.string.beauty_setting_pannel_dynamic_effect_bands_hairband)));
mMotionDataList.add(new BeautyData(R.drawable.video_purplecat, getResources().getString(R.string.beauty_setting_pannel_dynamic_effect_purple_kitten)));
mMotionDataList.add(new BeautyData(R.drawable.video_huaxianzi, getResources().getString(R.string.beauty_setting_pannel_dynamic_effect_flower_faerie)));
mMotionDataList.add(new BeautyData(R.drawable.video_baby_agetest, getResources().getString(R.string.beauty_setting_pannel_dynamic_effect_little_Princess)));
mMotionDataList.add(new BeautyData(R.drawable.video_starear, getResources().getString(R.string.beauty_setting_pannel_dynamic_effect_star_ear)));
mMotionDataList.add(new BeautyData(R.drawable.video_lianpu, getResources().getString(R.string.beauty_setting_pannel_dynamic_effect_change_face)));
// TODO:眼镜狗,彩虹云
}
/**
* 初始化美容数据
*/
private void initBeautyData() {
int beauty_smooth = UIAttributeUtil.getResResources(getContext(), R.attr.beautyPanelSmoothIcon, R.drawable.ic_beauty_smooth);
int beauty_natural = UIAttributeUtil.getResResources(getContext(), R.attr.beautyPanelNaturalIcon, R.drawable.ic_beauty_natural);
int beauty_pitu = UIAttributeUtil.getResResources(getContext(), R.attr.beautyPanelPituIcon, R.drawable.ic_beauty_pitu);
int beauty_white = UIAttributeUtil.getResResources(getContext(), R.attr.beautyPanelWhiteIcon, R.drawable.ic_beauty_white);
int beauty_ruddy = UIAttributeUtil.getResResources(getContext(), R.attr.beautyPanelRuddyIcon, R.drawable.ic_beauty_ruddy);
int beauty_bigeye = UIAttributeUtil.getResResources(getContext(), R.attr.beautyPanelBigeyeIcon, R.drawable.ic_beauty_bigeye);
int beauty_faceslim = UIAttributeUtil.getResResources(getContext(), R.attr.beautyPanelFaceslimIcon, R.drawable.ic_beauty_faceslim);
int beauty_facev = UIAttributeUtil.getResResources(getContext(), R.attr.beautyPanelFacevIcon, R.drawable.ic_beauty_facev);
int beauty_chin = UIAttributeUtil.getResResources(getContext(), R.attr.beautyPanelChinIcon, R.drawable.ic_beauty_chin);
int beauty_faceshort = UIAttributeUtil.getResResources(getContext(), R.attr.beautyPanelFaceshortIcon, R.drawable.ic_beauty_faceshort);
int beauty_noseslim = UIAttributeUtil.getResResources(getContext(), R.attr.beautyPanelNoseslimIcon, R.drawable.ic_beauty_noseslim);
int beauty_eyebright = UIAttributeUtil.getResResources(getContext(), R.attr.beautyPanelEyeLightenIcon, R.drawable.ic_eye_bright);
int beauty_toothwhite = UIAttributeUtil.getResResources(getContext(), R.attr.beautyPanelToothWhiteIcon, R.drawable.ic_tooth_white);
int beauty_pounchremove = UIAttributeUtil.getResResources(getContext(), R.attr.beautyPanelPounchRemoveIcon, R.drawable.ic_pounch_remove);
int beauty_wrinkles = UIAttributeUtil.getResResources(getContext(), R.attr.beautyPanelWrinkleIcon, R.drawable.ic_wrinkles);
int beauty_smileLines = UIAttributeUtil.getResResources(getContext(), R.attr.beautyPanelSmileLinesRemoveIcon, R.drawable.ic_smilelines);
int beauty_forehead = UIAttributeUtil.getResResources(getContext(), R.attr.beautyPanelForeheadIcon, R.drawable.ic_forehead);
int beauty_eyedistance = UIAttributeUtil.getResResources(getContext(), R.attr.beautyPanelEyeDistanceIcon, R.drawable.ic_eye_distance);
int beauty_eyeangle = UIAttributeUtil.getResResources(getContext(), R.attr.beautyPanelEyeAngleIcon, R.drawable.ic_eye_angle);
int beauty_mouthshape = UIAttributeUtil.getResResources(getContext(), R.attr.beautyPanelMouthShapeIcon, R.drawable.ic_mouseshape);
int beauty_nosewing = UIAttributeUtil.getResResources(getContext(), R.attr.beautyPanelNoseWingIcon, R.drawable.ic_nose_wing);
int beauty_noseposition = UIAttributeUtil.getResResources(getContext(), R.attr.beautyPanelNosePositionIcon, R.drawable.ic_nose_position);
int beauty_mousewidth = UIAttributeUtil.getResResources(getContext(), R.attr.beautyPanelMouseWidthIcon, R.drawable.ic_mouse_width);
int beauty_faceshape = UIAttributeUtil.getResResources(getContext(), R.attr.beautyPanelFaceShapeIcon, R.drawable.ic_faceshape);
mBeautyDataList = new ArrayList<BeautyData>();
mBeautyDataList.add(new BeautyData(beauty_smooth, getResources().getString(R.string.beauty_pannel_style_smooth)));
mBeautyDataList.add(new BeautyData(beauty_natural, getResources().getString(R.string.beauty_pannel_style_natural)));
mBeautyDataList.add(new BeautyData(beauty_pitu, getResources().getString(R.string.beauty_pannel_style_pitu)));
mBeautyDataList.add(new BeautyData(beauty_white, getResources().getString(R.string.beauty_pannel_white)));
mBeautyDataList.add(new BeautyData(beauty_ruddy, getResources().getString(R.string.beauty_pannel_ruddy)));
// mBeautyDataList.add(new BeautyData(beauty_bigeye, getResources().getString(R.string.beauty_pannel_bigeye)));
// mBeautyDataList.add(new BeautyData(beauty_faceslim, getResources().getString(R.string.beauty_pannel_faceslim)));
// mBeautyDataList.add(new BeautyData(beauty_facev, getResources().getString(R.string.beauty_pannel_facev)));
// mBeautyDataList.add(new BeautyData(beauty_chin, getResources().getString(R.string.beauty_pannel_chin)));
// mBeautyDataList.add(new BeautyData(beauty_faceshort, getResources().getString(R.string.beauty_pannel_faceshort)));
// mBeautyDataList.add(new BeautyData(beauty_noseslim, getResources().getString(R.string.beauty_pannel_noseslim)));
// mBeautyDataList.add(new BeautyData(beauty_eyebright, getResources().getString(R.string.beauty_pannel_eyelighten)));
// mBeautyDataList.add(new BeautyData(beauty_toothwhite, getResources().getString(R.string.beauty_pannel_toothwhite)));
// mBeautyDataList.add(new BeautyData(beauty_wrinkles, getResources().getString(R.string.beauty_pannel_wrinkleremove)));
// mBeautyDataList.add(new BeautyData(beauty_pounchremove, getResources().getString(R.string.beauty_pannel_pounchremove)));
// mBeautyDataList.add(new BeautyData(beauty_smileLines, getResources().getString(R.string.beauty_pannel_smilelinesremove)));
// mBeautyDataList.add(new BeautyData(beauty_forehead, getResources().getString(R.string.beauty_pannel_forehead)));
// mBeautyDataList.add(new BeautyData(beauty_eyedistance, getResources().getString(R.string.beauty_pannel_eyedistance)));
// mBeautyDataList.add(new BeautyData(beauty_eyeangle, getResources().getString(R.string.beauty_pannel_eyeangle)));
// mBeautyDataList.add(new BeautyData(beauty_mouthshape, getResources().getString(R.string.beauty_pannel_mouthshape)));
// mBeautyDataList.add(new BeautyData(beauty_nosewing, getResources().getString(R.string.beauty_pannel_nosewing)));
// mBeautyDataList.add(new BeautyData(beauty_noseposition, getResources().getString(R.string.beauty_pannel_noseposition)));
// mBeautyDataList.add(new BeautyData(beauty_mousewidth, getResources().getString(R.string.beauty_pannel_mousewidth)));
// mBeautyDataList.add(new BeautyData(beauty_faceshape, getResources().getString(R.string.beauty_pannel_faceshape)));
}
/**
* 初始化滤镜数据
*/
private void initFilterData() {
mFilterBeautyDataList = new ArrayList<BeautyData>();
mFilterBeautyDataList.add(new BeautyData(R.drawable.ic_effect_non, getResources().getString(R.string.beauty_setting_pannel_filter_none)));
mFilterBeautyDataList.add(new BeautyData(R.drawable.biaozhun, getResources().getString(R.string.beauty_setting_pannel_filter_standard)));
mFilterBeautyDataList.add(new BeautyData(R.drawable.yinghong, getResources().getString(R.string.beauty_setting_pannel_filter_cheery)));
mFilterBeautyDataList.add(new BeautyData(R.drawable.yunshang, getResources().getString(R.string.beauty_setting_pannel_filter_cloud)));
mFilterBeautyDataList.add(new BeautyData(R.drawable.chunzhen, getResources().getString(R.string.beauty_setting_pannel_filter_pure)));
mFilterBeautyDataList.add(new BeautyData(R.drawable.bailan, getResources().getString(R.string.beauty_setting_pannel_filter_orchid)));
mFilterBeautyDataList.add(new BeautyData(R.drawable.yuanqi, getResources().getString(R.string.beauty_setting_pannel_filter_vitality)));
mFilterBeautyDataList.add(new BeautyData(R.drawable.chaotuo, getResources().getString(R.string.beauty_setting_pannel_filter_super)));
mFilterBeautyDataList.add(new BeautyData(R.drawable.xiangfen, getResources().getString(R.string.beauty_setting_pannel_filter_fragrance)));
mFilterBeautyDataList.add(new BeautyData(R.drawable.fwhite, getResources().getString(R.string.beauty_setting_pannel_filter_white)));
mFilterBeautyDataList.add(new BeautyData(R.drawable.langman, getResources().getString(R.string.beauty_setting_pannel_filter_romantic)));
mFilterBeautyDataList.add(new BeautyData(R.drawable.qingxin, getResources().getString(R.string.beauty_setting_pannel_filter_fresh)));
mFilterBeautyDataList.add(new BeautyData(R.drawable.weimei, getResources().getString(R.string.beauty_setting_pannel_filter_beautiful)));
mFilterBeautyDataList.add(new BeautyData(R.drawable.fennen, getResources().getString(R.string.beauty_setting_pannel_filter_pink)));
mFilterBeautyDataList.add(new BeautyData(R.drawable.huaijiu, getResources().getString(R.string.beauty_setting_pannel_filter_reminiscence)));
mFilterBeautyDataList.add(new BeautyData(R.drawable.landiao, getResources().getString(R.string.beauty_setting_pannel_filter_blues)));
mFilterBeautyDataList.add(new BeautyData(R.drawable.qingliang, getResources().getString(R.string.beauty_setting_pannel_filter_cool)));
mFilterBeautyDataList.add(new BeautyData(R.drawable.rixi, getResources().getString(R.string.beauty_setting_pannel_filter_Japanese)));
}
/**
* 初始化绿幕数据
*/
private void initGreenScreenData() {
mGreenScreenDataList = new ArrayList<BeautyData>();
mGreenScreenDataList.add(new BeautyData(R.drawable.ic_effect_non, getResources().getString(R.string.beauty_setting_pannel_green_screen_none)));
mGreenScreenDataList.add(new BeautyData(R.drawable.ic_beauty_goodluck, getResources().getString(R.string.beauty_setting_pannel_green_screen_good_luck)));
}
private void initKoubeiData() {
mKoubeiDataList = new ArrayList<BeautyData>();
mKoubeiDataList.add(new BeautyData(R.drawable.ic_effect_non, getResources().getString(R.string.beauty_setting_pannel_key_none)));
mKoubeiDataList.add(new BeautyData(R.drawable.ic_beauty_koubei, getResources().getString(R.string.beauty_setting_pannel_key_AI_key)));
}
private void initGestureData() {
mGestureDataLit = new ArrayList<BeautyData>();
mGestureDataLit.add(new BeautyData(R.drawable.ic_effect_non, getResources().getString(R.string.beauty_setting_pannel_key_none)));
mGestureDataLit.add(new BeautyData(R.drawable.video_pikachu, getResources().getString(R.string.beauty_setting_pannel_pikaqiu)));
mGestureDataLit.add(new BeautyData(R.drawable.video_liuxingyu, getResources().getString(R.string.beauty_setting_pannel_liuxingyu)));
mGestureDataLit.add(new BeautyData(R.drawable.video_kongxue2, getResources().getString(R.string.beauty_setting_pannel_kongxue)));
mGestureDataLit.add(new BeautyData(R.drawable.video_dianshizhixing, getResources().getString(R.string.beauty_setting_pannel_dianshizhixing)));
mGestureDataLit.add(new BeautyData(R.drawable.video_bottle1, getResources().getString(R.string.beauty_setting_pannel_bottle)));
}
private void initFaceBeautyData() {
mFaceBeautyDataList = new ArrayList<BeautyData>();
mFaceBeautyDataList.add(new BeautyData(R.drawable.ic_effect_non, getResources().getString(R.string.beauty_setting_pannel_key_none)));
mFaceBeautyDataList.add(new BeautyData(R.drawable.video_cherries, getResources().getString(R.string.beauty_setting_pannel_cherries)));
mFaceBeautyDataList.add(new BeautyData(R.drawable.video_haiyang2, getResources().getString(R.string.beauty_setting_pannel_haiyang)));
mFaceBeautyDataList.add(new BeautyData(R.drawable.video_fenfenxia_square, getResources().getString(R.string.beauty_setting_pannel_fenfenxia)));
mFaceBeautyDataList.add(new BeautyData(R.drawable.video_guajiezhuang, getResources().getString(R.string.beauty_setting_pannel_guajiezhuang)));
mFaceBeautyDataList.add(new BeautyData(R.drawable.video_qixichun, getResources().getString(R.string.beauty_setting_pannel_qixichun)));
mFaceBeautyDataList.add(new BeautyData(R.drawable.video_gufengzhuang, getResources().getString(R.string.beauty_setting_pannel_gufengzhuang)));
mFaceBeautyDataList.add(new BeautyData(R.drawable.video_dxxiaochounv, getResources().getString(R.string.beauty_setting_pannel_xiaochounv)));
mFaceBeautyDataList.add(new BeautyData(R.drawable.video_remix1, getResources().getString(R.string.beauty_setting_pannel_hunhezhuang)));
mFaceBeautyDataList.add(new BeautyData(R.drawable.video_yuansufugu, getResources().getString(R.string.beauty_setting_pannel_yuansufugu)));
}
private void setFirstPickerType() {
mFirstGradleArrayString.clear();
mFirstGradleArrayString.addAll(Arrays.asList(mBeautyStyleString));
mFirstGradleAdapter = new ArrayAdapter<String>(mContext, 0, mFirstGradleArrayString) {
@Override
public View getView(int position, View convertView, ViewGroup parent) {
String value = getItem(position);
if (convertView == null) {
LayoutInflater inflater = LayoutInflater.from(getContext());
convertView = inflater.inflate(android.R.layout.simple_list_item_1, null);
}
TextView view = (TextView) convertView.findViewById(android.R.id.text1);
view.setTag(position);
view.setTextSize(TypedValue.COMPLEX_UNIT_SP, 16);
view.setText(value);
view.setPadding(15, 5, 30, 5);
view.setOnClickListener(new OnClickListener() {
@Override
public void onClick(View view) {
int index = (int) view.getTag();
ViewGroup group = (ViewGroup) mFirstGradlePicker.getChildAt(0);
for (int i = 0; i < mFirstGradleAdapter.getCount(); i++) {
View v = group.getChildAt(i);
if (v instanceof TextView) {
if (i == index) {
((TextView) v).setTextColor(mTextColorPrimary);
// ((TextView) v).setTextColor(mContext.getResources().getColor(R.color.colorRed));
} else {
((TextView) v).setTextColor(Color.WHITE);
}
}
}
setSecondPickerType(index);
}
});
return convertView;
}
};
mFirstGradlePicker.setAdapter(mFirstGradleAdapter);
mFirstGradlePicker.setClicked(ITEM_TYPE_BEAUTY);
}
private void setSecondPickerType(int type) {
mSencodGradleType = type;
beautyDataList = null;
switch (type) {
case ITEM_TYPE_BEAUTY:
beautyDataList = mBeautyDataList;
break;
case ITEM_TYPE_FILTTER:
beautyDataList = mFilterBeautyDataList;
break;
case ITEM_TYPE_MOTION:
beautyDataList = mMotionDataList;
break;
case ITEM_TYPE_KOUBEI:
beautyDataList = mKoubeiDataList;
break;
case ITEM_TYPE_GREEN:
beautyDataList = mGreenScreenDataList;
break;
case ITEM_TYPE_BEAUTY_FACE:
beautyDataList = mFaceBeautyDataList;
break;
case ITEM_TYPE_GESUTRE:
beautyDataList = mGestureDataLit;
break;
default:
break;
}
mItemAdapter.addAll(beautyDataList);
mItemAdapter.setOnItemClickListener(new OnItemClickListener() {
@Override
public void onItemClick(BeautyData beautyData, int pos) {
switch (mSencodGradleType) {
case ITEM_TYPE_BEAUTY:
case ITEM_TYPE_FILTTER:
case ITEM_TYPE_GREEN:
setPickerEffect(mSencodGradleType, pos);
break;
case ITEM_TYPE_KOUBEI:
if (pos > motionDataKoubeiList.size() - 1) {
return;
}
motionData = motionDataKoubeiList.get(pos);
if (motionData.mMotionId.equals("none") || !TextUtils.isEmpty(motionData.mMotionPath)) {
setPickerEffect(mSencodGradleType, pos);
} else if ((TextUtils.isEmpty(motionData.mMotionPath))) {
downloadVideoMaterial(beautyData, motionData, pos);
}
break;
case ITEM_TYPE_MOTION:
if (pos > motionDataList.size() - 1) {
return;
}
motionData = motionDataList.get(pos);
if (motionData.mMotionId.equals("none") || !TextUtils.isEmpty(motionData.mMotionPath)) {
setPickerEffect(mSencodGradleType, pos);
} else if ((TextUtils.isEmpty(motionData.mMotionPath))) {
downloadVideoMaterial(beautyData, motionData, pos);
}
break;
case ITEM_TYPE_BEAUTY_FACE:
if (pos > motionBeautyFaceList.size() - 1) {
return;
}
motionData = motionBeautyFaceList.get(pos);
if (motionData.mMotionId.equals("none") || !TextUtils.isEmpty(motionData.mMotionPath)) {
setPickerEffect(mSencodGradleType, pos);
} else if ((TextUtils.isEmpty(motionData.mMotionPath))) {
downloadVideoMaterial(beautyData, motionData, pos);
}
break;
case ITEM_TYPE_GESUTRE:
if (pos > motionGestureList.size() - 1) {
return;
}
motionData = motionGestureList.get(pos);
if (motionData.mMotionId.equals("none") || !TextUtils.isEmpty(motionData.mMotionPath)) {
setPickerEffect(mSencodGradleType, pos);
} else if ((TextUtils.isEmpty(motionData.mMotionPath))) {
downloadVideoMaterial(beautyData, motionData, pos);
}
break;
}
}
});
mSecondGradlePicker.setAdapter(mItemAdapter);
mSecondGradlePicker.setClicked(mSzSecondGradleIndex[mSencodGradleType]);
}
private void downloadVideoMaterial(BeautyData beautyData, final MotionData motionData, final int pos) {
MaterialDownloader materialDownloader = new MaterialDownloader(mContext, beautyData.text, motionData.mMotionUrl);
materialDownloader.start(new Downloadlistener() {
@Override
public void onDownloadFail(final String errorMsg) {
((Activity) mContext).runOnUiThread(new Runnable() {
@Override
public void run() {
if (mCustomProgressDialog != null) {
mCustomProgressDialog.dismiss();
}
Toast.makeText(mContext, errorMsg, Toast.LENGTH_SHORT);
}
});
}
@Override
public void onDownloadProgress(final int progress) {
((Activity) mContext).runOnUiThread(new Runnable() {
@Override
public void run() {
Log.i(TAG, "onDownloadProgress, progress = " + progress);
if (mCustomProgressDialog == null) {
mCustomProgressDialog = new CustomProgressDialog();
mCustomProgressDialog.createLoadingDialog(mContext);
mCustomProgressDialog.setCancelable(false); // 设置是否可以通过点击Back键取消
mCustomProgressDialog.setCanceledOnTouchOutside(false); // 设置在点击Dialog外是否取消Dialog进度条
mCustomProgressDialog.show();
}
mCustomProgressDialog.setMsg(progress + "%");
}
});
}
@Override
public void onDownloadSuccess(String filePath) {
motionData.mMotionPath = filePath;
mPrefs.edit().putString(motionData.mMotionId, filePath).apply();
((Activity) mContext).runOnUiThread(new Runnable() {
@Override
public void run() {
if (mCustomProgressDialog != null) {
mCustomProgressDialog.dismiss();
mCustomProgressDialog = null;
}
setPickerEffect(mSencodGradleType, pos);
}
});
}
});
}
public void setMotionTmplEnable(boolean enable) {
if (mProxy != null) {
if (enable) {
mProxy.setMotionTmpl(null);
} else {
mProxy.setMotionTmpl(mBeautyParams.mMotionTmplPath);
}
}
}
/**
* 清空美颜配置,如果SDK是新创建的则不需要最后清理,如果SDK是单例,需要调用此方法清空上次设置的美颜参数<br/>
* 示例:TXUGCRecord是单例,需要调用,TXLivePusher每次创建新的,不需要调用
*/
public void clear() {
mBeautyParams = new BeautyParams();
if (mProxy != null) {
mProxy.setFilter(mBeautyParams.mFilterBmp, mBeautyParams.mFilterIndex);
mProxy.setFilterStrength(mBeautyParams.mFilterStrength);
mProxy.setGreenScreenFile(mBeautyParams.mGreenFile);
mProxy.setBeautyStyle(mBeautyParams.mBeautyStyle);
mProxy.setBeautyLevel(mBeautyParams.mBeautyLevel);
mProxy.setWhitenessLevel(mBeautyParams.mWhiteLevel);
mProxy.setRuddyLevel(mBeautyParams.mRuddyLevel);
mProxy.setEyeScaleLevel(mBeautyParams.mBigEyeLevel);
mProxy.setFaceSlimLevel(mBeautyParams.mFaceSlimLevel);
mProxy.setFaceVLevel(mBeautyParams.mFaceVLevel);
mProxy.setChinLevel(mBeautyParams.mChinSlimLevel);
mProxy.setFaceShortLevel(mBeautyParams.mFaceShortLevel);
mProxy.setNoseSlimLevel(mBeautyParams.mNoseSlimLevel);
mProxy.setEyeLightenLevel(mBeautyParams.mEyeLightenLevel);
mProxy.setToothWhitenLevel(mBeautyParams.mToothWhitenLevel);
mProxy.setWrinkleRemoveLevel(mBeautyParams.mWrinkleRemoveLevel);
mProxy.setPounchRemoveLevel(mBeautyParams.mPounchRemoveLevel);
mProxy.setSmileLinesRemoveLevel(mBeautyParams.mSmileLinesRemoveLevel);
mProxy.setForeheadLevel(mBeautyParams.mForeheadLevel);
mProxy.setEyeDistanceLevel(mBeautyParams.mEyeDistanceLevel);
mProxy.setEyeAngleLevel(mBeautyParams.mEyeAngleLevel);
mProxy.setMouthShapeLevel(mBeautyParams.mMouthShapeLevel);
mProxy.setNoseWingLevel(mBeautyParams.mNoseWingLevel);
mProxy.setNosePositionLevel(mBeautyParams.mNosePositionLevel);
mProxy.setLipsThicknessLevel(mBeautyParams.mLipsThicknessLevel);
mProxy.setFaceBeautyLevel(mBeautyParams.mFaceBeautyLevel);
mProxy.setMotionTmpl(mBeautyParams.mMotionTmplPath);
}
}
public interface OnItemClickListener {
void onItemClick(BeautyData beautyData, int pos);
}
private void setPickerEffect(int type, int index) {
initSeekBarValue();
mSzSecondGradleIndex[type] = index;
mThirdGradleIndex = index;
switch (type) {
case ITEM_TYPE_BEAUTY:
mSeekbar.setVisibility(View.VISIBLE);
mSeekBarValue.setVisibility(View.VISIBLE);
mSeekbar.setProgress(mSzSeekBarValue[type][index]);
setBeautyStyle(index, mSzSeekBarValue[type][index]);
break;
case ITEM_TYPE_FILTTER:
setFilter(index);
mSeekbar.setVisibility(View.VISIBLE);
mSeekBarValue.setVisibility(View.VISIBLE);
mSeekbar.setProgress(mSzSeekBarValue[type][index]);
break;
case ITEM_TYPE_MOTION:
case ITEM_TYPE_BEAUTY_FACE:
case ITEM_TYPE_GESUTRE:
mSeekbar.setVisibility(View.GONE);
mSeekBarValue.setVisibility(View.GONE);
setDynamicEffect(type, index);
break;
case ITEM_TYPE_KOUBEI:
mSeekbar.setVisibility(View.GONE);
mSeekBarValue.setVisibility(View.GONE);
setDynamicEffect(type, index);
break;
case ITEM_TYPE_GREEN:
mSeekbar.setVisibility(View.GONE);
mSeekBarValue.setVisibility(View.GONE);
setGreenScreen(index);
break;
default:
break;
}
}
private Bitmap decodeResource(Resources resources, int id) {
TypedValue value = new TypedValue();
resources.openRawResource(id, value);
BitmapFactory.Options opts = new BitmapFactory.Options();
opts.inTargetDensity = value.density;
return BitmapFactory.decodeResource(resources, id, opts);
}
//设置滤镜
private void setFilter(int index) {
Bitmap bmp = getFilterBitmapByIndex(index);
mBeautyParams.mFilterBmp = bmp;
mBeautyParams.mFilterIndex = index;
if (mProxy != null) {
mProxy.setFilter(bmp, index);
}
}
public Bitmap getFilterBitmapByIndex(int index) {
Bitmap bmp = null;
switch (index) {
case 1:
bmp = decodeResource(getResources(), R.drawable.filter_biaozhun);
break;
case 2:
bmp = decodeResource(getResources(), R.drawable.filter_yinghong);
break;
case 3:
bmp = decodeResource(getResources(), R.drawable.filter_yunshang);
break;
case 4:
bmp = decodeResource(getResources(), R.drawable.filter_chunzhen);
break;
case 5:
bmp = decodeResource(getResources(), R.drawable.filter_bailan);
break;
case 6:
bmp = decodeResource(getResources(), R.drawable.filter_yuanqi);
break;
case 7:
bmp = decodeResource(getResources(), R.drawable.filter_chaotuo);
break;
case 8:
bmp = decodeResource(getResources(), R.drawable.filter_xiangfen);
break;
case 9:
bmp = decodeResource(getResources(), R.drawable.filter_white);
break;
case 10:
bmp = decodeResource(getResources(), R.drawable.filter_langman);
break;
case 11:
bmp = decodeResource(getResources(), R.drawable.filter_qingxin);
break;
case 12:
bmp = decodeResource(getResources(), R.drawable.filter_weimei);
break;
case 13:
bmp = decodeResource(getResources(), R.drawable.filter_fennen);
break;
case 14:
bmp = decodeResource(getResources(), R.drawable.filter_huaijiu);
break;
case 15:
bmp = decodeResource(getResources(), R.drawable.filter_landiao);
break;
case 16:
bmp = decodeResource(getResources(), R.drawable.filter_qingliang);
break;
case 17:
bmp = decodeResource(getResources(), R.drawable.filter_rixi);
break;
default:
bmp = null;
break;
}
return bmp;
}
//设置绿幕
private void setGreenScreen(int index) {
String file = "";
switch (index) {
case 1:
file = "green_1.mp4";
break;
default:
break;
}
mBeautyParams.mGreenFile = file;
if (mProxy != null) {
mProxy.setGreenScreenFile(file);
}
}
//设置动效
private void setDynamicEffect(int type, int index) {
MotionData motionData = null;
if (type == ITEM_TYPE_MOTION) {
motionData = motionDataList.get(index);
} else if (type == ITEM_TYPE_KOUBEI) {
motionData = motionDataKoubeiList.get(index);
} else if (type == ITEM_TYPE_BEAUTY_FACE) {
motionData = motionBeautyFaceList.get(index);
} else if (type == ITEM_TYPE_GESUTRE) {
motionData = motionGestureList.get(index);
if (motionData.mMotionId.equals("video_pikachu")) {
Toast.makeText(mContext, "伸出手掌", Toast.LENGTH_SHORT).show();
}
}
mBeautyParams.mMotionTmplPath = motionData.mMotionPath;
if (mProxy != null) {
mProxy.setMotionTmpl(motionData.mMotionPath);
}
}
// 设置美颜类型
private void setBeautyStyle(int style, int beautyLevel) {
if (style >= 3) {
return;
}
mBeautyParams.mBeautyStyle = style;
mBeautyParams.mBeautyLevel = beautyLevel;
if (mProxy != null) {
mProxy.setBeautyStyle(style);
mProxy.setBeautyLevel(beautyLevel);
}
}
@Override
public void onProgressChanged(SeekBar seekBar, int progress, boolean fromUser) {
initSeekBarValue();
mSzSeekBarValue[mSencodGradleType][mThirdGradleIndex] = progress; // 记录设置的值
mSeekBarValue.setText(String.valueOf(progress));
if (seekBar.getId() == R.id.seekbarThird) {
if (mSencodGradleType == ITEM_TYPE_BEAUTY) {
BeautyData beautyData = beautyDataList.get(mThirdGradleIndex);
String beautyType = beautyData.text;
if (beautyType.equals(getResources().getString(R.string.beauty_pannel_style_smooth))) {
mBeautyParams.mBeautyStyle = BEAUTYPARAM_BEAUTY_STYLE_SMOOTH;
mBeautyParams.mBeautyLevel = progress;
if (mProxy != null) {
mProxy.setBeautyStyle(BEAUTYPARAM_BEAUTY_STYLE_SMOOTH);
mProxy.setBeautyLevel(progress);
}
} else if (beautyType.equals(getResources().getString(R.string.beauty_pannel_style_natural))) {
mBeautyParams.mBeautyStyle = BEAUTYPARAM_BEAUTY_STYLE_NATURAL;
mBeautyParams.mBeautyLevel = progress;
if (mProxy != null) {
mProxy.setBeautyStyle(BEAUTYPARAM_BEAUTY_STYLE_NATURAL);
mProxy.setBeautyLevel(progress);
}
} else if (beautyType.equals(getResources().getString(R.string.beauty_pannel_style_pitu))) {
mBeautyParams.mBeautyStyle = BEAUTYPARAM_BEAUTY_STYLE_HAZY;
mBeautyParams.mBeautyLevel = progress;
if (mProxy != null) {
mProxy.setBeautyStyle(BEAUTYPARAM_BEAUTY_STYLE_HAZY);
mProxy.setBeautyLevel(progress);
}
} else if (beautyType.equals(getResources().getString(R.string.beauty_pannel_white))) {
mBeautyParams.mWhiteLevel = progress;
if (mProxy != null) {
mProxy.setWhitenessLevel(progress);
}
} else if (beautyType.equals(getResources().getString(R.string.beauty_pannel_ruddy))) {
mBeautyParams.mRuddyLevel = progress;
if (mProxy != null) {
mProxy.setRuddyLevel(progress);
}
} else if (beautyType.equals(getResources().getString(R.string.beauty_pannel_bigeye))) {
mBeautyParams.mBigEyeLevel = progress;
if (mProxy != null) {
mProxy.setEyeScaleLevel(progress);
}
} else if (beautyType.equals(getResources().getString(R.string.beauty_pannel_faceslim))) {
mBeautyParams.mFaceSlimLevel = progress;
if (mProxy != null) {
mProxy.setFaceSlimLevel(progress);
}
} else if (beautyType.equals(getResources().getString(R.string.beauty_pannel_facev))) {
mBeautyParams.mFaceVLevel = progress;
if (mProxy != null) {
mProxy.setFaceVLevel(progress);
}
} else if (beautyType.equals(getResources().getString(R.string.beauty_pannel_chin))) {
mBeautyParams.mChinSlimLevel = progress;
if (mProxy != null) {
mProxy.setChinLevel(progress);
}
} else if (beautyType.equals(getResources().getString(R.string.beauty_pannel_faceshort))) {
mBeautyParams.mFaceShortLevel = progress;
if (mProxy != null) {
mProxy.setFaceShortLevel(progress);
}
} else if (beautyType.equals(getResources().getString(R.string.beauty_pannel_noseslim))) {
mBeautyParams.mNoseSlimLevel = progress;
if (mProxy != null) {
mProxy.setNoseSlimLevel(progress);
}
} else if (beautyType.equals(getResources().getString(R.string.beauty_pannel_eyelighten))) {
mBeautyParams.mEyeLightenLevel = progress;
if (mProxy != null) {
mProxy.setEyeLightenLevel(progress);
}
} else if (beautyType.equals(getResources().getString(R.string.beauty_pannel_toothwhite))) {
mBeautyParams.mToothWhitenLevel = progress;
if (mProxy != null) {
mProxy.setToothWhitenLevel(progress);
}
} else if (beautyType.equals(getResources().getString(R.string.beauty_pannel_pounchremove))) {
mBeautyParams.mPounchRemoveLevel = progress;
if (mProxy != null) {
mProxy.setPounchRemoveLevel(progress);
}
} else if (beautyType.equals(getResources().getString(R.string.beauty_pannel_wrinkleremove))) {
mBeautyParams.mWrinkleRemoveLevel = progress;
if (mProxy != null) {
mProxy.setWrinkleRemoveLevel(progress);
}
} else if (beautyType.equals(getResources().getString(R.string.beauty_pannel_smilelinesremove))) {
mBeautyParams.mSmileLinesRemoveLevel = progress;
if (mProxy != null) {
mProxy.setSmileLinesRemoveLevel(progress);
}
} else if (beautyType.equals(getResources().getString(R.string.beauty_pannel_forehead))) {
mBeautyParams.mForeheadLevel = progress;
if (mProxy != null) {
mProxy.setForeheadLevel(progress);
}
} else if (beautyType.equals(getResources().getString(R.string.beauty_pannel_eyedistance))) {
mBeautyParams.mEyeDistanceLevel = progress;
if (mProxy != null) {
mProxy.setEyeDistanceLevel(progress);
}
} else if (beautyType.equals(getResources().getString(R.string.beauty_pannel_eyeangle))) {
mBeautyParams.mEyeAngleLevel = progress;
if (mProxy != null) {
mProxy.setEyeAngleLevel(progress);
}
} else if (beautyType.equals(getResources().getString(R.string.beauty_pannel_mouthshape))) {
mBeautyParams.mMouthShapeLevel = progress;
if (mProxy != null) {
mProxy.setMouthShapeLevel(progress);
}
} else if (beautyType.equals(getResources().getString(R.string.beauty_pannel_nosewing))) {
mBeautyParams.mNoseWingLevel = progress;
if (mProxy != null) {
mProxy.setNoseWingLevel(progress);
}
} else if (beautyType.equals(getResources().getString(R.string.beauty_pannel_noseposition))) {
mBeautyParams.mNosePositionLevel = progress;
if (mProxy != null) {
mProxy.setNosePositionLevel(progress);
}
} else if (beautyType.equals(getResources().getString(R.string.beauty_pannel_mousewidth))) {
mBeautyParams.mMouthShapeLevel = progress;
if (mProxy != null) {
mProxy.setLipsThicknessLevel(progress);
}
} else if (beautyType.equals(getResources().getString(R.string.beauty_pannel_faceshape))) {
mBeautyParams.mFaceBeautyLevel = progress;
if (mProxy != null) {
mProxy.setFaceBeautyLevel(progress);
}
}
} else if (mSencodGradleType == ITEM_TYPE_FILTTER) {
if (mProxy != null) {
mProxy.setFilterStrength(progress);
}
}
}
}
private void initSeekBarValue() {
if (null == mSzSeekBarValue) {
mSzSeekBarValue = new int[16][24];
for (int i = 1; i < mSzSeekBarValue[ITEM_TYPE_FILTTER].length; i++) {
mSzSeekBarValue[ITEM_TYPE_FILTTER][i] = mFilterBasicLevel;
}
// 前八个滤镜的推荐值 (其他默认为5)
mSzSeekBarValue[ITEM_TYPE_FILTTER][1] = 4;
mSzSeekBarValue[ITEM_TYPE_FILTTER][2] = 8;
mSzSeekBarValue[ITEM_TYPE_FILTTER][3] = 8;
mSzSeekBarValue[ITEM_TYPE_FILTTER][4] = 8;
mSzSeekBarValue[ITEM_TYPE_FILTTER][5] = 10;
mSzSeekBarValue[ITEM_TYPE_FILTTER][6] = 8;
mSzSeekBarValue[ITEM_TYPE_FILTTER][7] = 10;
mSzSeekBarValue[ITEM_TYPE_FILTTER][8] = 5;
// 设置美颜默认值
mSzSeekBarValue[ITEM_TYPE_BEAUTY][0] = mBeautyBasicLevel;
mSzSeekBarValue[ITEM_TYPE_BEAUTY][1] = mBeautyBasicLevel;
mSzSeekBarValue[ITEM_TYPE_BEAUTY][2] = mBeautyBasicLevel;
mSzSeekBarValue[ITEM_TYPE_BEAUTY][3] = mWhiteBasicLevel;
mSzSeekBarValue[ITEM_TYPE_BEAUTY][4] = mRuddyBasicLevel;
}
}
@Override
public void onStartTrackingTouch(SeekBar seekBar) {
}
@Override
public void onStopTrackingTouch(SeekBar seekBar) {
}
public int getFilterProgress(int index) {
return mSzSeekBarValue[ITEM_TYPE_FILTTER][index];
}
public String[] getBeautyFilterArr() {
return mFilterTypeString;
}
@Override
public void onClick(View v) {
}
public void setCurrentFilterIndex(int index) {
mSzSecondGradleIndex[ITEM_TYPE_FILTTER] = index;
if (mSencodGradleType == ITEM_TYPE_FILTTER) {
ViewGroup group = (ViewGroup) mSecondGradlePicker.getChildAt(0);
int size = mItemAdapter.getCount();
for (int i = 0; i < size; i++) {
View v = group.getChildAt(i);
if (v instanceof TextView) {
if (i == index) {
((TextView) v).setTextColor(mTextColorPrimary);
// ((TextView) v).setTextColor(mContext.getResources().getColor(R.color.colorRed));
} else {
((TextView) v).setTextColor(Color.WHITE);
}
}
}
mThirdGradleIndex = index;
mSeekbar.setVisibility(View.VISIBLE);
mSeekBarValue.setVisibility(View.VISIBLE);
mSeekbar.setProgress(mSzSeekBarValue[ITEM_TYPE_FILTTER][index]);
}
}
}
package com.tencent.liteav.demo.beauty;
import android.graphics.Bitmap;
/**
* 美颜参数
*/
public class BeautyParams {
// 美颜类型
public int mBeautyStyle = 0;
// 美颜
public int mBeautyLevel = 4;
// 美白
public int mWhiteLevel = 1;
// 红润
public int mRuddyLevel = 0;
// 滤镜LUT图
public Bitmap mFilterBmp;
// 滑动滤镜索引
public int mFilterIndex;
// 滤镜程度
public int mFilterStrength = 0;
// 大眼
public int mBigEyeLevel;
// 瘦脸
public int mFaceSlimLevel;
// 瘦鼻
public int mNoseSlimLevel;
// 缩下巴
public int mChinSlimLevel;
// V脸
public int mFaceVLevel;
// 短脸
public int mFaceShortLevel;
// 亮眼
public int mEyeLightenLevel = 0;
// 白牙
public int mToothWhitenLevel = 0;
// 祛皱
public int mWrinkleRemoveLevel = 0;
// 祛眼袋
public int mPounchRemoveLevel = 0;
// 祛法令纹
public int mSmileLinesRemoveLevel = 0;
// 发际线
public int mForeheadLevel = 0;
// 眼距
public int mEyeDistanceLevel = 0;
// 眼角
public int mEyeAngleLevel = 0;
// 嘴型
public int mMouthShapeLevel = 0;
// 鼻翼
public int mNoseWingLevel = 0;
// 鼻子位置
public int mNosePositionLevel = 0;
// 嘴唇厚度
public int mLipsThicknessLevel = 0;
// 脸型
public int mFaceBeautyLevel = 0;
// 长腿
public int mLongLegLevel = 0;
// 瘦腰
public int mThinWaistLevel = 0;
// 瘦体
public int mThinBodyLevel = 0;
// 瘦肩
public int mThinShoulderLevel = 0;
// 动效文件路径
public String mMotionTmplPath;
// 绿幕
public String mGreenFile;
}
package com.tencent.liteav.demo.beauty;
import android.app.Dialog;
import android.content.Context;
import android.view.LayoutInflater;
import android.view.View;
import android.view.animation.Animation;
import android.view.animation.AnimationUtils;
import android.widget.ImageView;
import android.widget.LinearLayout;
import android.widget.RelativeLayout;
import android.widget.TextView;
public class CustomProgressDialog {
private Dialog mDialog;
private TextView tvMsg;
public void createLoadingDialog(Context context) {
LayoutInflater inflater = LayoutInflater.from(context);
View v = inflater.inflate(R.layout.layout_loading_progress, null);
LinearLayout layout = (LinearLayout) v.findViewById(R.id.layout_progress);
ImageView spaceshipImage = (ImageView) v.findViewById(R.id.progress_img);
tvMsg = (TextView) v.findViewById(R.id.msg_tv);
Animation hyperspaceJumpAnimation = AnimationUtils.loadAnimation(context, R.anim.load_progress_animation);
spaceshipImage.startAnimation(hyperspaceJumpAnimation);
mDialog = new Dialog(context, R.style.loading_dialog);
mDialog.setCancelable(false);
mDialog.setContentView(layout, new RelativeLayout.LayoutParams(
RelativeLayout.LayoutParams.MATCH_PARENT,
RelativeLayout.LayoutParams.MATCH_PARENT));// 设置布局
}
public void setCancelable(boolean cancelable) {
if (mDialog != null) {
mDialog.setCancelable(cancelable);
}
}
public void setCanceledOnTouchOutside(boolean canceledOnTouchOutside) {
if (mDialog != null) {
mDialog.setCanceledOnTouchOutside(canceledOnTouchOutside);
}
}
public void show() {
if (mDialog != null) {
mDialog.show();
}
}
public void dismiss() {
if (mDialog != null) {
mDialog.dismiss();
}
}
public void setMsg(String msg) {
if (tvMsg == null) {
return;
}
if (tvMsg.getVisibility() == View.GONE) {
tvMsg.setVisibility(View.VISIBLE);
}
tvMsg.setText(msg);
}
}
package com.tencent.liteav.demo.beauty;
public interface Downloadlistener {
void onDownloadFail(String errorMsg);
void onDownloadProgress(final int progress);
void onDownloadSuccess(String filePath);
}
package com.tencent.liteav.demo.beauty;
import java.io.File;
public interface HttpFileListener {
void onProgressUpdate(int progress);
void onSaveSuccess(File file);
void onSaveFailed(File file, Exception e);
void onProcessEnd();
}
package com.tencent.liteav.demo.beauty;
import android.content.Context;
import android.text.TextUtils;
import java.io.File;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.net.HttpURLConnection;
import java.net.URL;
public class HttpFileUtil implements Runnable {
public static final int BUFFERED_READER_SIZE = 8192;
public static final int TIMEOUT = 30000;
private Context mContext;
private String mUrl;
private String mFolder;
private String mFilename;
private HttpFileListener mListener;
private long mContentLength;
private long mDownloadingSize;
private boolean mNeedProgress;
public HttpFileUtil(Context context, String url, String folder, String filename, HttpFileListener listener, boolean needProgress) {
mContext = context;
mUrl = url;
mFolder = folder;
mFilename = filename;
mListener = listener;
mNeedProgress = needProgress;
}
@Override
public void run() {
if (!VideoDeviceUtil.isNetworkAvailable(mContext) ||
TextUtils.isEmpty(mUrl) || TextUtils.isEmpty(mFolder) || TextUtils.isEmpty(mFilename) || !mUrl.startsWith("http")) {
fail(null);
return;
}
File dstFolder = new File(mFolder);
if (!dstFolder.exists()) {
dstFolder.mkdirs();
} else {
if (dstFolder.isFile()) {
if (mListener != null) {
mListener.onSaveFailed(dstFolder, null);
return;
}
}
}
File dstFile = new File(mFolder + File.separator + mFilename);
HttpURLConnection client = null;
InputStream responseIs = null;
FileOutputStream fos = null;
int statusCode = -1;
boolean success = false;
Exception failException = null;
try {
if (dstFile.exists()) {
dstFile.delete();
}
dstFile.createNewFile();
client = (HttpURLConnection) new URL(mUrl).openConnection();
// 设置网络超时参数
client.setConnectTimeout(TIMEOUT);
client.setReadTimeout(TIMEOUT);
client.setDoInput(true);
client.setRequestMethod("GET");
statusCode = client.getResponseCode();
success = client.getResponseCode() == HttpURLConnection.HTTP_OK;
if (success) {
if (mNeedProgress) {
mContentLength = client.getContentLength();
}
responseIs = client.getInputStream();
int length = -1;
byte[] buffer = new byte[BUFFERED_READER_SIZE];
fos = new FileOutputStream(dstFile);
mDownloadingSize = 0;
mListener.onProgressUpdate(0);
while ((length = responseIs.read(buffer)) != -1) {
fos.write(buffer, 0, length);
if (mNeedProgress) {
int pre = (int) (mDownloadingSize * 100 / mContentLength);
mDownloadingSize += length;
int now = (int) (mDownloadingSize * 100 / mContentLength);
if (pre != now && mListener != null) {
mListener.onProgressUpdate(now);
}
}
}
fos.flush();
if (mListener != null) {
mListener.onProgressUpdate(100);
mListener.onSaveSuccess(dstFile);
}
} else {
failException = new HttpStatusException("http status got exception. code = " + statusCode);
}
} catch (Exception e) {
failException = e;
e.printStackTrace();
} finally {
try {
if (fos != null) {
fos.close();
}
if (responseIs != null) {
responseIs.close();
}
if (client != null) {
client.disconnect();
}
mListener.onProcessEnd();
} catch (IOException e) {
e.printStackTrace();
}
}
if (!success || null != failException) {
mListener.onSaveFailed(dstFile, failException);
}
}
private void fail(Exception e) {
if (mListener != null) {
mListener.onSaveFailed(null, e);
}
mListener = null;
}
}
package com.tencent.liteav.demo.beauty;
/**
* Http状态异常[自定义抛出的异常]
*/
public class HttpStatusException extends Exception {
public HttpStatusException(String detailMessage) {
super(detailMessage);
}
}
package com.tencent.liteav.demo.beauty;
import android.annotation.TargetApi;
import android.graphics.Bitmap;
public interface IBeautyKit {
/**
* 设置指定素材滤镜特效
*
* @param filterImage : 指定素材,即颜色查找表图片。注意:一定要用png格式!!!
* demo用到的滤镜查找表图片位于RTMPAndroidDemo/app/src/main/res/drawable-xxhdpi/目录下。
*/
void setFilter(Bitmap filterImage, int index);
/**
* 设置滤镜效果程度
*
* @param strength : 从0到1,越大滤镜效果越明显,默认取值0.5
*/
void setFilterStrength(float strength);
/**
* 设置绿幕文件(企业版有效,其它版本设置此参数无效)[API >= 18]
* <p>
* 此处的绿幕功能并非智能抠背,它需要被拍摄者的背后有一块绿色的幕布来辅助产生特效。
*
* @param path 视频文件路径。支持 MP4;null 表示关闭特效。
*/
@TargetApi(18)
void setGreenScreenFile(String path);
/**
* 设置美颜类型
*
* @param beautyStyle 美颜风格.三种美颜风格:0 :光滑 1:自然 2:朦胧
*/
void setBeautyStyle(int beautyStyle);
/**
* 设置美颜级别
*
* @param beautyLevel 美颜级别,取值范围0 - 9; 0表示关闭,1 - 9值越大,效果越明显。
*/
void setBeautyLevel(int beautyLevel);
/**
* 设置美白级别
*
* @param whitenessLevel 美白级别,取值范围0 - 9; 0表示关闭,1 - 9值越大,效果越明显。
*/
void setWhitenessLevel(int whitenessLevel);
/**
* 设置红润级别
*
* @param ruddyLevel 红润级别,取值范围0 - 9; 0表示关闭,1 - 9值越大,效果越明显。
*/
void setRuddyLevel(int ruddyLevel);
/**
* 设置大眼级别(企业版有效,其它版本设置此参数无效)
*
* @param eyeScaleLevel 大眼级别,取值范围0 - 9; 0表示关闭,1 - 9值越大,效果越明显。
*/
void setEyeScaleLevel(int eyeScaleLevel);
/**
* 设置瘦脸级别(企业版有效,其它版本设置此参数无效)
*
* @param faceSlimLevel 瘦脸级别,取值范围0 - 9; 0表示关闭,1 - 9值越大,效果越明显。
*/
void setFaceSlimLevel(int faceSlimLevel);
/**
* 设置V脸级别(企业版有效,其它版本设置此参数无效)
*
* @param faceVLevel V脸级别,取值范围0 - 9; 0表示关闭,1 - 9值越大,效果越明显。
*/
void setFaceVLevel(int faceVLevel);
/**
* 设置下巴拉伸或收缩(企业版有效,其它版本设置此参数无效)
*
* @param chinLevel 下巴拉伸或收缩级别,取值范围 -9 - 9;0 表示关闭,小于0表示收缩,大于0表示拉伸。
*/
void setChinLevel(int chinLevel);
/**
* 设置短脸级别(企业版有效,其它版本设置此参数无效)
*
* @param faceShortLevel 短脸级别,取值范围0 - 9; 0表示关闭,1 - 9值越大,效果越明显。
*/
void setFaceShortLevel(int faceShortLevel);
/**
* 设置瘦鼻级别(企业版有效,其它版本设置此参数无效)
*
* @param noseSlimLevel 瘦鼻级别,取值范围0 - 9; 0表示关闭,1 - 9值越大,效果越明显。
*/
void setNoseSlimLevel(int noseSlimLevel);
/**
* 设置亮眼 (企业版有效,其它版本设置此参数无效)
*
* @param eyeLightenLevel 亮眼级别,取值范围0 - 9; 0表示关闭,1 - 9值越大,效果越明显。
*/
void setEyeLightenLevel(int eyeLightenLevel);
/**
* 设置白牙 (企业版有效,其它版本设置此参数无效)
*
* @param toothWhitenLevel 白牙级别,取值范围0 - 9; 0表示关闭,1 - 9值越大,效果越明显。
*/
void setToothWhitenLevel(int toothWhitenLevel);
/**
* 设置祛皱 (企业版有效,其它版本设置此参数无效)
*
* @param wrinkleRemoveLevel 祛皱级别,取值范围0 - 9; 0表示关闭,1 - 9值越大,效果越明显。
*/
void setWrinkleRemoveLevel(int wrinkleRemoveLevel);
/**
* 设置祛眼袋 (企业版有效,其它版本设置此参数无效)
*
* @param pounchRemoveLevel 祛眼袋级别,取值范围0 - 9; 0表示关闭,1 - 9值越大,效果越明显。
*/
void setPounchRemoveLevel(int pounchRemoveLevel);
/**
* 设置祛法令纹 (企业版有效,其它版本设置此参数无效)
*
* @param smileLinesRemoveLevel 祛法令纹级别,取值范围0 - 9; 0表示关闭,1 - 9值越大,效果越明显。
*/
void setSmileLinesRemoveLevel(int smileLinesRemoveLevel);
/**
* 设置发际线 (企业版有效,其它版本设置此参数无效)
*
* @param foreheadLevel 发际线级别,取值范围0 - 9; 0表示关闭,1 - 9值越大,效果越明显。
*/
void setForeheadLevel(int foreheadLevel);
/**
* 设置眼距 (企业版有效,其它版本设置此参数无效)
*
* @param eyeDistanceLevel 眼距级别,取值范围0 - 9; 0表示关闭,1 - 9值越大,效果越明显。
*/
void setEyeDistanceLevel(int eyeDistanceLevel);
/**
* 设置眼角 (企业版有效,其它版本设置此参数无效)
*
* @param eyeAngleLevel 眼角级别,取值范围0 - 9; 0表示关闭,1 - 9值越大,效果越明显。
*/
void setEyeAngleLevel(int eyeAngleLevel);
/**
* 设置嘴型 (企业版有效,其它版本设置此参数无效)
*
* @param mouthShapeLevel 嘴型级别,取值范围0 - 9; 0表示关闭,1 - 9值越大,效果越明显。
*/
void setMouthShapeLevel(int mouthShapeLevel);
/**
* 设置鼻翼 (企业版有效,其它版本设置此参数无效)
*
* @param noseWingLevel 鼻翼级别,取值范围0 - 9; 0表示关闭,1 - 9值越大,效果越明显。
*/
void setNoseWingLevel(int noseWingLevel);
/**
* 设置鼻子位置 (企业版有效,其它版本设置此参数无效)
*
* @param nosePositionLevel 鼻子位置级别,取值范围0 - 9; 0表示关闭,1 - 9值越大,效果越明显。
*/
void setNosePositionLevel(int nosePositionLevel);
/**
* 设置嘴唇厚度 (企业版有效,其它版本设置此参数无效)
*
* @param lipsThicknessLevel 嘴唇厚度级别,取值范围0 - 9; 0表示关闭,1 - 9值越大,效果越明显。
*/
void setLipsThicknessLevel(int lipsThicknessLevel);
/**
* 设置脸型 (企业版有效,其它版本设置此参数无效)
*
* @param faceBeautyLevel 脸型级别,取值范围0 - 9; 0表示关闭,1 - 9值越大,效果越明显。
*/
void setFaceBeautyLevel(int faceBeautyLevel);
/**
* 选择使用哪一款 AI 动效挂件(企业版有效,其它版本设置此参数无效)
*/
void setMotionTmpl(String tmplPath);
/**
* 设置动效静音(企业版有效,其它版本设置此参数无效)
* <p>
* 有些挂件本身会有声音特效,通过此 API 可以关闭这些特效播放时所带的声音效果。
*
* @param motionMute YES:静音;NO:不静音。
*/
void setMotionMute(boolean motionMute);
}
package com.tencent.liteav.demo.beauty;
import android.content.Context;
import android.graphics.Color;
import android.support.v7.widget.RecyclerView;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.BaseAdapter;
import android.widget.ImageView;
import android.widget.TextView;
import java.util.ArrayList;
public class IconTextAdapter extends BaseAdapter {
private static final String TAG = "IconTextAdapter";
private final Context mContext;
private int mTextColorPrimary;
private ArrayList<BeautyData> data = new ArrayList<BeautyData>();
private BeautyPanel.OnItemClickListener mItemClickListener;
// 当前选中
private int mSelectPos;
public IconTextAdapter(Context context) {
mContext = context;
}
public void addAll(ArrayList<BeautyData> beautyDataList) {
data.clear();
data.addAll(beautyDataList);
notifyDataSetChanged();
}
public void clearAllData() {
data.clear();
notifyDataSetChanged();
}
@Override
public int getCount() {
return data.size();
}
@Override
public Object getItem(int position) {
return data.get(position);
}
@Override
public long getItemId(int position) {
return position;
}
@Override
public View getView(final int position, View convertView, ViewGroup parent) {
final ViewHolder holder;
if (convertView == null) {
convertView = LayoutInflater.from(mContext).inflate(R.layout.item_beauty, parent, false);
holder = new ViewHolder(convertView);
convertView.setTag(holder);
} else {
holder = (ViewHolder) convertView.getTag();
}
final BeautyData beautyData = data.get(position);
holder.icon.setImageResource(beautyData.icon);
holder.title.setText(beautyData.text);
if (mSelectPos == position) {
holder.title.setTextColor(mTextColorPrimary);
} else {
holder.title.setTextColor(Color.WHITE);
}
convertView.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
if (mItemClickListener != null) {
mItemClickListener.onItemClick(beautyData, position);
}
if (mSelectPos != position) {
mSelectPos = position;
notifyDataSetChanged();
}
}
});
return convertView;
}
public void setOnItemClickListener(BeautyPanel.OnItemClickListener itemClickListener) {
mItemClickListener = itemClickListener;
}
public void setTextColor(int colorPrimary) {
mTextColorPrimary = colorPrimary;
}
public class ViewHolder extends RecyclerView.ViewHolder {
private ImageView icon;
private TextView title;
public ViewHolder(View itemView) {
super(itemView);
icon = (ImageView) itemView.findViewById(R.id.icon);
title = (TextView) itemView.findViewById(R.id.title);
}
}
}
package com.tencent.liteav.demo.beauty;
import android.annotation.TargetApi;
import android.content.Context;
import android.os.Build;
import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import android.text.TextUtils;
import java.io.File;
import java.util.concurrent.Executors;
import java.util.concurrent.LinkedBlockingDeque;
import java.util.concurrent.ThreadPoolExecutor;
import java.util.concurrent.TimeUnit;
/**
* 美颜模块素材下载
*/
public class MaterialDownloader {
private Context mContext;
public static final String DOWNLOAD_FILE_POSTFIX = ".zip";
public static final String ONLINE_MATERIAL_FOLDER = "cameraVideoAnimal";
private static final int CPU_COUNT = Runtime.getRuntime().availableProcessors();
private static final int CORE_POOL_SIZE = CPU_COUNT + 1;
private boolean mProcessing;
private String mUrl;
private Downloadlistener mListener;
private DownloadThreadPool mDownloadThreadPool;
private String mMaterialId;
public MaterialDownloader(Context context, String materialId, String url) {
mContext = context;
mMaterialId = materialId;
mUrl = url;
mProcessing = false;
}
public void start(@Nullable Downloadlistener listener) {
if (listener == null || TextUtils.isEmpty(mUrl) || mProcessing) {
return;
}
mProcessing = true;
mListener = listener;
mListener.onDownloadProgress(0);
HttpFileListener fileListener = new HttpFileListener() {
@Override
public void onSaveSuccess(@NonNull File file) {
//删除该素材目录下的旧文件
File path = new File(file.toString().substring(0, file.toString().indexOf(DOWNLOAD_FILE_POSTFIX)));
if (path.exists() && path.isDirectory()) {
File[] oldFiles = path.listFiles();
if (oldFiles != null) {
for (File f : oldFiles) {
f.delete();
}
}
}
String dataDir = VideoUtil.unZip(file.getPath(), file.getParentFile().getPath());
if (TextUtils.isEmpty(dataDir)) {
mListener.onDownloadFail(mContext.getString(R.string.video_material_download_progress_material_unzip_failed));
stop();
return;
}
file.delete();
mListener.onDownloadSuccess(dataDir);
stop();
}
@Override
public void onSaveFailed(File file, Exception e) {
mListener.onDownloadFail(mContext.getString(R.string.video_material_download_progress_download_failed));
stop();
}
@Override
public void onProgressUpdate(int progress) {
mListener.onDownloadProgress(progress);
}
@Override
public void onProcessEnd() {
mProcessing = false;
}
};
File onlineMaterialDir = VideoDeviceUtil.getExternalFilesDir(mContext, ONLINE_MATERIAL_FOLDER);
if (onlineMaterialDir == null || onlineMaterialDir.getName().startsWith("null")) {
mListener.onDownloadFail(mContext.getString(R.string.video_material_download_progress_no_enough_storage_space));
stop();
return;
}
if (!onlineMaterialDir.exists()) {
onlineMaterialDir.mkdirs();
}
ThreadPoolExecutor threadPool = getThreadExecutor();
threadPool.execute(new HttpFileUtil(mContext, mUrl, onlineMaterialDir.getPath(), mMaterialId + DOWNLOAD_FILE_POSTFIX, fileListener, true));
}
public void stop() {
mListener = null;
}
public synchronized ThreadPoolExecutor getThreadExecutor() {
if (mDownloadThreadPool == null || mDownloadThreadPool.isShutdown()) {
mDownloadThreadPool = new DownloadThreadPool(CORE_POOL_SIZE);
}
return mDownloadThreadPool;
}
public static class DownloadThreadPool extends ThreadPoolExecutor {
@TargetApi(Build.VERSION_CODES.GINGERBREAD)
public DownloadThreadPool(int poolSize) {
super(poolSize, poolSize, 0L, TimeUnit.MILLISECONDS,
new LinkedBlockingDeque<Runnable>(),
Executors.defaultThreadFactory(), new DiscardOldestPolicy());
}
}
}
package com.tencent.liteav.demo.beauty;
public class MotionData {
public String mMotionId;
public String mMotionName;
public String mMotionUrl;
public String mMotionPath;
public MotionData(String motionId, String motionName, String motionUrl, String motionPath) {
mMotionId = motionId;
mMotionName = motionName;
mMotionUrl = motionUrl;
mMotionPath = motionPath;
}
}
package com.tencent.liteav.demo.beauty;
import android.content.Context;
import android.database.DataSetObserver;
import android.util.AttributeSet;
import android.view.View;
import android.view.ViewGroup;
import android.widget.Adapter;
public class TCHorizontalScrollView extends android.widget.HorizontalScrollView {
private DataSetObserver mObserver;
private Adapter mAdapter;
public TCHorizontalScrollView(Context context) {
super(context);
initialize();
}
public TCHorizontalScrollView(Context context, AttributeSet attrs) {
super(context, attrs);
initialize();
}
public TCHorizontalScrollView(Context context, AttributeSet attrs, int defStyleAttr) {
super(context, attrs, defStyleAttr);
initialize();
}
public void setAdapter(Adapter adapter) {
if (mAdapter != null) {
mAdapter.unregisterDataSetObserver(mObserver);
}
mAdapter = adapter;
mAdapter.registerDataSetObserver(mObserver);
updateAdapter();
}
private void updateAdapter() {
ViewGroup group = (ViewGroup) getChildAt(0);
group.removeAllViews();
for (int i = 0; i < mAdapter.getCount(); i++) {
View view = mAdapter.getView(i, null, group);
group.addView(view);
}
}
void initialize() {
mObserver = new DataSetObserver() {
@Override
public void onChanged() {
super.onChanged();
updateAdapter();
}
@Override
public void onInvalidated() {
super.onInvalidated();
((ViewGroup) getChildAt(0)).removeAllViews();
}
};
}
public void setClicked(int position) {
((ViewGroup) getChildAt(0)).getChildAt(position).performClick();
}
}
\ No newline at end of file
package com.tencent.liteav.demo.beauty;
import android.content.Context;
import android.content.res.TypedArray;
import android.graphics.drawable.Drawable;
/**
* 属性管理
*/
public class UIAttributeUtil {
/**
* 获取主题设置的图片资源的drawable
*
* @param context context
* @param attrId style-attr对应的id
* @param defaultResourceId 默认的图片id
* @return Drawable
*/
public static Drawable getDrawableResources(Context context, int attrId, int defaultResourceId) {
TypedArray a = context.obtainStyledAttributes(new int[]{attrId});
int resourceId = a.getResourceId(0, defaultResourceId);
Drawable drawable = context.getResources().getDrawable(resourceId);
a.recycle();
return drawable;
}
public static int getColorRes(Context context, int attrId, int defaultColorId) {
TypedArray a = context.obtainStyledAttributes(new int[]{attrId});
int color = a.getColor(0, context.getResources().getColor(defaultColorId));
a.recycle();
return color;
}
public static int getTextSizeResources(Context context, int attrId, int defaultTextSize) {
TypedArray a = context.obtainStyledAttributes(new int[]{attrId});
int textSize = a.getDimensionPixelOffset(0, defaultTextSize);
a.recycle();
return textSize;
}
public static int getResResources(Context context, int attrId, int defaultResourceId) {
TypedArray a = context.obtainStyledAttributes(new int[]{attrId});
int resourceId = a.getResourceId(0, defaultResourceId);
a.recycle();
return resourceId;
}
public static int[] getResResourcsArray(Context context, int[] attrId, int[] defaultResourceId) {
int[] resourceIdArray = new int[attrId.length];
TypedArray a = context.obtainStyledAttributes(attrId);
for (int i = 0; i < attrId.length; i++) {
resourceIdArray[i] = a.getResourceId(i, defaultResourceId[i]);
}
a.recycle();
return resourceIdArray;
}
}
package com.tencent.liteav.demo.beauty;
import android.content.Context;
import android.net.ConnectivityManager;
import android.net.NetworkInfo;
import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import android.util.Log;
import java.io.File;
public class VideoDeviceUtil {
private static final String TAG = "VideoDeviceUtil";
public VideoDeviceUtil() {
}
public static boolean isNetworkAvailable(@NonNull Context context) {
ConnectivityManager connectivity = (ConnectivityManager) context.getSystemService(Context.CONNECTIVITY_SERVICE);
if (connectivity == null) {
return false;
} else {
NetworkInfo networkInfo = connectivity.getActiveNetworkInfo();
return networkInfo != null && networkInfo.isConnectedOrConnecting();
}
}
@Nullable
public static File getExternalFilesDir(@NonNull Context context, String folder) {
if (context == null) {
Log.e(TAG, "getExternalFilesDir context is null");
return null;
}
File sdcardDir = context.getApplicationContext().getExternalFilesDir(null);
if (sdcardDir == null) {
Log.e(TAG, "sdcardDir is null");
return null;
}
String path = sdcardDir.getPath();
File file = new File(path + File.separator + folder);
try {
if (file.exists() && file.isFile()) {
file.delete();
}
if (!file.exists()) {
file.mkdirs();
}
} catch (Exception var5) {
var5.printStackTrace();
}
return file;
}
}
package com.tencent.liteav.demo.beauty;
import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import android.text.TextUtils;
import java.io.BufferedInputStream;
import java.io.BufferedOutputStream;
import java.io.File;
import java.io.FileInputStream;
import java.io.FileOutputStream;
import java.io.IOException;
import java.util.Collection;
import java.util.zip.ZipEntry;
import java.util.zip.ZipInputStream;
public class VideoUtil {
private static final String TAG = "VideoUtil";
public VideoUtil() {
}
public static boolean isEmpty(@Nullable Collection object) {
return null == object || object.isEmpty();
}
public static synchronized String unZip(@NonNull String zipFile, @NonNull String targetDir) {
if (TextUtils.isEmpty(zipFile)) {
return null;
} else {
File file = new File(zipFile);
if (!file.exists()) {
return null;
} else {
File targetFolder = new File(targetDir);
if (!targetFolder.exists()) {
targetFolder.mkdirs();
}
String dataDir = null;
short BUFFER = 4096;
FileInputStream fis = null;
ZipInputStream zis = null;
FileOutputStream fos = null;
BufferedOutputStream dest = null;
try {
fis = new FileInputStream(file);
zis = new ZipInputStream(new BufferedInputStream(fis));
while (true) {
while (true) {
String strEntry;
ZipEntry entry;
do {
if ((entry = zis.getNextEntry()) == null) {
return dataDir;
}
strEntry = entry.getName();
} while (strEntry.contains("../"));
if (entry.isDirectory()) {
String count1 = targetDir + File.separator + strEntry;
File data1 = new File(count1);
if (!data1.exists()) {
data1.mkdirs();
}
if (TextUtils.isEmpty(dataDir)) {
dataDir = data1.getPath();
}
} else {
byte[] data = new byte[BUFFER];
String targetFileDir = targetDir + File.separator + strEntry;
File targetFile = new File(targetFileDir);
try {
fos = new FileOutputStream(targetFile);
dest = new BufferedOutputStream(fos, BUFFER);
int count;
while ((count = zis.read(data)) != -1) {
dest.write(data, 0, count);
}
dest.flush();
} catch (IOException var41) {
var41.printStackTrace();
} finally {
try {
if (dest != null) {
dest.close();
}
if (fos != null) {
fos.close();
}
} catch (IOException var40) {
var40.printStackTrace();
}
}
}
}
}
} catch (IOException e) {
e.printStackTrace();
} finally {
try {
if (zis != null) {
zis.close();
}
if (fis != null) {
fis.close();
}
} catch (IOException e) {
e.printStackTrace();
}
}
return dataDir;
}
}
}
}
<?xml version="1.0" encoding="utf-8"?>
<set xmlns:android="http://schemas.android.com/apk/res/android">
<rotate
android:duration="1500"
android:fromDegrees="0"
android:interpolator="@android:anim/linear_interpolator"
android:pivotX="50%"
android:pivotY="50%"
android:repeatCount="-1"
android:repeatMode="restart"
android:startOffset="-1"
android:toDegrees="+360" />
</set>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
<item android:id="@android:id/background">
<shape>
<corners android:radius="6dp" />
<solid android:color="#ffd8d8d8" />
</shape>
</item>
<item android:id="@android:id/secondaryProgress">
<clip>
<shape>
<corners android:radius="6dp" />
<solid android:color="#FF584C" />
</shape>
</clip>
</item>
<item android:id="@android:id/progress">
<clip>
<shape>
<corners android:radius="6dp" />
<solid android:color="#FF584C" />
</shape>
</clip>
</item>
</layer-list>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:state_selected="true" android:color="?attr/beautyPanelColorPrimary"/>
<item android:color="#ffffff"/>
</selector>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="bottom"
android:background="@drawable/ic_beauty_bottom_bg"
android:minHeight="105dp"
android:orientation="vertical">
<LinearLayout
android:id="@+id/record_layout_seekbar"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="10dp"
android:gravity="center_vertical"
android:orientation="horizontal">
<SeekBar
android:id="@+id/seekbarThird"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1.98"
android:indeterminate="false"
android:max="9"
android:maxHeight="4dp"
android:minHeight="4dp"
android:paddingLeft="15dp"
android:paddingRight="36dp"
android:progress="0"
android:progressDrawable="@drawable/seekbar_progress_drawable"
android:thumb="@drawable/play_seekbar_icon"
android:visibility="visible" />
<TextView
android:id="@+id/tvSeekbarValue"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:paddingRight="15dp"
android:text="0"
android:textColor="@color/colorRed"
android:textSize="18sp" />
</LinearLayout>
<LinearLayout
android:id="@+id/layout_koubei"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="10dp"
android:gravity="center_vertical"
android:orientation="horizontal"
android:visibility="gone">
<TextView
android:id="@+id/tv_koubei_none"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:drawableTop="@drawable/ic_effect_non"
android:gravity="center"
android:paddingRight="15dp"
android:text="无动效"
android:textColor="#FF584C"
android:textSize="12dp" />
<TextView
android:id="@+id/tv_koubei"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:drawableTop="@drawable/ic_beauty_koubei"
android:gravity="center"
android:text="AI抠背"
android:textColor="@drawable/text_color1"
android:textSize="12dp" />
</LinearLayout>
<LinearLayout
android:id="@+id/layout_green"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="10dp"
android:gravity="center_vertical"
android:orientation="horizontal"
android:visibility="gone">
<TextView
android:id="@+id/tv_green_none"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:drawableTop="@drawable/ic_effect_non"
android:gravity="center"
android:paddingRight="15dp"
android:text="无"
android:textColor="#FF584C"
android:textSize="12dp" />
<TextView
android:id="@+id/tv_green"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:drawableTop="@drawable/ic_beauty_goodluck"
android:gravity="center"
android:text="Good Luck"
android:textColor="@drawable/text_color1"
android:textSize="12dp" />
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center_vertical"
android:orientation="horizontal">
<com.tencent.liteav.demo.beauty.TCHorizontalScrollView
android:id="@+id/horizontalPickerViewSecond"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="10dp"
android:paddingRight="12dp"
android:scrollbars="none">
<LinearLayout
android:id="@android:id/content"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:gravity="center"
android:orientation="horizontal" />
</com.tencent.liteav.demo.beauty.TCHorizontalScrollView>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="50dp"
android:background="@drawable/ic_beauty_bottom_bg2"
android:gravity="center_vertical"
android:orientation="horizontal"
android:weightSum="2">
<com.tencent.liteav.demo.beauty.TCHorizontalScrollView
android:id="@+id/horizontalPickerViewFirst"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="10dp"
android:paddingRight="12dp"
android:scrollbars="none">
<LinearLayout
android:id="@android:id/content"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:gravity="center"
android:orientation="horizontal" />
</com.tencent.liteav.demo.beauty.TCHorizontalScrollView>
</LinearLayout>
</LinearLayout>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical"
android:padding="10dp">
<ImageView
android:id="@+id/icon"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:src="@drawable/ic_effect_non" />
<TextView
android:id="@+id/title"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:textColor="@color/white"
android:textSize="12dp" />
</LinearLayout>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:gravity="center"
android:id="@+id/layout_progress">
<ImageView
android:id="@+id/progress_img"
android:layout_width="48dp"
android:layout_height="48dp"
android:layout_centerInParent="true"
android:background="@drawable/loading_circle_progress"/>
<TextView
android:id="@+id/msg_tv"
android:layout_below="@id/progress_img"
android:layout_marginTop="10dp"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerHorizontal="true"
android:text=""
android:textColor="@color/white"
android:visibility="visible"/>
</LinearLayout>
\ No newline at end of file
<resources>
<string name="beauty_setting_pannel_style">Style</string>
<string name="beauty_setting_pannel_beauty">Beauty</string>
<string name="beauty_setting_pannel_filter">Filter</string>
<string name="beauty_setting_pannel_dynamic_effect">Dynamic effect</string>
<string name="beauty_setting_pannel_key">Blend Pic</string>
<string name="beauty_setting_pannel_green_screen">Green screen</string>
<string name="beauty_setting_pannel_facebeauty">Face beauty</string>
<string name="beauty_setting_pannel_gesture">Gesture</string>
<string name="beauty_pannel_style_smooth">Beauty(Smooth)</string>
<string name="beauty_pannel_style_natural">Beauty(Natural)</string>
<string name="beauty_pannel_style_pitu">Beauty(PS)</string>
<string name="beauty_setting_pannel_beauty_beauty">Beauty</string>
<string name="beauty_pannel_white">White</string>
<string name="beauty_pannel_ruddy">Ruddy</string>
<string name="beauty_pannel_bigeye">Big eyes</string>
<string name="beauty_pannel_faceslim">Thin-face</string>
<string name="beauty_pannel_facev">V-face</string>
<string name="beauty_pannel_chin">Chin</string>
<string name="beauty_pannel_faceshort">Short-face</string>
<string name="beauty_pannel_noseslim">Thin-nose</string>
<string name="beauty_pannel_eyelighten">Eye-lighten</string>
<string name="beauty_pannel_toothwhite">Tooth-white</string>
<string name="beauty_pannel_pounchremove">Pounch-remove</string>
<string name="beauty_pannel_smilelinesremove">Smilelines-remove</string>
<string name="beauty_pannel_wrinkleremove">Wrinkle-remove</string>
<string name="beauty_pannel_forehead">Forehead</string>
<string name="beauty_pannel_eyedistance">Eye-distance</string>
<string name="beauty_pannel_eyeangle">Eye-angle</string>
<string name="beauty_pannel_mouthshape">Mouth-shape</string>
<string name="beauty_pannel_nosewing">Nose-wing</string>
<string name="beauty_pannel_noseposition">Nose-position</string>
<string name="beauty_pannel_mousewidth">Mouse-width</string>
<string name="beauty_pannel_faceshape">Face-shape</string>
<string name="beauty_setting_pannel_filter_none">None</string>
<string name="beauty_setting_pannel_filter_standard">Standard</string>
<string name="beauty_setting_pannel_filter_cheery">Cheery</string>
<string name="beauty_setting_pannel_filter_cloud">Cloud</string>
<string name="beauty_setting_pannel_filter_pure">Pure</string>
<string name="beauty_setting_pannel_filter_orchid">Orchid</string>
<string name="beauty_setting_pannel_filter_vitality">Vitality</string>
<string name="beauty_setting_pannel_filter_super">Super</string>
<string name="beauty_setting_pannel_filter_fragrance">Fragrance</string>
<string name="beauty_setting_pannel_filter_white">White</string>
<string name="beauty_setting_pannel_filter_romantic">Romantic</string>
<string name="beauty_setting_pannel_filter_fresh">Fresh</string>
<string name="beauty_setting_pannel_filter_beautiful">Aesthetic</string>
<string name="beauty_setting_pannel_filter_pink">Rosy</string>
<string name="beauty_setting_pannel_filter_reminiscence">Nostalgic</string>
<string name="beauty_setting_pannel_filter_blues">Blues</string>
<string name="beauty_setting_pannel_filter_cool">Cool</string>
<string name="beauty_setting_pannel_filter_Japanese">Sweet</string>
<string name="beauty_setting_pannel_dynamic_effect_none">None</string>
<string name="beauty_setting_pannel_dynamic_effect_boom">Boom</string>
<string name="beauty_setting_pannel_dynamic_effect_neon_mouse">Rainbow Mouse</string>
<string name="beauty_setting_pannel_dynamic_effect_star_ear">Star ear</string>
<string name="beauty_setting_pannel_dynamic_effect_crazy_cheer_up">Glow stick</string>
<string name="beauty_setting_pannel_dynamic_effect_Q_cancelonstellation">Q constellation</string>
<string name="beauty_setting_pannel_dynamic_effect_colored_ribbon">Color Ribbon</string>
<string name="beauty_setting_pannel_dynamic_effect_bands_hairband">Bang Ribbon</string>
<string name="beauty_setting_pannel_dynamic_effect_change_face">Change face</string>
<string name="beauty_setting_pannel_dynamic_effect_purple_kitten">Violet Cat</string>
<string name="beauty_setting_pannel_dynamic_effect_flower_faerie">Floral Fairy</string>
<string name="beauty_setting_pannel_dynamic_effect_little_Princess">Little princess</string>
<string name="beauty_setting_pannel_key_none">None</string>
<string name="beauty_setting_pannel_key_AI_key">AI Scratch</string>
<string name="beauty_setting_pannel_green_screen_none">None</string>
<string name="beauty_setting_pannel_green_screen_good_luck">Good luck</string>
<string name="beauty_setting_pannel_pikaqiu">PikaQiu</string>
<string name="beauty_setting_pannel_liuxingyu">Meteor Shower</string>
<string name="beauty_setting_pannel_kongxue">Snow Control</string>
<string name="beauty_setting_pannel_dianshizhixing">TV Star</string>
<string name="beauty_setting_pannel_bottle">Bottle</string>
<string name="beauty_setting_pannel_yuansufugu">Fu Gu</string>
<string name="beauty_setting_pannel_cherries">Cherries</string>
<string name="beauty_setting_pannel_haiyang">Ocean</string>
<string name="beauty_setting_pannel_fenfenxia">FenfenXia</string>
<string name="beauty_setting_pannel_guajiezhuang">Widow Makeup</string>
<string name="beauty_setting_pannel_qixichun">Qixichun</string>
<string name="beauty_setting_pannel_gufengzhuang">Gufeng</string>
<string name="beauty_setting_pannel_xiaochounv">Ugly Girl</string>
<string name="beauty_setting_pannel_hunhezhuang">Mixed Makeup</string>
<string name="video_material_download_progress_material_unzip_failed">Unable to decompress materials</string>
<string name="video_material_download_progress_download_failed">Unable to download</string>
<string name="video_material_download_progress_no_enough_storage_space">Insufficient storage</string>
</resources>
<resources>
<!-- Example customization of dimensions originally defined in res/values/dimens.xml
(such as screen margins) for screens with more than 820dp of available width. This
would include 7" and 10" devices in landscape (~960dp and ~1280dp respectively). -->
</resources>
<resources>
<string name="beauty_setting_pannel_style">風格</string>
<string name="beauty_setting_pannel_beauty">美顏</string>
<string name="beauty_setting_pannel_filter">濾鏡</string>
<string name="beauty_setting_pannel_dynamic_effect">動效</string>
<string name="beauty_setting_pannel_key">摳背</string>
<string name="beauty_setting_pannel_green_screen">綠幕</string>
<string name="beauty_setting_pannel_facebeauty">美妆</string>
<string name="beauty_setting_pannel_gesture">手势</string>
<string name="beauty_pannel_style_smooth">美顏(光滑)</string>
<string name="beauty_pannel_style_natural">美顏(自然)</string>
<string name="beauty_pannel_style_pitu">美顏(天天P图)</string>
<string name="beauty_setting_pannel_beauty_beauty">美顏</string>
<string name="beauty_pannel_white">美白</string>
<string name="beauty_pannel_ruddy">紅潤</string>
<string name="beauty_pannel_bigeye">大眼</string>
<string name="beauty_pannel_faceslim">瘦臉</string>
<string name="beauty_pannel_facev">V臉</string>
<string name="beauty_pannel_chin">下巴</string>
<string name="beauty_pannel_faceshort">短臉</string>
<string name="beauty_pannel_noseslim">瘦鼻</string>
<string name="beauty_pannel_eyelighten">亮眼</string>
<string name="beauty_pannel_toothwhite">白牙</string>
<string name="beauty_pannel_pounchremove">祛眼袋</string>
<string name="beauty_pannel_smilelinesremove">祛法令纹</string>
<string name="beauty_pannel_wrinkleremove">祛皱</string>
<string name="beauty_pannel_forehead">发际线</string>
<string name="beauty_pannel_eyedistance">眼距</string>
<string name="beauty_pannel_eyeangle">眼角</string>
<string name="beauty_pannel_mouthshape">嘴形</string>
<string name="beauty_pannel_nosewing">鼻翼</string>
<string name="beauty_pannel_noseposition">鼻子位置</string>
<string name="beauty_pannel_mousewidth">嘴唇厚度</string>
<string name="beauty_pannel_faceshape">脸型</string>
<string name="beauty_setting_pannel_filter_none"></string>
<string name="beauty_setting_pannel_filter_standard">標準</string>
<string name="beauty_setting_pannel_filter_cheery">櫻紅</string>
<string name="beauty_setting_pannel_filter_cloud">雲裳</string>
<string name="beauty_setting_pannel_filter_pure">純真</string>
<string name="beauty_setting_pannel_filter_orchid">白蘭</string>
<string name="beauty_setting_pannel_filter_vitality">元氣</string>
<string name="beauty_setting_pannel_filter_super">超脫</string>
<string name="beauty_setting_pannel_filter_fragrance">香氛</string>
<string name="beauty_setting_pannel_filter_white">美白</string>
<string name="beauty_setting_pannel_filter_romantic">浪漫</string>
<string name="beauty_setting_pannel_filter_fresh">清新</string>
<string name="beauty_setting_pannel_filter_beautiful">唯美</string>
<string name="beauty_setting_pannel_filter_pink">粉嫩</string>
<string name="beauty_setting_pannel_filter_reminiscence">懷舊</string>
<string name="beauty_setting_pannel_filter_blues">藍調</string>
<string name="beauty_setting_pannel_filter_cool">清涼</string>
<string name="beauty_setting_pannel_filter_Japanese">日系</string>
<string name="beauty_setting_pannel_dynamic_effect_none">無動效</string>
<string name="beauty_setting_pannel_dynamic_effect_boom">Boom</string>
<string name="beauty_setting_pannel_dynamic_effect_neon_mouse">霓虹鼠</string>
<string name="beauty_setting_pannel_dynamic_effect_star_ear">星耳</string>
<string name="beauty_setting_pannel_dynamic_effect_crazy_cheer_up">瘋狂打call</string>
<string name="beauty_setting_pannel_dynamic_effect_Q_cancelonstellation">Q星座</string>
<string name="beauty_setting_pannel_dynamic_effect_colored_ribbon">彩色絲帶</string>
<string name="beauty_setting_pannel_dynamic_effect_bands_hairband">劉海髮帶</string>
<string name="beauty_setting_pannel_dynamic_effect_change_face">變臉</string>
<string name="beauty_setting_pannel_dynamic_effect_purple_kitten">紫色小貓</string>
<string name="beauty_setting_pannel_dynamic_effect_flower_faerie">花仙子</string>
<string name="beauty_setting_pannel_dynamic_effect_little_Princess">小公舉</string>
<string name="beauty_setting_pannel_key_none"></string>
<string name="beauty_setting_pannel_key_AI_key">AI摳背</string>
<string name="beauty_setting_pannel_green_screen_none"></string>
<string name="beauty_setting_pannel_green_screen_good_luck">Good luck</string>
<string name="beauty_setting_pannel_pikaqiu">皮卡丘</string>
<string name="beauty_setting_pannel_liuxingyu">流星雨</string>
<string name="beauty_setting_pannel_kongxue">控雪</string>
<string name="beauty_setting_pannel_dianshizhixing">电视之星</string>
<string name="beauty_setting_pannel_bottle">瓶盖挑战</string>
<string name="beauty_setting_pannel_yuansufugu">原宿復古</string>
<string name="beauty_setting_pannel_cherries">櫻桃</string>
<string name="beauty_setting_pannel_haiyang">海洋</string>
<string name="beauty_setting_pannel_fenfenxia">粉粉霞</string>
<string name="beauty_setting_pannel_guajiezhuang">寡姐妝</string>
<string name="beauty_setting_pannel_qixichun">七夕唇印</string>
<string name="beauty_setting_pannel_gufengzhuang">古风妝</string>
<string name="beauty_setting_pannel_xiaochounv">小丑女</string>
<string name="beauty_setting_pannel_hunhezhuang">混合妝</string>
<string name="video_material_download_progress_material_unzip_failed">素材解壓失敗</string>
<string name="video_material_download_progress_download_failed">下載失敗</string>
<string name="video_material_download_progress_no_enough_storage_space">存儲空間不足</string>
</resources>
<resources>
<string name="beauty_setting_pannel_style">風格</string>
<string name="beauty_setting_pannel_beauty">美顏</string>
<string name="beauty_setting_pannel_filter">濾鏡</string>
<string name="beauty_setting_pannel_dynamic_effect">動效</string>
<string name="beauty_setting_pannel_key">摳背</string>
<string name="beauty_setting_pannel_green_screen">綠幕</string>
<string name="beauty_setting_pannel_facebeauty">美妆</string>
<string name="beauty_setting_pannel_gesture">手势</string>
<string name="beauty_pannel_style_smooth">美顏(光滑)</string>
<string name="beauty_pannel_style_natural">美顏(自然)</string>
<string name="beauty_pannel_style_pitu">美顏(天天P图)</string>
<string name="beauty_setting_pannel_beauty_beauty">美顏</string>
<string name="beauty_pannel_white">美白</string>
<string name="beauty_pannel_ruddy">紅潤</string>
<string name="beauty_pannel_bigeye">大眼</string>
<string name="beauty_pannel_faceslim">瘦臉</string>
<string name="beauty_pannel_facev">V臉</string>
<string name="beauty_pannel_chin">下巴</string>
<string name="beauty_pannel_faceshort">短臉</string>
<string name="beauty_pannel_noseslim">瘦鼻</string>
<string name="beauty_pannel_eyelighten">亮眼</string>
<string name="beauty_pannel_toothwhite">白牙</string>
<string name="beauty_pannel_pounchremove">祛眼袋</string>
<string name="beauty_pannel_smilelinesremove">祛法令纹</string>
<string name="beauty_pannel_wrinkleremove">祛皱</string>
<string name="beauty_pannel_forehead">发际线</string>
<string name="beauty_pannel_eyedistance">眼距</string>
<string name="beauty_pannel_eyeangle">眼角</string>
<string name="beauty_pannel_mouthshape">嘴形</string>
<string name="beauty_pannel_nosewing">鼻翼</string>
<string name="beauty_pannel_noseposition">鼻子位置</string>
<string name="beauty_pannel_mousewidth">嘴唇厚度</string>
<string name="beauty_pannel_faceshape">脸型</string>
<string name="beauty_setting_pannel_filter_none"></string>
<string name="beauty_setting_pannel_filter_standard">標準</string>
<string name="beauty_setting_pannel_filter_cheery">櫻紅</string>
<string name="beauty_setting_pannel_filter_cloud">雲裳</string>
<string name="beauty_setting_pannel_filter_pure">純真</string>
<string name="beauty_setting_pannel_filter_orchid">白蘭</string>
<string name="beauty_setting_pannel_filter_vitality">元氣</string>
<string name="beauty_setting_pannel_filter_super">超脫</string>
<string name="beauty_setting_pannel_filter_fragrance">香氛</string>
<string name="beauty_setting_pannel_filter_white">美白</string>
<string name="beauty_setting_pannel_filter_romantic">浪漫</string>
<string name="beauty_setting_pannel_filter_fresh">清新</string>
<string name="beauty_setting_pannel_filter_beautiful">唯美</string>
<string name="beauty_setting_pannel_filter_pink">粉嫩</string>
<string name="beauty_setting_pannel_filter_reminiscence">懷舊</string>
<string name="beauty_setting_pannel_filter_blues">藍調</string>
<string name="beauty_setting_pannel_filter_cool">清涼</string>
<string name="beauty_setting_pannel_filter_Japanese">日系</string>
<string name="beauty_setting_pannel_dynamic_effect_none">無動效</string>
<string name="beauty_setting_pannel_dynamic_effect_boom">Boom</string>
<string name="beauty_setting_pannel_dynamic_effect_neon_mouse">霓虹鼠</string>
<string name="beauty_setting_pannel_dynamic_effect_star_ear">星耳</string>
<string name="beauty_setting_pannel_dynamic_effect_crazy_cheer_up">瘋狂打call</string>
<string name="beauty_setting_pannel_dynamic_effect_Q_cancelonstellation">Q星座</string>
<string name="beauty_setting_pannel_dynamic_effect_colored_ribbon">彩色絲帶</string>
<string name="beauty_setting_pannel_dynamic_effect_bands_hairband">劉海髮帶</string>
<string name="beauty_setting_pannel_dynamic_effect_change_face">變臉</string>
<string name="beauty_setting_pannel_dynamic_effect_purple_kitten">紫色小貓</string>
<string name="beauty_setting_pannel_dynamic_effect_flower_faerie">花仙子</string>
<string name="beauty_setting_pannel_dynamic_effect_little_Princess">小公舉</string>
<string name="beauty_setting_pannel_key_none"></string>
<string name="beauty_setting_pannel_key_AI_key">AI摳背</string>
<string name="beauty_setting_pannel_green_screen_none"></string>
<string name="beauty_setting_pannel_green_screen_good_luck">Good luck</string>
<string name="beauty_setting_pannel_pikaqiu">皮卡丘</string>
<string name="beauty_setting_pannel_liuxingyu">流星雨</string>
<string name="beauty_setting_pannel_kongxue">控雪</string>
<string name="beauty_setting_pannel_dianshizhixing">电视之星</string>
<string name="beauty_setting_pannel_bottle">瓶盖挑战</string>
<string name="beauty_setting_pannel_yuansufugu">原宿復古</string>
<string name="beauty_setting_pannel_cherries">櫻桃</string>
<string name="beauty_setting_pannel_haiyang">海洋</string>
<string name="beauty_setting_pannel_fenfenxia">粉粉霞</string>
<string name="beauty_setting_pannel_guajiezhuang">寡姐妝</string>
<string name="beauty_setting_pannel_qixichun">七夕唇印</string>
<string name="beauty_setting_pannel_gufengzhuang">古风妝</string>
<string name="beauty_setting_pannel_xiaochounv">小丑女</string>
<string name="beauty_setting_pannel_hunhezhuang">混合妝</string>
<string name="video_material_download_progress_material_unzip_failed">素材解壓失敗</string>
<string name="video_material_download_progress_download_failed">下載失敗</string>
<string name="video_material_download_progress_no_enough_storage_space">存儲空間不足</string>
</resources>
<resources>
<string name="beauty_setting_pannel_style">风格</string>
<string name="beauty_setting_pannel_beauty">美颜</string>
<string name="beauty_setting_pannel_filter">滤镜</string>
<string name="beauty_setting_pannel_dynamic_effect">动效</string>
<string name="beauty_setting_pannel_key">抠背</string>
<string name="beauty_setting_pannel_green_screen">绿幕</string>
<string name="beauty_setting_pannel_facebeauty">美妆</string>
<string name="beauty_setting_pannel_gesture">手势</string>
<string name="beauty_pannel_style_smooth">美颜(光滑)</string>
<string name="beauty_pannel_style_natural">美颜(自然)</string>
<string name="beauty_pannel_style_pitu">美颜(天天P图)</string>
<string name="beauty_setting_pannel_beauty_beauty">美颜</string>
<string name="beauty_pannel_white">美白</string>
<string name="beauty_pannel_ruddy">红润</string>
<string name="beauty_pannel_bigeye">大眼</string>
<string name="beauty_pannel_faceslim">瘦脸</string>
<string name="beauty_pannel_facev">V脸</string>
<string name="beauty_pannel_chin">下巴</string>
<string name="beauty_pannel_faceshort">短脸</string>
<string name="beauty_pannel_noseslim">瘦鼻</string>
<string name="beauty_pannel_eyelighten">亮眼</string>
<string name="beauty_pannel_toothwhite">白牙</string>
<string name="beauty_pannel_pounchremove">祛眼袋</string>
<string name="beauty_pannel_smilelinesremove">祛法令纹</string>
<string name="beauty_pannel_wrinkleremove">祛皱</string>
<string name="beauty_pannel_forehead">发际线</string>
<string name="beauty_pannel_eyedistance">眼距</string>
<string name="beauty_pannel_eyeangle">眼角</string>
<string name="beauty_pannel_mouthshape">嘴形</string>
<string name="beauty_pannel_nosewing">鼻翼</string>
<string name="beauty_pannel_noseposition">鼻子位置</string>
<string name="beauty_pannel_mousewidth">嘴唇厚度</string>
<string name="beauty_pannel_faceshape">脸型</string>
<string name="beauty_setting_pannel_filter_none"></string>
<string name="beauty_setting_pannel_filter_standard">标准</string>
<string name="beauty_setting_pannel_filter_cheery">樱红</string>
<string name="beauty_setting_pannel_filter_cloud">云裳</string>
<string name="beauty_setting_pannel_filter_pure">纯真</string>
<string name="beauty_setting_pannel_filter_orchid">白兰</string>
<string name="beauty_setting_pannel_filter_vitality">元气</string>
<string name="beauty_setting_pannel_filter_super">超脱</string>
<string name="beauty_setting_pannel_filter_fragrance">香氛</string>
<string name="beauty_setting_pannel_filter_white">美白</string>
<string name="beauty_setting_pannel_filter_romantic">浪漫</string>
<string name="beauty_setting_pannel_filter_fresh">清新</string>
<string name="beauty_setting_pannel_filter_beautiful">唯美</string>
<string name="beauty_setting_pannel_filter_pink">粉嫩</string>
<string name="beauty_setting_pannel_filter_reminiscence">怀旧</string>
<string name="beauty_setting_pannel_filter_blues">蓝调</string>
<string name="beauty_setting_pannel_filter_cool">清凉</string>
<string name="beauty_setting_pannel_filter_Japanese">日系</string>
<string name="beauty_setting_pannel_dynamic_effect_none"></string>
<string name="beauty_setting_pannel_dynamic_effect_boom">Boom</string>
<string name="beauty_setting_pannel_dynamic_effect_neon_mouse">霓虹鼠</string>
<string name="beauty_setting_pannel_dynamic_effect_star_ear">星耳</string>
<string name="beauty_setting_pannel_dynamic_effect_crazy_cheer_up">疯狂打call</string>
<string name="beauty_setting_pannel_dynamic_effect_Q_cancelonstellation">Q星座</string>
<string name="beauty_setting_pannel_dynamic_effect_colored_ribbon">彩色丝带</string>
<string name="beauty_setting_pannel_dynamic_effect_bands_hairband">刘海发带</string>
<string name="beauty_setting_pannel_dynamic_effect_change_face">变脸</string>
<string name="beauty_setting_pannel_dynamic_effect_purple_kitten">紫色小猫</string>
<string name="beauty_setting_pannel_dynamic_effect_flower_faerie">花仙子</string>
<string name="beauty_setting_pannel_dynamic_effect_little_Princess">小公举</string>
<string name="beauty_setting_pannel_key_none">无动效</string>
<string name="beauty_setting_pannel_key_AI_key">AI抠背</string>
<string name="beauty_setting_pannel_green_screen_none"></string>
<string name="beauty_setting_pannel_green_screen_good_luck">Good luck</string>
<string name="beauty_setting_pannel_pikaqiu">皮卡丘</string>
<string name="beauty_setting_pannel_liuxingyu">流星雨</string>
<string name="beauty_setting_pannel_kongxue">控雪</string>
<string name="beauty_setting_pannel_dianshizhixing">电视之星</string>
<string name="beauty_setting_pannel_bottle">瓶盖挑战</string>
<string name="beauty_setting_pannel_yuansufugu">原宿复古</string>
<string name="beauty_setting_pannel_cherries">樱桃</string>
<string name="beauty_setting_pannel_haiyang">海洋</string>
<string name="beauty_setting_pannel_fenfenxia">粉粉霞</string>
<string name="beauty_setting_pannel_guajiezhuang">寡姐妆</string>
<string name="beauty_setting_pannel_qixichun">七夕唇印</string>
<string name="beauty_setting_pannel_gufengzhuang">古风妆</string>
<string name="beauty_setting_pannel_xiaochounv">小丑女</string>
<string name="beauty_setting_pannel_hunhezhuang">混合妆</string>
<string name="video_material_download_progress_material_unzip_failed">素材解压失败</string>
<string name="video_material_download_progress_download_failed">下载失败</string>
<string name="video_material_download_progress_no_enough_storage_space">存储空间不足</string>
</resources>
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string-array name="beauty_category">
<item>美颜</item>
<item>滤镜</item>
<!--<item>动效</item>-->
<!--<item>美妆</item>-->
<!--<item>手势</item>-->
<!--<item>抠背</item>-->
<!--<item>绿幕</item>-->
</string-array>
<string-array name="beauty_style">
<item>美颜(光滑)</item>
<item>美颜(自然)</item>
<item>美颜(天天P图)</item>
</string-array>
<string-array name="beauty_type">
<item>美颜</item>
<item>美白</item>
<item>红润</item>
<item>大眼</item>
<item>瘦脸</item>
<item>V脸</item>
<item>下巴</item>
<item>短脸</item>
<item>瘦鼻</item>
<item>亮眼</item>
<item>白牙</item>
<item>祛眼袋</item>
<item>祛法令纹</item>
<item>祛皱</item>
<item>发际线</item>
<item>眼距</item>
<item>眼角</item>
<item>嘴形</item>
<item>鼻翼</item>
<item>鼻子位置</item>
<item>嘴唇厚度</item>
<item>脸型</item>
</string-array>
<string-array name="filter_type">
<item></item>
<item>标准</item>
<item>樱红</item>
<item>云裳</item>
<item>纯真</item>
<item>白兰</item>
<item>元气</item>
<item>超脱</item>
<item>香氛</item>
<item>美白</item>
<item>浪漫</item>
<item>清新</item>
<item>唯美</item>
<item>粉嫩</item>
<item>怀旧</item>
<item>蓝调</item>
<item>清凉</item>
<item>日系</item>
</string-array>
<string-array name="motion_type">
<item></item>
<item>Boom</item>
<item>霓虹鼠</item>
<item>星耳</item>
<item>疯狂打call</item>
<item>Q星座</item>
<item>彩色丝带</item>
<item>刘海发带</item>
<item>变脸</item>
<item>紫色小猫</item>
<item>花仙子</item>
<item>小公举</item>
</string-array>
<string-array name="koubei">
<item>无动效</item>
<item>AI抠背</item>
</string-array>
<string-array name="green_screen">
<item></item>
<item>Good luck</item>
</string-array>
<string-array name="gesture_type">
<item>皮卡丘</item>
<item>流星雨</item>
<item>控雪</item>
<item>电视之星</item>
<item>瓶盖挑战</item>
</string-array>
<string-array name="makeup_type">
<item>原宿复古</item>
<item>樱桃</item>
<item>海洋</item>
<item>粉粉霞</item>
<item>寡姐妆</item>
<item>七夕唇印</item>
<item>古风妆</item>
<item>小丑女</item>
<item>混合妆</item>
</string-array>
</resources>
<?xml version="1.0" encoding="utf-8"?>
<resources>
</resources>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<resources>
<color name="colorRed">#FF584C</color>
<color name="white">#FFFFFF</color>
</resources>
<resources>
<!-- Default screen margins, per the Android Design guidelines. -->
<!-- umeng -->
<dimen name="titlebar">54dp</dimen>
<dimen name="activity_horizontal_margin">16dp</dimen>
<dimen name="activity_vertical_margin">16dp</dimen>
<dimen name="title">18sp</dimen>
<dimen name="subtitle">17sp</dimen>
<dimen name="main_content">16sp</dimen>
<dimen name="sub_content">14sp</dimen>
<dimen name="trivial_content">12sp</dimen>
<dimen name="text_size">16sp</dimen>
<dimen name="t1">36sp</dimen>
<dimen name="t2">34sp</dimen>
<dimen name="t3">32sp</dimen>
<dimen name="t4">28sp</dimen>
<dimen name="t5">24sp</dimen>
<!--大小-->
<!--h1-->
<dimen name="h1">9sp</dimen>
<!--h2-->
<dimen name="h2">10sp</dimen>
<!--h3-->
<dimen name="h3">11sp</dimen>
<!--h4-->
<dimen name="h4">12sp</dimen>
<!--h5-->
<dimen name="h5">13sp</dimen>
<!--h6-->
<dimen name="h6">14sp</dimen>
<!--h7-->
<dimen name="h7">15sp</dimen>
<!--h8-->
<dimen name="h8">16sp</dimen>
<!--h9-->
<dimen name="h9">17sp</dimen>
<!--h10-->
<dimen name="h10">18sp</dimen>
<!--h11-->
<dimen name="h11">19sp</dimen>
<dimen name="h12">20sp</dimen>
<dimen name="toolbar_margin">15dp</dimen>
<dimen name="small_area_margin_bottom">110dp</dimen>
<dimen name="small_area_margin_top">130dp</dimen>
<dimen name="small_area_height">110dp</dimen>
<dimen name="small_area_width">60dp</dimen>
<dimen name="small_area_marginright">10dp</dimen>
<dimen name="small_area_marginbetween">10dp</dimen>
<dimen name="live_btn_size">35dp</dimen>
<!-- AVSDK *******************************************************************************************************************************-->
<dimen name="qav_title_margin_top">3dp</dimen>
<dimen name="qav_title_bar_height">50dp</dimen>
<dimen name="video_small_view_width">120dp</dimen>
<dimen name="video_small_view_height">160dp</dimen>
<dimen name="video_small_view_offsetX">10dp</dimen>
<dimen name="video_small_view_offsetY">10dp</dimen>
<dimen name="video_small_video_margin">1.5dp</dimen>
<dimen name="video_small_mute_margin">5dp</dimen>
<dimen name="video_msgbox_offsetX">23dp</dimen>
<dimen name="video_msgbox_offsetY">3dp</dimen>
<dimen name="video_msgbox_offset">3dp</dimen>
<dimen name="video_title_default_width">200dp</dimen>
<dimen name="video_top_toolbar_margin">45dp</dimen>
<dimen name="video_bottom_toolbar_margin">10dp</dimen>
<!-- 视频聊天中小窗口移动时的阈值 -->
<dimen name="video_smallview_move_thresholdX">30dp</dimen>
<dimen name="video_smallview_move_thresholdY">40dp</dimen>
<dimen name="multi_audio_item_faceW">42dp</dimen>
<dimen name="multi_audio_item_faceH">42dp</dimen>
<dimen name="multi_video_item_faceW">56dp</dimen>
<dimen name="multi_video_item_faceH">56dp</dimen>
<dimen name="audio_friend_imgW">60dp</dimen>
<dimen name="audio_friend_imgH">60dp</dimen>
<dimen name="audio_friend_img_border">66.5dp</dimen>
<dimen name="audio_friend_border_margin_top">3.25dp</dimen>
<dimen name="audio_friend_infoH">191dp</dimen>
<dimen name="audio_icon_top">25dp</dimen>
<dimen name="audio_actionsheet_height">51dp</dimen>
<dimen name="video_lock_margin">-15dp</dimen>
<dimen name="audio_tip_margin">83dp</dimen>
<dimen name="qav_bubbble_icon_ratio">16dp</dimen>
<dimen name="qav_bubbble_icon_ratio_ex">8dp</dimen>
<dimen name="qav_multi_video_friend_item_width">60dp</dimen>
<dimen name="qav_grid_view_item_width_audio">75dp</dimen>
<dimen name="qav_grid_view_item_width_video">64dp</dimen>
<dimen name="qav_gaudio_grid_icon_width">50dp</dimen>
<dimen name="qav_gaudio_grid_item_width">88dp</dimen>
<dimen name="qav_gaudio_speaking_icon_width">10dp</dimen>
<dimen name="qav_gaudio_speaking_icon_margin_left">6dp</dimen>
<dimen name="qav_gaudio_member_name_margin_top">4dp</dimen>
<dimen name="qav_gaudio_speaking_icon_margin_top">5dp</dimen>
<dimen name="qav_gaudio_member_name_width">50dp</dimen>
<dimen name="qav_gaudio_msg_text_width">95dp</dimen>
<dimen name="qav_gaudio_grid_margin_top_nor">60dp</dimen>
<dimen name="qav_gaudio_members_holder_margin_top_large">80dp</dimen>
<dimen name="qav_gaudio_members_holder_margin_top_small">24dp</dimen>
<dimen name="qav_gaudio_grid_net_tip_margin_top_two_line">300dp</dimen>
<dimen name="qav_gaudio_grid_net_tip_margin_top_one_line">210dp</dimen>
<dimen name="qav_gaudio_members_container_two_line">180dp</dimen>
<dimen name="qav_gaudio_members_container_one_line">90dp</dimen>
<dimen name="qav_gaudio_members_holder_height_two_line">250dp</dimen>
<dimen name="qav_gaudio_members_holder_height_one_line">110dp</dimen>
<dimen name="qav_gaudio_grid_margin_top_waiting">40dp</dimen>
<dimen name="qav_gaudio_grid_margin_members_top">110dp</dimen>
<dimen name="qav_gaudio_grid_margin_top_sig">157dp</dimen>
<dimen name="qav_gaudio_grid_height">300dp</dimen>
<dimen name="qav_gaudio_indicate_margin_top_two_line">190dp</dimen>
<dimen name="qav_gaudio_indicate_margin_top_one_line">100dp</dimen>
<dimen name="gaudio_grid_margin">3dp</dimen>
<dimen name="gaudio_speaking_width">56dp</dimen>
<dimen name="gaudio_speaking_margin">1dp</dimen>
<dimen name="gaudio_spacing">15dp</dimen>
<dimen name="gaudio_spacing_320">10dp</dimen>
<dimen name="gaudio_padding">5dp</dimen>
<dimen name="gaudio_dialog_width">270dp</dimen>
<dimen name="gaudio_dialog_height_gprs">182dp</dimen>
<dimen name="gaudio_dialog_btn_margin_top">47dp</dimen>
<dimen name="gaudio_dialog_height">160dp</dimen>
<dimen name="gaudio_dialog_textsize">4sp</dimen>
<dimen name="gaudio_lock_textsize">5sp</dimen>
<dimen name="gaudio_request_video_text_size">15dp</dimen>
<dimen name="gaudio_lock_maxwidth">280dp</dimen>
<dimen name="multi_video_name_max_width">95dp</dimen>
<dimen name="gaudio_name_maxwidth">162dp</dimen>
<dimen name="gaudio_tips_name_maxwidth">46dp</dimen>
<dimen name="gaudio_list_name_maxwidth">120dp</dimen>
<dimen name="gaudio_bigname_maxwidth">156dp</dimen>
<dimen name="gaudio_name_maxwidth_dialog">130dp</dimen>
<dimen name="gaudio_name_maxwidth_inviter">70dp</dimen>
<dimen name="gaudio_name_maxwidth_title">60dp</dimen>
<dimen name="qav_double_friend_imgW">95dp</dimen>
<dimen name="qav_double_video_friend_imgW">50dp</dimen>
<dimen name="qav_notification_icon">64dp</dimen>
<dimen name="qav_gaudio_indicator_top">250dp</dimen>
<dimen name="qav_bottombar_spacing">7dp</dimen>
<dimen name="qav_invite_btn_right_margin">60dp</dimen>
<dimen name="qav_bottombar_icon_spacing">1dp</dimen>
<dimen name="qav_bottombar_btn_width">60dp</dimen>
<dimen name="qav_bottombar_btn_height">46dp</dimen>
<dimen name="qav_bottombar_margin">32dp</dimen>
<dimen name="qav_bottombar_margin_for_ivr">18dp</dimen>
<dimen name="qav_bottomlayer_margin">20dp</dimen>
<dimen name="qav_bottombar_normal_margin">16dp</dimen>
<dimen name="qav_bottombar_height">170dp</dimen>
<dimen name="qav_bottombar_bg_height">255dp</dimen>
<dimen name="qav_titlebar_height">25dp</dimen>
<dimen name="qav_info_margintop">160dp</dimen>
<dimen name="qav_info_margintop_video">60dp</dimen>
<dimen name="qav_info_name_margintop">5dp</dimen>
<dimen name="qav_ring_margintop">130dp</dimen>
<dimen name="qav_tips_margintop">300dp</dimen>
<dimen name="qav_info_margintop_ldpi">70dp</dimen>
<dimen name="qav_tips_margintop_ldpi">240dp</dimen>
<dimen name="qav_accept_video_margin_top">240dp</dimen>
<dimen name="qav_waiting_tip_margin_top_two_line">113dp</dimen>
<dimen name="qav_waiting_tip_margin_top_one_line">54dp</dimen>
<dimen name="qav_waiting_tip_margin_top">40dp</dimen>
<dimen name="qav_waiting_tip_margin_top_small">50dp</dimen>
<dimen name="qav_net_tip_margin_top">350dp</dimen>
<dimen name="qav_net_tip_margin_top_small">210dp</dimen>
<dimen name="qav_lock_margin">47dp</dimen>
<dimen name="qav_lock_bg_w">266dp</dimen>
<dimen name="qav_lock_right_edge">260dp</dimen>
<dimen name="qav_lock_left_margin">6dp</dimen>
<dimen name="qav_invite_btn_trans">40dp</dimen>
<dimen name="qav_bottombar_left_trans">23dp</dimen>
<dimen name="qav_bottombar_mid_trans">68dp</dimen>
<dimen name="qav_bottombar_right_trans">5dp</dimen>
<dimen name="qav_msg_name_max_width">100dp</dimen>
<dimen name="qav_msg_text_max_width">226dp</dimen>
<dimen name="qav_waiting_text_max_width">128dp</dimen>
<dimen name="qav_smartbar_height">48dp</dimen>
<dimen name="qav_setting_table_row_height">50dp</dimen>
<dimen name="ugc_item_thumb_height">60dp</dimen>
<dimen name="ugc_cut_margin">10dp</dimen>
<!-- AVSDK *******************************************************************************************************************************-->
<!-- UGC*******************************************************************************************************************************-->
<dimen name="ugc_aspect_width">50dp</dimen>
<dimen name="ugc_aspect_divider">18dp</dimen>
<dimen name="ugc_progress_cursor">2dp</dimen>
<dimen name="ugc_progress_min_pos">2dp</dimen>
<dimen name="ugc_progress_divider">1dp</dimen>
<!-- 视频进度条 -->
<dimen name="video_progress_height">50dp</dimen>
<dimen name="video_thumbnail_width">50dp</dimen>
<dimen name="repeat_slider_width">26dp</dimen>
<!-- UGC*******************************************************************************************************************************-->
</resources>
<resources>
<string name="beauty_setting_pannel_style">风格</string>
<string name="beauty_setting_pannel_beauty">美颜</string>
<string name="beauty_setting_pannel_filter">滤镜</string>
<string name="beauty_setting_pannel_dynamic_effect">动效</string>
<string name="beauty_setting_pannel_key">抠背</string>
<string name="beauty_setting_pannel_green_screen">绿幕</string>
<string name="beauty_setting_pannel_facebeauty">美妆</string>
<string name="beauty_setting_pannel_gesture">手势</string>
<string name="beauty_pannel_style_smooth">美颜(光滑)</string>
<string name="beauty_pannel_style_natural">美颜(自然)</string>
<string name="beauty_pannel_style_pitu">美颜(天天P图)</string>
<string name="beauty_setting_pannel_beauty_beauty">美颜</string>
<string name="beauty_pannel_white">美白</string>
<string name="beauty_pannel_ruddy">红润</string>
<string name="beauty_pannel_bigeye">大眼</string>
<string name="beauty_pannel_faceslim">瘦脸</string>
<string name="beauty_pannel_facev">V脸</string>
<string name="beauty_pannel_chin">下巴</string>
<string name="beauty_pannel_faceshort">短脸</string>
<string name="beauty_pannel_noseslim">瘦鼻</string>
<string name="beauty_pannel_eyelighten">亮眼</string>
<string name="beauty_pannel_toothwhite">白牙</string>
<string name="beauty_pannel_pounchremove">祛眼袋</string>
<string name="beauty_pannel_smilelinesremove">祛法令纹</string>
<string name="beauty_pannel_wrinkleremove">祛皱</string>
<string name="beauty_pannel_forehead">发际线</string>
<string name="beauty_pannel_eyedistance">眼距</string>
<string name="beauty_pannel_eyeangle">眼角</string>
<string name="beauty_pannel_mouthshape">嘴形</string>
<string name="beauty_pannel_nosewing">鼻翼</string>
<string name="beauty_pannel_noseposition">鼻子位置</string>
<string name="beauty_pannel_mousewidth">嘴唇厚度</string>
<string name="beauty_pannel_faceshape">脸型</string>
<string name="beauty_setting_pannel_filter_none"></string>
<string name="beauty_setting_pannel_filter_standard">标准</string>
<string name="beauty_setting_pannel_filter_cheery">樱红</string>
<string name="beauty_setting_pannel_filter_cloud">云裳</string>
<string name="beauty_setting_pannel_filter_pure">纯真</string>
<string name="beauty_setting_pannel_filter_orchid">白兰</string>
<string name="beauty_setting_pannel_filter_vitality">元气</string>
<string name="beauty_setting_pannel_filter_super">超脱</string>
<string name="beauty_setting_pannel_filter_fragrance">香氛</string>
<string name="beauty_setting_pannel_filter_white">美白</string>
<string name="beauty_setting_pannel_filter_romantic">浪漫</string>
<string name="beauty_setting_pannel_filter_fresh">清新</string>
<string name="beauty_setting_pannel_filter_beautiful">唯美</string>
<string name="beauty_setting_pannel_filter_pink">粉嫩</string>
<string name="beauty_setting_pannel_filter_reminiscence">怀旧</string>
<string name="beauty_setting_pannel_filter_blues">蓝调</string>
<string name="beauty_setting_pannel_filter_cool">清凉</string>
<string name="beauty_setting_pannel_filter_Japanese">日系</string>
<string name="beauty_setting_pannel_dynamic_effect_none"></string>
<string name="beauty_setting_pannel_dynamic_effect_boom">Boom</string>
<string name="beauty_setting_pannel_dynamic_effect_neon_mouse">霓虹鼠</string>
<string name="beauty_setting_pannel_dynamic_effect_star_ear">星耳</string>
<string name="beauty_setting_pannel_dynamic_effect_crazy_cheer_up">疯狂打call</string>
<string name="beauty_setting_pannel_dynamic_effect_Q_cancelonstellation">Q星座</string>
<string name="beauty_setting_pannel_dynamic_effect_colored_ribbon">彩色丝带</string>
<string name="beauty_setting_pannel_dynamic_effect_bands_hairband">刘海发带</string>
<string name="beauty_setting_pannel_dynamic_effect_change_face">变脸</string>
<string name="beauty_setting_pannel_dynamic_effect_purple_kitten">紫色小猫</string>
<string name="beauty_setting_pannel_dynamic_effect_flower_faerie">花仙子</string>
<string name="beauty_setting_pannel_dynamic_effect_little_Princess">小公举</string>
<string name="beauty_setting_pannel_key_none">无动效</string>
<string name="beauty_setting_pannel_key_AI_key">AI抠背</string>
<string name="beauty_setting_pannel_green_screen_none"></string>
<string name="beauty_setting_pannel_green_screen_good_luck">Good luck</string>
<string name="beauty_setting_pannel_pikaqiu">皮卡丘</string>
<string name="beauty_setting_pannel_liuxingyu">流星雨</string>
<string name="beauty_setting_pannel_kongxue">控雪</string>
<string name="beauty_setting_pannel_dianshizhixing">电视之星</string>
<string name="beauty_setting_pannel_bottle">瓶盖挑战</string>
<string name="beauty_setting_pannel_yuansufugu">原宿复古</string>
<string name="beauty_setting_pannel_cherries">樱桃</string>
<string name="beauty_setting_pannel_haiyang">海洋</string>
<string name="beauty_setting_pannel_fenfenxia">粉粉霞</string>
<string name="beauty_setting_pannel_guajiezhuang">寡姐妆</string>
<string name="beauty_setting_pannel_qixichun">七夕唇印</string>
<string name="beauty_setting_pannel_gufengzhuang">古风妆</string>
<string name="beauty_setting_pannel_xiaochounv">小丑女</string>
<string name="beauty_setting_pannel_hunhezhuang">混合妆</string>
<string name="video_material_download_progress_material_unzip_failed">素材解压失败</string>
<string name="video_material_download_progress_download_failed">下载失败</string>
<string name="video_material_download_progress_no_enough_storage_space">存储空间不足</string>
</resources>
<resources>
<!-- 自定义loading dialog -->
<style name="loading_dialog" parent="android:style/Theme.Dialog">
<item name="android:windowFrame">@null</item>
<item name="android:windowNoTitle">true</item>
<item name="android:windowBackground">@android:color/transparent</item>
<item name="android:windowIsFloating">true</item>
<item name="android:windowContentOverlay">@null</item>
</style>
</resources>
<?xml version="1.0" encoding="utf-8"?>
<resources>
<declare-styleable name="BeautyPanelStyle">
<!-- 美颜面板 -->
<attr name="beautyPanelColorPrimary" format="reference"/>
<attr name="beautyPanelSmoothIcon" format="reference" />
<attr name="beautyPanelNaturalIcon" format="reference" />
<attr name="beautyPanelPituIcon" format="reference" />
<attr name="beautyPanelWhiteIcon" format="reference" />
<attr name="beautyPanelRuddyIcon" format="reference" />
<attr name="beautyPanelBigeyeIcon" format="reference" />
<attr name="beautyPanelFaceslimIcon" format="reference" />
<attr name="beautyPanelFacevIcon" format="reference" />
<attr name="beautyPanelChinIcon" format="reference" />
<attr name="beautyPanelFaceshortIcon" format="reference" />
<attr name="beautyPanelNoseslimIcon" format="reference" />
<attr name="beautyPanelEyeLightenIcon" format="reference" />
<attr name="beautyPanelToothWhiteIcon" format="reference" />
<attr name="beautyPanelPounchRemoveIcon" format="reference" />
<attr name="beautyPanelSmileLinesRemoveIcon" format="reference" />
<attr name="beautyPanelWrinkleIcon" format="reference" />
<attr name="beautyPanelForeheadIcon" format="reference" />
<attr name="beautyPanelEyeDistanceIcon" format="reference" />
<attr name="beautyPanelEyeAngleIcon" format="reference" />
<attr name="beautyPanelMouthShapeIcon" format="reference" />
<attr name="beautyPanelNoseWingIcon" format="reference" />
<attr name="beautyPanelNosePositionIcon" format="reference" />
<attr name="beautyPanelMouseWidthIcon" format="reference" />
<attr name="beautyPanelFaceShapeIcon" format="reference" />
</declare-styleable>
</resources>
<?xml version="1.0" encoding="utf-8"?>
<resources>
<!-- 短视频录制主题UI配置-->
<style name="BeautyPanelStyle">
<!-- 美颜面板 -->
<item name="beautyPanelColorPrimary">@color/colorRed</item>
<item name="beautyPanelSmoothIcon">@drawable/ic_beauty_smooth</item>
<item name="beautyPanelNaturalIcon">@drawable/ic_beauty_natural</item>
<item name="beautyPanelPituIcon">@drawable/ic_beauty_pitu</item>
<item name="beautyPanelWhiteIcon">@drawable/ic_beauty_white</item>
<item name="beautyPanelRuddyIcon">@drawable/ic_beauty_ruddy</item>
<item name="beautyPanelBigeyeIcon">@drawable/ic_beauty_bigeye</item>
<item name="beautyPanelFaceslimIcon">@drawable/ic_beauty_faceslim</item>
<item name="beautyPanelFacevIcon">@drawable/ic_beauty_facev</item>
<item name="beautyPanelChinIcon">@drawable/ic_beauty_chin</item>
<item name="beautyPanelFaceshortIcon">@drawable/ic_beauty_faceshort</item>
<item name="beautyPanelNoseslimIcon">@drawable/ic_beauty_noseslim</item>
<item name="beautyPanelEyeLightenIcon">@drawable/ic_eye_bright</item>
<item name="beautyPanelToothWhiteIcon">@drawable/ic_tooth_white</item>
<item name="beautyPanelPounchRemoveIcon">@drawable/ic_pounch_remove</item>
<item name="beautyPanelSmileLinesRemoveIcon">@drawable/ic_smilelines</item>
<item name="beautyPanelWrinkleIcon">@drawable/ic_wrinkles</item>
<item name="beautyPanelForeheadIcon">@drawable/ic_forehead</item>
<item name="beautyPanelEyeDistanceIcon">@drawable/ic_eye_distance</item>
<item name="beautyPanelEyeAngleIcon">@drawable/ic_eye_angle</item>
<item name="beautyPanelMouthShapeIcon">@drawable/ic_mouseshape</item>
<item name="beautyPanelNoseWingIcon">@drawable/ic_nose_wing</item>
<item name="beautyPanelNosePositionIcon">@drawable/ic_nose_position</item>
<item name="beautyPanelMouseWidthIcon">@drawable/ic_mouse_width</item>
<item name="beautyPanelFaceShapeIcon">@drawable/ic_faceshape</item>
</style>
</resources>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment