Problem:
I want to implement a safe version to process data into a video via OpenCV, this should work on Windows, Mac and Linux. The data has to be saved in a lossless video-codec.
Saving the file under my current setup is no problem at all, and I know that using -1
as fourcc
with videoWriter
will pop up a window.
What I can't assure is that the system has the ability to show a window at all! So the popup-menu is okay as fallback, but not as the main solution.
Question:
Is there a way to check with OpenCV if a specific video-codec is installed on the machine without running into compile problems? Something like:
if (`codec installed`)
int codec = opencvfourcc(codec)
else
int codec = -1