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

压缩部分代码是有误吗? #28

Closed
linwenchao opened this issue Mar 24, 2018 · 5 comments
Closed

压缩部分代码是有误吗? #28

linwenchao opened this issue Mar 24, 2018 · 5 comments

Comments

@linwenchao
Copy link

linwenchao commented Mar 24, 2018

很方便的控件,但发现iOS上图片质量很差,修改以下代码后正常,麻烦检查一下:
RNSyanImagePicker.m

74行

NSInteger   quality  = [options sy_integerForKey:@"quality"];

266 / 271 行

UIImageJPEGRepresentation(image, quality * 1.0 / 100);

另外,266/271行为啥要分两次压缩而不重用data?
返回base64是否可选好一点?

其它代码和Android还没有看,感谢! @syanbo

@syanbo
Copy link
Owner

syanbo commented Mar 25, 2018

谢谢你的反馈

@linwenchao
Copy link
Author

linwenchao commented Mar 26, 2018

Hi @syanbo
在Android下对比测试了一下,再次建议把Base64设为可选,三次转码和压缩,实在太消耗资源了

@syanbo
Copy link
Owner

syanbo commented Mar 27, 2018

@linwenchao 非常感谢 我在下个版本中把Base64设为可选

@ljunb
Copy link
Collaborator

ljunb commented Mar 30, 2018

见 commit 8796a03,等言少到时发布新版

@syanbo
Copy link
Owner

syanbo commented Mar 30, 2018

已发布新版本

@syanbo syanbo closed this as completed Mar 30, 2018
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

3 participants