Skip to content

Tesseract1.doOCR method doesn't take into account the stride of the image #257

@kpentaris

Description

@kpentaris

Hello,

We recently integrated Tesseract and Tess4J and noticed that the APIs do not take into account the stride of the image which can potentially differ from the width or xsize of the image. I thought that maybe the setImage method would calculate this using the ByteBuffer.capacity() or something but checking the implementation it just assumes that the stride will be a multiple of the width and the bytes per pixel which is not always case e.g. when storing color images using 32bits but the bit depth still is 24. Is there something I'm missing or is this something to be fixed?

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