Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

关于Face2D-Sticker的问题 #71

Closed
MRDHR opened this issue Jan 12, 2021 · 2 comments
Closed

关于Face2D-Sticker的问题 #71

MRDHR opened this issue Jan 12, 2021 · 2 comments

Comments

@MRDHR
Copy link

MRDHR commented Jan 12, 2021

测试过Face2D-Sticker demo后,预览和贴纸是竖屏的,在修改activity为横屏后特征点和贴纸均横向显示,请问如何修改才能达到横向预览并且特征点和贴纸也正确显示?

目前表现:
QQ图片20210112174156

期望结果:
QQ图片20210112174348

灵魂画图 请见谅,
image

@Mike-mei
Copy link
Contributor

若要实现特征点和贴纸也正确显示,需要修改EGLCameral类,getRotationAngleZ 的角度 -180
重新计算x ,y 的值
float x = ( point.getX() / width) * 2 - 1
float y = 1-( point.getY() / height ) * 2

@MRDHR
Copy link
Author

MRDHR commented Jan 15, 2021

修改后确实可行,谢谢大佬回复。

@MRDHR MRDHR closed this as completed Jan 15, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants