Code Monkey home page Code Monkey logo

Comments (6)

lgabardos avatar lgabardos commented on June 26, 2024

Hum... Nobody ?

I also notice that sample given with the library crash for the same reason.

Launch it (portrait mode is ok), change the phone's orientation and... Force close with "java.lang.IllegalArgumentException: Crop rectangle does not fit within image data."

from zxingfragmentlib.

mitoyarzun avatar mitoyarzun commented on June 26, 2024

Hi!

It's working now, but the preview rectangle is a little bit off. I'm working on that, but it scans :)

from zxingfragmentlib.

nijian81 avatar nijian81 commented on June 26, 2024

up stair id correct , perfect .i resolve my trubel

from zxingfragmentlib.

gzp1124 avatar gzp1124 commented on June 26, 2024

in PlanarYUVLuminanceSource 49 line
if (left + width > dataWidth || top + height > dataHeight) { throw new IllegalArgumentException("Crop rectangle does not fit within image data."); }
i change rect calculate
int cameraWidth = cameraManager.getCameraResolution().y; int cameraHeight = cameraManager.getCameraResolution().x;
to
int cameraWidth = isVertical?cameraManager.getCameraResolution().y:cameraManager.getCameraResolution().x; int cameraHeight = isVertical?cameraManager.getCameraResolution().x:cameraManager.getCameraResolution().y;
it worked. :)

from zxingfragmentlib.

dafeige8 avatar dafeige8 commented on June 26, 2024

Upstairs, your "int cameraWidth = cameraManager.getCameraResolution().y; int cameraHeight = cameraManager.getCameraResolution().x;" in which file, is customized or Zxing comes with๏ผŸ

from zxingfragmentlib.

soenkegissel avatar soenkegissel commented on June 26, 2024

I had similar issue. Using zxing-android-embedded (https://github.com/journeyapps/zxing-android-embedded).

Zxing greater version 3.3.0 bring this issue to some users of my app.

Downgrading to 3.3.0 fix it.

dependencies {
implementation('com.journeyapps:zxing-android-embedded:3.6.0')
{ transitive = false }
implementation 'com.google.zxing:core:3.3.0'
}
This version is even compatible down to API level 14.

from zxingfragmentlib.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.