We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
chrome浏览器,图片大小5M,需要旋转的jpeg格式。 问题:首次无法打开,无法进行显示。 原因:canvas.drawImage方法调用的时候,图片还没有准备好。 代码: ng-image-crop.js 1593行。 这里调用canvas.toDataURL("image/png")的时候,图片没有准备好。 修改方式: var tmp = new Image(); tmp.src = canvas.toDataURL("image/png"); tmp.onload = function() { image = tmp; setTimeout(function () { resetCropHost(); events.trigger('image-updated'); }, 20 ) }
The text was updated successfully, but these errors were encountered:
No branches or pull requests
chrome浏览器,图片大小5M,需要旋转的jpeg格式。
问题:首次无法打开,无法进行显示。
原因:canvas.drawImage方法调用的时候,图片还没有准备好。
代码: ng-image-crop.js 1593行。
这里调用canvas.toDataURL("image/png")的时候,图片没有准备好。
修改方式:
var tmp = new Image();
tmp.src = canvas.toDataURL("image/png");
tmp.onload = function() {
image = tmp;
setTimeout(function () {
resetCropHost();
events.trigger('image-updated');
}, 20 )
}
The text was updated successfully, but these errors were encountered: