Preparing search index...

    Function computeStrips

    • Splits a tall image into square strips that overlap by half a strip.

      The strip side equals the image width, so each strip has the aspect ratio ML Kit reads upright text best in. Half-strip overlap guarantees that any line shorter than half a strip lies entirely inside at least one strip.

      Parameters

      Returns OcrStrip[]

      Strips covering the whole image, a single strip when the image is not taller than wide, or no strip when a dimension is not positive