Skip to content

rqrr not able to group capstone of image #39

@sergentbne

Description

@sergentbne

rqrr is not able to detect this QRcode

Image

here is the function that uses rqrr

fn decode_img_with_data(img_data: image::ImageBuffer<Luma<u8>, Vec<u8>>) -> Vec<u8> {
    // Prepare for detection

    let mut img = rqrr::PreparedImage::prepare(img_data);
    // Search for grids, without decoding
    let grids = img.detect_grids();

    let mut data = Vec::new();
    // Decode the grid
    let _ = grids[0].decode_to(&mut data).unwrap();
    assert!(data.len() != 0);
    return data;
}

and the results

thread 'main' panicked at src/decode_from_mp4.rs:162:18:
index out of bounds: the len is 0 but the index is 0
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

idk if other information is required, so it would be so nice of you to help me!

also! the qrcodes are always of the same size, so is there a way to just "declare" a grid instead of detecting it?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions