dingprog / makeup Goto Github PK
View Code? Open in Web Editor NEW让你的“女神”逆袭,代码撸彩妆(画妆)
Home Page: https://juejin.im/post/5d5ff49bf265da03d42fae9c
让你的“女神”逆袭,代码撸彩妆(画妆)
Home Page: https://juejin.im/post/5d5ff49bf265da03d42fae9c
美白和磨皮一起使用的话就报错了
你好,我想用你这个项目实现右眼的美妆相关功能,请问EyeAngleAndScaleCalc.Bean()的成员变量值是根据什么去确定的呢?我看你写的DrawUtils.draw方法直接都是写死的topP1,topP2,topP3等参数
case EYE_LASH:
//睫毛
EyeAngleAndScaleCalc.Bean bean = new EyeAngleAndScaleCalc.Bean();
bean.topP1 = new Point(90, 148);
bean.topP2 = new Point(246, 83);
bean.topP3 = new Point(405, 136);
bean.bottomP1 = new Point(45, 8);
bean.bottomP2 = new Point(65, 187);
bean.bottomP3 = new Point(342, 32);
bean.resTop = "lash_res_top.png";
bean.resBottom = "lash_res_bottom.png";
EyeDraw.drawLash(context, canvas, bean, FacePoint.getLeftEyePoint(faceJson), 80, false);
break;
case EYE_CONTACT:
//美瞳
Bitmap contact = BitmapUtils.getBitmapByAssetsName(context, "eye.png");
EyeDraw.drawContact(canvas, contact, FacePoint.getLeftEyePath(faceJson),
FacePoint.getLeftEyeCenter(faceJson), FacePoint.getLeftEyeRadius(faceJson), 120);
Paint paint = new Paint();
paint.setColor(Color.WHITE);
paint.setStyle(Paint.Style.STROKE);
break;
case EYE_DOUBLE:
//双眼皮
EyeAngleAndScaleCalc.Bean doubleBean = new EyeAngleAndScaleCalc.Bean();
doubleBean.topP1 = new Point(285, 288);
doubleBean.topP2 = new Point(459, 213);
doubleBean.topP3 = new Point(633, 288);
doubleBean.resTop = "double_eye.png";
EyeDraw.drawLash(context, canvas, doubleBean, FacePoint.getLeftEyePoint(faceJson), 150, false);
break;
case EYE_LINE:
//眼线
EyeAngleAndScaleCalc.Bean lineBean = new EyeAngleAndScaleCalc.Bean();
lineBean.topP1 = new Point(298, 276);
lineBean.topP2 = new Point(440, 216);
lineBean.topP3 = new Point(604, 266);
lineBean.resTop = "eye_line.png";
EyeDraw.drawLash(context, canvas, lineBean, FacePoint.getLeftEyePoint(faceJson), 100, false);
break;
case EYE_SHADOW:
//眼影
EyeAngleAndScaleCalc.Bean eyeShadow = new EyeAngleAndScaleCalc.Bean();
eyeShadow.topP1 = new Point(74, 160);
eyeShadow.topP2 = new Point(155, 102);
eyeShadow.topP3 = new Point(229, 160);
eyeShadow.rect = new Rect(74, 102, 229, 184);
eyeShadow.resTop = "eye_shadow.png";
EyeDraw.drawShadow(context, canvas, eyeShadow, FacePoint.getLeftEyePath(faceJson), FacePoint.getLeftEyePoint(faceJson), 150);
break;
希望大佬能够指教一下,谢谢
How can i use it for commercial use
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.