Ask Your Question

Revision history [back]

Detecting uppercase characters in waitKey()

I'm trying to read the character pressed during the waiting period in waitKey() function. It detects the character but doesn't differentiate between Upper and Lower case letters. Every time it gives the values of Lowercase letters. Please let meknow the way to detect uppercase letters.

Following is the code

 key = cv2.waitKey(0) & 0xFF
character = chr(int(key))