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

存在部分二维码,摄像头扫描可以识别,但是从相册获取不能识别 #124

Open
JMZone opened this issue Dec 19, 2018 · 10 comments

Comments

@JMZone
Copy link

JMZone commented Dec 19, 2018

存在部分二维码,摄像头扫描可以识别,但是从相册获取不能识别

@lishuailibertine
Copy link

嗯,也遇到了

@wanyijun
Copy link

现在这个问题还有吗?

@JMZone
Copy link
Author

JMZone commented Feb 22, 2019

现在这个问题还有吗?

如果没更新过就会有的.我之前是再加上XZbar去识别,配合使用

@qq432591
Copy link

同样存在这个问题

@popo193
Copy link

popo193 commented Jul 17, 2019

还是存在啊 有没有人解决了的?

@PengJiang520
Copy link

  • (UIImage *)redrawAlbumImage:(UIImage *)image {
    UIImage *bigImage = image;
    float actualHeight = bigImage.size.height;
    float actualWidth = bigImage.size.width;
    float newWidth =0;
    float newHeight =0;
    if(actualWidth > actualHeight) {
    //宽图
    newHeight =256.0f;
    newWidth = actualWidth / actualHeight * newHeight;
    }
    else{
    //长图
    newWidth =256.0f;
    newHeight = actualHeight / actualWidth * newWidth;
    }
    CGRect rect = CGRectMake(0.0,0.0, newWidth, newHeight);
    UIGraphicsBeginImageContext(rect.size);
    [bigImage drawInRect:rect];// scales image to rect
    image =UIGraphicsGetImageFromCurrentImageContext();
    UIGraphicsEndImageContext();
    //RETURN
    return image;
    }

压缩图片也是识别不出来二维码

@PengJiang520
Copy link

WeChat3b03634ef8c68895bff4e68077bb2e7e

@PengJiang520
Copy link

features永远为0

@wsrGitHub
Copy link

我是遇到彩色的二维码无法识别出来,然后我先把彩色图片转灰度了,可以理解变成黑白二维码图片了,然后就可以识别到了。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

8 participants