Thanks, I did change the files accordingly. The build process went without errors. Then I set OPENCV_FFMPEG_CAPTURE_OPTIONS
like this:
setenv("OPENCV_FFMPEG_CAPTURE_OPTIONS", "input_format;v4l2", 1);
and accessed the camera like this:
cv::VideoCapture d_reader(fname, cv::VideoCaptureAPIs::CAP_FFMPEG);
then unfortunately I got the following error message:
$./run /dev/video0
[video4linux2,v4l2 @ 0x564b8b62c380] No such input format: v4l2.
Did I set it correctly or does this mean the way fixing ffmpeg under Windows you suggested can’t be transferred to Ubuntu?