mintware-de / flutter_barcode_reader

A flutter plugin for reading 2D barcodes and QR codes.
MIT License
628 stars 463 forks source link

[Bug] does not return any value #267

Closed Alexfuse closed 4 years ago

Alexfuse commented 4 years ago

Describe the bug On Android does not return any value, on iOS everything is fine

To Reproduce Steps to reproduce the behavior:

  1. Add this code in buuton
    BarcodeScanner.scan(options: options).then((scanVal){
         print("scanVal ${scanVal.rawContent}");
    });
  2. Add options
    options = ScanOptions(
      strings: {
        "cancel" : "Отмена",
      }
    );
  3. Click button

Logs

I/Camera-JNI(15928): number_of_cameras:2
I/Camera-JNI(15928): number_of_cameras:2
I/Camera-JNI(15928): number_of_cameras:2
D/OpenGLRenderer(15928): textureCacheSize 37748736
D/mali_winsys(15928): EGLint new_window_surface(egl_winsys_display *, void *, EGLSurface, EGLConfig, egl_winsys_surface **, egl_color_buffer_format *, EGLBoolean) returns 0x3000, win:0x8f524808
I/OpenGLRenderer(15928): queryNativeWindowStatus 0x8f524808 query=0 dataspace=0
D/OpenGLRenderer(15928): textureCacheSize 37748736
I/gralloc (15928): gralloc_register_buffer hnd=0x8f578c80, share_fd=108, share_attr_fd=109, magic=51647890, format=1, internal_format=1, byte_stride=1920, flags=4, usage=0x900, size=1843200, width=480, height=960, internalWidth=480, internalHeight=960, stride=480, base=0x851aa000, writeOwner=0, attr_base=0xffffffff, yuv_info=1, fd=-1, buf_idx=0, offset=0, min_pgsz=4096, phyaddr=0
I/gralloc (15928): gralloc_register_buffer hnd=0x8f578d40, share_fd=110, share_attr_fd=111, magic=51647890, format=1, internal_format=1, byte_stride=1920, flags=4, usage=0x900, size=1843200, width=480, height=960, internalWidth=480, internalHeight=960, stride=480, base=0x84fe8000, writeOwner=0, attr_base=0xffffffff, yuv_info=1, fd=-1, buf_idx=0, offset=0, min_pgsz=4096, phyaddr=0
I/zygote  (15928): Background concurrent copying GC freed 6054(350KB) AllocSpace objects, 6(184KB) LOS objects, 25% free, 2MB/2MB, paused 16.102ms total 158.739ms
I/zygote  (15928): Compiler allocated 4MB to compile void android.widget.TextView.<init>(android.content.Context, android.util.AttributeSet, int, int)
I/gralloc (15928): gralloc_unregister_buffer hnd=0x8f85d1c0, share_fd=94, share_attr_fd=97, magic=51647890, format=1, internal_format=1, byte_stride=1920, flags=4, usage=0x900, size=1704960, width=480, height=888, internalWidth=480, internalHeight=888, stride=480, base=0x8421d000, writeOwner=0, attr_base=0xffffffff, yuv_info=1, fd=-1, buf_idx=0, offset=0, min_pgsz=4096, phyaddr=0
I/gralloc (15928): gralloc_unregister_buffer hnd=0x88846cc0, share_fd=98, share_attr_fd=105, magic=51647890, format=1, internal_format=1, byte_stride=1920, flags=4, usage=0x900, size=1704960, width=480, height=888, internalWidth=480, internalHeight=888, stride=480, base=0x8965f000, writeOwner=0, attr_base=0xffffffff, yuv_info=1, fd=-1, buf_idx=0, offset=0, min_pgsz=4096, phyaddr=0
I/gralloc (15928): gralloc_unregister_buffer hnd=0x8f85dc40, share_fd=103, share_attr_fd=104, magic=51647890, format=1, internal_format=1, byte_stride=1920, flags=4, usage=0x900, size=1704960, width=480, height=888, internalWidth=480, internalHeight=888, stride=480, base=0x8407c000, writeOwner=0, attr_base=0xffffffff, yuv_info=1, fd=-1, buf_idx=0, offset=0, min_pgsz=4096, phyaddr=0
W/libEGL  (15928): EGLNativeWindowType 0x88842008 disconnect failed
I/gralloc (15928): gralloc_unregister_buffer hnd=0x8f85c440, share_fd=95, share_attr_fd=96, magic=51647890, format=1, internal_format=1, byte_stride=1920, flags=4, usage=0x900, size=1843200, width=480, height=960, internalWidth=480, internalHeight=960, stride=480, base=0x843be000, writeOwner=0, attr_base=0xffffffff, yuv_info=1, fd=-1, buf_idx=0, offset=0, min_pgsz=4096, phyaddr=0
W/libEGL  (15928): EGLNativeWindowType 0x93635808 disconnect failed
V/CameraPreview(15928): Cancelling autofocus
I/Camera-JNI(15928): number_of_cameras:2
I/Camera-JNI(15928): number_of_cameras:2
I/gralloc (15928): gralloc_register_buffer hnd=0x8f85b600, share_fd=91, share_attr_fd=94, magic=51647890, format=1, internal_format=1, byte_stride=1920, flags=4, usage=0x900, size=1843200, width=480, height=960, internalWidth=480, internalHeight=960, stride=480, base=0x8963e000, writeOwner=0, attr_base=0xffffffff, yuv_info=1, fd=-1, buf_idx=0, offset=0, min_pgsz=4096, phyaddr=0
I/Camera-JNI(15928): number_of_cameras:2
I/Camera-JNI(15928): number_of_cameras:2
I/Camera-JNI(15928): number_of_cameras:2
I/Camera-JNI(15928): number_of_cameras:2
I/Camera-JNI(15928): number_of_cameras:2
I/Camera-JNI(15928): number_of_cameras:2
I/Camera-JNI(15928): number_of_cameras:2
I/Camera-JNI(15928): number_of_cameras:2
I/Camera-JNI(15928): number_of_cameras:2
I/Camera-JNI(15928): number_of_cameras:2
I/Camera-JNI(15928): number_of_cameras:2
I/Camera-JNI(15928): number_of_cameras:2
I/Camera-JNI(15928): number_of_cameras:2
I/Camera-JNI(15928): number_of_cameras:2

Environment (please complete the following information):

devtronic commented 4 years ago

See the pinned issue