Skip to content

Commit 58783da

Browse files
feat: one line overlay text
1 parent 1fd27a9 commit 58783da

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

OCR/ocr.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ def main(imgPath, textOutputFileName, imageOutputFileName, showFinalImage, isVer
5252
cv2.rectangle(imageWithOverlay, (x, y),
5353
(x + width, y + height), OVERLAY_BORDER_COLOR, OVERLAY_BORDER_THICKNESS)
5454

55-
cv2.putText(imageWithOverlay, text, (x + OVERLAY_TEXT_X_SHIFT, y + OVERLAY_TEXT_Y_SHIFT),
55+
cv2.putText(imageWithOverlay, text.replace('\n', ' '), (x + OVERLAY_TEXT_X_SHIFT, y + OVERLAY_TEXT_Y_SHIFT),
5656
OVERLAY_TEXT_FONT, OVERLAY_TEXT_SCALE, OVERLAY_TEXT_COLOR, OVERLAY_TEXT_THICKNESS)
5757

5858
output.append(text)

0 commit comments

Comments
 (0)