split ffmpeg recompilation to its own function