The function cv2.VideoWriter_fourcc
converts from a string (four chars) to an int.
For example, cv2.VideoWriter_fourcc(*'MJPG')
gives an int
for codec MJPG (whatever that is).
Does OpenCV provide the opposite function? I'd like to display the value as a string. I'd like to get a string from a fourcc int
value.
I could write the conversion myself, but I'd use something from OpenCV if it exists.