Learn Before
Concept
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
Updated 2021-06-26
Tags
Python Programming Language
Data Science