Hello C++ community. I'm a fairly new C++ programmer and I wrote a program that extracts the frames and audio from a video using ffmpeg to do data processing, but for some reason, filesystem throws a weird exception and my program doesn't shut down. Here is the relevant part of my code that is calling ffmpeg in main().
(...)
system(("ffmpeg -loglevel warning -i " + video_path + " -vf scale=" + to_string(target_frame_width) + ":" + to_string(target_frame_height) + " tmp/frames/%0d.bmp").c_str());
system(("ffmpeg -loglevel warning -i " + video_path + " tmp/audio.wav").c_str());
(...)
Expected output : frames saved as .bmp (bitmap images) named 1.bmp, 2.bmp, ... , n.bmp in the tmp/frames folder.
Can anybody tell me what's wrong with my code?