Learn Before
Creating Text
The putText method will start its coordinate values from the bottom left. It will require the img object, the string, the coordinate start location, the font, scale of font, color of text, thickness and an optional argument that specifies line type.
It is recommended to use cv2.LINE_AA.
font = cv2.FONT_HERSHEY_SIMPLEX img = cv2.putText(img, '1Cademy', (200, height - 10), font, 4, (0,0,0), 5, cv2.LINE_AA)
Font scale will magnify the size of the font. OpenCV provides a bunch of different fonts, and you will simply need to specify the value into a variable to keep the character count in each line low for readability, but not absolutely necessary.
0
1
Tags
Python Programming Language
Data Science
Related
Loading in Assets in OpenCV
Displaying Images
Resizing Images
Rotating Images
Conceptual Breakdown of OpenCV Image Storage
Slicing / Copying Portions of the Image
Creating Text
Project Directory Structure for OpenCV
Shape Creation in OpenCV
Writing Images (OpenCV)
Live Video Feed Processing in OpenCV
Installing and Importing OpenCV